CullSettings
Go to the documentation of this file.
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
*
* This library is open source and may be redistributed and/or modified under
* the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
* (at your option) any later version. The full license is in LICENSE file
* included with this distribution, and on the openscenegraph.org website.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* OpenSceneGraph Public License for more details.
*/
#ifndef OSG_CULLSETTINGS
#define OSG_CULLSETTINGS 1
#include <iosfwd>
#include <osg/Matrix>
#include <osg/ClearNode>
namespace osg {
// forward declare
class ArgumentParser;
class ApplicationUsage;
class OSG_EXPORT CullSettings
{
public:
CullSettings()
{
setDefaults();
readEnvironmentalVariables();
}
CullSettings(ArgumentParser& arguments)
{
setDefaults();
readEnvironmentalVariables();
readCommandLine(arguments);
}
CullSettings(const CullSettings& cs);
virtual ~CullSettings() {}
CullSettings& operator = (const CullSettings& settings)
{
if (this==&settings) return *this;
setCullSettings(settings);
return *this;
}
virtual void setDefaults();
enum VariablesMask
{
COMPUTE_NEAR_FAR_MODE = (0x1 << 0),
CULLING_MODE = (0x1 << 1),
LOD_SCALE = (0x1 << 2),
SMALL_FEATURE_CULLING_PIXEL_SIZE = (0x1 << 3),
CLAMP_PROJECTION_MATRIX_CALLBACK = (0x1 << 4),
NEAR_FAR_RATIO = (0x1 << 5),
IMPOSTOR_ACTIVE = (0x1 << 6),
DEPTH_SORT_IMPOSTOR_SPRITES = (0x1 << 7),
IMPOSTOR_PIXEL_ERROR_THRESHOLD = (0x1 << 8),
NUM_FRAMES_TO_KEEP_IMPOSTORS_SPRITES = (0x1 << 9),
CULL_MASK = (0x1 << 10),
CULL_MASK_LEFT = (0x1 << 11),
CULL_MASK_RIGHT = (0x1 << 12),
CLEAR_COLOR = (0x1 << 13),
CLEAR_MASK = (0x1 << 14),
LIGHTING_MODE = (0x1 << 15),
LIGHT = (0x1 << 16),
DRAW_BUFFER = (0x1 << 17),
READ_BUFFER = (0x1 << 18),
NO_VARIABLES = 0x00000000,
ALL_VARIABLES = 0x7FFFFFFF
};
typedef int InheritanceMask;
void setInheritanceMask(InheritanceMask mask) { _inheritanceMask = mask; }
InheritanceMask getInheritanceMask() const { return _inheritanceMask; }
void setCullSettings(const CullSettings& settings);
virtual void inheritCullSettings(const CullSettings& settings) { inheritCullSettings(settings, _inheritanceMask); }
virtual void inheritCullSettings(const CullSettings& settings, unsigned int inheritanceMask);
void readEnvironmentalVariables();
void readCommandLine(ArgumentParser& arguments);
enum InheritanceMaskActionOnAttributeSetting
{
DISABLE_ASSOCIATED_INHERITANCE_MASK_BIT,
DO_NOT_MODIFY_INHERITANCE_MASK
};
void setInheritanceMaskActionOnAttributeSetting(InheritanceMaskActionOnAttributeSetting action) { _inheritanceMaskActionOnAttributeSetting = action; }
InheritanceMaskActionOnAttributeSetting getInheritanceMaskActionOnAttributeSetting() const { return _inheritanceMaskActionOnAttributeSetting; }
inline void applyMaskAction(unsigned int maskBit)
{
if (_inheritanceMaskActionOnAttributeSetting==DISABLE_ASSOCIATED_INHERITANCE_MASK_BIT)
{
_inheritanceMask = _inheritanceMask & (~maskBit);
}
}
void setImpostorsActive(bool active) { _impostorActive = active; applyMaskAction(IMPOSTOR_ACTIVE); }
bool getImpostorsActive() const { return _impostorActive; }
void setImpostorPixelErrorThreshold(float numPixels) { _impostorPixelErrorThreshold=numPixels; applyMaskAction(IMPOSTOR_PIXEL_ERROR_THRESHOLD); }
float getImpostorPixelErrorThreshold() const { return _impostorPixelErrorThreshold; }
void setDepthSortImpostorSprites(bool doDepthSort) { _depthSortImpostorSprites = doDepthSort; applyMaskAction(DEPTH_SORT_IMPOSTOR_SPRITES); }
bool getDepthSortImpostorSprites() const { return _depthSortImpostorSprites; }
void setNumberOfFrameToKeepImpostorSprites(int numFrames) { _numFramesToKeepImpostorSprites = numFrames; applyMaskAction(NUM_FRAMES_TO_KEEP_IMPOSTORS_SPRITES); }
int getNumberOfFrameToKeepImpostorSprites() const { return _numFramesToKeepImpostorSprites; }
enum ComputeNearFarMode
{
DO_NOT_COMPUTE_NEAR_FAR = 0,
COMPUTE_NEAR_FAR_USING_BOUNDING_VOLUMES,
COMPUTE_NEAR_FAR_USING_PRIMITIVES,
COMPUTE_NEAR_USING_PRIMITIVES
};
void setComputeNearFarMode(ComputeNearFarMode cnfm) { _computeNearFar=cnfm; applyMaskAction(COMPUTE_NEAR_FAR_MODE); }
ComputeNearFarMode getComputeNearFarMode() const { return _computeNearFar;}
void setNearFarRatio(double ratio) { _nearFarRatio = ratio; applyMaskAction(NEAR_FAR_RATIO); }
double getNearFarRatio() const { return _nearFarRatio; }
enum CullingModeValues
{
NO_CULLING = 0x0,
VIEW_FRUSTUM_SIDES_CULLING = 0x1,
NEAR_PLANE_CULLING = 0x2,
FAR_PLANE_CULLING = 0x4,
VIEW_FRUSTUM_CULLING = VIEW_FRUSTUM_SIDES_CULLING|
NEAR_PLANE_CULLING|
FAR_PLANE_CULLING,
SMALL_FEATURE_CULLING = 0x8,
SHADOW_OCCLUSION_CULLING = 0x10,
CLUSTER_CULLING = 0x20,
DEFAULT_CULLING = VIEW_FRUSTUM_SIDES_CULLING|
SMALL_FEATURE_CULLING|
SHADOW_OCCLUSION_CULLING|
CLUSTER_CULLING,
ENABLE_ALL_CULLING = VIEW_FRUSTUM_CULLING|
SMALL_FEATURE_CULLING|
SHADOW_OCCLUSION_CULLING|
CLUSTER_CULLING
};
typedef int CullingMode;
void setCullingMode(CullingMode mode) { _cullingMode = mode; applyMaskAction(CULLING_MODE); }
CullingMode getCullingMode() const { return _cullingMode; }
void setCullMask(osg::Node::NodeMask nm) { _cullMask = nm; applyMaskAction(CULL_MASK); }
osg::Node::NodeMask getCullMask() const { return _cullMask; }
void setCullMaskLeft(osg::Node::NodeMask nm) { _cullMaskLeft = nm; applyMaskAction(CULL_MASK_LEFT); }
osg::Node::NodeMask getCullMaskLeft() const { return _cullMaskLeft; }
void setCullMaskRight(osg::Node::NodeMask nm) { _cullMaskRight = nm; applyMaskAction(CULL_MASK_RIGHT); }
osg::Node::NodeMask getCullMaskRight() const { return _cullMaskRight; }
void setLODScale(float scale) { _LODScale = scale; applyMaskAction(LOD_SCALE); }
float getLODScale() const { return _LODScale; }
void setSmallFeatureCullingPixelSize(float value) { _smallFeatureCullingPixelSize=value; applyMaskAction(SMALL_FEATURE_CULLING_PIXEL_SIZE); }
float getSmallFeatureCullingPixelSize() const { return _smallFeatureCullingPixelSize; }
struct ClampProjectionMatrixCallback : public osg::Referenced
{
virtual bool clampProjectionMatrixImplementation(osg::Matrixf& projection, double& znear, double& zfar) const = 0;
virtual bool clampProjectionMatrixImplementation(osg::Matrixd& projection, double& znear, double& zfar) const = 0;
};
void setClampProjectionMatrixCallback(ClampProjectionMatrixCallback* cpmc) { _clampProjectionMatrixCallback = cpmc; applyMaskAction(CLAMP_PROJECTION_MATRIX_CALLBACK); }
ClampProjectionMatrixCallback* getClampProjectionMatrixCallback() { return _clampProjectionMatrixCallback.get(); }
const ClampProjectionMatrixCallback* getClampProjectionMatrixCallback() const { return _clampProjectionMatrixCallback.get(); }
void write(std::ostream& out);
protected:
InheritanceMask _inheritanceMask;
InheritanceMaskActionOnAttributeSetting _inheritanceMaskActionOnAttributeSetting;
ComputeNearFarMode _computeNearFar;
CullingMode _cullingMode;
float _LODScale;
float _smallFeatureCullingPixelSize;
ref_ptr<ClampProjectionMatrixCallback> _clampProjectionMatrixCallback;
double _nearFarRatio;
bool _impostorActive;
bool _depthSortImpostorSprites;
float _impostorPixelErrorThreshold;
int _numFramesToKeepImpostorSprites;
Node::NodeMask _cullMask;
Node::NodeMask _cullMaskLeft;
Node::NodeMask _cullMaskRight;
};
template<class matrix_type, class value_type>
bool clampProjectionMatrix(matrix_type& projection, double& znear, double& zfar, value_type nearFarRatio)
{
double epsilon = 1e-6;
if (zfar<znear-epsilon)
{
if (zfar != -FLT_MAX || znear != FLT_MAX)
{
OSG_INFO<<"_clampProjectionMatrix not applied, invalid depth range, znear = "<<znear<<" zfar = "<<zfar<<std::endl;
}
return false;
}
if (zfar<znear+epsilon)
{
// znear and zfar are too close together and could cause divide by zero problems
// late on in the clamping code, so move the znear and zfar apart.
double average = (znear+zfar)*0.5;
znear = average-epsilon;
zfar = average+epsilon;
// OSG_INFO << "_clampProjectionMatrix widening znear and zfar to "<<znear<<" "<<zfar<<std::endl;
}
if (fabs(projection(0,3))<epsilon && fabs(projection(1,3))<epsilon && fabs(projection(2,3))<epsilon )
{
// OSG_INFO << "Orthographic matrix before clamping"<<projection<<std::endl;
value_type delta_span = (zfar-znear)*0.02;
if (delta_span<1.0) delta_span = 1.0;
value_type desired_znear = znear - delta_span;
value_type desired_zfar = zfar + delta_span;
// assign the clamped values back to the computed values.
znear = desired_znear;
zfar = desired_zfar;
projection(2,2)=-2.0f/(desired_zfar-desired_znear);
projection(3,2)=-(desired_zfar+desired_znear)/(desired_zfar-desired_znear);
// OSG_INFO << "Orthographic matrix after clamping "<<projection<<std::endl;
}
else
{
// OSG_INFO << "Persepective matrix before clamping"<<projection<<std::endl;
//std::cout << "_computed_znear"<<_computed_znear<<std::endl;
//std::cout << "_computed_zfar"<<_computed_zfar<<std::endl;
value_type zfarPushRatio = 1.02;
value_type znearPullRatio = 0.98;
//znearPullRatio = 0.99;
value_type desired_znear = znear * znearPullRatio;
value_type desired_zfar = zfar * zfarPushRatio;
// near plane clamping.
double min_near_plane = zfar*nearFarRatio;
if (desired_znear<min_near_plane) desired_znear=min_near_plane;
// assign the clamped values back to the computed values.
znear = desired_znear;
zfar = desired_zfar;
value_type trans_near_plane = (-desired_znear*projection(2,2)+projection(3,2))/(-desired_znear*projection(2,3)+projection(3,3));
value_type trans_far_plane = (-desired_zfar*projection(2,2)+projection(3,2))/(-desired_zfar*projection(2,3)+projection(3,3));
value_type ratio = fabs(2.0/(trans_near_plane-trans_far_plane));
value_type center = -(trans_near_plane+trans_far_plane)/2.0;
projection.postMult(osg::Matrix(1.0f,0.0f,0.0f,0.0f,
0.0f,1.0f,0.0f,0.0f,
0.0f,0.0f,ratio,0.0f,
0.0f,0.0f,center*ratio,1.0f));
// OSG_INFO << "Persepective matrix after clamping"<<projection<<std::endl;
}
return true;
}
}
#endif
ClearNode
Matrix
OSG_INFO
#define OSG_INFO
Definition Notify:87
osg::ArgumentParser
Definition ArgumentParser:28
osg::CullSettings::getInheritanceMask
InheritanceMask getInheritanceMask() const
Definition CullSettings:91
osg::CullSettings::_LODScale
float _LODScale
Definition CullSettings:256
osg::CullSettings::setSmallFeatureCullingPixelSize
void setSmallFeatureCullingPixelSize(float value)
Definition CullSettings:222
osg::CullSettings::setLODScale
void setLODScale(float scale)
Definition CullSettings:215
osg::CullSettings::getImpostorsActive
bool getImpostorsActive() const
Definition CullSettings:137
osg::CullSettings::getSmallFeatureCullingPixelSize
float getSmallFeatureCullingPixelSize() const
Definition CullSettings:225
osg::CullSettings::_cullMaskLeft
Node::NodeMask _cullMaskLeft
Definition CullSettings:267
osg::CullSettings::ComputeNearFarMode
ComputeNearFarMode
Definition CullSettings:161
osg::CullSettings::COMPUTE_NEAR_FAR_USING_PRIMITIVES
@ COMPUTE_NEAR_FAR_USING_PRIMITIVES
Definition CullSettings:164
osg::CullSettings::DO_NOT_COMPUTE_NEAR_FAR
@ DO_NOT_COMPUTE_NEAR_FAR
Definition CullSettings:162
osg::CullSettings::COMPUTE_NEAR_USING_PRIMITIVES
@ COMPUTE_NEAR_USING_PRIMITIVES
Definition CullSettings:165
osg::CullSettings::COMPUTE_NEAR_FAR_USING_BOUNDING_VOLUMES
@ COMPUTE_NEAR_FAR_USING_BOUNDING_VOLUMES
Definition CullSettings:163
osg::CullSettings::inheritCullSettings
virtual void inheritCullSettings(const CullSettings &settings)
Definition CullSettings:97
osg::CullSettings::CullSettings
CullSettings(ArgumentParser &arguments)
Definition CullSettings:37
osg::CullSettings::setCullMaskRight
void setCullMaskRight(osg::Node::NodeMask nm)
Definition CullSettings:211
osg::CullSettings::getClampProjectionMatrixCallback
ClampProjectionMatrixCallback * getClampProjectionMatrixCallback()
Definition CullSettings:241
osg::CullSettings::setClampProjectionMatrixCallback
void setClampProjectionMatrixCallback(ClampProjectionMatrixCallback *cpmc)
Definition CullSettings:239
osg::CullSettings::readCommandLine
void readCommandLine(ArgumentParser &arguments)
osg::CullSettings::_cullMask
Node::NodeMask _cullMask
Definition CullSettings:266
osg::CullSettings::applyMaskAction
void applyMaskAction(unsigned int maskBit)
Definition CullSettings:120
osg::CullSettings::setInheritanceMask
void setInheritanceMask(InheritanceMask mask)
Definition CullSettings:88
osg::CullSettings::setInheritanceMaskActionOnAttributeSetting
void setInheritanceMaskActionOnAttributeSetting(InheritanceMaskActionOnAttributeSetting action)
Definition CullSettings:115
osg::CullSettings::readEnvironmentalVariables
void readEnvironmentalVariables()
osg::CullSettings::_nearFarRatio
double _nearFarRatio
Definition CullSettings:260
osg::CullSettings::setNearFarRatio
void setNearFarRatio(double ratio)
Definition CullSettings:171
osg::CullSettings::VariablesMask
VariablesMask
Definition CullSettings:60
osg::CullSettings::LOD_SCALE
@ LOD_SCALE
Definition CullSettings:63
osg::CullSettings::CULL_MASK_RIGHT
@ CULL_MASK_RIGHT
Definition CullSettings:73
osg::CullSettings::DRAW_BUFFER
@ DRAW_BUFFER
Definition CullSettings:78
osg::CullSettings::LIGHT
@ LIGHT
Definition CullSettings:77
osg::CullSettings::ALL_VARIABLES
@ ALL_VARIABLES
Definition CullSettings:82
osg::CullSettings::NO_VARIABLES
@ NO_VARIABLES
Definition CullSettings:81
osg::CullSettings::LIGHTING_MODE
@ LIGHTING_MODE
Definition CullSettings:76
osg::CullSettings::NEAR_FAR_RATIO
@ NEAR_FAR_RATIO
Definition CullSettings:66
osg::CullSettings::IMPOSTOR_ACTIVE
@ IMPOSTOR_ACTIVE
Definition CullSettings:67
osg::CullSettings::DEPTH_SORT_IMPOSTOR_SPRITES
@ DEPTH_SORT_IMPOSTOR_SPRITES
Definition CullSettings:68
osg::CullSettings::COMPUTE_NEAR_FAR_MODE
@ COMPUTE_NEAR_FAR_MODE
Definition CullSettings:61
osg::CullSettings::IMPOSTOR_PIXEL_ERROR_THRESHOLD
@ IMPOSTOR_PIXEL_ERROR_THRESHOLD
Definition CullSettings:69
osg::CullSettings::CULLING_MODE
@ CULLING_MODE
Definition CullSettings:62
osg::CullSettings::CLEAR_COLOR
@ CLEAR_COLOR
Definition CullSettings:74
osg::CullSettings::NUM_FRAMES_TO_KEEP_IMPOSTORS_SPRITES
@ NUM_FRAMES_TO_KEEP_IMPOSTORS_SPRITES
Definition CullSettings:70
osg::CullSettings::SMALL_FEATURE_CULLING_PIXEL_SIZE
@ SMALL_FEATURE_CULLING_PIXEL_SIZE
Definition CullSettings:64
osg::CullSettings::CULL_MASK
@ CULL_MASK
Definition CullSettings:71
osg::CullSettings::CULL_MASK_LEFT
@ CULL_MASK_LEFT
Definition CullSettings:72
osg::CullSettings::CLEAR_MASK
@ CLEAR_MASK
Definition CullSettings:75
osg::CullSettings::CLAMP_PROJECTION_MATRIX_CALLBACK
@ CLAMP_PROJECTION_MATRIX_CALLBACK
Definition CullSettings:65
osg::CullSettings::READ_BUFFER
@ READ_BUFFER
Definition CullSettings:79
osg::CullSettings::getNearFarRatio
double getNearFarRatio() const
Definition CullSettings:172
osg::CullSettings::~CullSettings
virtual ~CullSettings()
Definition CullSettings:46
osg::CullSettings::getDepthSortImpostorSprites
bool getDepthSortImpostorSprites() const
Definition CullSettings:150
osg::CullSettings::write
void write(std::ostream &out)
osg::CullSettings::_computeNearFar
ComputeNearFarMode _computeNearFar
Definition CullSettings:254
osg::CullSettings::_numFramesToKeepImpostorSprites
int _numFramesToKeepImpostorSprites
Definition CullSettings:264
osg::CullSettings::getComputeNearFarMode
ComputeNearFarMode getComputeNearFarMode() const
Definition CullSettings:169
osg::CullSettings::getCullMaskLeft
osg::Node::NodeMask getCullMaskLeft() const
Definition CullSettings:209
osg::CullSettings::getNumberOfFrameToKeepImpostorSprites
int getNumberOfFrameToKeepImpostorSprites() const
Definition CullSettings:158
osg::CullSettings::_smallFeatureCullingPixelSize
float _smallFeatureCullingPixelSize
Definition CullSettings:257
osg::CullSettings::_cullMaskRight
Node::NodeMask _cullMaskRight
Definition CullSettings:268
osg::CullSettings::inheritCullSettings
virtual void inheritCullSettings(const CullSettings &settings, unsigned int inheritanceMask)
osg::CullSettings::getLODScale
float getLODScale() const
Definition CullSettings:218
osg::CullSettings::InheritanceMaskActionOnAttributeSetting
InheritanceMaskActionOnAttributeSetting
Definition CullSettings:110
osg::CullSettings::DISABLE_ASSOCIATED_INHERITANCE_MASK_BIT
@ DISABLE_ASSOCIATED_INHERITANCE_MASK_BIT
Definition CullSettings:111
osg::CullSettings::DO_NOT_MODIFY_INHERITANCE_MASK
@ DO_NOT_MODIFY_INHERITANCE_MASK
Definition CullSettings:112
osg::CullSettings::CullSettings
CullSettings(const CullSettings &cs)
osg::CullSettings::getClampProjectionMatrixCallback
const ClampProjectionMatrixCallback * getClampProjectionMatrixCallback() const
Definition CullSettings:243
osg::CullSettings::setImpostorsActive
void setImpostorsActive(bool active)
Definition CullSettings:134
osg::CullSettings::setCullSettings
void setCullSettings(const CullSettings &settings)
osg::CullSettings::setCullMask
void setCullMask(osg::Node::NodeMask nm)
Definition CullSettings:205
osg::CullSettings::_depthSortImpostorSprites
bool _depthSortImpostorSprites
Definition CullSettings:262
osg::CullSettings::setNumberOfFrameToKeepImpostorSprites
void setNumberOfFrameToKeepImpostorSprites(int numFrames)
Definition CullSettings:154
osg::CullSettings::getInheritanceMaskActionOnAttributeSetting
InheritanceMaskActionOnAttributeSetting getInheritanceMaskActionOnAttributeSetting() const
Definition CullSettings:116
osg::CullSettings::_inheritanceMask
InheritanceMask _inheritanceMask
Definition CullSettings:251
osg::CullSettings::_impostorPixelErrorThreshold
float _impostorPixelErrorThreshold
Definition CullSettings:263
osg::CullSettings::_cullingMode
CullingMode _cullingMode
Definition CullSettings:255
osg::CullSettings::CullingModeValues
CullingModeValues
Definition CullSettings:175
osg::CullSettings::SMALL_FEATURE_CULLING
@ SMALL_FEATURE_CULLING
Definition CullSettings:183
osg::CullSettings::CLUSTER_CULLING
@ CLUSTER_CULLING
Definition CullSettings:185
osg::CullSettings::DEFAULT_CULLING
@ DEFAULT_CULLING
Definition CullSettings:186
osg::CullSettings::FAR_PLANE_CULLING
@ FAR_PLANE_CULLING
Definition CullSettings:179
osg::CullSettings::ENABLE_ALL_CULLING
@ ENABLE_ALL_CULLING
Definition CullSettings:190
osg::CullSettings::NEAR_PLANE_CULLING
@ NEAR_PLANE_CULLING
Definition CullSettings:178
osg::CullSettings::SHADOW_OCCLUSION_CULLING
@ SHADOW_OCCLUSION_CULLING
Definition CullSettings:184
osg::CullSettings::NO_CULLING
@ NO_CULLING
Definition CullSettings:176
osg::CullSettings::VIEW_FRUSTUM_SIDES_CULLING
@ VIEW_FRUSTUM_SIDES_CULLING
Definition CullSettings:177
osg::CullSettings::VIEW_FRUSTUM_CULLING
@ VIEW_FRUSTUM_CULLING
Definition CullSettings:180
osg::CullSettings::setImpostorPixelErrorThreshold
void setImpostorPixelErrorThreshold(float numPixels)
Definition CullSettings:141
osg::CullSettings::getCullMaskRight
osg::Node::NodeMask getCullMaskRight() const
Definition CullSettings:212
osg::CullSettings::setDepthSortImpostorSprites
void setDepthSortImpostorSprites(bool doDepthSort)
Definition CullSettings:147
osg::CullSettings::setCullMaskLeft
void setCullMaskLeft(osg::Node::NodeMask nm)
Definition CullSettings:208
osg::CullSettings::getImpostorPixelErrorThreshold
float getImpostorPixelErrorThreshold() const
Definition CullSettings:144
osg::CullSettings::getCullMask
osg::Node::NodeMask getCullMask() const
Definition CullSettings:206
osg::CullSettings::_impostorActive
bool _impostorActive
Definition CullSettings:261
osg::CullSettings::setCullingMode
void setCullingMode(CullingMode mode)
Definition CullSettings:199
osg::CullSettings::setComputeNearFarMode
void setComputeNearFarMode(ComputeNearFarMode cnfm)
Definition CullSettings:168
osg::CullSettings::InheritanceMask
int InheritanceMask
Definition CullSettings:85
osg::CullSettings::setDefaults
virtual void setDefaults()
osg::CullSettings::_clampProjectionMatrixCallback
ref_ptr< ClampProjectionMatrixCallback > _clampProjectionMatrixCallback
Definition CullSettings:259
osg::CullSettings::CullingMode
int CullingMode
Definition CullSettings:196
osg::CullSettings::CullSettings
CullSettings()
Definition CullSettings:31
osg::CullSettings::_inheritanceMaskActionOnAttributeSetting
InheritanceMaskActionOnAttributeSetting _inheritanceMaskActionOnAttributeSetting
Definition CullSettings:252
osg::CullSettings::getCullingMode
CullingMode getCullingMode() const
Definition CullSettings:202
osg::Matrixd
Definition Matrixd:27
osg::Matrixf
Definition Matrixf:27
osg::Node::NodeMask
unsigned int NodeMask
Definition Node:363
osg::Referenced
Definition Referenced:44
osg::ref_ptr
Definition ref_ptr:32
osg
Definition AlphaFunc:19
osg::clampProjectionMatrix
bool clampProjectionMatrix(matrix_type &projection, double &znear, double &zfar, value_type nearFarRatio)
Definition CullSettings:274
osg::Matrix
Matrixd Matrix
Definition Matrix:27
OSG_EXPORT
#define OSG_EXPORT
Definition osg/Export:39
osg::CullSettings::ClampProjectionMatrixCallback
Definition CullSettings:233
osg::CullSettings::ClampProjectionMatrixCallback::clampProjectionMatrixImplementation
virtual bool clampProjectionMatrixImplementation(osg::Matrixf &projection, double &znear, double &zfar) const =0
osg::CullSettings::ClampProjectionMatrixCallback::clampProjectionMatrixImplementation
virtual bool clampProjectionMatrixImplementation(osg::Matrixd &projection, double &znear, double &zfar) const =0