Added distrules and makerpms for building RPM distributions
Removed old RedHatRPM distribution build directory
Added new dist/RPM directory and placed temporary .spec files (these
are generated by Make/makerpms and are not intended for stand-alone
use, but they keep the directory warm and CVS happy)
added prefixes and suffixes to libs and plugins. ALl this to accomodate
cygwin...
Also added INST_SYS_PREFIX and INST_SHARE_PREFIX for installation, as well
as "standardizing" the install locations for the various platforms.
the Make directory is left with four files only :
makedefs
makerules
makedirrules
instrules
These work for all platforms supported so far, which include :
Linux
Irix
Solaris
MacOSX
Cygwin
FreeBSD
in progress for the new support for controlling the projection matrix from
within the scene graph.
Also Added osg::State::getClippingVolume(), getProjectionMatrix() and
getModelViewMatrix() with allows drawables to access the current projection,
and model view matrices and the view frustum in local coords to the drawable.
it now maintains references to the last applied matrices, automatically doing
lazy state updating. This simplifies the various places in the OSG which
were previously doing the applying, add paves the way for managing the
projection matrix within the scene graph.
Remove MemoryAdapter and mem_ptr as they arn't being used, and can potentially
confuse users by their existance.
osg::Texture. The values default to 0, and in this state they are
sizes of the glTexSubImage2D are taken from the source image size. This
allows the previous setup with no settings for subload size to work as
before.
memory manager published at flipcode.com. This can be turned on
with the OSG_USE_MEMORY_MANGER option which then uses custom global
new and delete operators as well as provide osgNew and osgDelete macro's
which add ability to log line and file from which calls are made.
Updated osg,osgUtil,osgDB,osgText and osgPlugins/osg to use osgNew/osgDelete,
and fixed memory leaks highlighted by the new memory manager.
published at flipcode. I havn't adopted Paul's macro's for new/delete etc, but use
osg prefixed versions instead to allow greater flexiblity in handling include
ordering.
Have fixed a couple of new/delete[] problems which existed as a result.
To use the MemoryManager to track memory usage simply add
-DOSG_USE_MEMEORY_TRACKING to the compile line.
Have yet to move the osg from using new to osgNew, will do this next.
easier to specify which modes and attributes have been modified without
the user requiring to know to what value, or to have an equivilant attribute
to pass to the have_applied_attribute method. The original have_applied(mode)
and have_applied(attribute) methods have been renamed have_applied_mode(),
have_applied_attribute() as this was required to prevent the mode and type
values colliding during compile (it was causing a compile error when the method
names were the same.)
not delete the object even if its count goes to 0 or below. This should
only be called in special circumstances, the ReaderWriter::ReadResult
being one of them. This new method has allowed the problem of objects
being multiple referenced on return from readNodeFile() & readImageFile().
much more of the core texture setup code. This largely invloved paramterizing
the applyImmediateMode, which has also been rename applyTexImage to reflect
its functionality better.
include change the CameraManipulators so they work with double for time
instead of float. Also added support for DataType to osg::StateAttribute
and StateSet so that they can be set to either STATIC or DYNAMIC, this
allows the optimizer to know whether that an attribute can be optimized
or not.
in testing new glTextParamters update functionality. I have commented out
the call to attaching of the callback so osgtexture outwardly behaves as
before. The code lies dormant just incase we need to use it for testing
in the future.
mode by using a _texParamtersDirty flag in combination with an
applyTexParamters(State&) method which does the paramters setting in one
tidy bundle. This new implementations replaces the CompileFlags submitted
yesterday.
Simplified NodeCallback by remove osg::NodeCallback::Requirements as they
are no longer needed.
Fixed comments in Drawable.
Put guards around cosf definations so that they are only used under Win32/Mac.
Fixed warning in CullVisitor.
inserted a static transform to do the work of rotating the scene, then
applied a standard osgUtil::Optimizer::FlattenStaticTransformsVisitor
traversal to flatten the transfrom down on to the geometry nodes.
Moved CullVisitor/RenderStage/RenderStageLighting across to managing lights
entirely within RenderStageLighting, and changed the management of modelview
matrices so that RenderLeaf now stores the absolute modelview matrix, rather
than a model matrix as done previously. The later allows RenderLeaf's to do
a glLoadMatrix rather than a glPushMatrix/glMultMatrix/glPopMatrix.
level which appears to cause the code to hang, -O works fine for some strange
reason, I havn't found any direct problems in the code. This may be compiler
bug or a code bug, the bug may go away in later versions of GNUC++, the
problem currently occurs under GCC2.96.
plugin names hanging around despite being deprecated. These definiations
confused the make install/make instclean so it tried to link a non existant
library. Have removed old definitions and everything intalls properly once
more:-)
Change the osg::NodeVisitor::getLocalToWorldMatrix() /
getWorldToLocalMatrix() methods so it do not initilize the matrix being
passed to them, and assume the the users has already initiliazed them
appropriately, such as to take account of camera positions.
coords of the intersection point with the scene rather than the world
coord value for that point. The code now uses
osgUtil::Hit::getWorldIntersectionPoint() method for getting the world coords.
Added support for getWorldIntersectionPoint to Viewer.cpp.
Put and #ifdef around the setting of the default display list visitor so
it nolonger sets in under IRIX. This is a world around to the IR graphics
imbending lighting info into display lists, if the display lists are
created before state is set up it produces lighting artifacts such as
flickering. Remove the the default display list init visitor removes
these problems, display lists are then built on the fly and drawables
a drawn for the first time.
does not flatten drawables which have double references to them, but only
one reference with a static transform on it. This case can't be flattened
but this wasn't picked up. The code now detects the case correctly.
distribution clean from GUI examples, these instead should live in the bazaar.
This can better accomodate the many different types of viewer that users are
developming.
the conclusion that the osg::Matrix::inverse was broken, have lifted a new
implementation from sgl and it seems to work fine. Will need further testing
but looks good.
objects that are deleted whilest still having a positive _refCount, such
as when a object has been deleted on the stack, yet other references still
exist for it. Have put the desctructor implementation in Object.cpp to
avoid adding yet another file with only a couple of lines of code in.
by adding a ComputeTransformCallback to osg::Transform, and have now removed
the recently added AutoTransform since it is nolonger required. Have also
updated CullVisitor to account for the new ways for tracking transformation
matrices in the scene.
on the stack thus ensure that they arn't created locally and have their
memory deleted incorrectly.
Also updated the IntersectVisitor so that it no used osg::ref_ptr<> internally
for storing all data. Have also move the IntersectState helper class to inside the
IntersectVisitor which simplifies the external interface to the class.
class now combines Cloner and DeepCopy into one class. Cloner and DeepCopy
will be removed in next commit.
Also have added osgcopy app to Demos which shows how the CopyOp have be
subclassed to create users own specific handling of copying.
Have fixed copy constructor problems in GeoSet which fix the deep copy
problem experienced yesterday.
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
by the _unitScale to compenstate for different scales in the flt model. This
_unitScale had already been applied to the geometry data.
Integrated new defaults for the texturing wrap mode, for when now .attr file
is supplied with a flt file.
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.
correct redundent groups but for groups which had a single child it was
was not using replaceChild to rettach the child to its parents. It was using
parent->removeChild(group)...parent->addChild(child); which was allow the child
to be attached in a different place than the original group, this broke LOD code.
Have used removeChild instead which solves the LOD problem.
modes first then attributes since the it was cause a display bug on some
datesets. It seems that the modes needs enabling before glMaterial's
take affect, at least on the NVidia drivers under Windows and Linux.
The OpenGL reference guide doesn't mention any dependancy so I'm not
sure what the official line is. Some other OpenGl attribute and modes
need to be applied in that order according to the blue book, however,
drivers, at least the NVidia drivers seem require the opposite. This may raise
the spectra of before and after mode applies, but this will require extra
support in osg::State and osg::StateAttribute, and would have to be handled
on a per attribute basis, and possibly different of each platform. Yuck.
of objects which were transformed by multiple matrices at one time - this
cannot be handled in the flattening process (since we only have one piece
of geometry to transform). This visitor now handles this case by disabling
flattening of any objects and transforms associated in this way.
change in osg::Billboard.
Removed in instance of an object being passed () brackets, have removed the
brackets to avoid an amiguity with the compiler intepreting it as a function.
Alas changed the indenting to use 4 spaces instead of tabs, this irons out
differences when working under Windows and Unix, keeping the identing
consistent.
attributes are now set first, then modes. This is keep consistent with
the setting of glColorMaterial and glEnable(GL_COLOR_MATERIAL) as specfied
in OpenGL documentation.
defined the value to be 2048, this should avoid problems with path lengths
which have been overflowing the 1024 limit (Sasa report this bug). The
real solution is to use std::string throught FileUtils, but this will have
to wait for another day.
from passing the vector contents to the GeoSet::setPrimLengths(..) etc.
methods. This has been done to fix the compile under the MS .NET compiler
which has changed the definiation of the std::vector<..>::iterator to
a class rather than a pointer.
matched does not have a corresponding child to relate to. This can happen
if a user creates more than n+1 ranges, where n is the number of LOD children.
instead of four).
Added support for multiplying mesh geometry by the matrix attached to the
Lib3dsMesh structure, however this produces disjointed models so have
to the default mode to bypass this multiplication code. Will need to revisit
this in the future.
osgGLUT::Window, standardising on the Window ones, and therefore removing
an unitialized variable that had been introduced. This caused a crash
under WindowsXP due to send invalid values to glutReshapeWindow.
with the GLUT Viewer output as INFO rather than as a NOTICE. This suppress
this message which was appearing on some of the demos all the time, even
though are quite reasonable default behaviour is used.
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.
ReaderWriterATTR.cpp had a variable "mips" defined, which is predefined for the IRIX preprocessor.
Changed this to _mips.
FltFile.cpp had a class and transient variable defined within the scope of member function
FltFile::readExternals(), which was causing the IRIX 7.3 compiles to hork. Moved the class
definition to outside of the member function scope.
constructor such that a static variable is used to force the constructor
to check the number of clock cycles per second once, this means that
multiple timers can now be created with incurring a the 1 second delay
used for timming the clock speed every time the constructor is called.
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.
so that they both use the same implementation (the Quat code now) and the
code has been corrected to work from and to vectors which directly opposite
to one another.
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.
apply(Billboard& ) method which was apply the accumulated transform to
the billbaord geometry when it should have been applying the matrix without
the transform component.
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.
problem - './' was added to all files which which directly found without
requiring a search path rather than just locally found files, this broke
file loads which had wern't local but had a valid path. I have moved the
'./' work around to inside fileDSO and made it only apply to Linux as I
presume this is all it was needed for. Don?