Commit Graph

8229 Commits

Author SHA1 Message Date
Robert Osfield
6ff34d0bcb Warnings fixes, submitted by Randall Hopper. 2002-03-30 21:20:41 +00:00
Robert Osfield
434d7b98e5 Fix for Cygwin build. 2002-03-30 15:13:33 +00:00
Robert Osfield
56cee8c711 Move the applying of Projection and ModelView matrices into osg::State so that
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.
2002-03-29 17:26:40 +00:00
Robert Osfield
07f9421f39 Converted from dos file endings to unix. 2002-03-29 12:23:54 +00:00
Robert Osfield
ec4ee5281d Fixes for dos endings in MemoryManager.cpp, and compile fix for osgText for
Cygwin.
2002-03-29 12:23:20 +00:00
Don BURNS
114c18532a Added new install rules for makefiles and updated makedefs and makerules... more to come 2002-03-29 06:54:23 +00:00
Robert Osfield
34c05db393 Fixes for IRIX build. 2002-03-28 23:06:20 +00:00
Don BURNS
88de33c29d Couple a fixes in makedefs and makerules 2002-03-28 07:29:07 +00:00
Don BURNS
b66205f653 Added Norman Vines fixeds for cygwin 2002-03-28 06:35:57 +00:00
Robert Osfield
d421e35c8d A compile fix to the new Texture subload changes. 2002-03-27 23:04:52 +00:00
Robert Osfield
33c89c3be0 Added support for setting the texture subload width and height within
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.
2002-03-27 22:51:58 +00:00
Robert Osfield
7e2c82f141 Futher updates to MemoryManager, fixed memory leak in osgconv. 2002-03-27 16:31:25 +00:00
Robert Osfield
77ae5ddcb6 Updates to various files, replacing delete calls with osgDelete so that
greater debugging info can be gleaned.
2002-03-27 14:56:47 +00:00
Robert Osfield
7927335edf Added support for VERTICAL_SPILT and HORIZONTAL_SPLIT stereo modes. 2002-03-27 10:52:40 +00:00
Don BURNS
6b7cbdaf1a Update to makeefs/makerules 2002-03-27 06:09:17 +00:00
Don BURNS
219f225b9f update to makedefs.new makerules.new 2002-03-27 00:55:52 +00:00
Robert Osfield
84d2d01163 Added support for osg::MemoryManager which is based upon Paul Nettle's
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.
2002-03-26 23:52:52 +00:00
Don BURNS
72ff3186df Adding makedirrrules to Make directory 2002-03-26 21:26:27 +00:00
Don BURNS
fc036a28ce Temporarily adding makedefs.new and makerules.new to keep them
separate from current makedefs/makerules files.  Will eventually
remove all makedefs.* and makerules.* and replace only makedefs
and makerules with makedefs.new and makedefs.new
2002-03-26 21:24:04 +00:00
Robert Osfield
651a22453a Added osg::MemoryManger which is currently based on Paul Nettle's 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.
2002-03-25 23:18:02 +00:00
Robert Osfield
51b1b1eb38 Added missing osgstereoimage.dsp 2002-03-25 23:13:30 +00:00
Robert Osfield
06fcd12598 Fixes for MacOSX build. 2002-03-25 19:04:30 +00:00
Robert Osfield
b7022b7e23 Fixed warning in DisplaySettings.cpp 2002-03-23 21:30:32 +00:00
Robert Osfield
f50c5f7a5e Moved the exit on escape into Window, and added a virtual free method on both
Window an Viewer to clean up the windows, this is now called before exit is
finally called, ensure that more more memroy is clean up prior to exit.
2002-03-23 21:28:25 +00:00
Robert Osfield
33b0ceac0d Added GL_TEXTURE_3D definition for those with gl.h headers which don't
contain it.
2002-03-23 10:55:29 +00:00
Robert Osfield
1ba7e67e2c Added missing TextureCubeMap.cpp to cvs. 2002-03-21 15:46:34 +00:00
Robert Osfield
03cda7d3f8 Renamed have_applied_mode, have_applied_attribute, apply_mode, apply_attribute
to haveAppliedMode, haveAppliedAttribute, applyMode, applyAttribute to make
it more consistent with the general OSG name convetion.
2002-03-21 12:36:05 +00:00
Robert Osfield
a364875afb Added osg:State:have_applied_mode(mode) and have_applied_attribute(type) to make it
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.)
2002-03-21 12:00:10 +00:00
Robert Osfield
b53b3038eb _cullMaskRight was not being initialized in the constructor which was
resulting in some sporadic problems when running stereo - occoasionally the
right eye view wouldn't appear!
2002-03-21 11:57:16 +00:00
Don BURNS
3816a4fcfc Modified files reflect small changes to work with Sun OS port....
Removed redundant README file in osgviews... was a copy of sgv/README.
2002-03-21 07:50:14 +00:00
Robert Osfield
9836af1055 Added osg::TextureCubeMap which encapsulates OpenGL's cube texture mapping. 2002-03-20 22:39:51 +00:00
Robert Osfield
8656adb463 Added a Referenced::unref_nodelete() method which unreferences but does
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().
2002-03-20 14:03:30 +00:00
Robert Osfield
0b27e5c381 Updates to Texture and TextureCubeMap to clean up the code so they share
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.
2002-03-20 11:24:47 +00:00
Robert Osfield
8c9609b331 Added the fallback of intersecting with the a drawables bounding box, if the drawable
isn't a GeoSet and hence supported by the IntersectVisitor's GeoSet primitive
intersections code.
2002-03-20 11:22:06 +00:00
Robert Osfield
8f02db61e5 Added osg::TextureCubeMap. submission from Brede Johansen. 2002-03-18 23:10:33 +00:00
Robert Osfield
49e7be88a7 Fixed the MS version number check in Optiizer.cpp. Fixes to memory handling
in ReaderWriterDW.cpp.  Submissions from Geoff Michel.
2002-03-18 22:03:28 +00:00
Don BURNS
eb0587b5fb Changes required for SUN Solaris port... 2002-03-18 21:56:00 +00:00
Robert Osfield
45de7a5815 Added new osgstereoimage demo which loads two stero paired images to create
a 3D via of photographed scene.
2002-03-17 18:44:47 +00:00
Robert Osfield
0610d76c6a Fix of a delete char array so it used delete []. 2002-03-14 23:19:58 +00:00
Don BURNS
8b15a1f835 Fixed a problem for finding MIPS 64 bit libraries. Was seaching for
LD_LIBRARYN32_PATH instead of LD_LIBRARY64_PATH
2002-03-14 20:29:05 +00:00
Robert Osfield
c49c62ee15 Integrated various changes worked on at the Glasgow Science Center. Changes
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.
2002-03-14 17:34:08 +00:00
Robert Osfield
9e92b9b899 Added a TextureCallback which cycles through various filter modes, used
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.
2002-03-14 16:42:43 +00:00
Robert Osfield
e80496d5db Changed Texture so that is use lazy updating on texture paramters (Filter/Wrap)
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.
2002-03-14 16:01:21 +00:00
Robert Osfield
3a4efd335a Fix to handling of big/little endian in trpage_readbuf sent in by Randall Hopper,
and a waning fix.
2002-03-14 15:26:55 +00:00
Don BURNS
fea861e013 Fixed compile flags in Texture 2002-03-14 00:07:29 +00:00
Don BURNS
d0ee300405 Fixed DrawCallback in Drawable and added CullCallback to Drawable
Cull Visitor now checks for a Drawable's CullCallback and calls it
if it exists.  It then prunes based on the return value (bool) of the
cull callback.
2002-03-13 22:44:22 +00:00
Robert Osfield
bc30edb9e6 Support added for pivot points, submission from Mike Connel. 2002-03-09 10:54:56 +00:00
Robert Osfield
8a8015c41c Fixed setWindowWidth call to account for width and height correctly. 2002-03-09 10:53:19 +00:00
Robert Osfield
1d00a87b09 TXP plugin updates from Boris Bralo. 2002-03-09 10:52:32 +00:00
Robert Osfield
c67950561e TXP plugin changes submitted by Boris Bralo. 2002-03-09 10:52:01 +00:00