Commit Graph

8519 Commits

Author SHA1 Message Date
Robert Osfield
bd7ec9c5f7 Added initial cut of basic scripting support, introducing an osg::Script object to wrap up the individual scripts, osg::ScriptCallback for assigning a Script as node callback and an osg::ScriptEngine base class that plugins implement to provided support for specific scripting languages.
Provided are lua, python and V8 (for javascript) plugins that just open up enough of a link to the respective libs to run a script, there is no scene graph <-> script communication in current implementation.
2013-08-09 16:51:06 +00:00
Robert Osfield
babd6e0ee7 Removed CameraNode reference 2013-08-09 11:00:55 +00:00
Robert Osfield
93ebfd6217 Added translucent version of cushion which isn't depth tested to enable one to see the cursor even when it's behind other objects 2013-08-08 17:21:20 +00:00
Robert Osfield
82401defc7 Added osgPresentation::Cursor class to wrap up 3D cursor in the scene functionality 2013-08-08 16:49:33 +00:00
Robert Osfield
0c609bc17e From Aurelien Albert, "I've go some problem with the method "State_Utils::replace" : if the original_phrase is empty, it leads to an infinite loop.
Here is a path to prevent this."
2013-08-05 12:00:34 +00:00
Robert Osfield
5f6a1f4093 From Anish Thomas, added catch for to an empty DrawElementsUInt creation. 2013-08-01 11:25:02 +00:00
Robert Osfield
14f63cbe67 From Ulrich Hertlein, "Based on the exchange on osg-users I went ahead and reworked shp/XBaseParser to avoid
weird behaviour (closing stdin) and leaking file descriptors, as well as some const-ness."
2013-08-01 10:28:12 +00:00
Robert Osfield
46ec50aecb From Sebastian Messerschmidt, "Seems like your re-factoring didn't really produces the correct results.
You can check with the tester2.flt provided earlier and check with the result image.
I double checked this with OpenFlight creator, and it seems the yaw is broken.

With my initial quaternion version is seems correct and if I change the


float cos_yaw = cosf(osg::inDegrees(yaw));
float sin_yaw = sinf(osg::inDegrees(yaw));

to be
float cos_yaw = cosf(osg::inDegrees(-yaw));
float sin_yaw = sinf(osg::inDegrees(-yaw));

it seems to work as well."
2013-08-01 10:04:05 +00:00
Robert Osfield
837a680849 From Tom Jolley, "I found a couple more bugs after closely looking at the small piece of deprecated geometry in my model. There were problems with more than one primitive in a couple places. The first was the number of vertices were not being accumulated for DrawArraysPrimitiveType (caused another crash). The second is I had to move target_vindex and source_pindex before the PrimitiveSetList loop so they don't get reset on the next primitive (otherwise you end up with a lot of zeros in per vertex lists)." 2013-08-01 10:00:31 +00:00
Robert Osfield
07365c1073 Added osg::RenderInfo::pushRenderBin()/popRenderBin() and RenderInfo::getRenderBinStack() and getCameraStack() access methods for getting access to the current RenderBin/RenderStage. 2013-08-01 07:19:45 +00:00
Robert Osfield
364e2765e7 Added Intersector::get/setEpsilon(double) to allow users to control what epsilon is used by the LineSegmentIntersector when doing testing of itersections with bounding boxes 2013-07-31 13:11:49 +00:00
Robert Osfield
9878a83894 From Tom Jolly, "I ran across this error reading one of our older files. An iterator was being changed inside a loop that caused a crash." 2013-07-31 06:56:31 +00:00
Robert Osfield
56cb7de72a From Sergey Kurdakov, fixed GLES2 invalid enumerant warning by disabling the check against GL_MAX_TEXTURE_COORDS under GLES. 2013-07-31 06:42:49 +00:00
Robert Osfield
0620f249a5 Changed default of serialize draw to off 2013-07-24 17:30:46 +00:00
Robert Osfield
75fd039dba Added GL2Extensions::isDrawBuffersSupported() and usage of this in FrameBufferObject.cpp to prevent crash under GLES2 when users attempt to use MRT when it's not supported 2013-07-24 13:02:32 +00:00
Robert Osfield
ee5a1b0a83 Fixed warning 2013-07-24 12:48:59 +00:00
Robert Osfield
085d3af14c From Rocco Martino, build fix for compiling against ffmpeg/trunk 2013-07-23 18:11:35 +00:00
Robert Osfield
ca3efe6bdc Added NOT ANDROID to force use of posix API when building for Android under Windows 2013-07-23 15:28:31 +00:00
Robert Osfield
c21b60b038 Added lazy setting of the UserDataContainer to avoid unncessarily create a UserDataContain when an empty description list is passed to Node::setDescriptions(..) 2013-07-23 10:24:28 +00:00
Robert Osfield
51075421d3 Fixed crash when open(..) returns an error. 2013-07-23 09:54:25 +00:00
Robert Osfield
fcca4032ef From Andreas Ekstrand, "Attached is a small modification of the Collada writer that protects from crashes due to valArray being NULL in some situations." 2013-07-22 13:31:32 +00:00
Robert Osfield
4a2e1534d5 From Christian Ruzicka, "with the current touch implementation on iOS the touches are not forwarded to parent views because the base implementation is not called. Also see the "Best Practices" in the iOS documentation for event handling:
http://developer.apple.com/library/ios/#documentation/EventHandling/Conceptual/EventHandlingiPhoneOS/multitouch_background/multitouch_background.html

"If you handle events in a subclass of any other UIKit responder class:
- You do not have to implement all of the event handling methods.
- In the methods you do implement, be sure to call the superclass implementation. For example, [super touchesBegan:touches withEvent:event]."

I added the missing lines and tested it with OSG 3.1.9 and iOS SDK 6.1."
2013-07-19 21:05:54 +00:00
Robert Osfield
f21a1dc9ad Added default setting of BIND_PER_VERTEX when applying Geometry::setTexCoordArray() 2013-07-19 20:59:09 +00:00
Robert Osfield
b3aa1bda1d Updated OpenThreads version to be in sync with OSG version 2013-07-19 17:00:24 +00:00
Robert Osfield
a270a7635e From Wang Rui, "A very small clerical error in the src/osgViewer/CMakeLists.txt makes MinGW/Cygwin builds fail. Now it is fixed and now OSG works well again with Cygwin. :-) The OSC plugin also needs a small fix to compile with Cygwin, as attached file src/osgPlugins/osc/osc/OscHostEndianness.h shows." 2013-07-19 06:39:06 +00:00
Robert Osfield
5255884fec Added a dirty() call to Image::setData(..) 2013-07-18 20:17:48 +00:00
Robert Osfield
62374833dd From Laurens Voerman, "some of my ive files now generate a warning:
Warning, can't assign attribute binding as no has been array assigned to set binding for.

I think those are ive's with bumpmaps, but I have not checked yet. The problem is in
OpenSceneGraph\src\osgPlugins\ive\Geometry.cpp
where the code tries to set Normalize and Binding for a missing Array.
I think that code can safely be skipped, considering the write function has a hardcoded write when the array is missing. (introduced in svn rev 13488)

modified file (OpenSceneGraph\src\osgPlugins\ive\Geometry.cpp) attached  in Zip"
2013-07-02 14:17:44 +00:00
Robert Osfield
330de18eba From Laurens Voerman, "Recent changes cause a few warnings in MSVC 2012
svn 13587 From David Callu, warning fixes and removal of spaces at end of lines.

this can be fixed by adding a space before the comment opening /*.
full modified file (openscenegraph\src\osgplugins\osg\BinaryStreamOperator.h) attached in zip

Regards, Laurens.


openscenegraph\src\osgplugins\osg\BinaryStreamOperator.h(71): warning C4138: '*/' found outside of comment (OpenSceneGraph\src\osgPlugins\osg\ReaderWriterOSG2.cpp)
openscenegraph\src\osgplugins\osg\BinaryStreamOperator.h(73): warning C4138: '*/' found outside of comment (OpenSceneGraph\src\osgPlugins\osg\ReaderWriterOSG2.cpp)
openscenegraph\src\osgplugins\osg\BinaryStreamOperator.h(211): warning C4138: '*/' found outside of comment (OpenSceneGraph\src\osgPlugins\osg\ReaderWriterOSG2.cpp)
openscenegraph\src\osgplugins\osg\BinaryStreamOperator.h(213): warning C4138: '*/' found outside of comment (OpenSceneGraph\src\osgPlugins\osg\ReaderWriterOSG2.cpp)"
2013-07-02 14:02:06 +00:00
Robert Osfield
8420b158c1 Restructed handling of the _currentShaderCompositionUniformList in State::apply() and State::apply(const StateSet*) so that it can be used even when shader composition isn't enabled. 2013-07-02 13:45:23 +00:00
Robert Osfield
095b64dc41 From Aurelien Albert, "Recently I had to integrate a client OpenGL library with OSG. For textures and other StateAttribute I've done that by subclassing osg::StateAttribute and this works well.
But for glPrograms, in order to get all osg's uniform management system to work, I had to subclass osg::program::PerContextProgram.

Here is a modified version of this class, which add some "virtual" method to allow easy subclassing."
2013-07-02 10:32:53 +00:00
Robert Osfield
d3c2896651 Added SceneView::Options enum enetries APPLY_GLOBAL_DEFAULTS and CLEAR_GLOBAL_STATESET to control whether a _globalStateSet->clear() and _globalStateSet->setGlobalDefaults() should be called.
osgViewer::Renderer doesn't use these enum settings so now no longer has a calls StateSet::clear() or StateSet::setGlobalDefaults() on the osg::Camera's StateSet.  Previously these were being
called and breaking the ability to attached state to Camera's StateSet.
2013-07-02 09:27:14 +00:00
Robert Osfield
0abbef71e1 From Pjotr Svetachov, "In a submission on June 27th a lot of new array types were added. This modified the osg::Array::Type enum. Because of this s_ArrayNames array in Array.cpp is now not in sync. This can lead to corrupt exports or crashes when writing .osg files because the change added new types in the middle of the enum instead of at the end.
Attached is a new Array.cpp to reflect the new array types."
2013-07-01 16:15:25 +00:00
Robert Osfield
0289b05cd5 Fixed debug build compile problem 2013-07-01 09:09:49 +00:00
Robert Osfield
a64b412885 Reverted the usage of OSG_UNUSED and OT_UNUSED as in hindsight these should never have been merged. Adding code to quieten
inappropriate warnings is a bad programming practice and does not desrve a place in the OSG code base.
2013-07-01 08:21:13 +00:00
Robert Osfield
e876e0bad3 From John Kaniarz, "This patch modifies ReaderWriterPNG.cpp to
1. Check the bit depth of the passed Image and return an error if not 8 or 16. (not fully featured, but still an improvement over hard coded 8bit for everything)
2. Endian swap 16bit image data when on a little endian architecture.
"
2013-06-28 15:44:04 +00:00
Robert Osfield
88a8423802 From Marcel Pursche, fixed checking of destination dimensions in osg::copyImage. 2013-06-28 14:38:45 +00:00
Robert Osfield
d4e1a8d6a3 From Lilin Xiong, "When writing proxyNode to ive file, we forget "LoadingExternalReferenceMode ". Add some code to fix this.
if (out->getVersion() >= VERSION_0045)
{
    out->writeInt(getLoadingExternalReferenceMode());
}

if (in->getVersion() >= VERSION_0045)
{
   setLoadExternalReferenceFiles( (osg::ProxyNode::LoadingExternalReferenceMode)in->readInt() );
}
"
2013-06-28 14:32:12 +00:00
Robert Osfield
2e41e3f656 From Gill Peacegood, "fix for a memory leak in the DelaunayConstraint class" 2013-06-28 14:21:43 +00:00
Robert Osfield
5db57cfa34 Fixed handling of DISPLAY=127.0.0.1:2 usage. 2013-06-28 14:07:31 +00:00
Robert Osfield
353b18b27b From Aurelien Albert, Added support for glPrimitiveRestartIndex.
"The idea of this new OpenGL feature is :

- set RestartIndex = "n"
- draw elements strip
  -> when the index is "n", the strip is "stopped" and restarted

It's very usefull for drawing tiles with a single strip and a "restart" at the end of each row.

The idea a an OSG StateAttribute is :

Usually we use to build geometry from code, because software modelers rarely support it (and 3d file formats doesn't support it) :

-RootNode <= "PrimitiveRestartIndex=0"     // So now, we know that our restart index is 0 for all drawables under this node
|
- Drawable 1 : triangles => as usual
|
- Drawable 2 : triangles strip => as usual
|
- Drawable 3 : triangles strip + "GL_PRIMITIVE_RESTART" mode = ON => use the restart index
|
- Drawable 4 : triangles strip + "GL_PRIMITIVE_RESTART" mode = ON => use the restart index
|
- Drawable 5 : triangles strip => as usual


With a StateAttribute, it's easy for the developper to say "0 will be my restart index for all this object" and then activate the mode only on some nodes.

The main problem is if you set and restart index value which is not included in the vertex array (for exemple set restart index = 100 but you have only 50 vertex). There is no problem with OpenGL, but some OSG algorithms will try to access the vertex[100] and will segfault.

To solve this, I think there is two ways :

1/ add restart index in osg::PrimitiveSet and use this value in all algorithms. It's a lot of work, maybe dangerous, and it concern only a few situations : developpers who use this extension should be aware of advanced OpenGL (and OSG) data management

2/ use a StateAttribute, and choose a "correct" restart index. In my applications, I always use "0" as a restart index and duplicate the first vertex (vertex[0] = vertex[1]). So there is no difference for OpenGL and all OSG algorithms works properly.
"
2013-06-28 13:43:46 +00:00
Robert Osfield
b2c838033d Added handling of an odd number rows in the capsule rendering and primitive calculation. 2013-06-28 12:45:39 +00:00
Robert Osfield
097aedf23c From David Callu, warning fixes and removal of spaces at end of lines. 2013-06-28 12:00:43 +00:00
Robert Osfield
db1f2c5eb1 From David Callu, added support for glVertexAttribLPointer and glVertexAttribIPointer, utilized via osg::Array::setPreserveDataType(true); 2013-06-28 10:51:22 +00:00
Robert Osfield
4fd6566e00 From David Callu, serializer support for new Vec* and Vec*Array classes 2013-06-28 08:57:42 +00:00
Robert Osfield
f2c1a7597c 2013-06-28 08:11:46 +00:00
Robert Osfield
775c1443eb From David Callu, "Added Vec3ub, Vec3us, Vec4us, Vec2ub and Vec2us classes" 2013-06-27 17:37:03 +00:00
Robert Osfield
9f13e2fcb9 From Lionel Lagarde, "Support for paging and shared PBO"
"The attached file contains:
- a per-context read counter in GLBufferObject::BufferEntry
- a global client counter in BufferData
- the glue between Texture* and Image client counter
"
2013-06-27 16:44:32 +00:00
Robert Osfield
57947ea75c From Aurelien Albert, added passing on of the gl array normalize to OpenGL when uses vertex attribute aliasing. 2013-06-27 15:18:38 +00:00
Robert Osfield
90ceb88c12 Replaced deprecatated osg::Geometry::get*Binding() calls. 2013-06-27 14:46:16 +00:00
Robert Osfield
dfc1a899db Added Geometry::containsDeprecatedData() / fixDeprecatedData() 2013-06-27 13:37:26 +00:00
Robert Osfield
092dd93be8 Removed deprecated usage of osg::Geometry::get*Binding() 2013-06-27 10:58:26 +00:00
Robert Osfield
c1ebc3ac0c Replaced deprecated osg::Geometry::set*Binding() usage 2013-06-27 08:44:15 +00:00
Robert Osfield
38bb71460a Replaced deprecated Geometry::set*Binding() 2013-06-27 08:30:51 +00:00
Robert Osfield
8e65ab7e45 Replaced deprecated Geometry::set*Binding() usage 2013-06-26 18:06:09 +00:00
Robert Osfield
5a25a93bdd Removed deprecated Geometry::set*Binding() usage 2013-06-26 17:58:57 +00:00
Robert Osfield
7ee05a345a Replaced deprecated osg::Geometry::set*Binding() usage 2013-06-26 17:45:19 +00:00
Robert Osfield
55416d83b3 Replaced deprecated osg::Geometry::set*Binding() calls. 2013-06-26 17:44:30 +00:00
Robert Osfield
a459033eff From Sebastian Messerschmidt, "I've taken some time and refactored some places where the old set*Binding were used." 2013-06-26 16:16:23 +00:00
Robert Osfield
bead0740f2 From Aurelien Albert, "This submission allow the user to specify how to setup VertexAttributeAliasing.
I think this is necessary on OpenGL 3.2+ since this is no more "default" locations in the OpenGL specs.

The default behaviour stay the same.

There is a few new methods on osg::State :

- resetVertexAttributeAlias : reset all vertex alias to osg's default ones
- set**Alias : set a vertex attribute alias configuration
- setAttributeBindingList : set the attribute binding list (allow to specify an empty list if you're using "layout" qualifier in glsl code to specify the bindings. This save some CPU operations)"
2013-06-26 13:00:12 +00:00
Robert Osfield
ea2cbee347 Removed spaces from end of line 2013-06-26 12:33:40 +00:00
Robert Osfield
71c1fc87bb Fixed bug in TemplateTargetAttributeDispatch that was causing a crash with the osgsimplegl3 example 2013-06-26 12:33:14 +00:00
Robert Osfield
6377e37e88 From Pjotr Svetachov and Robert Osfield, "the index mesh and vertex pre-transform optimizers can rearrange or change the size of arrays assigned to a geometry. This leads to crashes or corrupt geometry when using shared arrays.
Attached a fix that duplicates shared geometry arrays."
2013-06-26 09:04:20 +00:00
Robert Osfield
b70dfd40aa Removed Geometry::fixDeprecatedData() as it won't work on const Geometry 2013-06-26 08:53:56 +00:00
Robert Osfield
36f48f2227 From Mathias Froehlich, "The attached file replaces the deprecated geometry use in osgSim.
The per primitive use is changed to full per vertex arrays."
2013-06-26 07:08:26 +00:00
Robert Osfield
1793466442 With assistance from Sukender, moved the depreacted osg::Geometry vertex indices and AttributeBinding definitions out into a separated namespace/class so to use
deprecated features you should now use deprecated_osg::Geometry in place of osg::Geometry.
2013-06-25 16:10:24 +00:00
Robert Osfield
ba9ccd91a1 From Cedric Pinson, "I fixed a little issue with the lightwave scene loader. On the version 5 there are id on the command LoadObjectLayer in the scene file and of this version the current code use this field as a part of the filename, and it fails because the file is not found.
I just added a field version_ to read it at the beginning and added extra code to check it and read the extra field if needed and read the good filename"
2013-06-24 12:51:02 +00:00
Robert Osfield
84d7d9a056 From Christian Ruzicka, "when MSAA is activated on iOS, the stencil attachment is not added (Stencil buffer is not working at all). Attached are the needed changes to make MSAA + stencil working on iOS.
Tested with OSG 3.1.7 and iOS SDK 6.1."
2013-06-24 12:31:48 +00:00
Robert Osfield
ba2242decb From Mourad Boufarguine, "Attached is a fix for the ply reader to use the output of osgDB::findDataFile.
"
2013-06-24 11:40:16 +00:00
Robert Osfield
6331a54a68 From Luc Frauciel, "You'll find attached a modification of DXWriter to support Material color:
If a material is present, the diffuse color is affected to current layer."
2013-06-24 11:39:26 +00:00
Robert Osfield
0896bd17bd From Lars Nillson, "The change in this submission is to take care of the setting given by a call to
setMaximumNumOfObjectsToCompilePerFrame(…).


Sometimes if you give a low number, more than the expected number of objects are compiled."
2013-06-24 11:14:13 +00:00
Robert Osfield
ca2688b046 Convert usage to use const versions of containers 2013-06-24 11:03:59 +00:00
Robert Osfield
261db64a9e From Farshid Lashkari, "I've attached a small patch that extends the Image::readImageFromCurrentTexture method to support more depth texture pixel formats (16, 24, 32, 32F). In order to compile, I moved some depth pixel format definitions from FrameBufferObject to Image.
"
2013-06-24 09:51:30 +00:00
Robert Osfield
70ae69648d From Nick Black, "Hey there! avcodec_open() has been deprecated for some time, and indeed has
been removed in the most recent versions of libavcodec/ffmpeg. You're
already using avcodec_open2() elsewhere, but one appears to have been
missed. The change is trivial:

[skynet](0) $ svn diff
Index: src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp
===================================================================
--- src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp        (revision 13355)
+++ src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp        (working copy)
@@ -109,7 +109,7 @@
         //    m_context->flags |= CODEC_FLAG_TRUNCATED;

         // Open codec
-        if (avcodec_open(m_context, p_codec) < 0)
+        if (avcodec_open2(m_context, p_codec, NULL) < 0)
             throw std::runtime_error("avcodec_open() failed");
     }

[skynet](0) $

I've applied similar changes this year to many other packages, including
cheese, blender, linphone, ad nauseam. It's been tested by verifying that
with my patch, OSG builds against the newest libavcodec and ffmpeg, whereas
otherwise it does not.

The modified src/osgPlugins/ffmpeg/FFmpegDecoderAudio.cpp is attached. It
originates in svn trunk revision 13355. Thanks!"
2013-06-24 09:12:58 +00:00
Robert Osfield
48020eed9e Introduced typedef's to make the code more readble and maintanable 2013-06-24 09:02:32 +00:00
Robert Osfield
4044fd5a74 From Wang Rui, "The file attached includes two new features for the serialization IO functionality. First, custom serializer version control should work now, just by defining a new REGISTER_CUSTOM_OBJECT_WRAPPER macro. For example:
// A custom class
namespace CustomDomain {

class MyGroup : public osg::Group
{
public:
    META_Node( CustomDomain, MyGroup );

    void setMyName( const std::string& n );
    const std::string& getMyName() const;

    void setMyID( int id );
    int getMyID() const;

    ...
};

}

// The serialization wrapper using a custom domain name
REGISTER_CUSTOM_OBJECT_WRAPPER( MyDomain,
                                CustomDomain_MyGroup,
                                new CustomDomain::MyGroup,
                                CustomDomain::MyGroup,
                                "osg::Object osg::Node osg::Group CustomDomain::MyGroup" )
{
    ADD_STRING_SERIALIZER( MyName, std::string() );
    {
        UPDATE_TO_VERSION_SCOPED( 1 );  // Updated for a new domain version
        ADD_INT_SERIALIZER( MyID, 0 );
    }
}

Save the class instance as follows:
osgDB::writeNodeFile( *myGroup, "serializer_test.osgt", new osgDB::Options("CustomDomains=MyDomain:1") );

The output file will include the domain version definition and all the class data, and can be read back. We can also force setting the domain version by the CustomDomains option while reading the saved files. If we save the class instance without any options, MyID will be ignored because the default domain version is 0.

This may help third-party libraries like osgEarth to maintain their own serializers without regarding to the OSG soversion changes.

Another feature added is a more robust binary format, which in fact adds a size-offset at each block's beginning. When there are problems or unsupported data types while reading, we can now directly jump to the block end indicated by the offset value. So a .osgb file will automatically ignore bad data and read remains as normal (at present it will fail at all). This feature will not break the backward compatibility, and can be disabled by setting "RobustBinaryFormat=false" while writing out.

Hope these changes can work smoothly with present and future community projects. Maybe we should also consider have an osgserializer example to test and demonstrate all things we can do now."
2013-06-24 08:48:55 +00:00
Robert Osfield
b3f0479118 From Wang Rui, "Sorry for my very slow response because of some personal issues. I found that new Geometry serializers can't work with old .osgb files. The modified FastPathHint serializer doesn't correctly read from the stream and thus jumbles following inputs. The file attached can be placed in osgWrappers/serializers/osg to fix that problem.
"
2013-06-24 08:22:50 +00:00
Robert Osfield
340a47dc66 From Wang Rui, "The osgdb_ffmpeg plugin may not work with latest ffmpeg windows sdk and will say "The procedure entry point xxx could not be located in xxx.dll" instead. The following link describes the reason (maybe a certain optimization problem of the VS compiler):
http://forum.videolan.org/viewtopic.php?f=32&t=98097

After adding the /OPT:NOREF, the problem has gone.

"
2013-06-24 08:19:34 +00:00
Robert Osfield
db4b7584fb From Farshid Lashkari, "In many game engines it is common to set the W component of the tangent vector to -1 if the UVs are mirrored and 1 if not. I've updated the osgUtil::TangentSpaceGenerator class to do the same." 2013-06-24 08:18:08 +00:00
Robert Osfield
df3626be27 Fixed author name error introduced by xxdiff 2013-06-21 14:37:35 +00:00
Robert Osfield
59d53b40a1 Removed unneccessary handling of BIND_PER_PRIMITIVE on output code 2013-06-21 14:17:42 +00:00
Robert Osfield
9d9543ca0a From Pjotr Svetachov, introduced use of osg::observer_ptr<osg::Camera> in place of osg::Camera* 2013-06-21 13:59:18 +00:00
Robert Osfield
da134aa8ed From Stephan Huber, "attached you'll find the missing readObject-implementations for the imageio-plugin as suggested by Remo Eichenberger." 2013-06-21 13:41:03 +00:00
Robert Osfield
cb09fff797 From Laurens Voerman, build fix 2013-06-21 12:10:44 +00:00
Robert Osfield
18d6d298bf Build fixes for new osg::Geometry 2013-06-21 10:59:03 +00:00
Robert Osfield
deb074120e Converted osg::Geometry::ArrayData usage across to osg::Array. 2013-06-21 10:14:18 +00:00
Robert Osfield
25f0d2ccde From Laurens Voerman, "I just tested openGL quadbuffered stereo with the osgviewer, the mouse works again, so does the keystonecorrection, but the right-eye render to texture camera appears not to clear it's color buffer.
I found the problem in src\osgViewer\View.cpp, fix attached."
2013-06-21 10:03:49 +00:00
Robert Osfield
6eabca211b Converted ArrayData usage across to set*Array() usage with new binding parameter 2013-06-21 09:47:04 +00:00
Robert Osfield
15fea448d8 Added new osg::Array::Binding parameter to osg::Geometry::set*Array(osg::Array* array, osg::Array::Binding binding=osg::Array::BIND_UNDEFINED) methods to make it easier for the user
to set the binding without the need to call the deprecated osg::Geometry::set*Binding(osg::Geometry::AttributeBinding)
2013-06-21 09:43:15 +00:00
Robert Osfield
d0f4086a57 From FrancoisTigeot, "OpenSceneGraph 3.0.1 doesn't build out of the box on DragonFly and needs
a few modifications to these files:
  - applications/present3D/Cluster.cpp
  - src/osgDB/FileUtils.cpp

The changes are needed to fix a few platform specific things such as the
absence of stat64, int/socklen_t differences, etc... and are in the same
line as Linux, Apple and FreeBSD specific checks.

I have attached the modified files; the original patches to 3.0.1 are
also visible here if you find it more convenient:
http://dl.wolfpond.org/dports/graphics.osg/dragonfly/patch-applications_present3D_Cluster.cpp
http://dl.wolfpond.org/dports/graphics.osg/dragonfly/patch-src_osgDB_FileUtils.cpp

With these changes, osg 3.0.1 is able to be built and packaged on DragonFly
whereas it previously failed to compile."
2013-06-21 09:17:28 +00:00
Robert Osfield
c3f28a52e4 From Matthias Helsing, "Here is the changed source to prefer using _NET_WM_STATE_ABOVE but fall back to XRaiseWindow should the Atoms not be supported. I'm not sure how many might be using the raiseWindow feature but I needed it for a splash on Ubuntu 12.04." 2013-06-21 08:56:24 +00:00
Robert Osfield
4738a2607b From Farshid Lashkari, "I've updated the dds, png, and jpeg plugins to support writing images with the GL_DEPTH_COMPONENT pixel format. They will simply treat it the same as the GL_LUMINANCE pixel format." 2013-06-21 08:37:47 +00:00
Robert Osfield
715dd4e930 Fixed the handling the mouse min/max ranges of slave Cameras that have a parent Camera with a viewport. 2013-06-20 16:44:14 +00:00
Robert Osfield
a2b2ba5860 Temporarily commented out call to view.assignStereoOrKeystoneToCamera() for implementing stereo as this was causing problem in trackball manipulation 2013-06-20 15:48:14 +00:00
Robert Osfield
603c280b62 Added local namespace for util functions, and fixed the return type of checkDeprecatedData() 2013-06-20 15:18:51 +00:00
Robert Osfield
eaa3afcd21 Commented out verbose debug messages for shader composition 2013-06-20 10:59:00 +00:00
Robert Osfield
7d2f9f3a0d From Juan Manuel Alvarez, "When handling keyboard events on osgQt, if a key is kept pressed, multiple sequences of KEYDOWN -> KEYUP events are fired.
This is because Qt auto repeats keyboard events, so multiple calls are made to GLWidget::keyPressEvent and GLWidget::keyReleaseEvent by Qt, and subsequently translated to OSG events.

The way to solve this is ignoring key released auto repeated events (see http://qt-project.org/doc/qt-4.8/qkeyevent.html#isAutoRepeat), so multiple KEYDOWN events are fired, but only one KEYUP.

I attach a modified osgQt/GraphicsWindowQt.cpp with this change."
2013-06-20 10:05:56 +00:00
Robert Osfield
9b095b2936 From Laurens Voerman, build fix for VS. 2013-06-20 09:27:50 +00:00
Robert Osfield
47c4c7c389 Removed svn:executable property 2013-06-19 17:26:59 +00:00
Robert Osfield
083c0f97d2 Removed svn:executable property. 2013-06-19 17:25:55 +00:00
Robert Osfield
df075ef9bb Cleaned up usage of BIND_PER_PRIMITIVE where possible. 2013-06-19 16:24:59 +00:00