From Jannik Heller, typo fixes
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14826 16af8721-9629-0410-8352-f15c8da7e697
This commit is contained in:
parent
ab2fc1be76
commit
70b5297575
@ -599,13 +599,13 @@ int main( int argc, char **argv )
|
|||||||
|
|
||||||
// set up optimizer options
|
// set up optimizer options
|
||||||
unsigned int optimizer_options = osgUtil::Optimizer::DEFAULT_OPTIMIZATIONS;
|
unsigned int optimizer_options = osgUtil::Optimizer::DEFAULT_OPTIMIZATIONS;
|
||||||
bool relase_and_compile = false;
|
bool release_and_compile = false;
|
||||||
while (arguments.read("--release-and-compile"))
|
while (arguments.read("--release-and-compile"))
|
||||||
{
|
{
|
||||||
relase_and_compile = true;
|
release_and_compile = true;
|
||||||
}
|
}
|
||||||
seh->setReleaseAndCompileOnEachNewSlide(relase_and_compile);
|
seh->setReleaseAndCompileOnEachNewSlide(release_and_compile);
|
||||||
if (relase_and_compile)
|
if (release_and_compile)
|
||||||
{
|
{
|
||||||
// make sure that imagery stays around after being applied to textures.
|
// make sure that imagery stays around after being applied to textures.
|
||||||
viewer.getDatabasePager()->setUnrefImageDataAfterApplyPolicy(true,false);
|
viewer.getDatabasePager()->setUnrefImageDataAfterApplyPolicy(true,false);
|
||||||
|
@ -126,7 +126,7 @@ int main( int argc, char **argv )
|
|||||||
|
|
||||||
if (!loadedModel)
|
if (!loadedModel)
|
||||||
{
|
{
|
||||||
osg::notify(osg::NOTICE)<<"Please specifiy a filename and the command line"<<std::endl;
|
osg::notify(osg::NOTICE)<<"Please specify a filename on the command line"<<std::endl;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* OpenSceneGraph example, osganimate.
|
/* OpenSceneGraph example, osgkeystone.
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
* of this software and associated documentation files (the "Software"), to deal
|
* of this software and associated documentation files (the "Software"), to deal
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* OpenSceneGraph example, osganimate.
|
/* OpenSceneGraph example, osgmemorytest.
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
* of this software and associated documentation files (the "Software"), to deal
|
* of this software and associated documentation files (the "Software"), to deal
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* OpenSceneGraph example, osganimate.
|
/* OpenSceneGraph example, osgocclusionquery.
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
* of this software and associated documentation files (the "Software"), to deal
|
* of this software and associated documentation files (the "Software"), to deal
|
||||||
|
@ -365,7 +365,7 @@ void PosterPrinter::bindCameraToImage( osg::Camera* camera, int row, int col )
|
|||||||
camera->accept( iv );
|
camera->accept( iv );
|
||||||
if ( _intersector->containsIntersections() )
|
if ( _intersector->containsIntersections() )
|
||||||
{
|
{
|
||||||
// Apply a cull calback to every paged node obtained, to force the highest level displaying.
|
// Apply a cull callback to every paged node obtained, to force the highest level displaying.
|
||||||
// This will be done by the PosterVisitor, who already records all the paged nodes.
|
// This will be done by the PosterVisitor, who already records all the paged nodes.
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* OpenSceneGraph example, osganimate.
|
/* OpenSceneGraph example, oldshadercomposition.
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
* of this software and associated documentation files (the "Software"), to deal
|
* of this software and associated documentation files (the "Software"), to deal
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* O penSceneGraph example, osganimate.
|
/* OpenSceneGraph example, osgshadercomposition.
|
||||||
*
|
*
|
||||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
* of this software and associated documentation files (the "Software"), to deal
|
* of this software and associated documentation files (the "Software"), to deal
|
||||||
|
@ -126,13 +126,13 @@ class AnimateTexGenCallback : public osg::NodeCallback
|
|||||||
|
|
||||||
if (texgenNode && nv->getFrameStamp())
|
if (texgenNode && nv->getFrameStamp())
|
||||||
{
|
{
|
||||||
// we have an exisitng stateset, so lets animate it.
|
// we have an existing stateset, so lets animate it.
|
||||||
animateTexGen(texgenNode,nv->getFrameStamp()->getSimulationTime());
|
animateTexGen(texgenNode,nv->getFrameStamp()->getSimulationTime());
|
||||||
}
|
}
|
||||||
|
|
||||||
// note, callback is repsonsible for scenegraph traversal so
|
// note, callback is responsible for scenegraph traversal so
|
||||||
// should always include call the traverse(node,nv) to ensure
|
// should always include call the traverse(node,nv) to ensure
|
||||||
// that the rest of cullbacks and the scene graph are traversed.
|
// that the rest of callbacks and the scene graph are traversed.
|
||||||
traverse(node,nv);
|
traverse(node,nv);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -87,7 +87,7 @@ public:
|
|||||||
// update filter modes and text.
|
// update filter modes and text.
|
||||||
setValues();
|
setValues();
|
||||||
|
|
||||||
// advance the current positon, wrap round if required.
|
// advance the current position, wrap round if required.
|
||||||
_currPos++;
|
_currPos++;
|
||||||
if (_currPos>=_minFilterList.size()) _currPos=0;
|
if (_currPos>=_minFilterList.size()) _currPos=0;
|
||||||
|
|
||||||
@ -246,7 +246,7 @@ public:
|
|||||||
// update filter modes and text.
|
// update filter modes and text.
|
||||||
setValues();
|
setValues();
|
||||||
|
|
||||||
// advance the current positon, wrap round if required.
|
// advance the current position, wrap round if required.
|
||||||
_currPos++;
|
_currPos++;
|
||||||
if (_currPos>=_maxAnisotropyList.size()) _currPos=0;
|
if (_currPos>=_maxAnisotropyList.size()) _currPos=0;
|
||||||
|
|
||||||
@ -402,7 +402,7 @@ public:
|
|||||||
// update filter modes and text.
|
// update filter modes and text.
|
||||||
setValues();
|
setValues();
|
||||||
|
|
||||||
// advance the current positon, wrap round if required.
|
// advance the current position, wrap round if required.
|
||||||
_currPos++;
|
_currPos++;
|
||||||
if (_currPos>=_wrapList.size()) _currPos=0;
|
if (_currPos>=_wrapList.size()) _currPos=0;
|
||||||
|
|
||||||
@ -596,7 +596,7 @@ public:
|
|||||||
// update filter modes and text.
|
// update filter modes and text.
|
||||||
setValues();
|
setValues();
|
||||||
|
|
||||||
// advance the current positon, wrap round if required.
|
// advance the current position, wrap round if required.
|
||||||
_currPos++;
|
_currPos++;
|
||||||
if (_currPos>=_imageList.size()) _currPos=0;
|
if (_currPos>=_imageList.size()) _currPos=0;
|
||||||
|
|
||||||
|
@ -132,13 +132,13 @@ class UpdateStateCallback : public osg::NodeCallback
|
|||||||
osg::StateSet* stateset = node->getStateSet();
|
osg::StateSet* stateset = node->getStateSet();
|
||||||
if (stateset)
|
if (stateset)
|
||||||
{
|
{
|
||||||
// we have an exisitng stateset, so lets animate it.
|
// we have an existing stateset, so lets animate it.
|
||||||
animateState(stateset);
|
animateState(stateset);
|
||||||
}
|
}
|
||||||
|
|
||||||
// note, callback is repsonsible for scenegraph traversal so
|
// note, callback is responsible for scenegraph traversal so
|
||||||
// should always include call the traverse(node,nv) to ensure
|
// should always include call the traverse(node,nv) to ensure
|
||||||
// that the rest of cullbacks and the scene graph are traversed.
|
// that the rest of callbacks and the scene graph are traversed.
|
||||||
traverse(node,nv);
|
traverse(node,nv);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -584,7 +584,7 @@ int main(int argc, char ** argv)
|
|||||||
}
|
}
|
||||||
else if (tf.valid())
|
else if (tf.valid())
|
||||||
{
|
{
|
||||||
// No exisitng trasfer function but need to assign one
|
// No existing transfer function but need to assign one
|
||||||
OSG_NOTICE<<"Need to assign transfer function to CompositeProperty"<<std::endl;
|
OSG_NOTICE<<"Need to assign transfer function to CompositeProperty"<<std::endl;
|
||||||
InsertTransferFunctionPropertyVisitor itfpv(tf.get());
|
InsertTransferFunctionPropertyVisitor itfpv(tf.get());
|
||||||
property->accept(itfpv);
|
property->accept(itfpv);
|
||||||
|
@ -29,7 +29,7 @@ namespace OpenThreads {
|
|||||||
/**
|
/**
|
||||||
* Get the number of processors.
|
* Get the number of processors.
|
||||||
*
|
*
|
||||||
* Note, systems where no support exists for querrying the number of processors, 1 is returned.
|
* Note, systems where no support exists for querying the number of processors, 1 is returned.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
extern OPENTHREAD_EXPORT_DIRECTIVE int GetNumberOfProcessors();
|
extern OPENTHREAD_EXPORT_DIRECTIVE int GetNumberOfProcessors();
|
||||||
|
@ -212,10 +212,10 @@ class OSG_EXPORT Array : public BufferData
|
|||||||
bool _preserveDataType;
|
bool _preserveDataType;
|
||||||
};
|
};
|
||||||
|
|
||||||
/** convinience function for getting the binding of array via a ptr that may be null.*/
|
/** convenience function for getting the binding of array via a ptr that may be null.*/
|
||||||
inline osg::Array::Binding getBinding(const osg::Array* array) { return array ? array->getBinding() : osg::Array::BIND_OFF; }
|
inline osg::Array::Binding getBinding(const osg::Array* array) { return array ? array->getBinding() : osg::Array::BIND_OFF; }
|
||||||
|
|
||||||
/** convinience function for getting the binding of array via a ptr that may be null.*/
|
/** convenience function for getting the binding of array via a ptr that may be null.*/
|
||||||
inline bool getNormalize(const osg::Array* array) { return array ? array->getNormalize() : false; }
|
inline bool getNormalize(const osg::Array* array) { return array ? array->getNormalize() : false; }
|
||||||
|
|
||||||
|
|
||||||
|
@ -120,7 +120,7 @@ public:
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/** Convinience function for getting the CallbackObject associated with specificed name from an Object's UserDataContainer.*/
|
/** Convenience function for getting the CallbackObject associated with specificed name from an Object's UserDataContainer.*/
|
||||||
inline CallbackObject* getCallbackObject(osg::Object* object, const std::string& name)
|
inline CallbackObject* getCallbackObject(osg::Object* object, const std::string& name)
|
||||||
{
|
{
|
||||||
osg::UserDataContainer* udc = object->getUserDataContainer();
|
osg::UserDataContainer* udc = object->getUserDataContainer();
|
||||||
@ -128,7 +128,7 @@ inline CallbackObject* getCallbackObject(osg::Object* object, const std::string&
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/** Convinience function for getting the CallbackObject associated with specificed name from an Object's UserDataContainer.*/
|
/** Convenience function for getting the CallbackObject associated with specificed name from an Object's UserDataContainer.*/
|
||||||
inline const CallbackObject* getCallbackObject(const osg::Object* object, const std::string& name)
|
inline const CallbackObject* getCallbackObject(const osg::Object* object, const std::string& name)
|
||||||
{
|
{
|
||||||
const osg::UserDataContainer* udc = object->getUserDataContainer();
|
const osg::UserDataContainer* udc = object->getUserDataContainer();
|
||||||
|
@ -66,7 +66,7 @@ class OSG_EXPORT Camera : public Transform, public CullSettings
|
|||||||
const View* getView() const { return _view; }
|
const View* getView() const { return _view; }
|
||||||
|
|
||||||
|
|
||||||
/** Set the Stats object used for collect various frame related
|
/** Set the Stats object used to collect various frame related
|
||||||
* timing and scene graph stats. */
|
* timing and scene graph stats. */
|
||||||
void setStats(osg::Stats* stats) { _stats = stats; }
|
void setStats(osg::Stats* stats) { _stats = stats; }
|
||||||
|
|
||||||
@ -309,14 +309,14 @@ class OSG_EXPORT Camera : public Transform, public CullSettings
|
|||||||
|
|
||||||
|
|
||||||
/** Set the draw buffer used at the start of each frame draw.
|
/** Set the draw buffer used at the start of each frame draw.
|
||||||
* Note, a buffer value of GL_NONE is used to sepecify that the rendering back-end should choose the most appropriate buffer.*/
|
* Note, a buffer value of GL_NONE is used to specify that the rendering back-end should choose the most appropriate buffer.*/
|
||||||
void setDrawBuffer(GLenum buffer) { _drawBuffer = buffer; applyMaskAction( DRAW_BUFFER ); }
|
void setDrawBuffer(GLenum buffer) { _drawBuffer = buffer; applyMaskAction( DRAW_BUFFER ); }
|
||||||
|
|
||||||
/** Get the draw buffer used at the start of each frame draw. */
|
/** Get the draw buffer used at the start of each frame draw. */
|
||||||
GLenum getDrawBuffer() const { return _drawBuffer; }
|
GLenum getDrawBuffer() const { return _drawBuffer; }
|
||||||
|
|
||||||
/** Set the read buffer for any required copy operations to use.
|
/** Set the read buffer for any required copy operations to use.
|
||||||
* Note, a buffer value of GL_NONE is used to sepecify that the rendering back-end should choose the most appropriate buffer.*/
|
* Note, a buffer value of GL_NONE is used to specify that the rendering back-end should choose the most appropriate buffer.*/
|
||||||
void setReadBuffer(GLenum buffer) { _readBuffer = buffer; applyMaskAction( READ_BUFFER ); }
|
void setReadBuffer(GLenum buffer) { _readBuffer = buffer; applyMaskAction( READ_BUFFER ); }
|
||||||
|
|
||||||
/** Get the read buffer for any required copy operations to use. */
|
/** Get the read buffer for any required copy operations to use. */
|
||||||
@ -447,23 +447,23 @@ class OSG_EXPORT Camera : public Transform, public CullSettings
|
|||||||
Implicit buffers are automatically substituted when user have not attached such buffer.
|
Implicit buffers are automatically substituted when user have not attached such buffer.
|
||||||
|
|
||||||
Camera may set up two FBOs: primary Render FBO and secondary Resolve FBO for multisample usage.
|
Camera may set up two FBOs: primary Render FBO and secondary Resolve FBO for multisample usage.
|
||||||
So in practive we have two masks defined for the Camera:
|
So in practice we have two masks defined for the Camera:
|
||||||
implicitBufferAttachmentRenderMask
|
implicitBufferAttachmentRenderMask
|
||||||
implicitBufferAttachmentResolveMask
|
implicitBufferAttachmentResolveMask
|
||||||
They can be set together by setImplicitBufferAttachmentMask method, or separately
|
They can be set together by setImplicitBufferAttachmentMask method, or separately
|
||||||
by setImplicitBufferAttachmentRenderMask and setImplicitBufferAttachmentResolveMask.
|
by setImplicitBufferAttachmentRenderMask and setImplicitBufferAttachmentResolveMask.
|
||||||
|
|
||||||
Camera defaults are USE_DISPLAY_SETTINGS_MASK which means that by default
|
Camera defaults are USE_DISPLAY_SETTINGS_MASK which means that by default
|
||||||
Camera chooses to substitue buffer attachments as defined by DisplaySettings.
|
Camera chooses to substitute buffer attachments as defined by DisplaySettings.
|
||||||
|
|
||||||
Usually DisplaySettings implicit buffer attachment selection defaults to: DEPTH and COLOR
|
Usually DisplaySettings implicit buffer attachment selection defaults to: DEPTH and COLOR
|
||||||
for both primary (Render) FBO and seconday Multisample (Resolve) FBO
|
for both primary (Render) FBO and seconday Multisample (Resolve) FBO
|
||||||
ie: IMPLICT_DEPTH_BUFFER_ATTACHMENT | IMPLICIT_COLOR_BUFFER_ATTACHMENT
|
ie: IMPLICIT_DEPTH_BUFFER_ATTACHMENT | IMPLICIT_COLOR_BUFFER_ATTACHMENT
|
||||||
|
|
||||||
If these masks are not changed and user did not attach depth buffer and/or color buffer
|
If these masks are not changed and user did not attach depth buffer and/or color buffer
|
||||||
to Camera, then OSG implicitly substitues these buffers.
|
to Camera, then OSG implicitly substitutes these buffers.
|
||||||
By default it does not implicitly allocate a stencil buffer.
|
By default it does not implicitly allocate a stencil buffer.
|
||||||
Use implicti buffer attachment masks to override default behavior:
|
Use implicit buffer attachment masks to override default behavior:
|
||||||
to turn off DEPTH or COLOR buffer substitution or to enforce STENCIL buffer substitution.
|
to turn off DEPTH or COLOR buffer substitution or to enforce STENCIL buffer substitution.
|
||||||
|
|
||||||
Note that both values are ignored if not using FBO.
|
Note that both values are ignored if not using FBO.
|
||||||
@ -496,7 +496,7 @@ class OSG_EXPORT Camera : public Transform, public CullSettings
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Get mask selecting implict buffer attachments for Camera primary FBO
|
Get mask selecting implicit buffer attachments for Camera primary FBO
|
||||||
if effectiveMask parameter is set, method follows USE_DISPLAY_SETTINGS_MASK dependence and returns effective mask
|
if effectiveMask parameter is set, method follows USE_DISPLAY_SETTINGS_MASK dependence and returns effective mask
|
||||||
if effectiveMask parameter is reset, method returns nominal mask set by the Camera
|
if effectiveMask parameter is reset, method returns nominal mask set by the Camera
|
||||||
*/
|
*/
|
||||||
@ -514,7 +514,7 @@ class OSG_EXPORT Camera : public Transform, public CullSettings
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Get mask selecting implict buffer attachments for Camera secondary MULTISAMPLE FBO
|
Get mask selecting implicit buffer attachments for Camera secondary MULTISAMPLE FBO
|
||||||
if effectiveMask parameter is set, method follows USE_DISPLAY_SETTINGS_MASK dependence and returns effective mask
|
if effectiveMask parameter is set, method follows USE_DISPLAY_SETTINGS_MASK dependence and returns effective mask
|
||||||
if effectiveMask parameter is reset, method returns nominal mask set by the Camera
|
if effectiveMask parameter is reset, method returns nominal mask set by the Camera
|
||||||
*/
|
*/
|
||||||
@ -710,7 +710,7 @@ class OSG_EXPORT Camera : public Transform, public CullSettings
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/** Functor to assist with ordering camers in the order they should be rendered in.*/
|
/** Functor to assist with ordering cameras in the order they should be rendered in.*/
|
||||||
struct CameraRenderOrderSortOp
|
struct CameraRenderOrderSortOp
|
||||||
{
|
{
|
||||||
inline bool operator() (const Camera* lhs,const Camera* rhs) const
|
inline bool operator() (const Camera* lhs,const Camera* rhs) const
|
||||||
|
@ -218,7 +218,7 @@ class OSG_EXPORT CullSettings
|
|||||||
float getLODScale() const { return _LODScale; }
|
float getLODScale() const { return _LODScale; }
|
||||||
|
|
||||||
/** Threshold at which small features are culled.
|
/** Threshold at which small features are culled.
|
||||||
\param value Boulding volume size in screen space. Default is 2.0. */
|
\param value Bounding volume size in screen space. Default is 2.0. */
|
||||||
void setSmallFeatureCullingPixelSize(float value) { _smallFeatureCullingPixelSize=value; applyMaskAction(SMALL_FEATURE_CULLING_PIXEL_SIZE); }
|
void setSmallFeatureCullingPixelSize(float value) { _smallFeatureCullingPixelSize=value; applyMaskAction(SMALL_FEATURE_CULLING_PIXEL_SIZE); }
|
||||||
|
|
||||||
/** Get the Small Feature Culling Pixel Size.*/
|
/** Get the Small Feature Culling Pixel Size.*/
|
||||||
|
@ -162,7 +162,7 @@ class OSG_EXPORT CullingSet : public Referenced
|
|||||||
const Vec4& getPixelSizeVector() const { return _pixelSizeVector; }
|
const Vec4& getPixelSizeVector() const { return _pixelSizeVector; }
|
||||||
|
|
||||||
/** Threshold at which small features are culled.
|
/** Threshold at which small features are culled.
|
||||||
\param value Boulding volume size in screen space. Default is 2.0. */
|
\param value Bounding volume size in screen space. Default is 2.0. */
|
||||||
void setSmallFeatureCullingPixelSize(float value) { _smallFeatureCullingPixelSize=value; }
|
void setSmallFeatureCullingPixelSize(float value) { _smallFeatureCullingPixelSize=value; }
|
||||||
|
|
||||||
float& getSmallFeatureCullingPixelSize() { return _smallFeatureCullingPixelSize; }
|
float& getSmallFeatureCullingPixelSize() { return _smallFeatureCullingPixelSize; }
|
||||||
|
@ -217,8 +217,8 @@ class OSG_EXPORT DisplaySettings : public osg::Referenced
|
|||||||
For more info: See description of Camera::setImplicitBufferAttachment method
|
For more info: See description of Camera::setImplicitBufferAttachment method
|
||||||
|
|
||||||
DisplaySettings implicit buffer attachment selection defaults to: DEPTH and COLOR
|
DisplaySettings implicit buffer attachment selection defaults to: DEPTH and COLOR
|
||||||
for both primary (Render) FBO and seconday Multisample (Resolve) FBO
|
for both primary (Render) FBO and secondary Multisample (Resolve) FBO
|
||||||
ie: IMPLICT_DEPTH_BUFFER_ATTACHMENT | IMPLICIT_COLOR_BUFFER_ATTACHMENT
|
ie: IMPLICIT_DEPTH_BUFFER_ATTACHMENT | IMPLICIT_COLOR_BUFFER_ATTACHMENT
|
||||||
**/
|
**/
|
||||||
enum ImplicitBufferAttachment
|
enum ImplicitBufferAttachment
|
||||||
{
|
{
|
||||||
@ -246,10 +246,10 @@ class OSG_EXPORT DisplaySettings : public osg::Referenced
|
|||||||
_implicitBufferAttachmentResolveMask = implicitBufferAttachmentResolveMask;
|
_implicitBufferAttachmentResolveMask = implicitBufferAttachmentResolveMask;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Get mask selecting default implict buffer attachments for Cameras primary FBOs. */
|
/** Get mask selecting default implicit buffer attachments for Cameras primary FBOs. */
|
||||||
ImplicitBufferAttachmentMask getImplicitBufferAttachmentRenderMask() const { return _implicitBufferAttachmentRenderMask; }
|
ImplicitBufferAttachmentMask getImplicitBufferAttachmentRenderMask() const { return _implicitBufferAttachmentRenderMask; }
|
||||||
|
|
||||||
/** Get mask selecting default implict buffer attachments for Cameras secondary MULTISAMPLE FBOs. */
|
/** Get mask selecting default implicit buffer attachments for Cameras secondary MULTISAMPLE FBOs. */
|
||||||
ImplicitBufferAttachmentMask getImplicitBufferAttachmentResolveMask() const { return _implicitBufferAttachmentResolveMask;}
|
ImplicitBufferAttachmentMask getImplicitBufferAttachmentResolveMask() const { return _implicitBufferAttachmentResolveMask;}
|
||||||
|
|
||||||
enum SwapMethod
|
enum SwapMethod
|
||||||
|
@ -70,10 +70,10 @@ extern OSG_EXPORT GLint gluBuild2DMipmaps (GLenum target, GLint internalFormat,
|
|||||||
|
|
||||||
typedef void (GL_APIENTRY * GLTexImage3DProc) ( GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
|
typedef void (GL_APIENTRY * GLTexImage3DProc) ( GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum type, const GLvoid *pixels);
|
||||||
|
|
||||||
/** Small variation on normal gluBuild3DMipmapLevels as we pass in the function pointer to glTexImage3D rather than rely on GLU style querry for this functon pointer.*/
|
/** Small variation on normal gluBuild3DMipmapLevels as we pass in the function pointer to glTexImage3D rather than rely on GLU style query for this function pointer.*/
|
||||||
extern OSG_EXPORT GLint gluBuild3DMipmapLevels (GLTexImage3DProc glTextImage3DProc, GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLint level, GLint base, GLint max, const void *data);
|
extern OSG_EXPORT GLint gluBuild3DMipmapLevels (GLTexImage3DProc glTextImage3DProc, GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLint level, GLint base, GLint max, const void *data);
|
||||||
|
|
||||||
/** Small variation on normal gluBuild3DMipmapLevels as we pass in the function pointer to glTexImage3D rather than rely on GLU style querry for this functon pointer.*/
|
/** Small variation on normal gluBuild3DMipmapLevels as we pass in the function pointer to glTexImage3D rather than rely on GLU style query for this function pointer.*/
|
||||||
extern OSG_EXPORT GLint gluBuild3DMipmaps (GLTexImage3DProc glTextImage3DProc, GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *data);
|
extern OSG_EXPORT GLint gluBuild3DMipmaps (GLTexImage3DProc glTextImage3DProc, GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *data);
|
||||||
|
|
||||||
/* ErrorCode */
|
/* ErrorCode */
|
||||||
|
@ -421,7 +421,7 @@ class OSG_EXPORT GraphicsContext : public Object
|
|||||||
/** Get the const swap callback which overrides the GraphicsContext::swapBuffersImplementation().*/
|
/** Get the const swap callback which overrides the GraphicsContext::swapBuffersImplementation().*/
|
||||||
const SwapCallback* getSwapCallback() const { return _swapCallback.get(); }
|
const SwapCallback* getSwapCallback() const { return _swapCallback.get(); }
|
||||||
|
|
||||||
/** convinience method for handling whether to call swapbuffers callback or the standard context swapBuffersImplementation.
|
/** Convenience method for handling whether to call swapbuffers callback or the standard context swapBuffersImplementation.
|
||||||
* swapBuffersCallbackOrImplemenation() is called by swapBuffers() and osg::SwapBuffersOperation, end users should normally
|
* swapBuffersCallbackOrImplemenation() is called by swapBuffers() and osg::SwapBuffersOperation, end users should normally
|
||||||
* call swapBuffers() rather than swapBuffersCallbackOrImplemenation(). */
|
* call swapBuffers() rather than swapBuffersCallbackOrImplemenation(). */
|
||||||
void swapBuffersCallbackOrImplemenation()
|
void swapBuffersCallbackOrImplemenation()
|
||||||
|
@ -388,7 +388,7 @@ class OSG_EXPORT Image : public BufferData
|
|||||||
/** Flip the image vertically, around t dimension. */
|
/** Flip the image vertically, around t dimension. */
|
||||||
void flipVertical();
|
void flipVertical();
|
||||||
|
|
||||||
/** Flip the image around the r dimension. Only relevent for 3D textures. */
|
/** Flip the image around the r dimension. Only relevant for 3D textures. */
|
||||||
void flipDepth();
|
void flipDepth();
|
||||||
|
|
||||||
/** Ensure image dimensions are a power of two.
|
/** Ensure image dimensions are a power of two.
|
||||||
|
@ -69,7 +69,7 @@ void readImage(const osg::Image* image, O& operation)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Convinience method for making it easy to cast all pixel channels types to a unit float RGBA form.*/
|
/** Convenience method for making it easy to cast all pixel channels types to a unit float RGBA form.*/
|
||||||
struct CastAndScaleToFloatOperation
|
struct CastAndScaleToFloatOperation
|
||||||
{
|
{
|
||||||
float cast(char v) { return static_cast<float>(v)*(1.0f/128.0f); }
|
float cast(char v) { return static_cast<float>(v)*(1.0f/128.0f); }
|
||||||
|
@ -137,7 +137,7 @@ class OSG_EXPORT Object : public Referenced
|
|||||||
/** get the const UserDataContainer attached to this object.*/
|
/** get the const UserDataContainer attached to this object.*/
|
||||||
const osg::UserDataContainer* getUserDataContainer() const { return _userDataContainer; }
|
const osg::UserDataContainer* getUserDataContainer() const { return _userDataContainer; }
|
||||||
|
|
||||||
/** Convinience method that returns the UserDataContainer, and if one doesn't already exist creates and assigns
|
/** Convenience method that returns the UserDataContainer, and if one doesn't already exist creates and assigns
|
||||||
* a DefaultUserDataContainer to the Object and then return this new UserDataContainer.*/
|
* a DefaultUserDataContainer to the Object and then return this new UserDataContainer.*/
|
||||||
osg::UserDataContainer* getOrCreateUserDataContainer();
|
osg::UserDataContainer* getOrCreateUserDataContainer();
|
||||||
|
|
||||||
@ -158,12 +158,12 @@ class OSG_EXPORT Object : public Referenced
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
/** Convinience method that casts the named UserObject to osg::TemplateValueObject<T> and gets the value.
|
/** Convenience method that casts the named UserObject to osg::TemplateValueObject<T> and gets the value.
|
||||||
* To use this template method you need to include the osg/ValueObject header.*/
|
* To use this template method you need to include the osg/ValueObject header.*/
|
||||||
template<typename T>
|
template<typename T>
|
||||||
bool getUserValue(const std::string& name, T& value) const;
|
bool getUserValue(const std::string& name, T& value) const;
|
||||||
|
|
||||||
/** Convinience method that creates the osg::TemplateValueObject<T> to store the
|
/** Convenience method that creates the osg::TemplateValueObject<T> to store the
|
||||||
* specified value and adds it as a named UserObject.
|
* specified value and adds it as a named UserObject.
|
||||||
* To use this template method you need to include the osg/ValueObject header. */
|
* To use this template method you need to include the osg/ValueObject header. */
|
||||||
template<typename T>
|
template<typename T>
|
||||||
|
@ -200,7 +200,7 @@ class OSG_EXPORT State : public Referenced
|
|||||||
/** Get the unform list in which to inject any uniforms that StateAttribute::apply(State&) methods provide.*/
|
/** Get the unform list in which to inject any uniforms that StateAttribute::apply(State&) methods provide.*/
|
||||||
StateSet::UniformList& getCurrentShaderCompositionUniformList() { return _currentShaderCompositionUniformList; }
|
StateSet::UniformList& getCurrentShaderCompositionUniformList() { return _currentShaderCompositionUniformList; }
|
||||||
|
|
||||||
/** Convinience method for StateAttribute:::apply(State&) methods to pass on their uniforms to osg::State so it can apply them at the appropriate point.*/
|
/** Convenience method for StateAttribute:::apply(State&) methods to pass on their uniforms to osg::State so it can apply them at the appropriate point.*/
|
||||||
void applyShaderCompositionUniform(const osg::Uniform* uniform, StateAttribute::OverrideValue value=StateAttribute::ON)
|
void applyShaderCompositionUniform(const osg::Uniform* uniform, StateAttribute::OverrideValue value=StateAttribute::ON)
|
||||||
{
|
{
|
||||||
StateSet::RefUniformPair& up = _currentShaderCompositionUniformList[uniform->getName()];
|
StateSet::RefUniformPair& up = _currentShaderCompositionUniformList[uniform->getName()];
|
||||||
|
@ -188,14 +188,14 @@ protected:
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/** Convinience function for getting the User Object associated with specificed name from an Object's UserDataContainer.*/
|
/** Convenience function for getting the User Object associated with specificed name from an Object's UserDataContainer.*/
|
||||||
inline Object* getUserObject(osg::Object* object, const std::string& name)
|
inline Object* getUserObject(osg::Object* object, const std::string& name)
|
||||||
{
|
{
|
||||||
osg::UserDataContainer* udc = object->getUserDataContainer();
|
osg::UserDataContainer* udc = object->getUserDataContainer();
|
||||||
return udc ? udc->getUserObject(name) : 0;
|
return udc ? udc->getUserObject(name) : 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Convinience function for getting the User Object associated with specificed name from an Object's UserDataContainer.*/
|
/** Convenience function for getting the User Object associated with specificed name from an Object's UserDataContainer.*/
|
||||||
inline const Object* getUserObject(const osg::Object* object, const std::string& name)
|
inline const Object* getUserObject(const osg::Object* object, const std::string& name)
|
||||||
{
|
{
|
||||||
const osg::UserDataContainer* udc = object->getUserDataContainer();
|
const osg::UserDataContainer* udc = object->getUserDataContainer();
|
||||||
|
@ -40,7 +40,7 @@ class OSG_EXPORT View : public virtual osg::Object
|
|||||||
virtual void take(View& rhs);
|
virtual void take(View& rhs);
|
||||||
|
|
||||||
|
|
||||||
/** Set the Stats object used for collect various frame related timing and scene graph stats.*/
|
/** Set the Stats object used to collect various frame related timing and scene graph stats.*/
|
||||||
void setStats(osg::Stats* stats) { _stats = stats; }
|
void setStats(osg::Stats* stats) { _stats = stats; }
|
||||||
|
|
||||||
/** Get the Viewers Stats object.*/
|
/** Get the Viewers Stats object.*/
|
||||||
|
@ -116,7 +116,7 @@ class PropertyInputIterator;
|
|||||||
|
|
||||||
|
|
||||||
/** ClassInterface provides a general means of checking for supported properties of classes, and getting/setting thoses properties.
|
/** ClassInterface provides a general means of checking for supported properties of classes, and getting/setting thoses properties.
|
||||||
Uses the osgDB serializers to do the actual object querry/get/set.
|
Uses the osgDB serializers to do the actual object query/get/set.
|
||||||
*/
|
*/
|
||||||
class OSGDB_EXPORT ClassInterface
|
class OSGDB_EXPORT ClassInterface
|
||||||
{
|
{
|
||||||
|
@ -75,7 +75,7 @@ class OSGMANIPULATOR_EXPORT Scale2DDragger : public Dragger
|
|||||||
inline osg::Node* getBottomRightHandleNode() { return _bottomRightHandleNode.get(); }
|
inline osg::Node* getBottomRightHandleNode() { return _bottomRightHandleNode.get(); }
|
||||||
inline const osg::Node* getBottomRightHandleNode() const { return _bottomRightHandleNode.get(); }
|
inline const osg::Node* getBottomRightHandleNode() const { return _bottomRightHandleNode.get(); }
|
||||||
|
|
||||||
/** Set/Get the handle nodes postion for dragger. */
|
/** Set/Get the handle nodes position for dragger. */
|
||||||
inline void setTopLeftHandlePosition(const osg::Vec2d& pos) { _topLeftHandlePosition = pos; }
|
inline void setTopLeftHandlePosition(const osg::Vec2d& pos) { _topLeftHandlePosition = pos; }
|
||||||
const osg::Vec2d& getTopLeftHandlePosition() const { return _topLeftHandlePosition; }
|
const osg::Vec2d& getTopLeftHandlePosition() const { return _topLeftHandlePosition; }
|
||||||
inline void setBottomLeftHandlePosition(const osg::Vec2d& pos) { _bottomLeftHandlePosition = pos; }
|
inline void setBottomLeftHandlePosition(const osg::Vec2d& pos) { _bottomLeftHandlePosition = pos; }
|
||||||
|
@ -35,7 +35,7 @@ public:
|
|||||||
|
|
||||||
META_Object(osgPresentation, PropertyManager)
|
META_Object(osgPresentation, PropertyManager)
|
||||||
|
|
||||||
/** Convinience method that casts the named UserObject to osg::TemplateValueObject<T> and gets the value.
|
/** Convenience method that casts the named UserObject to osg::TemplateValueObject<T> and gets the value.
|
||||||
* To use this template method you need to include the osg/ValueObject header.*/
|
* To use this template method you need to include the osg/ValueObject header.*/
|
||||||
template<typename T>
|
template<typename T>
|
||||||
bool getProperty(const std::string& name, T& value) const
|
bool getProperty(const std::string& name, T& value) const
|
||||||
@ -44,7 +44,7 @@ public:
|
|||||||
return getUserValue(name, value);
|
return getUserValue(name, value);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Convinience method that creates the osg::TemplateValueObject<T> to store the
|
/** Convenience method that creates the osg::TemplateValueObject<T> to store the
|
||||||
* specified value and adds it as a named UserObject.
|
* specified value and adds it as a named UserObject.
|
||||||
* To use this template method you need to include the osg/ValueObject header. */
|
* To use this template method you need to include the osg/ValueObject header. */
|
||||||
template<typename T>
|
template<typename T>
|
||||||
|
@ -93,7 +93,7 @@ class OSGSIM_EXPORT LightPointNode : public osg::Node
|
|||||||
|
|
||||||
~LightPointNode() {}
|
~LightPointNode() {}
|
||||||
|
|
||||||
// used to cache the bouding box of the lightpoints as a tighter
|
// used to cache the bounding box of the lightpoints as a tighter
|
||||||
// view frustum check.
|
// view frustum check.
|
||||||
mutable osg::BoundingBox _bbox;
|
mutable osg::BoundingBox _bbox;
|
||||||
|
|
||||||
|
@ -200,7 +200,7 @@ class OSGUTIL_EXPORT IntersectVisitor : public osg::NodeVisitor
|
|||||||
osg::Vec3 _pseudoEyePoint;
|
osg::Vec3 _pseudoEyePoint;
|
||||||
};
|
};
|
||||||
|
|
||||||
/** Picking intersection visitor specialises the IntersectVistor to allow more convinient handling of mouse picking.*/
|
/** Picking intersection visitor specialises the IntersectVistor to allow more convenient handling of mouse picking.*/
|
||||||
class OSGUTIL_EXPORT PickVisitor : public osgUtil::IntersectVisitor
|
class OSGUTIL_EXPORT PickVisitor : public osgUtil::IntersectVisitor
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
@ -28,7 +28,7 @@ class IntersectionVisitor;
|
|||||||
|
|
||||||
/** Pure virtual base class for implementing custom intersection technique.
|
/** Pure virtual base class for implementing custom intersection technique.
|
||||||
* To implement a specific intersection technique on must override all
|
* To implement a specific intersection technique on must override all
|
||||||
* the pure virtue methods, concrete examples of how to do this can be seen in
|
* the pure virtual methods, concrete examples of how to do this can be seen in
|
||||||
* the LineSegmentIntersector. */
|
* the LineSegmentIntersector. */
|
||||||
class Intersector : public osg::Referenced
|
class Intersector : public osg::Referenced
|
||||||
{
|
{
|
||||||
@ -146,7 +146,7 @@ class OSGUTIL_EXPORT IntersectorGroup : public Intersector
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/** InteresectionVisitor is used to testing for intersections with the scene, traversing the scene using generic osgUtil::Intersector's to test against the scene.
|
/** IntersectionVisitor is used to testing for intersections with the scene, traversing the scene using generic osgUtil::Intersector's to test against the scene.
|
||||||
* To implement different types of intersection techniques, one implements custom versions of the osgUtil::Intersector, and then
|
* To implement different types of intersection techniques, one implements custom versions of the osgUtil::Intersector, and then
|
||||||
* pass the constructed intersector to the IntersectionVisitor.*/
|
* pass the constructed intersector to the IntersectionVisitor.*/
|
||||||
class OSGUTIL_EXPORT IntersectionVisitor : public osg::NodeVisitor
|
class OSGUTIL_EXPORT IntersectionVisitor : public osg::NodeVisitor
|
||||||
|
@ -65,7 +65,7 @@ class OSGUTIL_EXPORT LineSegmentIntersector : public Intersector
|
|||||||
const osg::Vec3& getLocalIntersectNormal() const { return localIntersectionNormal; }
|
const osg::Vec3& getLocalIntersectNormal() const { return localIntersectionNormal; }
|
||||||
osg::Vec3 getWorldIntersectNormal() const { return matrix.valid() ? osg::Matrix::transform3x3(osg::Matrix::inverse(*matrix),localIntersectionNormal) : localIntersectionNormal; }
|
osg::Vec3 getWorldIntersectNormal() const { return matrix.valid() ? osg::Matrix::transform3x3(osg::Matrix::inverse(*matrix),localIntersectionNormal) : localIntersectionNormal; }
|
||||||
|
|
||||||
/** convinience function for mapping the intersection point to any textures assigned to the objects intersected.
|
/** Convenience function for mapping the intersection point to any textures assigned to the objects intersected.
|
||||||
* Returns the Texture pointer and texture coords of object hit when a texture is available on the object, returns NULL otherwise.*/
|
* Returns the Texture pointer and texture coords of object hit when a texture is available on the object, returns NULL otherwise.*/
|
||||||
osg::Texture* getTextureLookUp(osg::Vec3& tc) const;
|
osg::Texture* getTextureLookUp(osg::Vec3& tc) const;
|
||||||
|
|
||||||
|
@ -11,8 +11,8 @@
|
|||||||
* OpenSceneGraph Public License for more details.
|
* OpenSceneGraph Public License for more details.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef OSGUTIL_POSTIONALSTATECONTIANER
|
#ifndef OSGUTIL_POSITIONALSTATECONTAINER
|
||||||
#define OSGUTIL_POSTIONALSTATECONTIANER 1
|
#define OSGUTIL_POSITIONALSTATECONTAINER 1
|
||||||
|
|
||||||
#include <osg/Object>
|
#include <osg/Object>
|
||||||
#include <osg/Light>
|
#include <osg/Light>
|
||||||
|
@ -77,7 +77,7 @@ class OSGUTIL_EXPORT RayIntersector : public Intersector
|
|||||||
const osg::Vec3& getLocalIntersectNormal() const { return localIntersectionNormal; }
|
const osg::Vec3& getLocalIntersectNormal() const { return localIntersectionNormal; }
|
||||||
osg::Vec3 getWorldIntersectNormal() const { return matrix.valid() ? osg::Matrix::transform3x3(osg::Matrix::inverse(*matrix),localIntersectionNormal) : localIntersectionNormal; }
|
osg::Vec3 getWorldIntersectNormal() const { return matrix.valid() ? osg::Matrix::transform3x3(osg::Matrix::inverse(*matrix),localIntersectionNormal) : localIntersectionNormal; }
|
||||||
|
|
||||||
/** convinience function for mapping the intersection point to any textures assigned to the objects intersected.
|
/** Convenience function for mapping the intersection point to any textures assigned to the objects intersected.
|
||||||
* Returns the Texture pointer and texture coords of object hit when a texture is available on the object, returns NULL otherwise.*/
|
* Returns the Texture pointer and texture coords of object hit when a texture is available on the object, returns NULL otherwise.*/
|
||||||
osg::Texture* getTextureLookUp(osg::Vec3& tc) const;
|
osg::Texture* getTextureLookUp(osg::Vec3& tc) const;
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@
|
|||||||
namespace osgUtil {
|
namespace osgUtil {
|
||||||
|
|
||||||
/** A tri stripping visitor for converting Geometry surface primitives into tri strips.
|
/** A tri stripping visitor for converting Geometry surface primitives into tri strips.
|
||||||
* The current implemention is based upon Tanguy Fautre's triangulation code.
|
* The current implementation is based upon Tanguy Fautre's triangulation code.
|
||||||
*/
|
*/
|
||||||
class OSGUTIL_EXPORT TriStripVisitor : public BaseOptimizerVisitor
|
class OSGUTIL_EXPORT TriStripVisitor : public BaseOptimizerVisitor
|
||||||
{
|
{
|
||||||
|
@ -40,7 +40,7 @@ class OSGVIEWER_EXPORT CompositeViewer : public ViewerBase
|
|||||||
bool readConfiguration(const std::string& filename);
|
bool readConfiguration(const std::string& filename);
|
||||||
|
|
||||||
|
|
||||||
/** Set the Stats object used for collect various frame related timing and scene graph stats.*/
|
/** Set the Stats object used to collect various frame related timing and scene graph stats.*/
|
||||||
virtual void setViewerStats(osg::Stats* stats) { _stats = stats; }
|
virtual void setViewerStats(osg::Stats* stats) { _stats = stats; }
|
||||||
|
|
||||||
/** Get the Viewers Stats object.*/
|
/** Get the Viewers Stats object.*/
|
||||||
|
@ -34,8 +34,8 @@ class View;
|
|||||||
|
|
||||||
|
|
||||||
/** Base class for providing Windowing API agnostic access to creating and managing graphics window and events.
|
/** Base class for providing Windowing API agnostic access to creating and managing graphics window and events.
|
||||||
* Note, the GraphicsWindow is subclassed from osg::GraphicsContext, and to provide an implemention you'll need to implement its
|
* Note, the GraphicsWindow is subclassed from osg::GraphicsContext, and to provide an implementation you'll need to implement its
|
||||||
* range of pure virtual functions, you'll find these all have naming convention methodNameImplemention(..).
|
* range of pure virtual functions, you'll find these all have naming convention methodNameImplementation(..).
|
||||||
* GraphicsWindow adds the event queue on top of the GraphicsContext, thereby adding a mechanism for adapting Windowing events
|
* GraphicsWindow adds the event queue on top of the GraphicsContext, thereby adding a mechanism for adapting Windowing events
|
||||||
* as well as basics graphics context work, you should wire up custom GraphicsWindowImplementation to push their events through
|
* as well as basics graphics context work, you should wire up custom GraphicsWindowImplementation to push their events through
|
||||||
* into the EventQueue. */
|
* into the EventQueue. */
|
||||||
|
@ -72,7 +72,7 @@ public:
|
|||||||
/** Write the file specified by the "filename" user value field. Return true if file successfully written. */
|
/** Write the file specified by the "filename" user value field. Return true if file successfully written. */
|
||||||
bool writeToFile();
|
bool writeToFile();
|
||||||
|
|
||||||
/** convinience function that loads and assigns any keystone files specified in the DisplaySettings::KeystoneFileNames list, return true if Keystone's assigned to DisplaySettings.*/
|
/** Convenience function that loads and assigns any keystone files specified in the DisplaySettings::KeystoneFileNames list, return true if Keystone's assigned to DisplaySettings.*/
|
||||||
static bool loadKeystoneFiles(osg::DisplaySettings* ds);
|
static bool loadKeystoneFiles(osg::DisplaySettings* ds);
|
||||||
|
|
||||||
|
|
||||||
|
@ -47,7 +47,7 @@ class OSGVIEWER_EXPORT ViewConfig : public osg::Object
|
|||||||
/** configure method that is overridden by Config subclasses.*/
|
/** configure method that is overridden by Config subclasses.*/
|
||||||
virtual void configure(osgViewer::View& /*view*/) const {}
|
virtual void configure(osgViewer::View& /*view*/) const {}
|
||||||
|
|
||||||
/** convinience method for getting the relavent display settings to use.*/
|
/** convenience method for getting the relavent display settings to use.*/
|
||||||
virtual osg::DisplaySettings* getActiveDisplaySetting(osgViewer::View& view) const;
|
virtual osg::DisplaySettings* getActiveDisplaySetting(osgViewer::View& view) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -42,7 +42,7 @@ class OSGVIEWER_EXPORT Viewer : public ViewerBase, public osgViewer::View
|
|||||||
virtual void take(osg::View& rhs);
|
virtual void take(osg::View& rhs);
|
||||||
|
|
||||||
|
|
||||||
/** Set the Stats object used for collect various frame related timing and scene graph stats.*/
|
/** Set the Stats object used to collect various frame related timing and scene graph stats.*/
|
||||||
virtual void setViewerStats(osg::Stats* stats) { setStats(stats); }
|
virtual void setViewerStats(osg::Stats* stats) { setStats(stats); }
|
||||||
|
|
||||||
/** Get the Viewers Stats object.*/
|
/** Get the Viewers Stats object.*/
|
||||||
|
@ -40,7 +40,7 @@ class OSGVIEWER_EXPORT ViewerBase : public virtual osg::Object
|
|||||||
ViewerBase(const ViewerBase& vb);
|
ViewerBase(const ViewerBase& vb);
|
||||||
|
|
||||||
|
|
||||||
/** Set the Stats object used for collect various frame related timing and scene graph stats.*/
|
/** Set the Stats object used to collect various frame related timing and scene graph stats.*/
|
||||||
virtual void setViewerStats(osg::Stats* stats) = 0;
|
virtual void setViewerStats(osg::Stats* stats) = 0;
|
||||||
|
|
||||||
/** Get the Viewers Stats object.*/
|
/** Get the Viewers Stats object.*/
|
||||||
@ -85,7 +85,7 @@ class OSGVIEWER_EXPORT ViewerBase : public virtual osg::Object
|
|||||||
/** Return true if viewer threads are running. */
|
/** Return true if viewer threads are running. */
|
||||||
bool areThreadsRunning() const { return _threadsRunning; }
|
bool areThreadsRunning() const { return _threadsRunning; }
|
||||||
|
|
||||||
/** Stop any threads begin run by viewer.*/
|
/** Stop any threads being run by viewer.*/
|
||||||
virtual void stopThreading();
|
virtual void stopThreading();
|
||||||
|
|
||||||
/** Start any threads required by the viewer.*/
|
/** Start any threads required by the viewer.*/
|
||||||
@ -148,7 +148,7 @@ class OSGVIEWER_EXPORT ViewerBase : public virtual osg::Object
|
|||||||
bool getQuitEventSetsDone() const { return _quitEventSetsDone; }
|
bool getQuitEventSetsDone() const { return _quitEventSetsDone; }
|
||||||
|
|
||||||
|
|
||||||
/** Hint to tell the renderingTraversals() method whether to call relaseContext() on the last
|
/** Hint to tell the renderingTraversals() method whether to call releaseContext() on the last
|
||||||
* context that was made current by the thread calling renderingTraverals(). Note, when
|
* context that was made current by the thread calling renderingTraverals(). Note, when
|
||||||
* running multi-threaded viewer no threads will be made current or release current.
|
* running multi-threaded viewer no threads will be made current or release current.
|
||||||
* Setting this hint to false can enable the frame loop to be lazy about calling makeCurrent
|
* Setting this hint to false can enable the frame loop to be lazy about calling makeCurrent
|
||||||
@ -157,7 +157,7 @@ class OSGVIEWER_EXPORT ViewerBase : public virtual osg::Object
|
|||||||
* be left on, otherwise the wrong context could be left active, introducing errors in rendering.*/
|
* be left on, otherwise the wrong context could be left active, introducing errors in rendering.*/
|
||||||
void setReleaseContextAtEndOfFrameHint(bool hint) { _releaseContextAtEndOfFrameHint = hint; }
|
void setReleaseContextAtEndOfFrameHint(bool hint) { _releaseContextAtEndOfFrameHint = hint; }
|
||||||
|
|
||||||
/** Hint to tell the renderingTraversals() method whether to call relaseContext().*/
|
/** Hint to tell the renderingTraversals() method whether to call releaseContext().*/
|
||||||
bool getReleaseContextAtEndOfFrameHint() const { return _releaseContextAtEndOfFrameHint; }
|
bool getReleaseContextAtEndOfFrameHint() const { return _releaseContextAtEndOfFrameHint; }
|
||||||
|
|
||||||
|
|
||||||
|
@ -118,7 +118,7 @@ class PdfImage : public osg::Image
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/** Convinience class that provides a interactive quad that can be placed directly in the scene.*/
|
/** Convenience class that provides a interactive quad that can be placed directly in the scene.*/
|
||||||
class OSGWIDGET_EXPORT PdfReader : public osg::Geode
|
class OSGWIDGET_EXPORT PdfReader : public osg::Geode
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
@ -38,7 +38,7 @@ class VncImage : public osg::Image
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/** Convinience Vnc Client class that provides a interactive quad that can be placed directly in the scene.*/
|
/** Convenience Vnc Client class that provides a interactive quad that can be placed directly in the scene.*/
|
||||||
class OSGWIDGET_EXPORT VncClient : public osg::Geode
|
class OSGWIDGET_EXPORT VncClient : public osg::Geode
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
@ -643,10 +643,10 @@ class OSGWIDGET_EXPORT Window:
|
|||||||
|
|
||||||
// These are made into implementation functions since getting the width or height
|
// These are made into implementation functions since getting the width or height
|
||||||
// of a window can potentially be an expensive operation, and we'll want to cache
|
// of a window can potentially be an expensive operation, and we'll want to cache
|
||||||
// results if possible (which is handled transparently by the actualy Window::resize
|
// results if possible (which is handled transparently by the actual Window::resize
|
||||||
// method). They return a Sizes struct which contains two members: cur (for current)
|
// method). They return a Sizes struct which contains two members: cur (for current)
|
||||||
// and min (minimum). It's important that the Window know it's minimum possible
|
// and min (minimum). It's important that the Window know it's minimum possible
|
||||||
// size so that it can ignore invaled requests to resize.
|
// size so that it can ignore invalid requests to resize.
|
||||||
//
|
//
|
||||||
// Default versions using BoundingBox calculations are provided, but some Windows
|
// Default versions using BoundingBox calculations are provided, but some Windows
|
||||||
// override this (Table, Box).
|
// override this (Table, Box).
|
||||||
|
@ -830,7 +830,7 @@ int Thread::setCancelModeAsynchronous() {
|
|||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
//
|
//
|
||||||
// Description: set the thread to cancel at the next convienent point.
|
// Description: set the thread to cancel at the next convenient point.
|
||||||
//
|
//
|
||||||
// Use: public
|
// Use: public
|
||||||
//
|
//
|
||||||
|
@ -638,7 +638,7 @@ unsigned int Image::computePixelSizeInBits(GLenum format,GLenum type)
|
|||||||
|
|
||||||
// note, haven't yet added proper handling of the ARB GL_COMPRESSRED_* pathways
|
// note, haven't yet added proper handling of the ARB GL_COMPRESSRED_* pathways
|
||||||
// yet, no clear size for these since its probably implementation dependent
|
// yet, no clear size for these since its probably implementation dependent
|
||||||
// which raises the question of how to actually querry for these sizes...
|
// which raises the question of how to actually query for these sizes...
|
||||||
// will need to revisit this issue, for now just report an error.
|
// will need to revisit this issue, for now just report an error.
|
||||||
// this is possible a bit of mute point though as since the ARB compressed formats
|
// this is possible a bit of mute point though as since the ARB compressed formats
|
||||||
// arn't yet used for storing images to disk, so its likely that users wont have
|
// arn't yet used for storing images to disk, so its likely that users wont have
|
||||||
|
@ -41,7 +41,7 @@ void LightSource::setLight(Light* light)
|
|||||||
setLocalStateSetModes(_value);
|
setLocalStateSetModes(_value);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Set the GLModes on StateSet associated with the ClipPlanes.
|
// Set the GLModes on StateSet associated with the LightSource.
|
||||||
void LightSource::setStateSetModes(StateSet& stateset,StateAttribute::GLModeValue value) const
|
void LightSource::setStateSetModes(StateSet& stateset,StateAttribute::GLModeValue value) const
|
||||||
{
|
{
|
||||||
if (_light.valid())
|
if (_light.valid())
|
||||||
|
@ -482,7 +482,7 @@ bool OcclusionQueryNode::getPassed( const Camera* camera, NodeVisitor& nv )
|
|||||||
|
|
||||||
{
|
{
|
||||||
// Two situations where we want to simply do a regular traversal:
|
// Two situations where we want to simply do a regular traversal:
|
||||||
// 1) it's the first frame for this camers
|
// 1) it's the first frame for this camera
|
||||||
// 2) we haven't rendered for an abnormally long time (probably because we're an out-of-range LOD child)
|
// 2) we haven't rendered for an abnormally long time (probably because we're an out-of-range LOD child)
|
||||||
// In these cases, assume we're visible to avoid blinking.
|
// In these cases, assume we're visible to avoid blinking.
|
||||||
OpenThreads::ScopedLock<OpenThreads::Mutex> lock( _frameCountMutex );
|
OpenThreads::ScopedLock<OpenThreads::Mutex> lock( _frameCountMutex );
|
||||||
|
@ -400,7 +400,7 @@ void Texture1D::copyTexImage1D(State& state, int x, int y, int width)
|
|||||||
copyTexSubImage1D(state,0 ,x, y, width);
|
copyTexSubImage1D(state,0 ,x, y, width);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// the relevent texture object is not of the right size so
|
// the relevant texture object is not of the right size so
|
||||||
// needs to been deleted
|
// needs to been deleted
|
||||||
// remove previously bound textures.
|
// remove previously bound textures.
|
||||||
dirtyTextureObject();
|
dirtyTextureObject();
|
||||||
|
@ -350,7 +350,7 @@ void Texture2D::copyTexImage2D(State& state, int x, int y, int width, int height
|
|||||||
copyTexSubImage2D(state,0 ,0, x, y, width, height);
|
copyTexSubImage2D(state,0 ,0, x, y, width, height);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// the relevent texture object is not of the right size so
|
// the relevant texture object is not of the right size so
|
||||||
// needs to been deleted
|
// needs to been deleted
|
||||||
// remove previously bound textures.
|
// remove previously bound textures.
|
||||||
dirtyTextureObject();
|
dirtyTextureObject();
|
||||||
|
@ -89,7 +89,7 @@ void Texture2DMultisample::apply(State& state) const
|
|||||||
const GLExtensions* extensions = state.get<GLExtensions>();
|
const GLExtensions* extensions = state.get<GLExtensions>();
|
||||||
if (!extensions->isTextureMultisampledSupported)
|
if (!extensions->isTextureMultisampledSupported)
|
||||||
{
|
{
|
||||||
OSG_INFO<<"Texture2DMultisample not supoorted."<<std::endl;
|
OSG_INFO<<"Texture2DMultisample not supported."<<std::endl;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -477,7 +477,7 @@ void TextureRectangle::copyTexImage2D(State& state, int x, int y, int width, int
|
|||||||
copyTexSubImage2D(state,0 ,0, x, y, width, height);
|
copyTexSubImage2D(state,0 ,0, x, y, width, height);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// the relevent texture object is not of the right size so
|
// the relevant texture object is not of the right size so
|
||||||
// needs to been deleted
|
// needs to been deleted
|
||||||
// remove previously bound textures.
|
// remove previously bound textures.
|
||||||
dirtyTextureObject();
|
dirtyTextureObject();
|
||||||
|
@ -15,7 +15,6 @@
|
|||||||
#include <osgAnimation/Bone>
|
#include <osgAnimation/Bone>
|
||||||
#include <osgAnimation/Skeleton>
|
#include <osgAnimation/Skeleton>
|
||||||
#include <osgAnimation/UpdateBone>
|
#include <osgAnimation/UpdateBone>
|
||||||
#include <osgAnimation/BoneMapVisitor>
|
|
||||||
|
|
||||||
using namespace osgAnimation;
|
using namespace osgAnimation;
|
||||||
|
|
||||||
|
@ -37,8 +37,8 @@
|
|||||||
* Peder Blekken
|
* Peder Blekken
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* Ported into the OSG as a plugin, Robert Osfield Decemeber 2000.
|
* Ported into the OSG as a plugin, Robert Osfield December 2000.
|
||||||
* Note, reference above to license of simage_rgb is not relevent to the OSG
|
* Note, reference above to license of simage_rgb is not relevant to the OSG
|
||||||
* as the OSG does not use it. Also for patches, bugs and new features
|
* as the OSG does not use it. Also for patches, bugs and new features
|
||||||
* please send them direct to the OSG dev team rather than address above.
|
* please send them direct to the OSG dev team rather than address above.
|
||||||
*
|
*
|
||||||
|
@ -29,8 +29,8 @@
|
|||||||
* Peder Blekken
|
* Peder Blekken
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* Ported into the OSG as a plugin, Robert Osfield Decemeber 2000.
|
* Ported into the OSG as a plugin, Robert Osfield December 2000.
|
||||||
* Note, reference above to license of simage_rgb is not relevent to the OSG
|
* Note, reference above to license of simage_rgb is not relevant to the OSG
|
||||||
* as the OSG does not use it. Also for patches, bugs and new features
|
* as the OSG does not use it. Also for patches, bugs and new features
|
||||||
* please send them direct to the OSG dev team rather than address above.
|
* please send them direct to the OSG dev team rather than address above.
|
||||||
*
|
*
|
||||||
|
@ -35,8 +35,8 @@
|
|||||||
* Peder Blekken
|
* Peder Blekken
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* Ported into the OSG as a plugin, Robert Osfield Decemeber 2000.
|
* Ported into the OSG as a plugin, Robert Osfield December 2000.
|
||||||
* Note, reference above to license of simage_rgb is not relevent to the OSG
|
* Note, reference above to license of simage_rgb is not relevant to the OSG
|
||||||
* as the OSG does not use it. Also for patches, bugs and new features
|
* as the OSG does not use it. Also for patches, bugs and new features
|
||||||
* please send them direct to the OSG dev team rather than address above.
|
* please send them direct to the OSG dev team rather than address above.
|
||||||
*
|
*
|
||||||
|
@ -2899,7 +2899,7 @@ protected:
|
|||||||
|
|
||||||
/* The Support Styles are used to consolidate attributes related to labels.
|
/* The Support Styles are used to consolidate attributes related to labels.
|
||||||
For the most part, support styles are very simple, consisting of
|
For the most part, support styles are very simple, consisting of
|
||||||
very basic description of object to use for drawing suport.
|
very basic description of object to use for drawing support.
|
||||||
*/
|
*/
|
||||||
TX_EXDECL class TX_CLDECL trpgSupportStyle : public trpgReadWriteable
|
TX_EXDECL class TX_CLDECL trpgSupportStyle : public trpgReadWriteable
|
||||||
{
|
{
|
||||||
|
@ -238,7 +238,7 @@ unsigned int getNextCharacter(look_ahead_iterator& charString,String::Encoding e
|
|||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////
|
||||||
//
|
//
|
||||||
// String implemention.
|
// String implementation.
|
||||||
//
|
//
|
||||||
|
|
||||||
String::String(const String& str):
|
String::String(const String& str):
|
||||||
|
@ -879,11 +879,11 @@ bool SceneView::cullStage(const osg::Matrixd& projection,const osg::Matrixd& mod
|
|||||||
{
|
{
|
||||||
case(HEADLIGHT):
|
case(HEADLIGHT):
|
||||||
if (_light.valid()) renderStage->addPositionedAttribute(NULL,_light.get());
|
if (_light.valid()) renderStage->addPositionedAttribute(NULL,_light.get());
|
||||||
else OSG_WARN<<"Warning: no osg::Light attached to ogUtil::SceneView to provide head light.*/"<<std::endl;
|
else OSG_WARN<<"Warning: no osg::Light attached to osgUtil::SceneView to provide head light.*/"<<std::endl;
|
||||||
break;
|
break;
|
||||||
case(SKY_LIGHT):
|
case(SKY_LIGHT):
|
||||||
if (_light.valid()) renderStage->addPositionedAttribute(mv.get(),_light.get());
|
if (_light.valid()) renderStage->addPositionedAttribute(mv.get(),_light.get());
|
||||||
else OSG_WARN<<"Warning: no osg::Light attached to ogUtil::SceneView to provide sky light.*/"<<std::endl;
|
else OSG_WARN<<"Warning: no osg::Light attached to osgUtil::SceneView to provide sky light.*/"<<std::endl;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
@ -1379,7 +1379,7 @@ void SceneView::draw()
|
|||||||
_renderStage->draw(_renderInfo,previous);
|
_renderStage->draw(_renderInfo,previous);
|
||||||
}
|
}
|
||||||
|
|
||||||
// re apply the defalt OGL state.
|
// re apply the default OGL state.
|
||||||
state->popAllStateSets();
|
state->popAllStateSets();
|
||||||
state->apply();
|
state->apply();
|
||||||
|
|
||||||
@ -1459,7 +1459,7 @@ const osg::Matrix SceneView::computeMVPW() const
|
|||||||
if (getViewport())
|
if (getViewport())
|
||||||
matrix.postMult(getViewport()->computeWindowMatrix());
|
matrix.postMult(getViewport()->computeWindowMatrix());
|
||||||
else
|
else
|
||||||
OSG_WARN<<"osg::Matrix SceneView::computeMVPW() - error no viewport attached to SceneView, coords will be computed inccorectly."<<std::endl;
|
OSG_WARN<<"osg::Matrix SceneView::computeMVPW() - error no viewport attached to SceneView, coords will be computed incorrectly."<<std::endl;
|
||||||
|
|
||||||
return matrix;
|
return matrix;
|
||||||
}
|
}
|
||||||
|
@ -300,7 +300,7 @@ void View::setSceneData(osg::Node* node)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
OSG_INFO<<"View::setSceneData() Reusing exisitng scene"<<_scene.get()<<std::endl;
|
OSG_INFO<<"View::setSceneData() Reusing existing scene"<<_scene.get()<<std::endl;
|
||||||
}
|
}
|
||||||
|
|
||||||
_scene->setSceneData(node);
|
_scene->setSceneData(node);
|
||||||
|
Loading…
Reference in New Issue
Block a user