Robert Osfield
e6252256e0
Fixed unused parameter warning.
2016-06-08 12:10:00 +01:00
Robert Osfield
dd996a3289
Introduced CMake option OSG_PROVIDE_READFILE option that defaults to ON, but when switched to OFF disables the building of the osgDB::read*File() methods,
...
forcing users to use osgDB::readRef*File() methods. The later is preferable as it closes a potential threading bug when using paging databases in conjunction
with the osgDB::Registry Object Cache. This threading bug occurs when one thread gets an object from the Cache via an osgDB::read*File() call where only
a pointer to the object is passed back, so taking a reference to the object is delayed till it gets reassigned to a ref_ptr<>, but at the same time another
thread calls a flush of the Object Cache deleting this object as it's referenceCount is now zero. Using osgDB::readREf*File() makes sure the a ref_ptr<> is
passed back and the referenceCount never goes to zero.
To ensure the OSG builds when OSG_PROVIDE_READFILE is to OFF the many cases of osgDB::read*File() usage had to be replaced with a ref_ptr<> osgDB::readRef*File()
usage. The avoid this change causing lots of other client code to be rewritten to handle the use of ref_ptr<> in place of C pointer I introduced a serious of
templte methods in various class to adapt ref_ptr<> to the underly C pointer to be passed to old OSG API's, example of this is found in include/osg/Group:
bool addChild(Node* child); // old method which can only be used with a Node*
tempalte<class T> bool addChild(const osg::ref_ptr<T>& child) { return addChild(child.get()); } // adapter template method
These changes together cover 149 modified files, so it's a large submission. This extent of changes are warrent to make use of the Object Cache
and multi-threaded loaded more robust.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@15164 16af8721-9629-0410-8352-f15c8da7e697
2015-10-22 13:42:19 +00:00
Robert Osfield
1320c923ca
Changed the toggle of defines so that it works with assumed defaults now set up by the GeometryPool so that when toggling it doesn't have a delay in what the user would expect
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14708 16af8721-9629-0410-8352-f15c8da7e697
2015-02-20 15:12:57 +00:00
Robert Osfield
afbf20eba9
First step of refactoring the osg::Program management in osgTerrain::GeometryPool for better performance by placing default osg::Program and shader defines on a single StateSet below the osgTerrain::Terrain
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14704 16af8721-9629-0410-8352-f15c8da7e697
2015-02-20 15:02:43 +00:00
Robert Osfield
8546e911fc
Removed GL_ usage in defines
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14697 16af8721-9629-0410-8352-f15c8da7e697
2015-02-17 19:22:37 +00:00
Robert Osfield
b38c6258bf
Added support for new #pragam(atic) shader composition to new displacement mapping technique
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14683 16af8721-9629-0410-8352-f15c8da7e697
2015-02-10 17:20:26 +00:00
Robert Osfield
22cf4c18c3
Added MultiTextureControl event handling of shift 012 i.e. ')', '!', '"' and 'A' to toggle full on for each of the respective or all texture units.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14674 16af8721-9629-0410-8352-f15c8da7e697
2015-01-23 13:50:12 +00:00
Robert Osfield
dfb0b2ab8e
Renamed ShaderTerrain to DisplacementMappingTechnique and moved it from the osgterrain example testbed into the osgTerrain NodeKit
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14534 16af8721-9629-0410-8352-f15c8da7e697
2014-11-26 14:04:20 +00:00
Robert Osfield
d9f93f9d1a
Moved osgTerrain::GeometryPool from osgterrain example into osgTerrain NodeKit
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14533 16af8721-9629-0410-8352-f15c8da7e697
2014-11-26 13:36:28 +00:00
Robert Osfield
f49d7ae110
Added --db-affinit cpuNum option to osgterrain example to illustrate how to set the thead affinity of the DatabasePager threads.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14516 16af8721-9629-0410-8352-f15c8da7e697
2014-11-21 14:46:08 +00:00
Robert Osfield
5f45a39f28
Changed the way that the cell size is passed to the shader
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14481 16af8721-9629-0410-8352-f15c8da7e697
2014-11-19 10:43:07 +00:00
Robert Osfield
6661deeb24
Added use of GL_TRIANGLE_STRIP to cut down the size of the primitive indices required.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14476 16af8721-9629-0410-8352-f15c8da7e697
2014-11-14 17:44:20 +00:00
Robert Osfield
bff5b0261b
Implemented skirt functionality
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14475 16af8721-9629-0410-8352-f15c8da7e697
2014-11-14 16:47:32 +00:00
Robert Osfield
7a33cc00cd
Improvements to the ShaderTerrain experiemental terrain rendering technique.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14466 16af8721-9629-0410-8352-f15c8da7e697
2014-11-04 20:07:40 +00:00
Robert Osfield
997ee30039
Added experimental osgTerrain::ShaderTerrain TerrainTechnique to osgterrain example to flesh out new shader based displacement mapping approach to osgTerrain databases.
...
Requires shader files place in OpenSceneGraph-Data/shaders from OpenSceneGraph-Data's svn/trunk to function.
Run osgterrain example with --shader command line option to select displacement mapping shader approach.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14458 16af8721-9629-0410-8352-f15c8da7e697
2014-10-21 15:08:44 +00:00
Robert Osfield
8202ccc679
From Jean-Sebastien, "In my auto-build today there are 3 errors caused by using a ref_ptr<T> in a function taking a T* when building without the implicit conversion."
2010-12-23 09:59:35 +00:00
Robert Osfield
8707758429
Added handling of CoordinateSystemNode when they decorate a loaded model, copying the contents of the CoordinateSystemNode across to the Terrain node
2010-12-09 12:16:11 +00:00
Robert Osfield
15afc29018
Added window size event handler
2010-04-01 21:04:36 +00:00
Robert Osfield
31e526f253
Added TerainHandler event handler to provide 'v'/'V' and 'r'/'R' key controls for change vertical scale and sample ratio respectively.
2010-03-29 08:49:20 +00:00
Robert Osfield
04e4fa74cc
Added new osgterrain example that is simplified to just basic setup and control osgTerrain nodes, leaving the osgthreadedterrain as the more complex example.
2010-03-19 16:31:48 +00:00
Robert Osfield
515e421e1e
Renamed osgterrain to osgthreadedterrain to better reflect it's functionality.
2010-03-19 14:55:35 +00:00
Robert Osfield
ad8f2d8974
Changed build OSG_USE_REF_PTR_IMPLICIT_OUTPUT_CONVERSION to ON and then fixed all the resulting build errors.
2009-06-17 10:39:39 +00:00
Robert Osfield
7b5f3ec92a
Moved IncrementalCompileOperation out of include-src/osgUtil/GLObjectVisitor into their own files.
...
Added support to IncrementCompileOperation for controlling how much time is alloted to compilation and flush
2009-03-12 15:21:04 +00:00
Robert Osfield
7473b06275
Preliminary work on general purpose incremental compile support in osgViewer.
2009-03-08 12:00:36 +00:00
Robert Osfield
2d55740b3e
Refactored osg::TransferFunction1D to use an std::map internally which is kept in sync with the actual osg::Image that is passed to the GPU.
...
Added .osg support for osg::TransferFunction1D.
Updated wrappers
2009-02-02 14:43:27 +00:00
Robert Osfield
418dc34776
Fixed warnings
2009-01-07 11:24:47 +00:00
Robert Osfield
720551d549
From Michael Platings, Converted std::fstream/ifstream/ofstream to osgDB::fstream/ifstream/ofstream and
...
fopen to osgDB::fopen to facilitate support for wide character filenames using UT8 encoding.
2008-11-07 15:08:08 +00:00
Robert Osfield
10186190f6
Introduced support for controlling mipmapping of osgTerrain::ImageLayer and compression of osgTerrain::HeightFieldLayer.
2008-10-20 08:43:25 +00:00
Robert Osfield
35c5bd2c92
Renamed Terrain to TerrainTile
2008-03-27 10:55:39 +00:00
Robert Osfield
67f1503c7d
Refactored osgTerrain so that the interface for setting up layer is more straight forward, and added support into GeometryTechnique for handling multiple layers
2008-02-22 11:52:23 +00:00
Robert Osfield
f4d2d1241d
Further work on osgTerrain::Locator and GDAL plugin
2007-08-30 19:26:52 +00:00
Robert Osfield
5b1b648ef5
Replaced CartesianLocator and EllipsoidLocator by a single general purpose
...
Locator class
2007-08-27 16:59:51 +00:00
Robert Osfield
d57a16e023
Added DisplaySetting::s/getCompileContextHint() and use of this hint in osgViewer::Viewer/CompositeViewer.
...
Removed the CustomViewer in osgterrain example as the above now removes the need for it.
2007-08-11 14:49:14 +00:00
Robert Osfield
4cd437d7d4
Refactored the use of the MasterOperation so that it now gets attached to the
...
Viewer via the new Viewer::addUpdateOperation() method, rather than need a
custom Viewer::updateTraversal().
2007-08-11 12:43:31 +00:00
Robert Osfield
8248b6fac9
Removed now redundent ReaderWriterTerrain.cpp
2007-08-09 08:15:38 +00:00
Robert Osfield
1c6193ba78
Renamed osgTerrain::TerrainNode to osgTerrain::Terrain and introduced basic
...
.osg read support for osgTerrain::Terrain.
2007-08-07 19:53:57 +00:00
Robert Osfield
14fcf4f8b3
Converted usleep call to OpenThreads::Thread::microSleep() to avoid VS build problems
2007-07-21 20:11:16 +00:00
Robert Osfield
a4433e9af4
Added reset it to set block correctly before use.
2007-07-19 18:59:20 +00:00
Robert Osfield
1ed0e0a861
Improved the filtering of changes to master file to prevent using reading from
...
files that are still under going changes.
2007-07-19 17:02:37 +00:00
Robert Osfield
c3adce3ef4
Added osg::RefBlockCount subclassed from the new OpenThreads::BlockCount and used it into osgterrain example
2007-07-19 15:24:11 +00:00
Robert Osfield
fb1a34a8c5
Added support for using multiple load threads as a thread pool used by the MasterOperation
2007-07-19 12:09:25 +00:00
Robert Osfield
035f49c0b3
Refactored the viewer setup code to use a CustomViewer subclass of Viewer which
...
wraps up the set up of compile contexts and merging of changes.
2007-07-18 16:17:06 +00:00
Robert Osfield
ea5ca995e3
Merged the new master operation/operation thread code with older standard
...
terrain set up code.
2007-07-17 16:18:13 +00:00
Robert Osfield
04c1dee7a2
Fixed GraphcicsContext::getMaxContextID so it properly returns the current max contextID.
...
Fixed the osgviewer's compile context code to account for the above fix.
Added compile context support into osgterrain example.
2007-07-17 10:54:17 +00:00
Robert Osfield
610a76b210
Fixed typo
2007-07-17 09:15:08 +00:00
Robert Osfield
b132aed217
Work in progress on support for dynamically reading a master file in a background thread
2007-07-16 21:39:30 +00:00
Robert Osfield
e40d346fbb
Added MasterOperation to do file querry and loading and background thread.
2007-07-16 17:40:38 +00:00
Robert Osfield
166ac4a7d3
Added custom colour support to TransferFunction setup.
2007-07-16 15:47:42 +00:00
Robert Osfield
d4aaa31549
Improvements to the .terrain file support
2007-07-16 15:13:47 +00:00
Robert Osfield
f9fab3c3b0
First steps at provide a .terrain file format to experiment with file
...
definitions of terrain subgraphs
2007-07-16 12:37:39 +00:00