Re: [osg-users] [build] cannot build osg on mac os x 10.6.5 with gcc version 4.2.1
Hi, Am 04.01.11 01:06, schrieb Nikos Yiotis: [i]Warning: Could not find plugin to read objects from file Images/land_shallow_topo_2048.jpg. View::setUpViewAcrossAllScreens() : Error, no WindowSystemInterface available, cannot create windows. Viewer::realize() - failed to set up any windows Can you set OSG_NOTIFY_LEVEL to a more verbose mode (DEBUG_INFO), to get some more information why image-loading fails? What's the value of OSG_WINDOWING_SYSTEM and OSG_DEFAULT_IMAGE_PLUGIN_FOR_OSX in CMake? cheers, Stephan ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] How to control the model in MFC program?
Hi, I designed a program based on MFC dialog.I want to rotate and move the model by some buttons.And I send a message using the function PostMessage(..) in the handeler of the buttons.In the handeler of the message I modify the viewmatrix and call frame() to render the model.The problem is sometimes the model can not be displayed when I click the button.How can I deal with that? Thank you! Cheers, Duan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35290#35290 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [build] cannot build osg on mac os x 10.6.5 with gcc version 4.2.1
Hi, I thought OSG_NOTIFY_LEVEL was a cmake flag not an env. flag. So I built source from scratch, generating xcode.proj and not makefile this time. I set OSG_WINDOWING_SYSTEM to Cocoa (from Carbon) OSG_DEFAULT_IMAGE_PLUGIN_FOR_OSX to imageio (from quicktime) and it builds, although I get many warnings -literally for each .dylib used-, e.g. ld: warning: duplicate dylib /Users/nikos/NetBeansProjects/OpenSceneGraph/OpenSceneGraph-2.8.3/Bin/lib/Debug/libosgTextd.dylib How can I suppress this? Now osgversion outputs OpenSceneGraph Library 2.8.3 and the osglogo fails again now with osglogo: command not found I set the OSG_NOTIFY_LEVEL to DEBUG_INFO although $ENV_PATH gives me a blank line...the path is correctly highlighted though. I've seen this blank line before, but a quick search does not give me any hints on how to fix that. Thank you! Cheers, Nikos -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35291#35291 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] imageio pluggin, MACOSX 10.6, x86_64bit build question
Hi, I would like to know why the imageio pluggin .so wasn't invoked for jpg/png images with my cocoa/x64 bit build of osg on MACOSX 10.6. For example, running some of the osg examples indicates that it was unable to load the images (although they were correctly found). Could it be the .png or .jpg extensions are forcing osg to look for the associated image pluggins? How is this supposed to be invoked, at least when running the apps from the command line? Thanks for any help- Cheers, Ted -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35292#35292 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] LineSegmentIntersector::Intersection contains no indexList
Hi, I am trying to get uv coordinates and color of a point I found using the LineSegmentIntersector. My problem is that the found intersection has no indexList so I cannot use the code used in osgmovie. This short code example should boil down to the point: Code: osg::Box* b = new osg::Box( osg::Vec3d(0,0,0), 1.0f); osg::Geode* g = new osg::Geode(); g-addDrawable( new osg::ShapeDrawable( b ) ); osg::ref_ptr osgUtil::LineSegmentIntersector lineSeg = new osgUtil::LineSegmentIntersector(osg::Vec3d(0,-2,0), osg::Vec3d(0,0,0)); osgUtil::IntersectionVisitor findIntersections(lineSeg.get()); g-accept(findIntersections); osgUtil::LineSegmentIntersector::Intersection currHit = lineSeg-getFirstIntersection(); osg::Vec3d intersecPnt = currHit.getWorldIntersectPoint(); int vecArraySize = currHit.indexList.size(); int vecRatioSize = currHit.ratioList.size(); intersecPnt is correctly found, but vecArraySize and vecRatioSize is zero. I read through some layers of osg code and it seems my proble is the treatVertexDataAsTemporary variable. It prevents at the end of TriangleIntersector::operator () (part of LineSegmentIntersectorUtils in linesegmentintersector.cpp) that the found three vertices used to compute the intersection are inserted into the result as they are temporary. How do I get the correct uv coordinates in such a situation or how do I force the inclusion of the needed vertices? Cheers, Oliver -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35293#35293 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] VS2010 Memcpy error with osgviewerMFC example
Hi J-S, I think you're original suspicion is probably right. It looks like the C runtime libraries from VS2005 are still being loaded, though I can't figure out where from... Hopefully once I resolve that the problem will go away. I will update after that. Thanks for advice! --Garrett -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35294#35294 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] NVIDIA OptiX cross-format
Hi Holger, I would prefer to have an export to OptiX native format. And if there is none, to have a class that would take OSG scene graph as a data source, setups OptiX node graph and does OptiX rendering, returning final image. That would be a very cool class for anyone interested in photorealistic raytracing! Keep me updated if you reach any nice results. John Original message From: Holger Helmich holger.helm...@gmx.de Subject: [osg-users] NVIDIA OptiX cross-format Date: 3. 1. 2011 17:29:07 Hi, i am working on an OptiX integration into an OSG based application. I am wondering if there are other projects about this issue. Currently i study to set up an serialized OptiX format (e.g. binary or XML) including reader and writter, what could be something like done for OSG (http://www.openscenegraph.org/projects/osg/wiki/Support/KnowledgeBase/Ser ializationSupport) this year. The idea would be to set up an open format (if there is none) for OptiX's node graph. Of course it is not possible as OSG input, but would probably be a first step. Thank you! Cheers, Holger -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35267#35267 ___ 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] VS2010 Memcpy error with osgviewerMFC example
Hi Garrett, I think you're original suspicion is probably right. It looks like the C runtime libraries from VS2005 are still being loaded, though I can't figure out where from... Hopefully once I resolve that the problem will go away. I will update after that. Thanks for advice! Dependency Walker will tell you. It's a really useful tool once you learn to read its output :-). If you don't see it initially after just loading the app in Dependency Walker, then the problem is probably in one of the plugins or their dependencies. To see this, start a profile run in Depencency Walker, which will run your app and thus will check all plugins (which are loaded at runtime only). You might be loading an old version of a plugin or something like that. Hope this helps, J-S -- __ Jean-Sebastien Guayjean-sebastien.g...@cm-labs.com http://www.cm-labs.com/ http://whitestar02.webhop.org/ ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] Getting window id for all platforms
Hi all. I would like to get the window reference for all platforms using osgViewer::Viewer. I found the thread: http://www.mail-archive.com/osg-users@openscenegraph.net/msg12957.html Where I used this code for win32: http://www.mail-archive.com/osg-users@openscenegraph.net/msg12957.html osgViewer::GraphicsWindowWin32* gw = dynamic_castosgViewer::GraphicsWindowWin32* ( application-getViewer()-getCamera()-getGraphicsContext()); HWND hWnd = gw-getHWND(); But I cant find a way to get that under X11, (MacOS, Cocoo or whatever). Is there a portable way of getting this reference? /A ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] osgUtil::Optimizer MERGE_GEODES MERGE_GEOMETRY TEXTURE_ATLAS_BUILDER
Hi all, I am trying to improve our scene graph layout for some of our data, and my first step is to improve our use of osgconv with various optimizer settings. We've been using it for a while but never really examined the results to see if it was doing what it was supposed to. Starting with a really simple object, I have some parts that need to stay separate (in terms of nodes and textures) so I have marked them as DYNAMIC, and the rest I have marked as STATIC. These are all under a single Group. There are 8 geodes and 8 geometry there, using about 4 different textures among them. Then, I set OSG_OPTIMIZER=MERGE_GEODES MERGE_GEOMETRY TEXTURE_ATLAS_BUILDER abd run osgconv with -O OutputTextureFiles to optimize the model. I was expecting the 8 geodes and 8 geometry to become a single geode and geometry pair, and a single texture atlas to be created for the textures. First, two atlases were created, this I think I've found why (there's a maximum size and a margin is used to make sure the image doesn't bleed to the other side). I'll try to tweak the settings to get what I want in this case. But there are two other problems in the result: 1. there are 4 geodes and 4 geometry instead of 1 and 1. 2. it didn't include two of the textures in the atlas. I can't figure out from the code why it's not merging all the geodes and geometry together, and why it's not including two textures in the atlas. In the model itself, nothing really sticks out as being different between the geodes/geometry that were merged and those that weren't (and ditto for the textures that were included in the atlas and those that weren't). Are there any guidelines to make sure the result is optimal? Or are there criteria I should know about to be able to get the results I want (other than dataVariance)? Thanks in advance, J-S -- __ Jean-Sebastien Guayjean-sebastien.g...@cm-labs.com http://www.cm-labs.com/ http://whitestar02.webhop.org/ ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Problem with Transparency when using osg::Cameras
Hello and happy new year! Sorry for the late response. What I am doing is explained in my last post there: http://forum.openscenegraph.org/viewtopic.php?t=7296 I use cameras because of their culling mask. This way I can control which geometry (under the camera node) should be drawn. Is there any other better way to do this? Thanks you very much! Cheers, George -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35301#35301 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] Using TerrainManipulator when the projection matrix is in Ortho mode
Greetings! I'm experimenting using the a scene graph projected in Ortho mode using the setProjectionMatrixAsOrtho function on the camera and while using the TerrainManipulator on the camera I noticed that the pan is working, but zoom is not! In fact, the only way that I could affect any kind of zoom was to narrow the POV on the camera (that realty is not a zoom). I tried to look for any examples but came up short. Is there any switch or methodology that I missed that can give me an Ortho projection of an otherwise a 3D scene graph? ... Happy New Year All D Glenn D Glenn (a.k.a David Glenn) - Moving Heaven and Earth! -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35303#35303 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Problem with Transparency when using osg::Cameras
Paul Martz wrote: Why do you need a camera in the scene graph for this? Why not use the top-level viewer camera? -Paul Hello Paul! Because I need multiple cameras. Each camera has a different culling mask for drawing different parts of the same graph. My diagram here has one osg::Camera for simplicity. But the actual graph has three cameras instead of one. Imagine that you replace the osg::Group group02 of this diagram with the graph of my older post. This is closer to what my full scene graph looks like. Thank you! Cheers, George -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35304#35304 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Using TerrainManipulator when the projection matrix is in Ortho mode
Hi David, I'm experimenting using the a scene graph projected in Ortho mode using the setProjectionMatrixAsOrtho function on the camera and while using the TerrainManipulator on the camera I noticed that the pan is working, but zoom is not! In fact, the only way that I could affect any kind of zoom was to narrow the POV on the camera (that realty is not a zoom). Well in fact yes... Zoom, in camera-speak, is making the FOV of the camera smaller/larger. What the normal manipulators do to zoom is to move the camera itself, i.e. dolly in/out in camera-speak. You may have seen the dolly in zoom out effect in movies, where the camera dollies in while doing a zoom out with the lens at the same time, and I use that expression to help me remember the difference between the two. http://en.wikipedia.org/wiki/Dolly_zoom http://en.wikipedia.org/wiki/File:Contra-zoom_aka_dolly_zoom_animation.gif But to get back to your question, this is an FAQ... Since with an ortho camera moving the camera forward or back will have no visible effect (apart from when you start hitting your near/far planes), you won't be able to zoom with the normal camera manipulators in an ortho view. You will have to make your own manipulator or use another way of changing the camera's left/right and top/bottom clipping planes, effectively the camera's field of view (though in ortho it's not a frustum, but a box). I kind of wish (and I've expressed this wish in threads that asked the same question before, but haven't had time to do anything about it) that the OSG camera manipulators supported affecting other parameters of the camera than just its view matrix. As it is, you'll have to affect the projection matrix yourself directly, i.e. your camera manipulator will have to know about the camera(s) it's affecting, which defeats the nice loose coupling that we have between camera manipulator and camera otherwise. Hope this helps, J-S -- __ Jean-Sebastien Guayjean-sebastien.g...@cm-labs.com http://www.cm-labs.com/ http://whitestar02.webhop.org/ ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Using TerrainManipulator when the projection matrix is in Ortho mode
Skylark wrote: Hi David, Well in fact yes... Zoom, in camera-speak, is making the FOV of the camera smaller/larger. What the normal manipulators do to zoom is to move the camera itself, i.e. dolly in/out in camera-speak. You may have seen the dolly in zoom out effect in movies, where the camera dollies in while doing a zoom out with the lens at the same time, and I use that expression to help me remember the difference between the two. http://en.wikipedia.org/wiki/Dolly_zoom http://en.wikipedia.org/wiki/File:Contra-zoom_aka_dolly_zoom_animation.gif Well, you’re right there! Forgive me J-S for briefly forgetting my Cinematography 101 on my last post! I guess what I was referring to was that the behavior was not the same as what I got in Perspective using the TerrainManipulator. I had to deal with the Ortho view area manualy and well as the mouse zoom. And yes I do realize the facts of the behavior of ortho projection. In fact that is why I'm using it in this case - to get a map-like view on a 3D world! I was just hoping (agenst hope) that someone had dealt with this before I - since there are some planview's out there that i heard of that was done in OSG! I guess I'll just have to come up with something to get the mouse to work somewhat the same way it works in Perspective mode! The worse case, I will have to look on how it was done manualy in the old Performer code I have and translate it to a Manipulator some how! Thanks! --- D Glenn D Glenn (a.k.a David Glenn) - Moving Heaven and Earth! -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35306#35306 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Using TerrainManipulator when the projection matrix is in Ortho mode
Here we go again... :-) On 1/4/2011 10:56 AM, David Glenn wrote: Greetings! I'm experimenting using the a scene graph projected in Ortho mode using the setProjectionMatrixAsOrtho function on the camera and while using the TerrainManipulator on the camera I noticed that the pan is working, but zoom is not! In fact, the only way that I could affect any kind of zoom was to narrow the POV on the camera (that realty is not a zoom). Hi David -- To be precise, changing the FOV _is_ zoom. A zoom lens on a camera changes the FOV to make the image larger or smaller. In fact, in an orthographic projection, changing the FOV is the _only_ way to make the image larger or smaller, as the eye has no distance, only direction. There is no parallax effect in an orthographic projection. I tried to look for any examples but came up short. You should check the archives for discussion of ortho, zoom, and fov. This has been discussed multiple times in the past. Is there any switch or methodology that I missed that can give me an Ortho projection of an otherwise a 3D scene graph? ... Happy New Year All D Glenn D Glenn (a.k.a David Glenn) - Moving Heaven and Earth! -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35303#35303 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- -Paul Martz Skew Matrix Software http://www.skew-matrix.com/ ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Using TerrainManipulator when the projection matrix is in Ortho mode
Hi David, I was just hoping (agenst hope) that someone had dealt with this before I - since there are some planview's out there that i heard of that was done in OSG! Well that doesn't mean no one has ever dealt with these issues, just that no one has ever contributed a camera manipulator that did it. They probably did what we did and what I would suggest you do: create a derived class of whatever camera manipulator you want, override the handle() method, check if the event type is a drag with the right mouse button pressed (or whatever other event you want to check for) and do the zoom then. In all other cases just call the base class handle() from your handle() method. As I said, you'll need to pass the camera to your camera manipulator so it can call setProjectionMatrixAsOrtho with modified values at the appropriate time. Hope this helps, J-S -- __ Jean-Sebastien Guayjean-sebastien.g...@cm-labs.com http://www.cm-labs.com/ http://whitestar02.webhop.org/ ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Using TerrainManipulator when the projection matrix is in Ortho mode
On 1/4/2011 1:14 PM, Jean-Sébastien Guay wrote: Hi David, I was just hoping (agenst hope) that someone had dealt with this before I - since there are some planview's out there that i heard of that was done in OSG! Well that doesn't mean no one has ever dealt with these issues, just that no one has ever contributed a camera manipulator that did it. They probably did what we did and what I would suggest you do: create a derived class of whatever camera manipulator you want, override the handle() method, check if the event type is a drag with the right mouse button pressed (or whatever other event you want to check for) and do the zoom then. In all other cases just call the base class handle() from your handle() method. That's a good solution, and I want to emphasize the or whatever other event you want to check for part. I prefer to have control over both FOV and distance (yes, even in perspective mode), as they clearly produce different results, and sometimes I want one effect and sometimes I want the other. For this reason I recommend against using the right button for FOV. OSG has already set a precedence that this button controls distance. Using right mouse for FOV could be confusing. I usually modify FOV with ctrl right mouse in my code. -- -Paul Martz Skew Matrix Software http://www.skew-matrix.com/ ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [forum] Line Of Sight and skyline tools
Dan, Take a look at the osgintersection example. It uses osgSim::LineOfSight class... Regards, -Shayne -Original Message- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Darko Radiceski Sent: Monday, January 03, 2011 10:01 PM To: osg-users@lists.openscenegraph.org Subject: [osg-users] [forum] Line Of Sight and skyline tools Hi all, I had a question in regards to possible examples of lines of sight or skyline tool implementations in OSG. I did notice the OSGSim LineOfSight helper class in my research and was wondering if there are any examples of that class in use. Also any examples of skyline calculation from the loaded data within the scene? Any advice or pointers would be greatly appreciated. Thank you! Cheers, Dan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35287#35287 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org smime.p7s Description: S/MIME cryptographic signature ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Using TerrainManipulator when the projection matrix is in Ortho mode
Greetings! Sorry all! I didn't mean to open old battle wounds Paul. I was just wondering if anybody else has written anything before I tacked it on my own! Frankly I've never had the chance to look into the logistics of it yet! I just got the command from Mt High that my project has to be Orthographic and I’ve never done anything Orthographic in OSG (outside of a Hud display) before. Thanks for the help! D Glenn D Glenn (a.k.a David Glenn) - Moving Heaven and Earth! -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35311#35311 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] imageio pluggin, MACOSX 10.6, x86_64bit build question
Hi Ted, On 5/01/11 0:12 , Ted Morris wrote: I would like to know why the imageio pluggin .so wasn't invoked for jpg/png images with my cocoa/x64 bit build of osg on MACOSX 10.6. For example, running some of the osg examples indicates that it was unable to load the images (although they were correctly found). Could it be the .png or .jpg extensions are forcing osg to look for the associated image pluggins? The way OSG selects plugins for loading is by looking at the extension, checking if an already loaded plugin handles this, and if not load osgdb_extension.so. This obviously doesn't work for multi-extension plugins such as imageio, quicktime, or ffmpeg. You have to manually pre-load the plugin in this case. How is this supposed to be invoked, at least when running the apps from the command line? osgviewer -e imageio --image file.jpg Hope this helps, Cheers, /ulrich ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] [build] cannot build osg on mac os x 10.6.5 with gcc version 4.2.1
I ran OSG_NOTIFY_LEVEL=debug through a script, but my echo $ENV_PATH still appears blank. How can I verify that it is set? Again, all set with PATH, DYLB_PATH, etc. Cheers, Nikos -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35313#35313 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] runtime error
Thanks for the reply. Might have confused you. I have a 64 bit machine and a 32 bit machine. I have been building osg on both machines and installing the openscenegraph package on both from package manager. I just removed the osg package with package manager and then got the latest trunk on both machines. I build fine and they install fine on each platform. However, I get the same result. I get the error when I build osg from source and I can run osgversion when I install 2.8.1 from the package manager. I am doing this independently on both machines to see if I can get one or the other to work. I am wondering if it is the code? I am at a loss. I have not had trouble with osg for a while. All compiles well. Any ideas? On Mon, 2011-01-03 at 20:17 +0100, David Callu wrote: I Michael, This seem that you run 64bit osgversion executable and use 32bit libosg.so library, or vice versa. You have to choose one version to install on your computer, or put the directory containing the right version of osg library in first place of your PATH environment variable ex : if you use the 32bit version of osg, do # export PATH=/usr/local/lib:$PATH # /usr/local/bin/osgversion HTH David Callu 2011/1/3 Michael Hall hal...@att.net Ok. I installed OSG using apt-get and it installed 2.8.1 on both my 32 and 64 bit machines. Both ran the osgversion command. However, I removed the package from the 32 bit machine and tried to compile the latest. The compile goes fine no errors, the make install works great. However, when I try osgversion, I still get the following: osgversion: symbol lookup error: /usr/local/lib/libosg.so.70: undefined symbol: _ZN11OpenThreads5MutexC1ENS0_9MutexTypeE How do I run the ldd with osgversion to see what it needed? I have tried and I cannot figure out how to use it. I do have the libosg.s0.70 on my machine. Is any one else seeing this. Could be that I am missing something needed to run. Any help with ldd will be appreciated. Michael ___ 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
Re: [osg-users] [build] cannot build osg on mac os x 10.6.5 with gcc version 4.2.1
Hi Nikos, regarding osglogo not being found, it is built as part of the examples, so BUILD_OSG_EXAMPLES must be on in cmake. I'm building on 10.6.5 with Makefiles (using gcc 4.2.1) and set the following in cmake: BUILD_OSG_APPLICATIONS=ON BUILD_OSG_EXAMPLES=ON CMAKE_OS_ARCHITECTURES=x86_64 OSG_DEFAULT_IMAGE_PLUGIN_FOR_OSX=imageio OSG_WINDOWING_SYSTEM=Cocoa Hope this helps, Cheers, /ulrich ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Using TerrainManipulator when the projection matrix is in Ortho mode
Hi Paul, I prefer to have control over both FOV and distance (yes, even in perspective mode), as they clearly produce different results, and sometimes I want one effect and sometimes I want the other. I see your point, but I would say that depends on the expected level of the users of your application, and of course different applications will have different requirements as well. You can even do different things based on the current camera type. The last element of a projection matrix tells you if it's perspective or ortho - mat[3][3] will be 0 or 1 respectively (see http://www.songho.ca/opengl/gl_projectionmatrix.html). So you can have a single camera manipulator that works for any camera (for both projection types), and decide what to do depending on that value if you want. Hope this helps, J-S -- __ Jean-Sebastien Guayjean-sebastien.g...@cm-labs.com http://www.cm-labs.com/ http://whitestar02.webhop.org/ ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] runtime error
Hi, remove the openthreads packages using package manager as well. If that doesn't work, please post the output of: ldd osgversion on both machines jp On 05/01/11 03:29, Michael W. Hall wrote: Thanks for the reply. Might have confused you. I have a 64 bit machine and a 32 bit machine. I have been building osg on both machines and installing the openscenegraph package on both from package manager. I just removed the osg package with package manager and then got the latest trunk on both machines. I build fine and they install fine on each platform. However, I get the same result. I get the error when I build osg from source and I can run osgversion when I install 2.8.1 from the package manager. I am doing this independently on both machines to see if I can get one or the other to work. I am wondering if it is the code? I am at a loss. I have not had trouble with osg for a while. All compiles well. Any ideas? On Mon, 2011-01-03 at 20:17 +0100, David Callu wrote: I Michael, This seem that you run 64bit osgversion executable and use 32bit libosg.so library, or vice versa. You have to choose one version to install on your computer, or put the directory containing the right version of osg library in first place of your PATH environment variable ex : if you use the 32bit version of osg, do # export PATH=/usr/local/lib:$PATH # /usr/local/bin/osgversion HTH David Callu 2011/1/3 Michael Hallhal...@att.net Ok. I installed OSG using apt-get and it installed 2.8.1 on both my 32 and 64 bit machines. Both ran the osgversion command. However, I removed the package from the 32 bit machine and tried to compile the latest. The compile goes fine no errors, the make install works great. However, when I try osgversion, I still get the following: osgversion: symbol lookup error: /usr/local/lib/libosg.so.70: undefined symbol: _ZN11OpenThreads5MutexC1ENS0_9MutexTypeE How do I run the ldd with osgversion to see what it needed? I have tried and I cannot figure out how to use it. I do have the libosg.s0.70 on my machine. Is any one else seeing this. Could be that I am missing something needed to run. Any help with ldd will be appreciated. Michael ___ 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 -- This message is subject to the CSIR's copyright terms and conditions, e-mail legal notice, and implemented Open Document Format (ODF) standard. The full disclaimer details can be found at http://www.csir.co.za/disclaimer.html. This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. MailScanner thanks Transtec Computers for their support. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] How to control the model in MFC program?
Hi,sorry,problem solved.Something wrong with my projection matrix. ... Thank you! Cheers, Duan -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35318#35318 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Using TerrainManipulator when the projection matrix is in Ortho mode
Hi, I've made an ortho texture manipulator before for panning and zooming an image. Basically you have to scale the ortho projection before doing any translation/rotation. osg::Matrixd OrthoTextureManipulator::getInverseMatrix() const { return osg::Matrixd::translate(-_center) * osg::Matrixd::translate(-_zoom_offset) * osg::Matrixd::scale(_distance, _distance, 1.0) * osg::Matrixd::translate(_zoom_offset) * osg::Matrixd::rotate(_rotation.inverse()); } This was for a texture in the XY-plane. rgds jp On 05/01/11 00:26, David Glenn wrote: Greetings! Sorry all! I didn't mean to open old battle wounds Paul. I was just wondering if anybody else has written anything before I tacked it on my own! Frankly I've never had the chance to look into the logistics of it yet! I just got the command from Mt High that my project has to be Orthographic and I’ve never done anything Orthographic in OSG (outside of a Hud display) before. Thanks for the help! D Glenn D Glenn (a.k.a David Glenn) - Moving Heaven and Earth! -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=35311#35311 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- This message is subject to the CSIR's copyright terms and conditions, e-mail legal notice, and implemented Open Document Format (ODF) standard. The full disclaimer details can be found at http://www.csir.co.za/disclaimer.html. This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. MailScanner thanks Transtec Computers for their support. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] Limitation in current ImageLayer serializer
Hi, I have found a little more time to work on this issue but have become stuck. Using a user serializer I have managed to read and write the image sucsessfully in the case that the image is loaded, but cant get it to work in the case the image should not be loaded. I think the issue is that, when I don't want want to read the image (i.e. deffered loading is enabled), then I still need to read the image 'header' from the stream. If the image is embedded in the file then I think I will need to read the entire image regardless of wether deffered loading is enabled or not (I haven't looked at this case yet). The code I am using is (I am testing with .osgt files so far): static bool readImage( osgDB::InputStream is, osgTerrain::ImageLayer im ) { std::string filename = im.getFileName(); if (!filename.empty()) { bool hasImage; is hasImage; if(hasImage) { is osgDB::BEGIN_BRACKET; bool deferExternalLayerLoading = osgTerrain::TerrainTile::getTileLoadedCallback().valid() ? osgTerrain::TerrainTile::getTileLoadedCallback()-deferExternalLayerLoading() : false; if (!deferExternalLayerLoading) { osg::ref_ptrosg::Image image = is.readImage(); if (image.valid()) { im.setImage(image.get()); } } else { //I think this is where I need to read of the image 'header' } is osgDB::END_BRACKET; } } return true; } static bool writeImage( osgDB::OutputStream os, const osgTerrain::ImageLayer im ) { const osg::Image* value = im.getImage(); bool hasObject = (value!=NULL); os hasObject; if ( hasObject ) { os osgDB::BEGIN_BRACKET std::endl; os.writeImage( value ); os osgDB::END_BRACKET; } return true; } The relevenat section of the osgt file that is created is: Layers 1 { Object osgTerrain::ImageLayer { UniqueID 9 Name kljhjkl FileName earth_L1_X0_Y0_kljhjkl.dds Locator TRUE { osgTerrain::Locator { UniqueID 4 } } Image TRUE { UniqueID 10 FileName earth_L1_X0_Y0_kljhjkl.dds WriteHint 2 2 DataVariance STATIC }} } And the error I get when loading the file with deffered loading enabled is a bad allocation error. Any suggestions would be greatly appreciated! Cheers, Brad -Original Message- From: osg-users-boun...@lists.openscenegraph.org [mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Wang Rui Sent: Tuesday, 30 November 2010 1:47 PM To: osg-users@lists.openscenegraph.org Subject: Re: [osg-users] Limitation in current ImageLayer serializer Hi Brad, In fact when I'm working on the osgTerrain serializers, I don't pay much attention to the special mechanism that may be required when loading terrain tile and layer classes. For the case that the image layer may be loaded inactive according to an additional flag, I suggest that we should handle all of these with a user serializer instead, that is, REGISTER_OBJECT_WRAPPER( osgTerrain_ImageLayer, new osgTerrain::ImageLayer, osgTerrain::ImageLayer, osg::Object osgTerrain::Layer osgTerrain::ImageLayer ) { ADD_USER_SERIALIZER( Image ); // _image } And write/read images and activate them by ourselves. Here we can read out an image object from the input stream using is.readImage(), and write image to disk files with the operator. Hope this can help if you would like to help fix the problem. :-) Cheers, Wang Rui 2010/11/30 Brad Christiansen brad.christian...@thalesgroup.com.au: Hi, I have discovered a piece of missing functionality in the new serializer for osgTerrain::ImageLayers. The issue is that all optional layers are loaded when an osgb file is loaded regardless of weather they should be or not. The relevant piece of code for the the .ive format is in (in osgDB_ive) void ImageLayer::read(DataInputStream* in) at line 64: bool deferExternalLayerLoading = osgTerrain::TerrainTile::getTileLoadedCallback().valid() ? osgTerrain::TerrainTile::getTileLoadedCallback()-deferExternalLayerLoading() : false; // Should we read image data from stream IncludeImageMode includeImg = (IncludeImageMode)in-readChar(); if (includeImg==IMAGE_REFERENCE_FILE deferExternalLayerLoading) { setFileName(in-readString()); } else { setImage(in-readImage(includeImg)); } The new serializer simple adds an image serializer for an ImageLayer with no similar checks. I have had a quick look at coding a fix but have to admit I still dont fully understand how the new system works in such cases. If anyone can give me some pointers on how to go about adding this functionality that would be greatly apprecaited as at the momment I am having to covert my terrain