Re: [osg-users] Add a new child
On Mon, Sep 27, 2010 at 9:36 PM, Cosimo Luigi Manes man...@cheapnet.it wrote: the problem is that i load new nodes when the sg running Could it be that your camera isn't being updated to look at your new models? Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osg-submissions] QTKit plugin checked in, OSX users please test ; -)
Hi Eric, Am 27.09.10 19:28, schrieb Eric Wing: There are some other QTKit changes in Snow Leopard. It is now possible to display one QuickTime movie object in multiple views or layers. Due to changes with QuickTime X, the attributes QTMovieCurrentSizeAttribute and QTMovieSizeDidChangeNotification have been deprecated. Their replacements are called QTMovieNaturalSizeAttribute (to get “authored” size) and QTMovieNaturalSizeDidChangeNotification. I believe his notes are correct. I think you want QTMovieSizeDidChangeNotification and not QTMovieEditedNotification in your fix. Hm, I am a bit lost... I copied the code from http://developer.apple.com/library/mac/#documentation/Cocoa/Conceptual/QTKitApplicationTutorial/CustomizingtheMediaPlayerApplication/CustomizingtheMediaPlayerApplication.html (search for QTMovieNaturalSizeDidChangeNotification) I'll try your suggestion later this day and report back cheers, Stephan ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Shadows : Creating multiple osgShadow::ShadowedScene
Let's take an example: ShadowTechnique SHADOWMAP It creates a texture and installs a shader program which makes shadow effects by using the created texture. So what you think happens by the second shadowScene? On traversal it will create a new texture, by default install it in the same texture unit, and install a shader using just this newly created shadow texture. What you expect is a shader program using 2 shadow textures. But this one you have to write yourself. - Werner - On Tuesday 28 September 2010 06:29:50 Saravanan Sivaprahasam wrote: Thanks for the reply. But could any one explain me why it is not possible to add two osgShadow::ShadowedScene to the root node Thank you! Cheers, Saravanan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32115#32115 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- TEXION Software Solutions TEXION GmbH - Rotter Bruch 26a - D 52068 Aachen - HRB 14999 Aachen Fon: +49 241 475757-0, Fax: +49 241 475757-29, web: http://www.texion.eu Geschäftsführer/Managing Director: Werner Modenbach ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Add a new child
On 28/09/10 17:19 , Robert Osfield wrote: On Mon, Sep 27, 2010 at 9:36 PM, Cosimo Luigi Manes man...@cheapnet.it wrote: the problem is that i load new nodes when the sg running Could it be that your camera isn't being updated to look at your new models? I believe what Robert is referring to is this: that the camera will initially compute a position that shows the entire scene graph *at that time* (based on the current scene bounding sphere). This position won't be updated afterwards so if you add nodes they might not be in view. What happens when you press 'space' to reset the camera position? Cheers, /ulrich ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] Can I find a StateSet which has been setName?
Hi! Since the StateSet inherits from Object,so i can setName to a specific StateSet.Then can I find the StateSet by its name?Is there any way to do this such like to find a Node through its name? Thanks very much! ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Preparing for OpenSceneGraph-2.9.9 developer release, please test :-)
Hi, It sounds like the Aero bug, disable Aero? Believe Wojtek may have just submitted a fix for this to workaround the driver bug, also the latest beta driver from NVidia fixes this for me, not sure about a quadro card... Might be worth trying the beta NVidia drivers? Cheers Martin. -Original Message- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of jago jagoc Sent: 27 September 2010 14:57 To: OpenSceneGraph Users Subject: Re: [osg-users] Preparing for OpenSceneGraph-2.9.9 developer release, please test :-) Hi, it compiles without any problem (with examples enabled), when I start any examples that use full-screen display the screen goes black. My configuration: Windows Vista Business,64 bit (SP2) Quadro FX 3600M ( v. 258.96 ) osg - Revision 11792 Cheers, Jagovic ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Add a new child
Ulrich Hertlein wrote: On 28/09/10 17:19 , Robert Osfield wrote: What happens when you press 'space' to reset the camera position? Well, when i press 'space', software shows the nodes. How can i reset the camera position ? -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32122#32122 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Preparing for OpenSceneGraph-2.9.9 developerrelease, please test :-)
Hi, NVidia 260.63 fixes single screen. Multi screen is still a mess. And Nvidia ControlPanel does not show on some machines including mine. Wojtek Lewandowski -- From: Martin Naylor martinnay...@virginmedia.com Sent: Tuesday, September 28, 2010 10:29 AM To: 'OpenSceneGraph Users' osg-users@lists.openscenegraph.org Subject: Re: [osg-users] Preparing for OpenSceneGraph-2.9.9 developerrelease, please test :-) Hi, It sounds like the Aero bug, disable Aero? Believe Wojtek may have just submitted a fix for this to workaround the driver bug, also the latest beta driver from NVidia fixes this for me, not sure about a quadro card... Might be worth trying the beta NVidia drivers? Cheers Martin. -Original Message- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of jago jagoc Sent: 27 September 2010 14:57 To: OpenSceneGraph Users Subject: Re: [osg-users] Preparing for OpenSceneGraph-2.9.9 developer release, please test :-) Hi, it compiles without any problem (with examples enabled), when I start any examples that use full-screen display the screen goes black. My configuration: Windows Vista Business,64 bit (SP2) Quadro FX 3600M ( v. 258.96 ) osg - Revision 11792 Cheers, Jagovic ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] osg newbie question: billboard with multiple drawables?
Hi, I'm hoping someone can help. I'm trying to develop an in-scene 'label' for my 3D objects (consisting of text and geometry). I was hoping I'd be able to use the osg billboard and add my geometry and text to it as drawables, but I now realise that each drawable will have its own pivot point, so my text and geometry will become misaligned. Is there a way to massage the billboard such that it 'groups' all its children and effectively applies a single transformation about a single pivot point (hence keeping the text and geometry in the same plane)? Or can anyone suggest a simpler / better approach to the problem? Just to reiterate - I'm trying to create screen-facing labels to insert into my 3D scene - the label needs to support text and geometry. Any advice on how to best approach this is much appreciated - I'm hoping someone has tackled a similar problem in the past. Many thanks Paul -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32125#32125 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] map text to geometry
Hi, I want to map a osgText to a geometry, for example a sphere. My idea was to get a texture out of osgText and map the texture to a geometry. Is there a better way to do this? And how do I get a texture out of osgText? thanks in advance Katja -- VISUAL ENGINEERING SOLUTIONS - Wir machen Innovation sichtbar! _ Katja Kristin Oechsner | VISENSO GmbH | Nobelstr. 15 | D-70569 Stuttgart Fon Office ++ 49 - 711 - 849 700 0 Fon Direct ++ 49 - 711 - 849 700 24 Fax Office ++ 49 - 711 - 849 700 79 k...@visenso.de | http://www.visenso.de __ Geschäftsführer: Dr. Andreas Wierse, Martin Zimmermann Registergericht: Amtsgericht Stuttgart Registernummer: HRB 720380 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] [osgPlugins] ffmpeg plugin : big delay
Hey guys, I'm encountering a small issue related to ffmpeg plugin. I'm trying to acquire and show in real time video (RTSP) coming from an axis camera. The problem is that my video has a delay of around 5 seconds.. I did some tests using VLC, and by modifing the cache size I had realtime video..but I have no idea how to make that using osg ffmpeg plugin. Does any one had to overcome this issue? Thank you! Cheers, Malek -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32128#32128 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Can I find a StateSet which has been setName?
Hi William, On Tue, Sep 28, 2010 at 9:24 AM, william nily william.n...@gmail.com wrote: Since the StateSet inherits from Object,so i can setName to a specific StateSet.Then can I find the StateSet by its name?Is there any way to do this such like to find a Node through its name? The tool for the job is a custom NodeVisitor, which does the traversal of the scene graph for you and then picks out the StateSet's on all the Node and Drawables. Something like: class MyFindStateSet : public osg::NodeVisitor { public: std::string _name; MyFindStateSet(const std::string name): osg::NodeVisitor(osg::NodeVisitor::TRAVERSE_ALL_CHILDREN), _name(name) {} void checkStateSet(const osg::StateSate* stateset) { if (node.getStateSet() node.getStateSet()-getName()==_name) { // found a node with a the correct stateset, now do what you want... } } void apply(osg::Node node) { checkStateSet(node.getStateSet()); // must traverse children otherwise we want descend scene graph traverse(node); } void apply(osg::Geode geode) { checkStateSet(geode.getStateSet()); // traverse the drawables of the geode. for(unsigned int i = 0; igeode.getNumChildren(); ++i) { checkStateSet(geode.getDrawable(i)-getStateSet()); } } }; .. { .. // now create the visitor and pass it to the scene graph to do the traversal MyFindStateSet mfss(mystateset); myscenegraph-accept(mffs); .. } For further examples of NodeVisitor's in action just do a search of the OSG code base, you'll find many of them all over the place. It's one of the most useful classes in the OSG. Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] osg newbie question: billboard with multiple drawables?
Hi Paul, The easiest way to do it is use an osg::AutoTransform, this is like a Billboard but can rotate to screen a whole subgraph rather than just drawables. Billboard is lightweight for things like trees, but AutoTransform is more flexible. Robert. On Tue, Sep 28, 2010 at 11:03 AM, paul graham pd...@hotmail.com wrote: Hi, I'm hoping someone can help. I'm trying to develop an in-scene 'label' for my 3D objects (consisting of text and geometry). I was hoping I'd be able to use the osg billboard and add my geometry and text to it as drawables, but I now realise that each drawable will have its own pivot point, so my text and geometry will become misaligned. Is there a way to massage the billboard such that it 'groups' all its children and effectively applies a single transformation about a single pivot point (hence keeping the text and geometry in the same plane)? Or can anyone suggest a simpler / better approach to the problem? Just to reiterate - I'm trying to create screen-facing labels to insert into my 3D scene - the label needs to support text and geometry. Any advice on how to best approach this is much appreciated - I'm hoping someone has tackled a similar problem in the past. Many thanks Paul -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32125#32125 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] map text to geometry
Hi Katja, osgText uses a texture atlas to store it's glyphs and separate quads to pull out the correct part of the texture atlas to get individual text characters, this makes it impossible to just pull the text texture directly and apply it to an ordinary geometry as the texture coordinates would be all over the place. All is not lost though, the OSG supports render to texture, so it would be possible for you to render a text subgraph and any other geometry you want to a texture and then apply this texture to your geometry. The OSG provides an osgSim::OverlayNode to help make this task even more straight forward as it will manage the render to texture setup for you. See osgsimulation exampe for an example of it in action. Robert. On Tue, Sep 28, 2010 at 11:47 AM, Katja Oechsner k...@visenso.de wrote: Hi, I want to map a osgText to a geometry, for example a sphere. My idea was to get a texture out of osgText and map the texture to a geometry. Is there a better way to do this? And how do I get a texture out of osgText? thanks in advance Katja -- VISUAL ENGINEERING SOLUTIONS - Wir machen Innovation sichtbar! _ Katja Kristin Oechsner | VISENSO GmbH | Nobelstr. 15 | D-70569 Stuttgart Fon Office ++ 49 - 711 - 849 700 0 Fon Direct ++ 49 - 711 - 849 700 24 Fax Office ++ 49 - 711 - 849 700 79 k...@visenso.de | http://www.visenso.de __ Geschäftsführer: Dr. Andreas Wierse, Martin Zimmermann Registergericht: Amtsgericht Stuttgart Registernummer: HRB 720380 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] ffmpeg plugin : big delay
I'm wondering is there any relation with that instruction : line 231 in FFmpegDecoderVideo.cpp packet = m_packets.timedPop(is_empty, 10); what does the 10 stand for? thanks, Malek -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32132#32132 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] osg newbie question: billboard with multiple drawables?
Hi Robert, many thanks for the prompt reply - I've been playing around with the autotransform and you're right - it is much more suited to our needs than the billboard. Thanks again Paul -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32133#32133 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] osgart 2.0 with osg2.9.8 video blinking
Hi, i compiled osgart 2.0 RC3 with osg2.9.8, when running the video screen was blinking, but before that i used osgart with osg2.8.3 everything all right, does anyone meet the same problem? i use win7 64bit and vs2008 compile 32bit osg. Thank you! Cheers, Huan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32134#32134 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Convert wxImage to osg:Image
Hi Thibault, Thanks a lot for the reply! I will check this out. Thanks again! Best Regards, Lahiru -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32135#32135 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] Problem loading images when migrating to new OSGViewer
Hi, I've been migrating some code from OSG 0.9.9 to the latest stable release (2.8.3), and I've run into an issue when migrating from OSGProducer::viewer to OsgViewer::viewer. I have three models, an airplane.3ds model, a sky.3ds model, and a globe.osga model. All three models load correctly (the nodes returned from osgDB::readNodeFile are not NULL), but only the airplane model shows up when the viewer display is rendered. The only functions that I needed to change from osgProducer to osgViewer were my initialization and update functions. I've made sure to replace osgProducer calls with equivalent osgViewer calls when I upgraded (see code below), but is there anything I might have missed? Code: 3DPlaneViewer::Initialize(){ osgViewer::Viewer* viewer = new osgViewer::Viewer(); //scene root osg::Group* root = new osg::Group(); //load globe and add transform of globe to root group osg::Node* globeNode = osgDB::readNodeFile(globe.osga); osg::MatrixTransform* globeTransform = new osg::MatrixTransform(); globeTransform-addChild( globeNode ); //create group for globe and sky osg::Group*terrainNodes = new Group(); terrainNodes-asGroup()-addChild( globeTransform ); //load airplane osg::Node* airplaneNode = osgDB::readNodeFile(airplane.3ds); //specify a location for plane on globe with lat, long, altitude osg::Matrixd airplaneMatrix; osg::EllipsoidModel* ellipse-computeLocalToWorldTransformFromLatLongHeight( osg::DegreesToRadians(20.0f),osg::DegreesToRadians(-30.0f), 15000,airplaneMatrix ); //rotate airplane node airplaneMatrix.preMult( airplaneMatrix.rotate( osg::Quat(osg::DegreesToRadians(180.0f), osg::Vec3f( 0, 0, 1 ) ))); //setup matrix wrapper node osg::MatrixTransform* airplaneTransform = new osg::MatrixTransform(); airplaneTransform-getOrCreateStateSet()-setMode(GL_RESCALE_NORMAL,osg::StateAttribute::ON); airplaneTransform-setMatrix(airplaneMatrix); airplaneTransform-addChild( airplaneNode ); terrainNodes-asGroup()-addChild( airplaneTransform ); //load and add the sky model osg::Node* skyNode = osgDB::readNodeFile(sky.3DS); osg::MatrixTransform* skyTransform = new osg::MatrixTransform(); skyTransform-addChild( skyNode ); terrainNodes-asGroup()-addChild( skyTransform ); root-addChild( terrainNodes ); //realize the scene in the viewer viewer-setSceneData(root); viewer-realize(); } 3DPlaneViewer::Update() { //removed calls to osgProducer::sync() viewer-updateTraversal(); //do some other updates on other objects in the scene viewer-frame(); } Thanks, John -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32136#32136 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] osg newbie question: billboard with multiple drawables?
Hi, on the subject of the autotransform: in scale_to_screen mode, I was trying to use minScale and maxScale to effectively bound the drawn screen size of my geode between a minimum and maximum, but I think I'm mis-interpreting these parameters. Increasing maxScale does not appear to increase the maximum drawn size of my geode, and setting minScale doesn't seem to permit me to define a minimum drawn size? I've had a look at the AutoTransform code and I can see that the application of these scale settings are affected by the transition width, but it's not clear to me how they are connected? If anyone can clarify for me, the relationship between transition width, minScale and maxScale and whether or not these could be used to define a minimum and maximum drawn size of a geode, I'd really appreciate it. Many thanks in advance. Paul -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32137#32137 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Problem loading images when migrating to new OSGViewer
Hi John, I don't know the cause of only the airplane showing up, but can suggest a few things to try to explore what might be going wrong. First up try loading each of the models with osgviewer and see if each one loads up OK. Second write out the completed scene graph to a .osg file just before you run the viewer code. Then try to load this scene graph into osgviewer and see what happens. On the osgProducer::Viewer - osgViewer::Viewer conversion, with osgViewer the Viewer::frame() method does the sync, update and event traversals, and the rendering traversals all together. Have a look at the source code to Viewer::frame() to see what it's doing. You can break your frame loop out to call each traversals individually if you want. Have a look at discussions about this on the mailing lists/forum and the website, and the examples. In your case you can safely comment out the call to viewer-updateTravesal() as viewer-frame() will be doing it for you. Robert. On Tue, Sep 28, 2010 at 4:10 PM, John Stokes jstokes2...@yahoo.com wrote: Hi, I've been migrating some code from OSG 0.9.9 to the latest stable release (2.8.3), and I've run into an issue when migrating from OSGProducer::viewer to OsgViewer::viewer. I have three models, an airplane.3ds model, a sky.3ds model, and a globe.osga model. All three models load correctly (the nodes returned from osgDB::readNodeFile are not NULL), but only the airplane model shows up when the viewer display is rendered. The only functions that I needed to change from osgProducer to osgViewer were my initialization and update functions. I've made sure to replace osgProducer calls with equivalent osgViewer calls when I upgraded (see code below), but is there anything I might have missed? Code: 3DPlaneViewer::Initialize(){ osgViewer::Viewer* viewer = new osgViewer::Viewer(); //scene root osg::Group* root = new osg::Group(); //load globe and add transform of globe to root group osg::Node* globeNode = osgDB::readNodeFile(globe.osga); osg::MatrixTransform* globeTransform = new osg::MatrixTransform(); globeTransform-addChild( globeNode ); //create group for globe and sky osg::Group*terrainNodes = new Group(); terrainNodes-asGroup()-addChild( globeTransform ); //load airplane osg::Node* airplaneNode = osgDB::readNodeFile(airplane.3ds); //specify a location for plane on globe with lat, long, altitude osg::Matrixd airplaneMatrix; osg::EllipsoidModel* ellipse-computeLocalToWorldTransformFromLatLongHeight( osg::DegreesToRadians(20.0f),osg::DegreesToRadians(-30.0f), 15000,airplaneMatrix ); //rotate airplane node airplaneMatrix.preMult( airplaneMatrix.rotate( osg::Quat(osg::DegreesToRadians(180.0f), osg::Vec3f( 0, 0, 1 ) ))); //setup matrix wrapper node osg::MatrixTransform* airplaneTransform = new osg::MatrixTransform(); airplaneTransform-getOrCreateStateSet()-setMode(GL_RESCALE_NORMAL,osg::StateAttribute::ON); airplaneTransform-setMatrix(airplaneMatrix); airplaneTransform-addChild( airplaneNode ); terrainNodes-asGroup()-addChild( airplaneTransform ); //load and add the sky model osg::Node* skyNode = osgDB::readNodeFile(sky.3DS); osg::MatrixTransform* skyTransform = new osg::MatrixTransform(); skyTransform-addChild( skyNode ); terrainNodes-asGroup()-addChild( skyTransform ); root-addChild( terrainNodes ); //realize the scene in the viewer viewer-setSceneData(root); viewer-realize(); } 3DPlaneViewer::Update() { //removed calls to osgProducer::sync() viewer-updateTraversal(); //do some other updates on other objects in the scene viewer-frame(); } Thanks, John -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32136#32136 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] ffmpeg plugin : big delay
Hi, You can try this patch. Mikhail. Index: src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp === --- src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp(revision 11784) +++ src/osgPlugins/ffmpeg/FFmpegDecoderVideo.cpp(working copy) @@ -208,6 +208,7 @@ pts = 0; } +pts -= m_stream-start_time; pts *= av_q2d(m_stream-time_base); // Publish the frame if we have decoded a complete frame ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] ffmpeg plugin : big delay
Hi Mikhail, Thanks for your response. I think that the patch was disabled by the forum administrator. I'm not able to download it. Cheers, Malek -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32140#32140 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Load of 8 bits image for creating texture
Hi Robert, I know I'm a little bit late but I've just begin to try your solution at the beginning of this week (no time before... :( ). I'm now able to load the image information on a Texture2D and the color table in a Texture1D thanks to the osg::TransferFunction1D class. What I miss now is the link between the two types of texture (Should be there in the same osg::StateSet ? How link the one with the other ?) I've tried to create two textures in the same stateSet but nothing appears. It will be very helpful if you could say me what I'm missing ? Thanks in advance for your help, Adrien. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32141#32141 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Load of 8 bits image for creating texture
Hi Adrien, When using multi-texturing you need to decide which texture units to use then set up your texenv (if using fixed function pipeline) or shaders to reflect this. Typically, in your case, one would use texture unit 0 and texture unit 1, so you'd do something like: stateset-setTextureAttribute(0, textureSource); stateset-setTextureAttribute(1, textureLookUp); Robert. On Tue, Sep 28, 2010 at 5:19 PM, Adrien Chassard osgfo...@tevs.eu wrote: Hi Robert, I know I'm a little bit late but I've just begin to try your solution at the beginning of this week (no time before... :( ). I'm now able to load the image information on a Texture2D and the color table in a Texture1D thanks to the osg::TransferFunction1D class. What I miss now is the link between the two types of texture (Should be there in the same osg::StateSet ? How link the one with the other ?) I've tried to create two textures in the same stateSet but nothing appears. It will be very helpful if you could say me what I'm missing ? Thanks in advance for your help, Adrien. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32141#32141 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] osgart 2.0 with osg2.9.8 video blinking
Hi Huan i compiled osgart 2.0 RC3 with osg2.9.8, when running the video screen was blinking, but before that i used osgart with osg2.8.3 ?everything all right, does anyone meet the same problem? i use win7 64bit and vs2008 compile 32bit osg Are you using texture 2d for your video streams, if so your'e having the same problem as myself, Search the mailing list for 'Texture2D subload callback gone mad' It's an issue with the texture object manager assigning a new texture object every frame. I've sent an example showing the issue to Robert so hopefully he's aware of the issue and can fix it soon. If you use texture rectangles you won't have an issue as they don't require a sub load callback Tom ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] ffmpeg plugin : big delay
Hi, You can find patch in mailing list archive at http://www.mail-archive.com/osg-users@lists.openscenegraph.org/msg44088.html Mikhail. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] ffmpeg plugin : big delay
ok Thanks again, I'll let you know. Malek -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32146#32146 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] [3rdparty] OSG and SDL
Hi, I am using SDL to get input from a joystick so that I can integrate joystick control in OSG (I have tried the VRPN approach and right now SDL is looking better for my needs). I have searched for as much information about integrating OSG and SDL as possible, and so far it appears that I must use SDL windows and have OSG draw to SDL windows, instead of OSG using its own windowing system. Does anyone know if this assertion is accurate? Is there any way to connect SDL through an OSG Viewer? All I care about are the input events associated with the joystick... Thank you! Cheers, Matt -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32147#32147 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Problem loading images when migrating to new OSGViewer
Robert, Thank you for your insight. I did try loading my models with the standalone osgviewer and each of them loaded correctly as did the exported .osg using osgDB::writeNodeFile. I was testing out commenting out different sections, and I noticed that I had this piece of code that I left out in my last post: Code: OsgViewer* viewer = new osgViewer::Viewer(); viewer-getCamera()-setClearColor( osg::Vec4(0.2,0.2,1,1) ); //Replace osgProducer::viewer cull setting with new osgViewer setting //old code: viewer-getCullSettings().setComputeNearFarMode(osgUtil::CullVisitor::DO_NOT_COMPUTE_NEAR_FAR); viewer-getCamera()-setComputeNearFarMode(osgUtil::CullVisitor::DO_NOT_COMPUTE_NEAR_FAR); When I comment out the updated setComputeNearFarMode line of code, my globe and sky models show up correctly but my plane model disappears. Is there a correct cull setting that I should be using to get everything to display? I tried using the COMPUTE_NEAR_FAR_USING_PRIMITIVES and COMPUTE_NEAR_FAR_USING_BOUNDING_VALUES with this call, but I'm not quite sure what bounding value I should be using or if I should be looking at another culling method. Thanks, John[/code] -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32148#32148 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] Problem compiling 2.9.9 with Qt in MacOSX
Hello: I am trying to compile 2.9.9 in a Mac OSX 10.6 snow leopard and I got a problem with Qt (error log below). In fact it would be better if I can compile it without Qt. Any hint? Regards, -- Alejandro [ 98%] Building CXX object src/osgQt/CMakeFiles/osgQt.dir/QFontImplementation.cpp.o In file included from /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtCore.framework/Headers/qnamespace.h:45, from /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtCore.framework/Headers/qobjectdefs.h:45, from /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtGui.framework/Headers/qwindowdefs.h:45, from /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtGui.framework/Headers/qfont.h:45, from /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtGui.framework/Headers/QFont:1, from /Users/ale/src/OpenSceneGraph-2.9.9/include/osgQt/QFontImplementation:19, from /Users/ale/src/OpenSceneGraph-2.9.9/src/osgQt/QFontImplementation.cpp:13: /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtCore.framework/Headers/qglobal.h:288:2: error: #error You are building a 64-bit application, but using a 32-bit version of Qt. Check your build configuration. In file included from /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtGui.framework/Headers/qmatrix.h:46, from /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtGui.framework/Headers/qtransform.h:44, from /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtGui.framework/Headers/qimage.h:45, from /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtGui.framework/Headers/QImage:1, from /Users/ale/src/OpenSceneGraph-2.9.9/src/osgQt/QFontImplementation.cpp:21: /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtGui.framework/Headers/qregion.h: In member function ‘OpaqueRgnHandle* QRegion::handle(bool) const’: /Developer/SDKs/MacOSX10.6.sdk/Library/Frameworks/QtGui.framework/Headers/qregion.h:160: error: ‘toQDRgn’ was not declared in this scope lipo: can't figure out the architecture type of: /var/folders/qE/qEL4-gb+HEiohD3qgoFONE+++TI/-Tmp-//ccGy7LHP.out make[2]: *** [src/osgQt/CMakeFiles/osgQt.dir/QFontImplementation.cpp.o] Error 1 make[1]: *** [src/osgQt/CMakeFiles/osgQt.dir/all] Error 2 make: *** [all] Error 2 Alejandro-Aguilar-Sierras-iMac:OpenSceneGraph-2.9.9 ale$ ccmake . ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [3rdparty] OSG and SDL
If you just want to use SDL to read joystick inputs, you don't have to use SDL windows. You can use SDL for joystick inputs, and render OGS to windows managed by Qt, CEGUI, or whatever meets your needs. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [3rdparty] OSG and SDL
Perhaps I just don't know enough about whats going on in my OSG build...but right now I can just instantiate and start a Viewer in OSG and it automatically opens a window and handles drawing for me. Is there a way to go about using OSG this same way but to incorporate SDL? Right now when I try to grab SDL events while also running an osgViewer, my main function just exits as if the osgViewer isn't blocking the thread. My main function has the following code: Code: if( SDL_Init(SDL_INIT_JOYSTICK) 0) { std::cerr unable to init SDL: SDL_GetError() '\n'; return false; }else{ std::clog Init'd Joystick :) std::endl; } std::atexit(SDL_Quit); if( SDL_NumJoysticks() == 0 ) { std::cerr no joysticks found\n; return false; }else{ std::clog Found SDL_NumJoysticks() joysticks :) std::endl std::endl; for(int i = 0; i SDL_NumJoysticks(); ++i) { std::clog Joystick (i + 1) : SDL_JoystickName(i) std::endl std::endl; } } SDL_Joystick *joystick; SDL_JoystickEventState(SDL_ENABLE); joystick = SDL_JoystickOpen(0); int running = true; SDL_Event event; std::clog Left/Right axis: SDL_JoystickGetAxis(joystick, 0) std::endl; std::clog Up/Down axis: SDL_JoystickGetAxis(joystick, 1) std::endl; // construct the viewer osg::ref_ptrosgViewer::Viewer viewer = new osgViewer::Viewer; // make the viewer create a 512x512 window and position it at 32, 32 viewer-setUpViewInWindow( 32, 32, 512, 512 ); // set the scene-graph data the viewer will render viewer-setSceneData( CreateScene() ); // execute main loop return viewer-run(); I'm just trying to initialize SDL, grab initial joystick data to prove I am connected to it, then start the osgViewer. However, the OSG window never pops up... -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32151#32151 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] IPhone retina displays
Good news on this All seems to be working, I've also improved the IPhoneWindowingSystemInterface to handle true resolutions and multiple screens. So on IPad we should now be able to set a window to an external screen and also change the res of the screen (I don't have an IPad though so needs testing, but should work, gulp :) ) In the end I've gone for the approach of IPhoneWindowingSystemInterface providing the actual pixel res of the screen. Then by default if the user does not set a viewContentScaleFactor in their windowData, the screens scaleFactor is used. This means the default context created by osg viewer will always be full pixel res and the window will be full points res. This was so that I didn't have to create a context of a different size to that requested by default. If the user needs backward compatibility they have to set the traits width and height themselves and set the windowData viewContentScaleFactor to 1.0. I still need to do a bit of testing as I think my objective c code is leaking but I'll get the changes checked in asap. Tom PS The touch coords are returned by the OS in points still so I've converted them to pixels so the current simple example still works as expected. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] osgart 2.0 with osg2.9.8 video blinking
Thank you! Thomas. osgart default using texture 2D, it seems change osgart to using texture rectangle still blinking, i guess would back to 2.8.3. Cheers, Huan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=32153#32153 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [osgPlugins] Missing plugins
I have OSG configured on Mac OS X with almost all optional dependencies (except the big ones like Qt, etc). I installed them using MacPorts. I suggest you use it, it's a breeze to install, it solves countless hours of headache. Eduardo On Tue, Sep 21, 2010 at 2:57 AM, Daryl Lee da...@daryllee.com wrote: Hi, I've got osgViewer running, but when I try osgviewer --image osg256.png (pg. 8 of the Quick Start Guide) I get an error, failing to load the PNG viewer plugin. I looked at the plugins folder and can't find anything with png in the name. I opened CMake-gui and inspected the configuration output and see these three lines: Could NOT find JPEG (missing: JPEG_LIBRARY JPEG_INCLUDE_DIR) Could NOT find PNG (missing: PNG_LIBRARY PNG_PNG_INCLUDE_DIR) Could NOT find TIFF (missing: TIFF_LIBRARY TIFF_INCLUDE_DIR) So I dutifully added the six missing values, pointing them to what I think might be correct folders and paths, and click Configure. The six new entries that I made disappear and the three lines of output are still there. So what do I need to do to get plugins for those filetypes? I'm doing all this on a MinGW/MSYS system. I haven't tried it yet on my MacOSX system. Cheers, Daryl -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=31884#31884 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Add a new child
On 28/09/10 18:45 , Cosimo Luigi Manes wrote: Ulrich Hertlein wrote: On 28/09/10 17:19 , Robert Osfield wrote: What happens when you press 'space' to reset the camera position? Well, when i press 'space', software shows the nodes. How can i reset the camera position ? osgGA::CameraManipulator (the base class for the default manipulators) has a 'home()' method than will recompute the position if 'setAutoComputeHomePosition' is true. /ulrich ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org