AGX Dynamics
2.35.0.1
agxOSG/Node.h
Go to the documentation of this file.
1
/*
2
Copyright 2007-2022. Algoryx Simulation AB.
3
4
All AGX source code, intellectual property, documentation, sample code,
5
tutorials, scene files and technical white papers, are copyrighted, proprietary
6
and confidential material of Algoryx Simulation AB. You may not download, read,
7
store, distribute, publish, copy or otherwise disseminate, use or expose this
8
material unless having a written signed agreement with Algoryx Simulation AB, or having been
9
advised so by Algoryx Simulation AB for a time limited evaluation, or having purchased a
10
valid commercial license from Algoryx Simulation AB.
11
12
Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13
from using this software, unless otherwise stated in written agreements with
14
Algoryx Simulation AB.
15
*/
16
17
#ifndef AGXOSG_NODE_H
18
#define AGXOSG_NODE_H
19
20
#include <
agxOSG/export.h
>
21
22
#include <
agx/PushDisableWarnings.h
>
// Disabling warnings. Include agx/PopDisableWarnings.h below!
23
#include <osg/Group>
24
#include <osg/MatrixTransform>
25
#include <osg/Texture2D>
26
#include <
agxOSG/SceneDecorator.h
>
27
#include <
agx/PopDisableWarnings.h
>
// End of disabled warnings.
28
#include <
agx/Vec3.h
>
29
#include <
agx/AffineMatrix4x4.h
>
30
31
32
33
namespace
agxOSG
34
{
35
36
class
AGXOSG_EXPORT
Texture2D
:
public
agx::Referenced
{
37
public
:
38
Texture2D
(osg::Texture2D *texture) : m_texture(texture) {}
39
40
operator
osg::Texture2D* () {
return
m_texture.get(); }
41
operator
const
osg::Texture2D* ()
const
{
return
m_texture.get(); }
42
43
osg::Texture2D *
getTexture
() {
return
m_texture.get(); }
44
45
protected
:
46
virtual
~Texture2D
() {}
47
48
osg::ref_ptr<osg::Texture2D>
m_texture
;
49
};
50
51
52
class
GeometryNode
;
53
54
55
56
57
class
AGXOSG_EXPORT
Transform
:
public
osg::MatrixTransform
58
{
59
public
:
60
Transform
();
61
void
setName
(
const
std::string& name );
62
bool
addChild
( osg::Node *child );
63
bool
addChild
(
agxOSG::GeometryNode
*child );
64
void
setMatrix
(
const
agx::AffineMatrix4x4
& m);
65
void
setScale
(
const
agx::Vec3
& scale );
66
protected
:
67
virtual
~Transform
();
68
69
};
70
}
71
#endif
AffineMatrix4x4.h
PopDisableWarnings.h
PushDisableWarnings.h
SceneDecorator.h
export.h
AGXOSG_EXPORT
#define AGXOSG_EXPORT
Vec3.h
agxOSG::GeometryNode
A node that can be associated with a collision geometry so that the transformation of this node is up...
Definition:
GeometryNode.h:42
agxOSG::Texture2D
Definition:
agxOSG/Node.h:36
agxOSG::Texture2D::getTexture
osg::Texture2D * getTexture()
Definition:
agxOSG/Node.h:43
agxOSG::Texture2D::Texture2D
Texture2D(osg::Texture2D *texture)
Definition:
agxOSG/Node.h:38
agxOSG::Texture2D::m_texture
osg::ref_ptr< osg::Texture2D > m_texture
Definition:
agxOSG/Node.h:48
agxOSG::Texture2D::~Texture2D
virtual ~Texture2D()
Definition:
agxOSG/Node.h:46
agxOSG::Transform
Definition:
agxOSG/Node.h:58
agxOSG::Transform::Transform
Transform()
agxOSG::Transform::addChild
bool addChild(osg::Node *child)
agxOSG::Transform::setName
void setName(const std::string &name)
agxOSG::Transform::setMatrix
void setMatrix(const agx::AffineMatrix4x4 &m)
agxOSG::Transform::addChild
bool addChild(agxOSG::GeometryNode *child)
agxOSG::Transform::setScale
void setScale(const agx::Vec3 &scale)
agxOSG::Transform::~Transform
virtual ~Transform()
agx::AffineMatrix4x4T< Real >
agx::Referenced
Base class providing referencing counted objects.
Definition:
Referenced.h:114
agx::Vec3T< Real >
agxOSG
The agxOSG namespace provides functionality for visualizing AGX simulations with OpenSceneGraph.
include
agxOSG
Node.h
Generated on Fri Jan 20 2023 10:48:18 for AGX Dynamics by
1.9.1