From Ulrich Hertlein, spelling corrections and a few Doxgen comments.

This commit is contained in:
Robert Osfield
2006-02-20 21:05:23 +00:00
parent b0358c698a
commit 7d5c81bf5e
12 changed files with 72 additions and 31 deletions

View File

@@ -85,11 +85,14 @@ class OSG_EXPORT CameraNode : public Transform, public CullSettings
enum TransformOrder
{
PRE_MULTIPLE,
POST_MULTIPLE
PRE_MULTIPLY,
POST_MULTIPLY
};
/** Set the transformation order for world-to-local and local-to-world transformation.*/
void setTransformOrder(TransformOrder order) { _transformOrder = order; }
/** Get the transformation order.*/
TransformOrder getTransformOrder() const { return _transformOrder; }
@@ -195,12 +198,16 @@ class OSG_EXPORT CameraNode : public Transform, public CullSettings
SEPERATE_WINDOW
};
/** Set the render target.*/
void setRenderTargetImplementation(RenderTargetImplementation impl);
/** Set the render target and fall-back that's used if the former isn't available.*/
void setRenderTargetImplementation(RenderTargetImplementation impl, RenderTargetImplementation fallback);
/** Get the render target.*/
RenderTargetImplementation getRenderTargetImplementation() const { return _renderTargetImplementation; }
/** Get the render target fallback.*/
RenderTargetImplementation getRenderTargetFallback() const { return _renderTargetFallback; }

View File

@@ -50,10 +50,10 @@ class OSGSIM_EXPORT OverlayNode : public osg::Group
void dirtyOverlayTexture();
/** Set whether the OverlayNode should update the overlay texture on every frame.*/
void setContinousUpdate(bool update) { _continousUpdate = update; }
void setContinuousUpdate(bool update) { _continuousUpdate = update; }
/** Get whether the OverlayNode should update the overlay texture on every frame.*/
bool getContinousUpdate() const { return _continousUpdate; }
bool getContinuousUpdate() const { return _continuousUpdate; }
/** Set the clear color to use when rendering the overlay subgraph.*/
@@ -66,7 +66,7 @@ class OSGSIM_EXPORT OverlayNode : public osg::Group
void setTexEnvMode(GLenum mode);
/** Get the TexEnv mode used to combine the overlay texture with the base color/texture of the OverlayNode's decorate subgraph.*/
GLenum getTexEnvMode() { return _texEnvMode; }
GLenum getTexEnvMode() const { return _texEnvMode; }
/** Set the texture unit that the texture should be assigned to.*/
void setOverlayTextureUnit(unsigned int unit);
@@ -101,7 +101,7 @@ class OSGSIM_EXPORT OverlayNode : public osg::Group
osg::ref_ptr<osg::CameraNode> _camera;
// overaly subgraph is render to a texture
// overlay subgraph is render to a texture
osg::ref_ptr<osg::Node> _overlaySubgraph;
// texgen node to generate the tex coordinates for us
@@ -116,7 +116,7 @@ class OSGSIM_EXPORT OverlayNode : public osg::Group
unsigned int _textureSizeHint;
osg::ref_ptr<osg::Texture2D> _texture;
bool _continousUpdate;
bool _continuousUpdate;
osg::Polytope _textureFrustum;
};

View File

@@ -22,6 +22,11 @@
namespace osgSim {
/** VisibilityGroup renders (traverses) it's children only when the camera is inside a specified visibility volume.
* The visibility volume is intersected with a line segment that extends from
* the current camera's eye-point along the view vector for a given segment length.
* If an intersection is detected then the node's children are traversed.
*/
class OSGSIM_EXPORT VisibilityGroup : public osg::Group
{
public :
@@ -34,19 +39,32 @@ class OSGSIM_EXPORT VisibilityGroup : public osg::Group
META_Node(osgSim, VisibilityGroup);
virtual void traverse(osg::NodeVisitor& nv);
/** Set the subgraph that is intersected for the visibility determination.*/
void setVisibilityVolume(osg::Node* node) { _visibilityVolume = node; }
/** Get the subgraph that is intersected for the visibility determination.*/
osg::Node* getVisibilityVolume() { return _visibilityVolume.get(); }
/** Get the const subgraph that is intersected for the visibility determination.*/
const osg::Node* getVisibilityVolume() const { return _visibilityVolume.get(); }
/** Set the traversal mask for the intersection testing.*/
void setVolumeIntersectionMask(osg::Node::NodeMask mask) { _volumeIntersectionMask = mask; }
/** Get the traversal mask for the intersection testing.*/
osg::Node::NodeMask getVolumeIntersectionMask() const { return _volumeIntersectionMask; }
/** Set the length of the intersection segment.
* The segments extends this many database units from the camera eye-point along the look vector.
* If this is left at zero then the diameter of the bounding sphere of the visibility volume is used.*/
void setSegmentLength(float length) { _segmentLength = length; }
/** Get the length of the intersection segment.*/
float getSegmentLength() const { return _segmentLength; }
protected :
virtual ~VisibilityGroup() {}
osg::ref_ptr<osg::Node> _visibilityVolume;

View File

@@ -28,7 +28,7 @@
namespace osgUtil {
/**
* SceneView is literally a view of a scene, encapsulating the 'camera'
* SceneView is literaly a view of a scene, encapsulating the 'camera'
* (not to be confused with Producer::Camera) (modelview+projection matrices),
* global state, lights and the scene itself. Provides
* methods for setting up the view and rendering it.
@@ -122,7 +122,7 @@ class OSGUTIL_EXPORT SceneView : public osg::Referenced, public osg::CullSetting
const osg::Vec4& getClearColor() const { return _camera->getClearColor(); }
/** Mannually set the redraw interlaced stereo stencil mask request flag to control whether to redraw the stencil buffer on the next frame.*/
/** Manually set the redraw interlaced stereo stencil mask request flag to control whether to redraw the stencil buffer on the next frame.*/
void setRedrawInterlacedStereoStencilMask(bool flag) { _redrawInterlacedStereoStencilMask = flag; }
/** Get the redraw interlaced stereo stencil mask request flag.*/
@@ -207,7 +207,7 @@ class OSGUTIL_EXPORT SceneView : public osg::Referenced, public osg::CullSetting
/** Get the const projection matrix.*/
const osg::Matrixd& getProjectionMatrix() const { return _camera->getProjectionMatrix(); }
/** Get the othographic settings of the orthographic projection matrix.
/** Get the orthographic settings of the orthographic projection matrix.
* Returns false if matrix is not an orthographic matrix, where parameter values are undefined.*/
bool getProjectionMatrixAsOrtho(double& left, double& right,
double& bottom, double& top,