[osg-users] new ref_ptrs in Callbacks

2010-07-15 Thread Tom Pearce
Hi, Let me preface this by saying that I know how to make my code do what I want it to, so this question is of low importance and arises from doing something that could(should?) be considered silly- dynamic allocation within a callback operator method when the callback can have a class member

Re: [osg-users] new ref_ptrs in Callbacks

2010-07-15 Thread J.P. Delport
Hi, have you tried different threading models to see if it makes any difference? jp On 15/07/10 08:09, Tom Pearce wrote: Hi, Let me preface this by saying that I know how to make my code do what I want it to, so this question is of low importance and arises from doing something that

Re: [osg-users] new ref_ptrs in Callbacks

2010-07-15 Thread Tim Moore
On Thu, Jul 15, 2010 at 8:54 AM, J.P. Delport jpdelp...@csir.co.za wrote: Hi, have you tried different threading models to see if it makes any difference? jp To pursue further where J.P. is going with this, what you're doing is not going to work in any of the multi-threaded modes and is

[osg-users] Switch on statesets

2010-07-15 Thread Roman Grigoriev
Hi,guys! I try to manage my models and find some problem. So I have one model with summer textures and winter textures. My goal to create one ive file with embedded summer and winter textures. As far as I understand I can have only one stateset per geomentry and can't make some switches to

Re: [osg-users] Switch on statesets

2010-07-15 Thread Ulrich Hertlein
On 15/07/10 18:48 , Roman Grigoriev wrote: Hi,guys! I try to manage my models and find some problem. So I have one model with summer textures and winter textures. My goal to create one ive file with embedded summer and winter textures. As far as I understand I can have only one stateset

Re: [osg-users] osg camera location

2010-07-15 Thread Robert Osfield
Hi Ricky, I sounds like your confusing things. The 3d scene is world coordinates, the transforms in the scene graph place the subgraphs in world coordinate, these transforms (if any) provide the model part of the OpenGL modelview matrix. The osg::Camera then provides the view matrix that moves

Re: [osg-users] 1-bit texture for shader

2010-07-15 Thread Ulrich Hertlein
On 15/07/10 1:36 , Jason Daly wrote: I'm trying to create a 1-bit texture, like this: int internalFormat = GL_RED; int pixelFormat = GL_RED; int dataType = GL_BITMAP; I get the following error when running this code: Warning: detected OpenGL error 'invalid enumerant' after

Re: [osg-users] FBX reading of GL_POLYGON

2010-07-15 Thread Sukender
Alright then. Hope the algorithm works for all cases. I tested it a bit more, and as far as I can tell it seems okay. Please keep us (I mean the mailing list) in touch. Thanks. Sukender PVLE - Lightweight cross-platform game engine - http://pvle.sourceforge.net/ - Michael Platings

Re: [osg-users] DDS S3TC-DXTC compression only accept power of twosizes?

2010-07-15 Thread Sukender
Hi Wojtek, Well, I must admit my todo list is simply huge. For now I simply resize images before converting them. Moreover, some 3rd-party tools do not support non power of two images either. So I guess this task will be far, far away from the begining of my todo list! ;) Sukender PVLE -

[osg-users] Problem running my OSG application

2010-07-15 Thread Manuel Garea
Hi, I build an OSG app. I configured the Visual Studio Project linking all the libraries and including all necessary folders. I also set the PATH environment variable to my OSG bin folder. When I run my project with Visual Studio everything works fine, but when I go to the Debug Folder and run

Re: [osg-users] LOD Culling issue

2010-07-15 Thread Vincent Bourdier
Hi Robert, Thanks for your answer. Do you mean that I have to initialize the Bounding Sphere of the PagedLOD node when I create it ? because I didn't found any special method in LOD or PagedLOD about that. Thanks. Regards, Vincent. Le 10/07/2010 11:32, Robert Osfield a écrit : Hi

Re: [osg-users] 1-bit texture for shader

2010-07-15 Thread Tim Moore
On Thu, Jul 15, 2010 at 11:43 AM, Ulrich Hertlein u.hertl...@sandbox.dewrote: On 15/07/10 1:36 , Jason Daly wrote: I'm trying to create a 1-bit texture, like this: int internalFormat = GL_RED; int pixelFormat = GL_RED; int dataType = GL_BITMAP; I get the following

Re: [osg-users] Human 3d model animation/motion

2010-07-15 Thread Jean-Sébastien Guay
Hello Sanat, For the osgAnimationViewer example, what is the data that we need to use? I am runnng the example from VisualStudio, so it comes to the line in bold below and exits with 1. Like osgviewer, you need to give it a file to load. It will load any 3D model file that OSG can load, but

[osg-users] Select node on screen

2010-07-15 Thread Tufan Taş
Hi, I have nodes on screen and I want to select a node by clicking on it using mouse. Do you know any samples about this subject? ... Thank you! Cheers, Tufan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=30027#30027

Re: [osg-users] My Lines Disapering but Ploygons don't

2010-07-15 Thread Jean-Sébastien Guay
Hi David, Tom, Are you enabling transparency? - for example by: Code: osg::StateSet* state = node-getOrCreateStateSet(); state-setRenderingHint( osg::StateSet::TRANSPARENT_BIN ); state-setMode( GL_DEPTH_TEST, osg::StateAttribute::ON ); That last one should probably have been:

Re: [osg-users] Select node on screen

2010-07-15 Thread Trajce (Nick) Nikolov
Have a look at the osgpick example -Nick On Thu, Jul 15, 2010 at 4:53 PM, Tufan Taş tas.tu...@gmail.com wrote: Hi, I have nodes on screen and I want to select a node by clicking on it using mouse. Do you know any samples about this subject? ... Thank you! Cheers, Tufan

Re: [osg-users] Switch on statesets

2010-07-15 Thread Jean-Sébastien Guay
Hi Roman, There are many ways to do this, how you do it will depend on what you find more convenient... Ulrich's solution is one. You could create two Geodes with different textures (summer/winter) that share the same geometry. Or you could have two Geometry objects that share the same

[osg-users] Stop back buffer swap during rendering traversals

2010-07-15 Thread Michael Irby II
Hi, Does anyone know how I could go about stopping the View from doing a back buffer swap during the rendering traversals. I am outfitting OSG into current rendering engine, but I need the OSG view to not swap the back buffer at the end of the rendering traversals. Is there something I need to

Re: [osg-users] My Lines Disapering but Ploygons don't

2010-07-15 Thread Tom Pearce
Skylark wrote: That last one should probably have been: state-setMode( GL_BLEND, osg::StateAttribute::ON ); Aye, that's what I meant. I just copied/pasted the wrong line of code. Thanks for pointing that out J-S. I always turn on GL_DEPTH_TEST anyway to be safe, even though on is the

Re: [osg-users] Stop back buffer swap during rendering traversals

2010-07-15 Thread Jean-Sébastien Guay
Hi Michael, Does anyone know how I could go about stopping the View from doing a back buffer swap during the rendering traversals. I am outfitting OSG into current rendering engine, but I need the OSG view to not swap the back buffer at the end of the rendering traversals. Is there something

Re: [osg-users] Stop back buffer swap during rendering traversals

2010-07-15 Thread Michael Irby II
Hi, Ah, sounds easy enough. I noticed if you call setupViewInWindow or setupViewOnSingleScreen the graphics context is created there. So would I just not call that method and then just do the graphics context, camera, and window setup manually? -- Read this topic online here:

Re: [osg-users] Stop back buffer swap during rendering traversals

2010-07-15 Thread Jean-Sébastien Guay
Hi Michael, Ah, sounds easy enough. I noticed if you call setupViewInWindow or setupViewOnSingleScreen the graphics context is created there. So would I just not call that method and then just do the graphics context, camera, and window setup manually? Yes, exactly. You can take

Re: [osg-users] Stop back buffer swap during rendering traversals

2010-07-15 Thread Michael Irby II
Hi, Excellent. Thanks for your swift response and help. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=30038#30038 ___ osg-users mailing list osg-users@lists.openscenegraph.org

Re: [osg-users] VRJuggler Particles Effects Not working?

2010-07-15 Thread nick waller
Thanks Robert. We looked at the framestamp and found that VRJuggler was not setting the simulation time of it. Once we did that, particle and animation effects started working. However, now we have run into a different but related problem. The particles that show up seem to move when we

Re: [osg-users] 1-bit texture for shader

2010-07-15 Thread Jason Daly
Ulrich Hertlein wrote: So that is a limitation of osg::Image? Because glTexImage2D() supports it. (Or at least it did once, I have never used it and was quite surprised to find it in the man page.) My answer was based on my reading of the GL spec. If what you say is true, I may have

Re: [osg-users] 1-bit texture for shader

2010-07-15 Thread Jason Daly
Tim Moore wrote: GL_BITMAP is a valid texture type and supported by osg::Image, but only if the pixel format is GL_COLOR_INDEX. That is not likely to be optimal on today's hardware. Ah, that's whay I didn't see it, then. I was reading the GL 3.3 spec, which has eschewed color index mode.

Re: [osg-users] new ref_ptrs in Callbacks

2010-07-15 Thread Tom Pearce
Hi JP, Tim, Thanks for the replies. Using the single threaded mode gets rid of the flicker, as does setting the state set data variance to dynamic when I create the scene graph: mt-getOrCreateStateSet()-setDataVariance(osg::Object::DYNAMIC); I'm convinced that your explanation of collision

Re: [osg-users] Human 3d model animation/motion

2010-07-15 Thread Sanat Talmaki
Hi Jean, Thanks, that helped. I'll take a look at the FBX plugin too. Best, Sanat. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=30043#30043 ___ osg-users mailing list

Re: [osg-users] My Lines Disapering but Ploygons don't

2010-07-15 Thread David Glenn
Yea That was it! Now if I can only fix my original problem, but that I figured there was a quick answer for! Makes me wonder what other GL settings I need to activate that I forgot! Humm!! :? Thanks! D Glenn D Glenn (a.k.a David Glenn) - Join the Navy and See the

[osg-users] Moving Particle Effects

2010-07-15 Thread Frank Sullivan
Hello, I am hoping to create a particle effect that moves. However, I am having difficulty with this. If I call ParticleEffect::setPosition, it seems to have the effect of destroying the existing particle system and rebuilding it from scratch: Code: void ParticleEffect::setPosition(const

Re: [osg-users] Moving Particle Effects

2010-07-15 Thread Jordi Torres
Hi Frank, Take a look to the osgparticleeffects example in the examples folder. In this code you can see how if you pick a moving model the particle system moves with it. You can see the result picking the cessna or the hanglide model in the example. Hope this helps. 2010/7/15 Frank Sullivan

[osg-users] cmake errors with 2.9.8

2010-07-15 Thread John Kelso
Hi all, I just tried build OSG 2.9.8 on our CentOS system, using cmake 2.4.7. My cmake command gave me errors. The main thing I see are lines like this: CMake Error: Error in cmake code at .../OpenSceneGraph-2.9.8/CMakeModules/ModuleInstall.cmake:28: INSTALL TARGETS given unknown argument

Re: [osg-users] cmake errors with 2.9.8

2010-07-15 Thread Chuck Seberino
John, There have been a lot of OSX-specific updates to cmake between your version and the latest. 2.4.7 is so old that it doesn't even recognize the FRAMEWORK argument, let alone do the right thing with it (ignore in your case). Upgrading cmake will solve your problems. Chuck On Jul 15,

Re: [osg-users] Moving Particle Effects

2010-07-15 Thread Frank Sullivan
That works very well, Jordi, thanks. -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=30049#30049 ___ osg-users mailing list osg-users@lists.openscenegraph.org

Re: [osg-users] cmake errors with 2.9.8

2010-07-15 Thread Jean-Sébastien Guay
Hi Chuck, John, There have been a lot of OSX-specific updates to cmake between your version and the latest. 2.4.7 is so old that it doesn't even recognize the FRAMEWORK argument, let alone do the right thing with it (ignore in your case). Upgrading cmake will solve your problems. When

Re: [osg-users] My Lines Disapering but Ploygons don't

2010-07-15 Thread David Glenn
FYI Figured out how to build a phatom globe to hide objects after it gos behind the earths horizon. Now I can pan across the earth and my layered objects disapear behind the earth as it should. check out: http://forum.openscenegraph.org/viewtopic.php?t=6188 Thanks to Simon Julier and Farshid

Re: [osg-users] Transparent but occluding phantom objects for AR application

2010-07-15 Thread David Glenn
Hay, Thanks for showing me how to do that! I have a layered view with a globe in the background and layers of objects over that. The problem was if you rotated the globe and the layered objects (since they used different views) the objects would not disappear as the objects went behind the

Re: [osg-users] new ref_ptrs in Callbacks

2010-07-15 Thread Tim Moore
On Thu, Jul 15, 2010 at 6:40 PM, Tom Pearce tmpea...@gmail.com wrote: Hi JP, Tim, Thanks for the replies. Using the single threaded mode gets rid of the flicker, as does setting the state set data variance to dynamic when I create the scene graph:

Re: [osg-users] Usage of the command line of osgTerrain

2010-07-15 Thread ting zhang
Hi, Robert Thank you very much. Since osgTerrain is both used in VPB and osgEarth, is it related with the runtime generation of terrains? I used osgEarth, I found that the runtime generation of terrains in osgEarth is excellent. When I viewed a new detailed scene, the scene came to me quickly

Re: [osg-users] Switch on statesets

2010-07-15 Thread Roman Grigoriev
Hi,guys! Thanx for your replies. My models are imported from FBX and import/export plugin placed statesets under geometry. So in this situation I have to write nodevisitor that traverse scenegraph to get stateset of geometry, after get parent geode, add another geode with different stateset and