Robert Osfield
4704621c39
Replaced (long int) with more portable (GLint64)
2016-02-18 10:58:26 +00:00
Robert Osfield
0244b234ca
From Tony Vasile, "This is a fix for the handling of OpenFlight files with switches whose children have a transformation matrix on them. It may break other things and I have only tested this with one of my models."
2016-02-18 10:07:29 +00:00
Robert Osfield
09fd75dcf4
From Mourad Boufarguine, "This submission fixes typos in Uniform::getTypename() method in Uniform.cpp (missing "r" in usampler names)."
2016-02-18 09:28:33 +00:00
Robert Osfield
c3d45732a1
Renamed zero and one to transparentCount and opaqueCount to avoid confusion in their meaning and usage.
2016-02-18 08:59:26 +00:00
Robert Osfield
89f74b1a56
Fixed warning
2016-02-17 17:36:10 +00:00
Robert Osfield
6089257d3c
Commented out unused functions and variable.
2016-02-17 17:08:07 +00:00
Robert Osfield
97336b89ac
Introduced a separate GLuint64 one variable to get around a 32bit build timer issue under Windows.
2016-02-17 16:03:26 +00:00
Robert Osfield
229b833a5a
Fixed check against Drawable::isCullingActive().
...
Removed old code intended to check the Geode parent of a Drawable to see if it's CullingActive is true as this was broken by the change osg::Drawable being derived from osg::Node rather than osg::Object.
2016-01-27 10:10:01 +00:00
Robert Osfield
bf1aa5088e
Revert "From Jannik Heller and Robert Osfield, introduced ReadResult/WriteResult::statusMessage() method that creates a std::string from the stutus value and message string."
...
as this submission was meant for the master only, not the binary compatible 3.4 branch.
This reverts commit df97a18a5754ed39ac43044ad9557e8409790ff3.
2016-01-25 12:18:32 +00:00
Robert Osfield
e798db04c8
From John Farrier, "Best I can tell, there is an enumeration for NEVER_CHECK_GL_ERRORS in CheckForGLErrors, defined in State. State.cpp does check to see if you want MORE error checking, but there is no way to turn OFF error checking. This change allows disabling of OpenGL error checking."
2016-01-25 10:49:23 +00:00
Robert Osfield
adbadd66be
From Patrick Neary, "In ShaderComposer::getOrCreateProgram(), tesselation control and evaluation shaders are processed but not added to the shader program."
2016-01-25 10:26:52 +00:00
Robert Osfield
bd0cf5e47d
Changed the prototype from NULL to osg::DummyObject to address a bug in reading .osgt + .osgx where an image is written out but fails to read the file causes subsequent parts of the file to be mis-read
2016-01-22 10:14:35 +00:00
Robert Osfield
ff1051a6fd
From Jannik Heller and Robert Osfield, introduced ReadResult/WriteResult::statusMessage() method that creates a std::string from the stutus value and message string.
2016-01-19 17:39:03 +00:00
Robert Osfield
3e23c5b22d
From Wojciech Lewandowski, Visual Studio 2008 compatibility fix
...
Two fixed files:
osgPlugins/osgjs/JSON_Objects
osgPlugins/stl/ReaderWriterSTL.cpp.
They did not compile with VS 2008 (recent master from Github). It looks like they defined stdint types (missing in VS 2008) but code using them also included <osg/Types> header. Errors were caused by minor differences in signed int definitions. I just removed own definitions and added include<osg/Types> instead. It solves the problem and makes the code clearer now.
2015-12-14 18:47:09 +00:00
Robert Osfield
5675d86c9b
From Jordi Torres, Fix for missing header file in distribution
...
osg/TriangleLinePointIndexFunctor was not being installed because it was not added to the CMakeLists.txt
2015-11-23 13:17:06 +00:00
Robert Osfield
5405d9c465
Added support for copying include/osgViewer/config headers on make install.
2015-11-23 12:29:25 +00:00
Robert Osfield
3b17418031
Fixed warning message
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15179 16af8721-9629-0410-8352-f15c8da7e697
2015-11-09 15:14:07 +00:00
Robert Osfield
9fc6850962
From Jannik Heller, fixed typo of OSG_COMPIlE_CONTEXTS env var
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15175 16af8721-9629-0410-8352-f15c8da7e697
2015-11-08 11:59:23 +00:00
Robert Osfield
46904ff67a
From Mathias Froehlich, "Avoid per frame X11 roundtrips"
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15174 16af8721-9629-0410-8352-f15c8da7e697
2015-11-05 14:38:19 +00:00
Robert Osfield
636d595912
From Alberto Luaces, "here are two minimal capitalization fixes for mingw cross-compilation, where case sensitivity matters."
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15172 16af8721-9629-0410-8352-f15c8da7e697
2015-10-26 11:43:28 +00:00
Robert Osfield
5310a96c73
Restructed the setting of the RenderStage ClearColor/ClearMask to make the code more readable and to avoid double setting of the ClearMask.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15170 16af8721-9629-0410-8352-f15c8da7e697
2015-10-26 11:41:44 +00:00
Robert Osfield
5dc251a5c1
From Sebastian Messershmidt, "The uncommented pointer type QTimerEvent */*event*/ leads to a compiler error under visual studio 2010"
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15168 16af8721-9629-0410-8352-f15c8da7e697
2015-10-23 11:07:30 +00:00
Robert Osfield
6a67be2e32
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/branches/OpenSceneGraph-3.4@15165 16af8721-9629-0410-8352-f15c8da7e697
2015-10-22 14:14:53 +00:00
Robert Osfield
74f1838960
Added osg::flushAllDeletedGLObjects to clean up of graphics context after the existing osg::deleteAllGLObjects() to catch any cases where delete doesn't flush GL objects.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15149 16af8721-9629-0410-8352-f15c8da7e697
2015-10-08 15:58:22 +00:00
Robert Osfield
f4e71bad3a
OSG_INIT_SINGLETON_PROXY into DatabasePager::prototype() and Registry::instance(), removing the InitRegistry proxy object in src/osgViewer/ViewerBase.cpp.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15148 16af8721-9629-0410-8352-f15c8da7e697
2015-10-05 11:18:46 +00:00
Robert Osfield
05f3e038d8
Added fix for case when Renderer is assigned to a Camera that has now View
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15142 16af8721-9629-0410-8352-f15c8da7e697
2015-09-25 11:15:09 +00:00
Robert Osfield
1a9a74216b
Refactored osgViewer::Renderer's handled of FrameStamp to avoid threading conflicts
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15139 16af8721-9629-0410-8352-f15c8da7e697
2015-09-25 10:10:10 +00:00
Robert Osfield
6344d4430d
From John Hedström,"Texture2DArray support for the .osg serializer"
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15137 16af8721-9629-0410-8352-f15c8da7e697
2015-09-24 14:14:43 +00:00
Robert Osfield
3c7bf7ec8a
Fixed line endings
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15133 16af8721-9629-0410-8352-f15c8da7e697
2015-09-24 09:29:15 +00:00
Robert Osfield
87e5c54ee7
From Jannik Heller, "I've hit what I believe to be a bug (or at the very least, an unintuitive behaviour) in the osg::Geometry copy constructor. I noticed it when using osg::clone on a Geometry with vertex buffer objects, and the copy flags DEEP_COPY_ARRAYS. To be precise, I add a Geometry to an osgUtil::IncrementalCompileOperation, then osg::clone the Geometry. I was getting reports from users of random crashes happening.
...
I believe the offending lines are in the osg::Geometry copy constructor:
if ((copyop.getCopyFlags() & osg::CopyOp::DEEP_COPY_ARRAYS))
{
if (_useVertexBufferObjects)
{
// copying of arrays doesn't set up buffer objects so we'll need to force
// Geometry to assign these, we'll do this by switching off VBO's then renabling them.
setUseVertexBufferObjects(false);
setUseVertexBufferObjects(true);
}
}
Toggling the vertex buffer objects off then on again actually touches not only the arrays controlled by DEEP_COPY_ARRAYS, but also the PrimitiveSets which are controlled by DEEP_COPY_PRIMITIVES. This means if the user has copyflags of only DEEP_COPY_ARRAYS, we are modifying arrays that belong to the original const Geometry& we are copying from. I believe this shouldn't be allowed to happen because we are using a const& specifier for the original Geometry.
In my case the osgUtil::IncrementalCompileOperation was trying to compile the geometry, while in the main thread a clone operation toggled the VBO's off and on, a crash ensues.
In the attached patch, you will find a more efficient handling of VBO's in the osg::Geometry copy constructor, so that only the Arrays that were actually deep copied have their VBO assigned, and no changes are made to Arrays that already had a valid VBO assigned. In addition, the DEEP_COPY_PRIMITIVES flag is now honored so that VBO's are set up correctly should a user copy a Geometry with only that flag.
"
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15128 16af8721-9629-0410-8352-f15c8da7e697
2015-09-04 15:35:14 +00:00
Robert Osfield
4ee38248a2
From Julien Valentin, "Serializing custom geometry i ran into a crash due to a
...
setVertexAttribArrayList(array) with array containing NULL vertexAttrib.
I added a test in order to avoid it
Code:
void Geometry::setVertexAttribArrayList(const ArrayList& arrayList)
{
_vertexAttribList = arrayList;
dirtyDisplayList();
if (_useVertexBufferObjects)
{
for(ArrayList::iterator itr = _vertexAttribList.begin();
itr != _vertexAttribList.end();
++itr)
{
if(itr->get())//ADDED
addVertexBufferObjectIfRequired(itr->get());
}
}
}
"
and
"The bug i ran into is a crash reading osgt Geometry with null vertexattribs.
The only thing i added is a not nul check on array passed to setVertexAttribArrayList."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15122 16af8721-9629-0410-8352-f15c8da7e697
2015-09-04 14:35:03 +00:00
Robert Osfield
b92c3f1455
Merged shaders from svn/trunk that refactor the workaround to the NVidia driver bug
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15111 16af8721-9629-0410-8352-f15c8da7e697
2015-08-12 10:19:15 +00:00
Robert Osfield
471b256d30
Refactored workaround of NVidia nan length bug.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15097 16af8721-9629-0410-8352-f15c8da7e697
2015-08-11 20:08:07 +00:00
Robert Osfield
8f73ddc27d
Moved the FIND_PACKAGE(Boost) from the root CMakeLists.txt into the local Find scripts to avoid Boost check when not neccessary.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15094 16af8721-9629-0410-8352-f15c8da7e697
2015-08-11 08:44:46 +00:00
Robert Osfield
697128a11d
From svn/trunk merged support for passing the GL_VENDOR string into the #pragma(tic) shader compositions defines
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15089 16af8721-9629-0410-8352-f15c8da7e697
2015-08-10 19:56:53 +00:00
Robert Osfield
b74924fab4
Updated built-in shaders from OpenSceneGraph-Data vesion that introduce #pragma(tic) shaders that resolve the NVidia loop iteration bug.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15082 16af8721-9629-0410-8352-f15c8da7e697
2015-08-10 19:39:18 +00:00
Robert Osfield
75217a2ed5
Quietened down #pragma(tic) shader composition messages
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15080 16af8721-9629-0410-8352-f15c8da7e697
2015-08-10 19:19:03 +00:00
Robert Osfield
2bed348da1
Build fix for VS and installing TYpes
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15076 16af8721-9629-0410-8352-f15c8da7e697
2015-08-10 05:04:39 +00:00
Robert Osfield
e8722e76ea
Changed GLint64 and GLuint64 to use int64_t and uint64_t (pulled in via include/osg/Types) to avoid conflict with Qt5 definitions
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15072 16af8721-9629-0410-8352-f15c8da7e697
2015-08-09 10:16:03 +00:00
Robert Osfield
8b4ff0f50a
Added #idef guards for SGIX usage
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15070 16af8721-9629-0410-8352-f15c8da7e697
2015-08-09 09:40:59 +00:00
Robert Osfield
559da06ffa
From Glenn Waldron, fix error in ZIP plugin handling of memory buffer
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15068 16af8721-9629-0410-8352-f15c8da7e697
2015-08-08 08:49:53 +00:00
Robert Osfield
1186143571
Merged workaround for NVidia driver/GPU bug by updating shaders from svn/trunk that change float to int usage.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15062 16af8721-9629-0410-8352-f15c8da7e697
2015-08-06 15:04:36 +00:00
Robert Osfield
732364d49b
Added checks for the validity of chached coordinate arrays.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15061 16af8721-9629-0410-8352-f15c8da7e697
2015-08-06 15:03:50 +00:00
Robert Osfield
5e8d5b50db
From Andy Skinner, "Someone was using our code on a system that does not seem to have the SGIX symbols used in osgViewer.cpp.
...
I used osgSetGLExtensionsFuncPtr to remove the symbols. I don't know how to test this path, but it did remove the symbols from libosgViewer.so. I have also not been able yet to see if that was sufficient for our customer.
I did this by looking at other cases, and I tried to follow some of the same practices in PixelBufferX11, like using _useSGIX in a similar way to the previous _useGLX1_3."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15042 16af8721-9629-0410-8352-f15c8da7e697
2015-08-03 19:14:11 +00:00
Robert Osfield
91fd245d7c
From Jannik Heller, "Here is a patch for the S3TC capability check.
...
On a Intel HD graphics Linux system with Mesa 10.1.3, I found that osg's Extensions::isTextureCompressionS3TCSupported() returned false, even though S3TC compressed textures *are* in fact working. I tested this by loading and rendering various DXT1, DXT3 and DXT5 compressed textures in the OSG.
"glxinfo | grep s3tc" gives:
GL_S3_s3tc
Note, if I install the package "libtxc-dxtn-s2tc0", I get in addition:
glxinfo | grep s3tc
GL_EXT_texture_compression_s3tc
GL_S3_s3tc
However, S3TC compressed textures worked correctly within the OSG even without libtxc-dxtn-s2tc0 installed.
I'm not sure what the differences between these extensions are, but based on the description at https://www.opengl.org/registry/specs/S3/s3tc.txt I would assume that both will work for OSG's purposes. The attached patch changes isTextureCompressionS3TCSupported() to accept either extension."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15034 16af8721-9629-0410-8352-f15c8da7e697
2015-07-31 13:44:36 +00:00
Robert Osfield
8e9f688809
From Kristofer Tingdahl, warning fixes.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15031 16af8721-9629-0410-8352-f15c8da7e697
2015-07-31 10:54:17 +00:00
Robert Osfield
6c1c179c62
Compile fix for Mingw.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15028 16af8721-9629-0410-8352-f15c8da7e697
2015-07-31 10:27:08 +00:00
Robert Osfield
761cf52bb7
Added explicit initialization of osg::Referenced(true) to osg::Operation subclasses as it uses virtual inhertiance from osg::Referenced.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15024 16af8721-9629-0410-8352-f15c8da7e697
2015-07-23 15:46:39 +00:00
Robert Osfield
0a56f65077
Fixed indentation
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15019 16af8721-9629-0410-8352-f15c8da7e697
2015-07-23 14:30:39 +00:00
Robert Osfield
3339395071
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15018 16af8721-9629-0410-8352-f15c8da7e697
2015-07-23 14:03:15 +00:00
Robert Osfield
34e53a37e0
Warning fixes for Clang-3.6
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15017 16af8721-9629-0410-8352-f15c8da7e697
2015-07-23 11:14:00 +00:00
Robert Osfield
482fd41d58
Added missing handling of lightnumber and associate lights
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15014 16af8721-9629-0410-8352-f15c8da7e697
2015-07-23 09:23:32 +00:00
Robert Osfield
2eef9d233b
Changed the GL_HEADER_HAS_GLINT64 and GL_HEADER_HAS_GLUINT64 to use cmakedefine to improve handling of when cmake doesn't find GLint64 and GLuint64.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15012 16af8721-9629-0410-8352-f15c8da7e697
2015-07-23 07:39:01 +00:00
Robert Osfield
8e20224828
From svn/trunk merged automatic detection of GLint64 + GLuint64 in GL headers
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@15003 16af8721-9629-0410-8352-f15c8da7e697
2015-07-22 14:27:36 +00:00
Robert Osfield
6e65a9955e
Added check for validity of OpenFlight shininess value.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14999 16af8721-9629-0410-8352-f15c8da7e697
2015-07-21 14:22:01 +00:00
Robert Osfield
8c991c056f
Reduced debug message verbosity.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14994 16af8721-9629-0410-8352-f15c8da7e697
2015-07-20 13:23:50 +00:00
Robert Osfield
6273495c64
Changed the _MSC_VER check to <= 1700 to support VS2012.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14988 16af8721-9629-0410-8352-f15c8da7e697
2015-07-20 07:42:00 +00:00
Robert Osfield
8f26396e78
Reinstated the TIFFSetField(image, TIFFTAG_ROWSPERSTRIP, rowsperstrip);
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14986 16af8721-9629-0410-8352-f15c8da7e697
2015-07-19 09:51:17 +00:00
Robert Osfield
887768b55a
From Patrick Neary, "To the tiff plugin, add the capability to write tiff images with unsigned short data"
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14970 16af8721-9629-0410-8352-f15c8da7e697
2015-07-17 08:12:51 +00:00
Robert Osfield
5b1cfd26ab
From Patrick Neary, "Added some lesser used tokens that we use from GL_ARB_texture_rg to computeFormatDataType(), and computeNumComponents() in src/osg/Image.cpp"
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14966 16af8721-9629-0410-8352-f15c8da7e697
2015-07-16 19:16:54 +00:00
Robert Osfield
f48a4baa4e
From Cory Slep and Robert Osfield, "When using Open Scene Graph and Qt on Android, the resulting thread that an application developer’s Q*Application is run on is different than what Qt considers the “main” thread, which can cause subtle problems. This is because Qt loads native libraries in one thread, and later runs the application in a different thread. They delay running in the second thread as long as possible as they have a nontrivial bootstrapping process. The motivation for Qt having this second thread is to allow them to remain responsive to both Java and native events, and capture events that would otherwise be “missed”
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14964 16af8721-9629-0410-8352-f15c8da7e697
2015-07-16 15:56:40 +00:00
Robert Osfield
49c802153d
Added check to catch cases where the backdrop coordinate cache is too small for the number of contexts being computed.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14962 16af8721-9629-0410-8352-f15c8da7e697
2015-07-16 11:01:50 +00:00
Robert Osfield
13e79d3210
Added initializers and reverted OSX workaround from 2013.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14960 16af8721-9629-0410-8352-f15c8da7e697
2015-07-15 10:02:31 +00:00
Robert Osfield
ccae59e98a
Added _defineList into the osg::StateSet::compare() implementation to address issues with osgUtil::Optimizer ignoring defines.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14949 16af8721-9629-0410-8352-f15c8da7e697
2015-07-14 08:25:20 +00:00
Robert Osfield
222871aade
Added Text::GlyphQuads::release/resizeGLObjects() and handling of inconsistent contextID sizes to avoid crashes when viewers and scene graphs aren't initialized correctly to the right number of contexts.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14946 16af8721-9629-0410-8352-f15c8da7e697
2015-07-13 16:09:40 +00:00
Robert Osfield
d221133728
Standardize the call to setUpThreading() in CompositeViewer/Viewer::realize().
...
Standardize the call to scene->resizeGLObjects().
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/branches/OpenSceneGraph-3.4@14945 16af8721-9629-0410-8352-f15c8da7e697
2015-07-13 16:04:38 +00:00
Robert Osfield
98ebacdcbb
Fixed repeated name in SETUP_PLUGIN.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14936 16af8721-9629-0410-8352-f15c8da7e697
2015-07-02 11:58:49 +00:00
Robert Osfield
f0ac1a16f9
Build fix
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14934 16af8721-9629-0410-8352-f15c8da7e697
2015-07-02 08:57:08 +00:00
Robert Osfield
74ddaeaf50
From Mathias Froehlich, added seriliazers for new osg::ClipControl
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14930 16af8721-9629-0410-8352-f15c8da7e697
2015-07-01 05:10:20 +00:00
Robert Osfield
b4cd40cf7c
From Mathias Froehlich, "Attached a new state attribute implementing the glClipControl that appeared with GL4.5."
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14928 16af8721-9629-0410-8352-f15c8da7e697
2015-06-30 09:11:00 +00:00
Robert Osfield
5cd478e4bb
Quitened down debug for ViewConfig argument parsing
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14927 16af8721-9629-0410-8352-f15c8da7e697
2015-06-30 08:39:33 +00:00
Robert Osfield
d3baf9d311
Build fix for GLDAL>=2
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14925 16af8721-9629-0410-8352-f15c8da7e697
2015-06-30 08:38:01 +00:00
Robert Osfield
b5a3a58076
From Jannik Heller, fixed clearReferencesToDependentCameras() calls
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14922 16af8721-9629-0410-8352-f15c8da7e697
2015-06-19 09:51:30 +00:00
Robert Osfield
3bcfad833c
Fixed handling of use GLObjectsVisitor for modifying scene graph state without compiling to OpenGL so that the visitor can be run safely without a graphics context being current.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14921 16af8721-9629-0410-8352-f15c8da7e697
2015-06-17 16:25:47 +00:00
Robert Osfield
6f00eb2548
Small tidy up to make script more readable.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14920 16af8721-9629-0410-8352-f15c8da7e697
2015-06-16 17:18:11 +00:00
Robert Osfield
4ec0e76c0b
Added QT_QTCORE_INCLUDE_DIR entry to qfont plugin build to fix Qt4 build under Linux
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14919 16af8721-9629-0410-8352-f15c8da7e697
2015-06-16 17:17:50 +00:00
Robert Osfield
1e0d682979
From Jannik Heller, "I've added the check for Qt version mismatches into osgQt as suggested in http://forum.openscenegraph.org/viewtopic.php?t=14999 .
...
When an application is built with Qt4, but osgQt was built with Qt5 (or vice versa), upon #includeing osgQt users will receive an #error aborting the build.
This at least provides a proper error message rather than a crash, while we are working on better fixes for the problem."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14918 16af8721-9629-0410-8352-f15c8da7e697
2015-06-15 19:59:01 +00:00
Robert Osfield
1e78098967
From Farshid Lashkari, "I've modified some setter methods of TextBase to avoid unnecessary calls to computeGlyphRepresentation() if the value has not changed."
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14912 16af8721-9629-0410-8352-f15c8da7e697
2015-06-12 08:04:42 +00:00
Robert Osfield
e76c91ed78
From Colin McDonald, "An earlier fix in OSG 3.2 has been inadvertently lost in 3.3.x. The glGenerateMipMap function is part of the GL_EXT_framebuffer_object extension. Just checking if the function is present before using it for texture mipmaps is not sufficient, as on remote X-windows displays the client side capability may be different from the display server. This can lead to mipmapped textures failing to render. I've restored a fbo extension check. I've also tided up the GL version checking a little."
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14907 16af8721-9629-0410-8352-f15c8da7e697
2015-06-10 16:47:15 +00:00
Robert Osfield
d2e0081690
From Philippe Renon, "Fixed potential divide by zero in NodeTrackerManipulator : The divide by zero happens when throwing a NodeTrackerManipulator.
...
The infinite result trickles down and later causes NaN in culling.
The fix was to use getThrowScale() as done everywhere else."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14905 16af8721-9629-0410-8352-f15c8da7e697
2015-06-10 10:00:27 +00:00
Robert Osfield
11a55ea6de
Added supoort for osg::CullSettings/Camera::InheritanceMaskActionOnAttributeSetting and InheritanceMask properties.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14904 16af8721-9629-0410-8352-f15c8da7e697
2015-06-09 16:49:20 +00:00
Robert Osfield
7e05d2fd54
Introduce osg::Object::asNode(), asNodeVisitor(), asStateAttribute() and asUniform() to replace dynamic_cast<> usage in Callback.cpp.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14902 16af8721-9629-0410-8352-f15c8da7e697
2015-06-09 10:49:34 +00:00
Robert Osfield
4073910ce8
From Mike Connell, "Give ReadFileCallback access to parent location : These small changes to the database pager allow user code in the ReadFileCallback to safely determine where the file being loaded is destined to be inserted into the scenegraph.
...
"
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14899 16af8721-9629-0410-8352-f15c8da7e697
2015-06-08 11:18:24 +00:00
Robert Osfield
ceabbdb8d9
Addressed race condition where SceneView::setLightingMode() was setting a shread Master Camera's StateSet.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14898 16af8721-9629-0410-8352-f15c8da7e697
2015-06-08 10:20:53 +00:00
Robert Osfield
f7f1487fca
Fixed setReferenceTime() bug where a * eather than the correct / was being used. Bug and fix suggested Benjamin Richter.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14896 16af8721-9629-0410-8352-f15c8da7e697
2015-06-07 11:13:02 +00:00
Robert Osfield
32b60cd2d7
From Jannik Heller, Transform::computeBound() optimization.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14894 16af8721-9629-0410-8352-f15c8da7e697
2015-06-04 09:13:05 +00:00
Robert Osfield
fd46645ade
From KOS, "New classes for osgAnimation presented: UpdateFloatUniform, UpdateVec3fUniform and UpdateMatrixfUniform (based on UpdateUniform template)
...
Classes operate like osgAnimation::UpdateMaterial for Material's diffuse component, but change Uniform."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14890 16af8721-9629-0410-8352-f15c8da7e697
2015-06-03 09:14:35 +00:00
Robert Osfield
e7244e654a
Build fix for when Uniform::Callback isn't defined
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14887 16af8721-9629-0410-8352-f15c8da7e697
2015-06-03 08:38:18 +00:00
Robert Osfield
da73723949
From Konstantin Matveyev, serializer support for UniformCallback
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14886 16af8721-9629-0410-8352-f15c8da7e697
2015-06-02 10:25:13 +00:00
Robert Osfield
e3f0876e87
From Konstantin Matveyev, "I've changed osg::Uniform::Callback to osg::UniformCallback.
...
osg::UniformCallback inherits osg::Callback now.
I don't really now if this class should be inside osgWrappers/serializers
because StateAttributeCallback is not presented there, but i've included it in the patch.
Please see archive in the attachment.
PS
DEEP_COPY_UNIFORMS works for me.
"
Note from Robert Osfield, added typedef UniformCallback Callback for backwards compatibility.
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14885 16af8721-9629-0410-8352-f15c8da7e697
2015-06-02 09:33:22 +00:00
Robert Osfield
ba9dfb2ff6
From Albert Luaces, typo fixes.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14883 16af8721-9629-0410-8352-f15c8da7e697
2015-06-01 13:40:20 +00:00
Robert Osfield
d14a602a59
From Jannik Heller, typo fixes
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14882 16af8721-9629-0410-8352-f15c8da7e697
2015-06-01 13:11:49 +00:00
Robert Osfield
e0028bef6e
From Jannik Heller, "This patch adds a missing initialization of osgParticle::ParticleProcessor::_frameNumber in the copy constructor.
...
I noticed this because valgrind was complaining about use of uninitialized memory."
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14881 16af8721-9629-0410-8352-f15c8da7e697
2015-06-01 12:14:53 +00:00
Robert Osfield
120bf699b2
From Frashud Lashkari, "I was getting "Unsupported wrapper class..." error messages when attempting to load osgb models simultaneously from multiple threads. I believe the problem is caused by un-synchronized access to the global osgDB::ObjectWrapperManager class. I've attached a change that adds a mutex to the class and uses it when accessing the internal wrapper/compress maps. This appears to fix the issues I was having."
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14880 16af8721-9629-0410-8352-f15c8da7e697
2015-06-01 12:07:04 +00:00
Robert Osfield
78a01ce2a5
From Jannik Heller, "I have added new functions Texture::generateAndAssignTextureObject mirroring the Texture::generateTextureObject functions.
...
I have left the Texture::generateTextureObject functions intact as I'm not sure if/how it's used outside the core OSG. If you feel that compatibility isn't important in that area feel free to drop it.
While testing the build with OSG_USE_REF_PTR_IMPLICIT_OUTPUT_CONVERSION=OFF I found a compile error in GlyphGeometry.cpp that was entirely unrelated to the changes I've made. The fix is included in the patch.
There is one thing left to fix and that is Texture2D::SubloadCallback:
class OSG_EXPORT SubloadCallback : public Referenced
{
public:
....
virtual TextureObject* generateTextureObject(const Texture2D& texture, State& state) const
{
return osg::Texture::generateTextureObject(&texture, state.getContextID(), GL_TEXTURE_2D);
}
...
}"
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14879 16af8721-9629-0410-8352-f15c8da7e697
2015-06-01 10:50:44 +00:00
Robert Osfield
44c406e167
From Jannik Heller, build fix
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14878 16af8721-9629-0410-8352-f15c8da7e697
2015-06-01 10:41:43 +00:00
Robert Osfield
f72b62a065
From Jannik Heller, fix for race condition in orphanded BufferObject handling.
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14877 16af8721-9629-0410-8352-f15c8da7e697
2015-05-29 07:52:27 +00:00
Robert Osfield
4f423ff66b
From Colin McDonald, "rc/osgUtl/MeshOptimizers.cpp won't compile on some systems due to a missing std:: namespace prefix."
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14876 16af8721-9629-0410-8352-f15c8da7e697
2015-05-26 17:24:48 +00:00
Robert Osfield
906bb27fa0
From Farshid Lashkari, "attached a small change to osgUtil::SceneView that prevents unnecessary calls to glClear when the split stereo separation is 0."
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14875 16af8721-9629-0410-8352-f15c8da7e697
2015-05-26 17:22:05 +00:00
Robert Osfield
0f35f31d72
From Thomas Hogarth, "Little fix for ClassInterface::getSupportedProperties, before if you set searchAssociates to false then it would return the same BaseSerialiser::Type for every entry in the PropertyMap as i was not being incremented on line 539. Fix attached."
...
git-svn-id: http://svn.openscenegraph.org/osg/OpenSceneGraph/trunk@14874 16af8721-9629-0410-8352-f15c8da7e697
2015-05-26 17:17:26 +00:00