Re: [osg-users] placing image on scene

2008-04-17 Thread Robert Osfield
Hi Bryan, On Thu, Apr 17, 2008 at 1:54 AM, Bryan Berg [EMAIL PROTECTED] wrote: Can I clarify than if a cull callback gets called for a node, that means the node will be visible ? It simply means that node where the cull callback has been attached hasn't been culled yet, so its a potential

Re: [osg-users] Access to osg::Image data

2008-04-17 Thread Robert Osfield
Hi Paul, I'm afraid there is too little code in your excerpt to guess at what might be wrong, what is wrong is part of the code you haven't included. The osgvolume example does various ops on a 3D osg::Image so I'd recommend review this example. Robert. On Thu, Apr 17, 2008 at 6:45 AM, Paul

Re: [osg-users] Create underwater effects

2008-04-17 Thread Kim C Bale
There isn't really anything specific to OSG that can help you with this. I am working on underwater effects at the moment and most of my work has been with shaders. Tessendorf offers a fairly comprehensive guide to ocean rendering both above and below water here:

Re: [osg-users] Getting the model matrix in the vertex shader.

2008-04-17 Thread Wojciech Lewandowski
Hi J-S, I am not sure whether its related or not. We once observed the case when osg uniforms (like osg_ViewMatrixInverse) were not applied by graph nested cameras. I don't recall what exactly was going there. We forced this apply by adding osg_ViewMatrixInverse to nested camera stateset.

Re: [osg-users] Depth buffer issue

2008-04-17 Thread Judie
I have to laugh at myself for this brilliant idea! Alpha blending is mutually exclusive with occlusion. In otherwords, the parts that I want occluded by the invisible portion, if that invisible portion is alpha blended, will be visible. However, I want a copy of the invisible geometry so that I

Re: [osg-users] Depth buffer issue

2008-04-17 Thread Judie
Hi Frédéric, Thanks for your advice. The invisible objects are in the scenegraph before the visible ones so at least I have that going for me. I think we won't be moving the camera view too much so I think it will be OK. I just thought it was weird that I would get the expected behavior until I

Re: [osg-users] Providing A Lock Method in osgWidget

2008-04-17 Thread Jeremy Moles
On Wed, 2008-04-16 at 15:43 +0100, Robert Osfield wrote: On Wed, Apr 16, 2008 at 3:30 PM, Jeremy Moles [EMAIL PROTECTED] wrote: My question, then, is twofold: 1. Given the above (and the fact that I am able to modify the osg::Array objects within the Widget directly and see

[osg-users] Please test SVN of OpenSceneGraph in pre for 2.3.9 dev release

2008-04-17 Thread Robert Osfield
Hi All, I'm planning to make a 2.3.9 dev release today. Could SVN users do an svn update and try out compile and build. I have just checked in updates to the Quicktime plugin from Stephan Huber, these will need to be tested by Windows and OSX users that use the Quicktime plugin. Thanks in

Re: [osg-users] Using a visitor after a DEEP_COPY_ALL doesn't returnanything

2008-04-17 Thread Judie
Hi Paul, Does that work on your compiler? I tried that as well, but I got the following error: error C2440: 'initializing' : cannot convert from 'class osg::Object *' to 'class osg::ref_ptrclass osg::Node' No constructor could take the source type, or constructor overload resolution was

Re: [osg-users] Using a visitor after a DEEP_COPY_ALL doesn't returnanything

2008-04-17 Thread Serge Lages
Hi, Just cast the clone() return to an osg::Node * and it should work : osg::ref_ptrosg::Node copyA = static_castosg::Node *(A-clone( osg::CopyOp::DEEP_COPY_ALL )); On Thu, Apr 17, 2008 at 4:54 PM, Judie [EMAIL PROTECTED] wrote: Hi Paul, Does that work on your compiler? I tried that as

[osg-users] Cyclic graphs?!

2008-04-17 Thread Art Tevs
Hi folks, as far as I can see for now osg doesn't check if the given scene graph contains cycles. If one do this, then there is a seg fault, if my test were correct ;-) However imagine I have a situation, where I need to have a cycle in the graph. For example: A - /|\ / ||

Re: [osg-users] Using a visitor after a DEEP_COPY_ALL doesn't returnanything

2008-04-17 Thread Judie
Hi Serge, Thanks for that piece of information. I am still not getting a deep copy of the nodes, however. I did an experiment and I went to the top level node: osg::Node* subgraph = m_sceneView-getSceneData(); and I used this one for the deep copy osg::ref_ptrosg::Node copyA =

Re: [osg-users] Using a visitor after a DEEP_COPY_ALL doesn't returnanything

2008-04-17 Thread Serge Lages
Hi Judie, You may check that all the nodes contained into your graph have the clone method implemented. Do you have some custom nodes into the graph ? On Thu, Apr 17, 2008 at 6:00 PM, Judie [EMAIL PROTECTED] wrote: Hi Serge, Thanks for that piece of information. I am still not getting a deep

Re: [osg-users] Cyclic graphs?!

2008-04-17 Thread Jason Daly
Art Tevs wrote: Hi folks, as far as I can see for now osg doesn't check if the given scene graph contains cycles. If one do this, then there is a seg fault, if my test were correct ;-) However imagine I have a situation, where I need to have a cycle in the graph. For example: ... Any

Re: [osg-users] Cyclic graphs?!

2008-04-17 Thread Art Tevs
Hi Jason, I know that scene graphs are per definition DAG. I know that I am using it in a wrong way with that setup. However let us think on something like extended scene graphs where cycles are also more or less possible ;-) Does anybody already made some thoughts on that? --- Jason Daly

Re: [osg-users] Please test SVN of OpenSceneGraph in pre for 2.3.9 devrelease

2008-04-17 Thread Andy Skinner
It built for me in windows and linux 64 bit. I'm still trying to get a solaris machine, and that is often where there has been trouble. andy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Robert Osfield Sent: Thursday, April 17, 2008 10:45 AM To:

[osg-users] When must you use SingleThreaded threading model

2008-04-17 Thread Jason Beverage
Hi Robert, I was looking through the examples and noticed that osgphotoalbum, osgdistortion and a few of the other examples are explicitly setting the viewer to SingleThreaded threading model. Is there anything inherit in those examples where you *must* use the SingleThreaded viewer model rather

Re: [osg-users] When must you use SingleThreaded threading model

2008-04-17 Thread Robert Osfield
Hi Jason, Some of these examples are probably single threaded purely from being overly conservative in the early days of osgViewer and the new threading models, others may require SingleThreaded because of assumptions made in the code which mean the code isn't thread safe. Robert. On Thu, Apr

Re: [osg-users] Create underwater effects

2008-04-17 Thread Jeremy Moles
On Thu, 2008-04-17 at 10:11 +0100, Kim C Bale wrote: There isn't really anything specific to OSG that can help you with this. I am working on underwater effects at the moment and most of my work has been with shaders. Tessendorf offers a fairly comprehensive guide to ocean rendering both

Re: [osg-users] How to pick up openGL objects in osg scene?

2008-04-17 Thread Robert Osfield
Hi Zhujun, You'll need to implement accept(PrimtiveFunctor) and supports(PrimitiveFunctor) methods so that it passes back the internal geometry. The PrimtiveFunctor has OpenGL like mathods for specifying the vertex and primitive data so you should be able to work out how to map your OpenGL code

Re: [osg-users] When must you use SingleThreaded threading model

2008-04-17 Thread Jean-Sébastien Guay
Hi Robert, Some of these examples are probably single threaded purely from being overly conservative in the early days of osgViewer and the new threading models, others may require SingleThreaded because of assumptions made in the code which mean the code isn't thread safe. If you remember

[osg-users] scene update

2008-04-17 Thread Yanling Liu
Hi, just a simple question. Is there any pre-draw-callback function in osgViewer available so that I can update my scene at the beginning of each frame? Is the setPreDrawCallback in osg::Camera the right place to do scene update? What if I have multiple cameras but just want to udpate scene only

Re: [osg-users] Cyclic graphs?!

2008-04-17 Thread Jason Daly
Art Tevs wrote: However let us think on something like extended scene graphs where cycles are also more or less possible ;-) Does anybody already made some thoughts on that? Hi, Art, I'm sure it's been pondered in the past, I'm just not sure it's relevant to OSG's purposes. Maybe

Re: [osg-users] When must you use SingleThreaded threading model

2008-04-17 Thread Robert Osfield
Hi J-S, On Thu, Apr 17, 2008 at 7:36 PM, Jean-Sébastien Guay [EMAIL PROTECTED] wrote: No solution was forthcoming when we investigated this, and the thread kind of died for lack of time from both of us. I think going through the examples and removing the explicit setting of SingleThreaded

Re: [osg-users] scene update

2008-04-17 Thread Robert Osfield
Hi Yanling, There are update,event and cull callbacks, you also have complete control over the frame loop so you can do what you want being renderingTraversals() is dispatched. Robert. On Thu, Apr 17, 2008 at 7:42 PM, Yanling Liu [EMAIL PROTECTED] wrote: Hi, just a simple question. Is there

Re: [osg-users] Cyclic graphs?!

2008-04-17 Thread Robert Osfield
Hi Art, I've never tried it myself, but the OSG should be able to support cyclic graphs, just not out of the box. The way I'd do it is have a custom Update/Event/CullCallback that is attached to a node in the cycle, these callbacks count the number of times through in each traversal, once an max

Re: [osg-users] Please test SVN of OpenSceneGraph in pre for 2.3.9 devrelease

2008-04-17 Thread Robert Osfield
Hi Andy et. al, On Thu, Apr 17, 2008 at 6:24 PM, Andy Skinner [EMAIL PROTECTED] wrote: It built for me in windows and linux 64 bit. I'm still trying to get a solaris machine, and that is often where there has been trouble. Thanks for the testing. I'll leave tagging 2.3.9 till tomorrow, and

Re: [osg-users] Cyclic graphs?!

2008-04-17 Thread Jean-Sébastien Guay
Hi Art, However let us think on something like extended scene graphs where cycles are also more or less possible ;-) Does anybody already made some thoughts on that? Maybe you've got a cool idea that requires that kind of structure [...] I concur with Jason, and I think the question

[osg-users] picking osg objects using osgUtil::SceneView (cant find osgUtil::PickVisitor!)

2008-04-17 Thread erf
I want to pick osg objects in the scene when pressing the mouse button on them. I am using sceneView so i guess i cant use the osgViewer::View. computeIntersections and i did not find PickVisitor! Im using osg 2.3.7. So i guess i have to use IntersectVisitor. Is there a utility function for

Re: [osg-users] Cyclic graphs?!

2008-04-17 Thread Wojciech Lewandowski
Fractals ? Wojtek ;-) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Jean-Sebastien Guay Sent: Thursday, April 17, 2008 8:57 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Cyclic graphs?! Hi Art, However let us think on something like extended

Re: [osg-users] picking osg objects using osgUtil::SceneView (cant find osgUtil::PickVisitor!)

2008-04-17 Thread Robert Osfield
Hi Erland, Would it not be possible just to use osgViewer rather than SceneView. One of the points of osgViewer is that it provides more higher level functionality that users commonly require, and in doing so avoid the pain of end users having to implement themselves, and the pain involved in

Re: [osg-users] When must you use SingleThreaded threading model

2008-04-17 Thread Wojciech Lewandowski
Hi Guys, One multithreaded issue I am aware of is osgShadow::ShadowMap::cull method. Its definitely not thread safe. It has no critical section locks. I can imagine a scenario when two views cull threads execute concurrently and mess up _texgen matrix. Other similar scenarios are also possible I

Re: [osg-users] Cyclic graphs?!

2008-04-17 Thread Art Tevs
Hi folks, Hmm, yeah it could be. However I haven't thought a lot of thread safety in a cyclic scene graph. Of course, for my purpose, I maybe would be able to redesign the problem and break the cycle in it or more or less leave with it by changing hte ::traverse() methods accordingly. However, I

Re: [osg-users] picking osg objects using osgUtil::SceneView (cant find osgUtil::PickVisitor!)

2008-04-17 Thread erf
Hei Robert. I would like to do that, but im working in a company and right now im trying to integrating osg in a existing rendring system (which handles events, mfc window, renders 3d terrain++) for rendering simple objects, so i'd rather use SceneView as for now. I think i could be using

Re: [osg-users] Please test SVN of OpenSceneGraph in pre for 2.3.9devrelease

2008-04-17 Thread Andy Skinner
This worked on Solaris, too. andy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Robert Osfield Sent: Thursday, April 17, 2008 2:59 PM To: OpenSceneGraph Users Subject: Re: [osg-users] Please test SVN of OpenSceneGraph in pre for 2.3.9devrelease Hi

Re: [osg-users] Please test SVN of OpenSceneGraph in pre for 2.3.9devrelease

2008-04-17 Thread Cedric Pinson
It compiles fine on gentoo gcc version 4.1.2 (Gentoo 4.1.2 p1.0.2) Andy Skinner wrote: This worked on Solaris, too. andy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Robert Osfield Sent: Thursday, April 17, 2008 2:59 PM To: OpenSceneGraph

Re: [osg-users] Access to osg::Image data

2008-04-17 Thread Paul Pocock
osgvolume is a perfect reference - Thanks Robert On Thu, 2008-04-17 at 09:15 +0100, Robert Osfield wrote: Hi Paul, I'm afraid there is too little code in your excerpt to guess at what might be wrong, what is wrong is part of the code you haven't included. The osgvolume example does

Re: [osg-users] When must you use SingleThreaded threading model

2008-04-17 Thread Paul Martz
Hi all -- Another one of the examples that forces SingleThreaded is osgdepthpartition. I keep intending to rewrite it using CompositeViewer with ordered view processing, but haven't gotten around to it yet. In a nutshell, if any code executed by the cull or draw threads (such as your own

[osg-users] How to set Fonts file Path?

2008-04-17 Thread xyc508
Hello,all, I use setFont(Fonts//ARIAL.TTF) ,it can take affects on development machine,but after change other machine it can't show the right Fonts,why? (The file ARIAL.TTF is on the both machine C:\WINDOWS\Fonts\ARIAL.TTF) I got a little confuse: -

[osg-users] What's the mpr.dll ?

2008-04-17 Thread xyc508
Hello, I develop a osg application,it runs right on development machine,but change other machine,it can't. I use DEPENDS.Exe to find the file mpr.dll have problem,it show the error: Warning: At least one module has an unresolved import due to a missing export function in a delay-load

Re: [osg-users] When must you use SingleThreaded threading model

2008-04-17 Thread Jean-Sébastien Guay
Hi Paul, In a nutshell, if any code executed by the cull or draw threads (such as your own callbacks or custom nodes) isn't thread safe, then you must use SingleThreaded. With all due respect, I would reword that: if any code executed by the cull or draw threads (such as your own callbacks

[osg-users] [Help]occlusion quey node does not work when the occluder node is set cullface

2008-04-17 Thread wangzhuhhjj
hi,guys I'm using occlusion query node of osg2.3.7 and it's wonderful. But I met a problem that I put the ceiling and floor of a room in root and the furnitures in room in occlusion query node. Then I set ceiling's face osg::CullFace::FRONT and floor as osg::CullFace::BACK, so that when I see