copy constructor which takes an optional Cloner object, and the old
osg::Object::clone() has changed so that it now requires a Cloner as paramter.
This is passed on to the copy constructor to help control the shallow vs
deep copying. The old functionality of clone() which was clone of type has
been renamed to cloneType().
Updated all of the OSG to work with these new conventions, implemention all
the required copy constructors etc. A couple of areas will do shallow
copies by design, a couple of other still need to be updated to do either
shallow or deep.
Neither of the shallow or deep copy operations have been tested yet, only
the old functionality of the OSG has been checked so far, such running the
viewer on various demo datasets.
Also fixed a problem in osg::Optimize::RemoveRendundentNodesVisitor which
was not checking that Group didn't have have any attached StateSet's, Callbacks
or UserData. These checks have now been added, which fixes a bug which was
revealled by the new osgscribe demo, this related to removal of group acting
as state decorator.
method
and getWorldToLocalMatrix(), computeLocalToWorld() and computeWorldToLocal()
methods.
Have updated the CullVisitor, IntersectVisitor and Optimizer to use the
new osg::Transform::getLocalToWorldMatrix() which has the same functionality
as the old getMatrix() but is now supports subclasses of osg::Transform
transparently.
Have added osg::PositionAttitudeTransform as subclass of osg::Transform
which manages the transform as position and attitude via a Vec3 and Quat
respectively.
OpenGL light is being operated on, and also now relies upong the standard
osg::State handling of OpenGL modes to switch on the appropriate lights.
The previous static counter mechansim for the light number was causing a
redundent light to be created when the osg plugin created the first osg::Light
to use a prototype for other osg::Light's to be cloned from in the
.osg plugin execution.
The static count mechanism also prevent the lights modes being controlled
independantly from the setting of the light paramters themselves. This
meant that a light once created was global, and couldn't be turned off
locally via the OSG's support for OpenGL mode enabling/disabling. This
has been overcome with the new implementation, the user has complete
flexiblity of when and where to use the different lights at their
disposal.
Renamed the osg::VisualsSettings to osg::DisplaySettings, and
osgUtil::VisualsRequirementsVisitor to osgUtil::DisplayRequirementsVisitor.
Added support for OSG_SCREEN_HEIGHT into osg::DisplaySettings, and added
a DisplaySettings* to the constructors of osg::SceneView and osg::Camera.
it consistent with the rest of the osg::Matrix naming. Updated OSG
distribution to account for new name.
Added support for the STATIC/DYNAMIC osg::Transform::Type to the .osg
ASCII reader/writer plugin and the flt reader plugin.
Removed the non cost version of osg::Transform::getMatrix() as this could
by pass the dirty mechinism.
that used it, all references to the Standard C++ stream classes use the
std::ostream etc convention, all references to "using namespace std" and
"using namespace std::ostream etc" have been removed.
the functionality clear given the name. This will break user code unfortunately
so please be away of the following mapping.
osg::Matrix::makeTrans(..)?\026 -> osg::Matrix::makeTranslate(..)
osg::Matrix::makeRot(..)?\026 -> osg::Matrix::makeRotate(..)
osg::Matrix::trans(..)?\026 -> osg::Matrix::translate(..)
osg::Quat::makeRot(..)?\026 -> osg::Quat::makeRotate(..)
Also updated the rest of the OSG distribution to use the new names, and
have removed the old deprecated Matrix methods too.
default AttributeDeleteFunctor which uses delete []. Users can create
their own handlers for the attribute memory to override this default
behavior.
Fixed a typo in ReaderWriterOBJ.cpp.
Updates to the osg::Transform, adding preMult and postMult methods and
deprecating the old preRotate,preTranslate,preScale.
Updated the rest of the OSG so that it nolonger uses the deprecated
osg::Transform nodes.
Renamed osgUtil::SceneView::setGlobalState() to
osgUtil::SceneView::setGlobalStateSet() so that the name reflects its
functionality better. Updated osgGLUT::Viewer etc to cope with new
name change.
list of text drawables as a paragraph block, handles breaking of text into
individual lines automatically.
Changed the osg::Node::setUserData so that the data type has to be an
osg::Referenced, and removes the dependancy on osg::MemoryAdapter. I have
done this since it simplifies the OSG side of the interface and makes it
less like that the user might abuse the memory managment of the data. It
does however mean that user data will have by subclassed from Referenced,
and therefor may require users to have their own adapter to do this.
However, this little nuasance is worth the extra cleaness and robustness
afforded by going the osg::Referenced route.
Modified osg/Drawable::draw(..) so that it uses display list COMPILE
rather than COMPILE_AND_EXECUTE to solve performance problems under
NVidia drivers. The old behavior is still available by comments out
a #define.
Fixed the default compilation list src/osgPlugins/Makefile so that it
compiles by defalt png and gif.
to allow it to use different comparison schemes, now it can use checking for pointer equality (the default)
or attribute contexts. This has been added to assist optimization of databases within the flt loader, but
also could be useful for other operations too.
should be applied to a node or its child with the new osg::Node::setCullingActive()
flag. A mechanism has been implemented so that if child has its culling disabled
then their parents, all the way up to the root are also have their culling
implicitly disabled.
The osg::CullVisitor has updated to take account of
both the explicit control via setCullingActive and the implicit culling
disabling through children being disabled.
This feature is useful for nodes which don't have a bounding volume to cull
against, earth sky implementations and light sources.
The default osg::Node::_cullingActive is true, i.e. culling is enabled by
default.
these global attributes are created by cloning any attributes which are
applied during rendering, the clone in a shallow copy, which will set up
default valus for that attribute. This should prevent attribute bleed
from one stateset to the next when the global StateSet doesn't contain
an attribute used within the scene graph.
and have updated GeoSet to use mutable values for the _numverts etc, allowing
osg::GeoSet::computeNumVerts() to be a const operation. osg::GeoSet::getNumVerts
is now a const once more, so avoiding compilation problems. Also chaned the new
osgconv orientation code to use a Drawable::AttributeFunctor so it can work on
other Drawables other than just GeoSets.
updated the ReaderWriterBMP.cpp (mods sent in my Geoff Michel) and
moved the osgUtil::Statistics to osg::Statistics in preperation to adding it
to the the Drawable base class.
Also move osg across to using radians for angular paramters by default.
By defining USE_DEGREES_INTERNALLY you can get the OSG to revert to
the old style degrees. This later feature is deprecated and only meant
for helping comptability in the interim.
added support in osgUtil::OptimizeStateVisitor for removing duplicate
StateSet's from the scene graph, previously only duplicated StateAttributes
we're removed.
Also added Matrix::ensureRealized() to support the lazy initialization of Matrix, whilest keeping the implementation robust so that external calls to Matrix which get values do so on an initialized matrix.
2) cleaned up osg::Timer, still in progress. My intent has been to
pave the way for support for other OS's.
3) new osg::FrameStamp class which has a frame number, reference
time for each frame to be app, culled and drawn. The FrameStamp
also can be passed to other machines (i.e. cluster) and the
FrameStamp can be used with the slaves own app,cull and draw.
I've also added the beginings of a calander time data to the
FrameStamp to allow time or day and year to be used in setting
up position of sun/moon etc. etc.
4) The osg::State now has contains a pointer to the last applied
osg::Camera and the current osg::FrameStamp, so that drawables
can use both pieces of information for creating effects such
CLOD, earth/sky etc. The osg::NodeVisitor also now allows you
to attach a FrameStamp to support syncronization of actions on
the scene graph.
but getting there.
o First cut of osgcluster demo. Very simple beginings. Alas
I only one PC here so I can't test it in its current guise.
o New support for NodeCallbacks, via AppCallback attached to
osg::Node's, and a default osgUtil::AppVisitor which calls them on
each frame.
o Support for traversal masks in osg::NodeVisitor, osg::Node
which allows nodes to be switched on or off via a bit mask.
o Suppport for traversal number (frame number) and reference time
into osg::NodeVisitor to handle syncronization of app and cull
traversals. This also assist clustering as traversal number
master to slaves.