Re: [osg-users] Invalid GL buffer object

2013-10-17 Thread Robert Osfield
Hi Sajjadul, I really don't know specifically what might be wrong with what you are doing, I can't make sense of the code snippets, it's the wider context that would probably illustrate what is going wrong. The best I can do is mention that importance of only doing OpenGL calls from a thread with

[osg-users] osgVolume intersected by geode problem about sequence of intersection points using osgUtil::PlaneIntersector

2013-10-17 Thread tianyun . su
Hi, I am trying to get the intersection points between an intersection plane and a terrain using osgUtil::PlaneIntersector。 The code is listed as following: osg::Plane planeLeft( osg::Vec3(1,0,0), osg::Vec3(0+1,0,0) );//define an intersetion plane osg::Polytope polytopeLeft;//define the rang

Re: [osg-users] Invalid GL buffer object

2013-10-17 Thread Sajjadul Islam
Hi Forum, I forgot to mention that i get a valid glBO pointer even though i have 0 buffer object id with glGenBuffers(..) Thank you! Cheers, Sajjadul -- Read this topic online here: http://forum.openscenegraph.org/viewtopic.php?p=56840#56840 _

Re: [osg-users] Invalid GL buffer object

2013-10-17 Thread Sajjadul Islam
Hi Forum, It has been a while and i did not get any feed-back over my last post. I realized that i was not clear enough in my explanation. Let me try again. I store the current graphics context and part of the code snippet shows that the current context is stored: Code: void Context::ope

Re: [osg-users] osgVolume intersected by geode

2013-10-17 Thread Robert Osfield
Hi Jorden, This behaviour is an artefact of the ray tracing implementation used in osgVolume::RayTracedTechnique - the rays are generated from the back face of the volume and if these fragments are culled by the z test nothing appears, even if the complete ray would be in front of the z value in t

Re: [osg-users] UBO bug in Program.cpp

2013-10-17 Thread Robert Osfield
Hi Chris, Thanks for spotting the error. Your suggested fix looks sound to me, now merged and submitted to svn/trunk and OSG-3.2 branch. Robert. On 17 October 2013 17:38, D. Christopher Fennell < dchristopherfenn...@yahoo.com> wrote: > Hi everybody, > > I'm not sure if this is the correct for

[osg-users] UBO bug in Program.cpp

2013-10-17 Thread D. Christopher Fennell
Hi everybody, I'm not sure if this is the correct forum, but there is a bug in Program.cpp regarding uniform buffer objects (UBO) in the LinkProgram function. The following line _extensions->glGetProgramiv(_glProgramHandle, GL_ACTIVE_UNIF

[osg-users] A bug in multi-threaded osgTerrain (with proposed fix) plus assorted questions

2013-10-17 Thread Keith Steiger
I'm using osgSim::LineOfSight to answer line-of-sight questions for a larger application. I'm seeding my osgSim::DatabaseCacheReadCallback with the appropriate files before I start, and then sending quite a few requests at the same time, processed through a thread pool. If two threads end up i

Re: [osg-users] Grayscale texture

2013-10-17 Thread Paweł Księżopolski
jimmy82 wrote: > Hi, > Is there any way that I can choose a suitable texture format that > represents only 8-bit gray-scale texture? So far, I understand that the > internal representation of gray-scale and coloured texture are similar under > OpenGL compression schemes and S3TC. > All S

[osg-users] How change the vertical sync?

2013-10-17 Thread Julio Jerez
Oh there is one more thing you need to first, you need create a new context so that you can realize it, otherwise the function make current do not take place here is the final code viewer.setUpViewInWindow(x, y, width, height); //Get the traits of the current window os

Re: [osg-users] How to add shadows to deferred shading?

2013-10-17 Thread Marcel Pursche
Hi, it is a bit complex to explain in detail how the projection matrix transforms depth values. In short: the depth is linearized to [0,1] with the near and far plane and after this multiplied with a depth-dependent factor, so that near values take up more space in the depth range than far away

[osg-users] How change the vertical sync?

2013-10-17 Thread Julio Jerez
No, I do not think that controlling this at the driver level is the right way to do that. I digged a litle and I think I found a better way, in case any anyone wants to know, here is how it can be done on initilaization //Get the traits of the current window osg::ref_ptr< osg:

[osg-users] problem about sequence of intersection points using osgUtil::PlaneIntersector

2013-10-17 Thread tianyun . su
Hi, I am trying to get the intersection points between an intersection plane and a terrain using osgUtil::PlaneIntersector。 The code is listed as following: osg::Plane planeLeft( osg::Vec3(1,0,0), osg::Vec3(0+1,0,0) );//define an intersetion plane osg::Polytope polytopeLeft;//define the rang

Re: [osg-users] Track map on a 3D view

2013-10-17 Thread Robert Osfield
Hi Gianni, A CompositeViewer with two View's, potentially sharing the same window so that one view overlays the other like a HUD is the way I would tackle the tasks. The View's could share the same scene graph, or have their own scene graph. If you wanted to share the scene graph but view differ

Re: [osg-users] [build] Build Problem with osgGA at MacOS with Xcode 5

2013-10-17 Thread Robert Osfield
Hi Jan, I don't have an OSX box to test against, but at a guess the line "ld: symbol(s) not found for architecture x86_64" looks to be the most suspicious one. Any chance that the build settings have changed or that somehow the serializer plugins are compiling against libs that were created with

Re: [osg-users] How change the vertical sync?

2013-10-17 Thread PCJohn
Hi Julio, this is the code I am using (you may need to reformat it, because email splits many lines into two). Call it once you have active context. You may still need some includes like #include #if defined(__WIN32__) || defined(_WIN32) # [...] #else # include #endif and so on. John //

Re: [osg-users] Delay in reading .obj models

2013-10-17 Thread Robert Osfield
Hi Mots, It's not that there is a delay, it's just that the tessellation and tri stripping of the mesh that the .obj plugin does by default takes a long time on big meshes. Once the data is loaded into the scene graph and saved to .osgt the tessellation/tri stripping work has already been done so