Commit Graph

13246 Commits

Author SHA1 Message Date
Robert Osfield
47db2da8b4 From Andreas Henne, Support for GL3 core profile in osgText
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14717 16af8721-9629-0410-8352-f15c8da7e697
2015-02-25 18:56:29 +00:00
Robert Osfield
7d50c8e634 From Michael McDonnell, "I have changed the code so that the plus key increases both the inner
and outer tessellation. The minus key decrease both the inner and
outer tessellation. You can still use the arrow keys to control inner
and outer tessellation separately."

From Robert Osfield, clean up the code to fix warnings and make the coding style more consistent with the rest of the OSG.


git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14716 16af8721-9629-0410-8352-f15c8da7e697
2015-02-25 16:59:43 +00:00
Robert Osfield
e7d41377be Fixed handling of NULL entries in osg::Geometry TexCoordArrayList and VertexAttribArrayList.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14715 16af8721-9629-0410-8352-f15c8da7e697
2015-02-25 14:55:59 +00:00
Robert Osfield
213efd20ad Fixed matrix setup.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14714 16af8721-9629-0410-8352-f15c8da7e697
2015-02-24 11:06:05 +00:00
Robert Osfield
bd3f390b2f Fixed image allocation operations.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14712 16af8721-9629-0410-8352-f15c8da7e697
2015-02-23 20:28:28 +00:00
Robert Osfield
594b3064c0 From Miha Ravšelj and Robert Osfield, fix for serializer bug in osgText::TextBase and osg::Camera
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14711 16af8721-9629-0410-8352-f15c8da7e697
2015-02-23 11:43:21 +00:00
Robert Osfield
685a270c18 From Arjun Ramamurthy, fix for use of StatsHandler in multipleviews/windows
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14709 16af8721-9629-0410-8352-f15c8da7e697
2015-02-23 11:07:03 +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
72c4f3a8ba Removed redudent shaders, and updated remaining shaders to match OpenSceneGraph-Data/shaders
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14705 16af8721-9629-0410-8352-f15c8da7e697
2015-02-20 15:04:56 +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
5c023d1f76 Moved osgTerrain::GeometryPool from osgTerrain::DisplacementMappingTechnique to the osgTerrain::Terrain
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14703 16af8721-9629-0410-8352-f15c8da7e697
2015-02-18 10:52:52 +00:00
Robert Osfield
e5d51da1b3 From Sebastian Messerschmidt, "Attached you find a version of the ReaderWriterDDS with info outputs set to OSG_INFO instead of OSG_NOTICE. The old version spams the console for each loaded DDS file."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14701 16af8721-9629-0410-8352-f15c8da7e697
2015-02-18 10:23:14 +00:00
Robert Osfield
4cb5bce66a Added support for DefineList to StateSet::merge(..)
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14700 16af8721-9629-0410-8352-f15c8da7e697
2015-02-17 20:42:12 +00:00
Robert Osfield
3e2305d815 From Stephan Wenglorz, "the attached fix corrects a small bug in OperationThread::setDone(bool), calling it had the opposite effect of what was intended, i.e. setting done to false actually finished the thread. The effect was that VPB threads would exit before starting osgdem when a task had been enqueued, because they initially set done to false."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14699 16af8721-9629-0410-8352-f15c8da7e697
2015-02-17 19:40:58 +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
441dbe6b02 Removed commented out lines
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14696 16af8721-9629-0410-8352-f15c8da7e697
2015-02-17 19:21:29 +00:00
Robert Osfield
53198f2e9b Cleaned up warning generated when compiling osgocculusviewer
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14695 16af8721-9629-0410-8352-f15c8da7e697
2015-02-17 10:36:41 +00:00
Robert Osfield
6bddbdf074 Improvements to the #pragma(tic) shader composition support
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14694 16af8721-9629-0410-8352-f15c8da7e697
2015-02-13 12:50:43 +00:00
Robert Osfield
77b8962bcc Deprecated the old ShaderComposition example code so that it's now only invoked if you add a --old to the osgshadercomposition command line.
Introduced a new shader composition example based on the new #pragama and #define based GLSL shader/osg::StateSet::setDefine() functionality now built into the core OSG.


git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14692 16af8721-9629-0410-8352-f15c8da7e697
2015-02-13 10:56:59 +00:00
Robert Osfield
a40260a5a5 From Farshid Lashkari, "I've attached a fix for some internal glu functions so that they use size_t for computing allocation sizes instead of GLint. I encountered some large images that were triggering integer overflows with the current code."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14690 16af8721-9629-0410-8352-f15c8da7e697
2015-02-13 07:45:49 +00:00
Robert Osfield
66210a6aca Fixed warning
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14689 16af8721-9629-0410-8352-f15c8da7e697
2015-02-11 19:21:27 +00:00
Robert Osfield
9fa3defb0e Added reassignment of the #version line to the first entry in the source list.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14688 16af8721-9629-0410-8352-f15c8da7e697
2015-02-11 16:41:31 +00:00
Robert Osfield
4a9f4aae9d Added GL #define for Windows build
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14687 16af8721-9629-0410-8352-f15c8da7e697
2015-02-11 09:41:15 +00:00
Robert Osfield
a676d5d37b Windows build fix
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14686 16af8721-9629-0410-8352-f15c8da7e697
2015-02-10 21:13:16 +00:00
Robert Osfield
06f186dc07 Added GL_LINES_ADJACENCY_EXT variants back into ObjectWraper to enable backwards compatibility.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14685 16af8721-9629-0410-8352-f15c8da7e697
2015-02-10 18:01:02 +00:00
Robert Osfield
ea7dbabda1 Change for new Program API
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14684 16af8721-9629-0410-8352-f15c8da7e697
2015-02-10 17:53:29 +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
b90503fdf5 Introduced new shader composition approach that utilizes #pragma requires(), #pragma import_defines() and #ifdef in GLSL to enable multiple different versions of shaders based
on defines passed in from osg::StateSet::setDefine(..).



git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14681 16af8721-9629-0410-8352-f15c8da7e697
2015-02-10 17:04:02 +00:00
Robert Osfield
bb637e73f3 Fixed typo.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14680 16af8721-9629-0410-8352-f15c8da7e697
2015-02-04 15:11:00 +00:00
Robert Osfield
1debc21bb2 Removed unncessary _EXT
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14679 16af8721-9629-0410-8352-f15c8da7e697
2015-02-03 16:36:19 +00:00
Robert Osfield
bbb54cedc7 Commented out the experimental V8 and Python plugins as these plugins only existed as a proof of concept test linkage with these dependenices, and have no functionality beyond this.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14678 16af8721-9629-0410-8352-f15c8da7e697
2015-02-02 09:53:55 +00:00
Robert Osfield
a9804d7e19 Replaced _EXT defines with GL-3.2 versions
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14677 16af8721-9629-0410-8352-f15c8da7e697
2015-01-27 15:07:53 +00:00
Robert Osfield
045caf1086 From Javier Taibo,
"I have found a "bug" in the new audio decoding code (actually I think the bug is in ffmpeg, but anyway it should be wise to protect the OSG plug-in about it). I am attaching a security check in FFmpegDecoderAudio.cpp.

If anybody is curious about the problem, it happens sometimes when decoding an AAC audio stream. It eventually includes a PCE block inside the AAC audio frame and then ffmpeg audio decoding function signals a "new_frame" with 1024 samples, but a null pointer instead of the audio data. It can be easily detected because in these cases number of channels is 0. Maybe this is the intended behaviour for ffmpeg, but I find it quite weird.
"

" It seems that libav does not have a channels attribute in AVFrame structure. This new version should do."


git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14676 16af8721-9629-0410-8352-f15c8da7e697
2015-01-23 17:15:20 +00:00
Robert Osfield
4bcf4cf7bb Changed osgFX::MultiTextureControl so that it uses an osg::FloatArray internally to enable sharing with osg::Uniform.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14675 16af8721-9629-0410-8352-f15c8da7e697
2015-01-23 13:51:09 +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
f5faf615ef Added #define GL_SEPARATE_ATTRIBS and correcte GL_INTERLEAVED_ATTRIBS
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14673 16af8721-9629-0410-8352-f15c8da7e697
2015-01-22 16:49:00 +00:00
Robert Osfield
51b19d2d8b From Alexey Pavlov, "Export fix for Windows platform"
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14672 16af8721-9629-0410-8352-f15c8da7e697
2015-01-22 16:41:34 +00:00
Robert Osfield
e330e9309c Added GL_INTERLEAVED_ATTRIBS for windows build
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14671 16af8721-9629-0410-8352-f15c8da7e697
2015-01-22 15:08:26 +00:00
Robert Osfield
4a668d53c5 Fixed warning
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14670 16af8721-9629-0410-8352-f15c8da7e697
2015-01-22 15:07:50 +00:00
Robert Osfield
d5f2c34f24 From Andreas Henne, OpenGL core profile fixes required for OSX.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14669 16af8721-9629-0410-8352-f15c8da7e697
2015-01-21 15:35:19 +00:00
Robert Osfield
7fbeeefea8 Added TextureWeights uniform support and controls to osgFX::MultiTextureControl to support usage with shaders.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14668 16af8721-9629-0410-8352-f15c8da7e697
2015-01-21 11:09:29 +00:00
Robert Osfield
3ab06c54bf Re-enabled texturing and fixed runtime warning
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14667 16af8721-9629-0410-8352-f15c8da7e697
2015-01-20 18:01:10 +00:00
Robert Osfield
51afa2c1df Added hardwired geometry shaders
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14666 16af8721-9629-0410-8352-f15c8da7e697
2015-01-20 17:58:56 +00:00
Robert Osfield
a0f1442aae Updated shaders
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14664 16af8721-9629-0410-8352-f15c8da7e697
2015-01-20 17:40:46 +00:00
Robert Osfield
98f5fca9c2 Added key osgTerrain::GeometryPool methods virtual to make it easier to override the shaders
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14662 16af8721-9629-0410-8352-f15c8da7e697
2015-01-20 15:23:06 +00:00
Robert Osfield
0a4efa35c3 Changed the reset of the GLExtensions::Set() in the State destructor so that it checks to see if the local _glExtensions pointer has been set up and taken ownership of the GLExtensions::Set() value
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14661 16af8721-9629-0410-8352-f15c8da7e697
2015-01-20 11:24:31 +00:00
Robert Osfield
3eca5765c9 Added GeometryPool::s/getUseGeometryShader() hint, and OSG_TERRAIN_USE_GEOMETRY_SHADER env var for setting the default value.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14660 16af8721-9629-0410-8352-f15c8da7e697
2015-01-19 11:29:55 +00:00
Robert Osfield
249c0ff208 Added support for using geometry shaders to align the quad diagonals with the local terrain
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14658 16af8721-9629-0410-8352-f15c8da7e697
2015-01-16 11:03:11 +00:00
Robert Osfield
3e3d7e4dc1 Added a local Vec3Array cache to the HeightFieldDrawable to facilitate efficient intersection testing
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14656 16af8721-9629-0410-8352-f15c8da7e697
2015-01-12 10:31:58 +00:00
Robert Osfield
ed57c8718c Added ability to populate a local vertex cache for when one computes final vertex position in a vertex shader but still want to the Primitive functors to work with the transformed positions.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14655 16af8721-9629-0410-8352-f15c8da7e697
2015-01-12 10:30:50 +00:00