VR-Forces Development_Version Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
include
vrvOsg
DtSceneGraph.h
Go to the documentation of this file.
1
/******************************************************************************
2
** Copyright (c) 2012 MAK Technologies, Inc.
3
** All rights reserved.
4
******************************************************************************/
5
9
10
#pragma once
11
12
#include <
vrvOsg/DtOsgRenderer.h
>
13
#include <cstdio>
14
namespace
makVrv
15
{
20
class
DtSceneGraph
21
{
22
public
:
24
DtSceneGraph
(
DtOsgRenderer
* renderer);
25
27
virtual
~DtSceneGraph
();
28
30
virtual
void
addNodeToRoot
(osg::Node* node,
const
DtOsgRenderer::SceneRoot
& sr,
bool
createOnAccess);
31
36
virtual
void
addRootToNode
(osg::Group* node,
const
DtOsgRenderer::SceneRoot
& sr,
bool
createOnAccess);
37
42
virtual
void
addActiveRootToNode
(osg::Group* node,
const
DtOsgRenderer::SceneRoot
& sr,
bool
createOnAccess);
43
45
virtual
void
removeNodeFromRoot
(osg::Node* node,
const
DtOsgRenderer::SceneRoot
& sr);
46
51
virtual
void
removeRootFromNode
(osg::Group* node,
const
DtOsgRenderer::SceneRoot
& sr);
52
57
virtual
void
removeActiveRootFromNode
(osg::Group* node,
const
DtOsgRenderer::SceneRoot
& sr);
58
60
virtual
void
traverseRoot
(osg::NodeVisitor& nv,
const
DtOsgRenderer::SceneRoot
& sr);
61
63
virtual
void
setSceneRootNodeMask
(
const
DtOsgRenderer::SceneRoot
& sr, osg::Node::NodeMask nodeMask);
64
66
virtual
osg::Node::NodeMask
sceneRootNodeMask
(
const
DtOsgRenderer::SceneRoot
& sr);
67
69
virtual
osg::BoundingSphere
sceneRootBound
(
const
DtOsgRenderer::SceneRoot
& sr);
70
72
virtual
osg::BoundingSphere
sceneRootListBound
(
const
DtOsgRenderer::RootList
& srList );
73
79
virtual
osg::Group*
findSceneRootChildByName
(
80
const
DtOsgRenderer::SceneRoot
& parent,
const
std::string& rootName );
81
83
virtual
void
setRenderRootAsSceneData
( osgViewer::View& view );
84
86
virtual
osg::Group*
createModelSetRoot
(
int
modelSet );
87
89
virtual
bool
matchesSceneRoot
(
const
DtOsgRenderer::SceneRoot
& sr, osg::Group* group );
90
91
protected
:
92
// Used internally by the other scene root using functions to find the
93
// correct root for adding/removing children, Getting child counts, etc.
94
virtual
osg::Group*
getContainerRoot
(
const
DtOsgRenderer::SceneRoot
& root,
bool
createOnAccess);
95
96
// Container roots may have other roots over them for doing transforms, etc.
97
// This gets the topmost root associated with that scene root, useful for
98
// traversal, nodeMask setting/getting, etc.
99
virtual
osg::Group*
getActiveRoot
(
const
DtOsgRenderer::SceneRoot
& root);
100
101
private
:
102
DtOsgRenderer
*
myRenderer
;
103
};
104
}
Document ID: Generated on Tue Mar 8 22:13:38 EST 2016 from SVN revision 162938
Copyright © 2005-2015 VT MÄK. All Rights Reserved (
www.mak.com
)