Re: [osg-users] Using PolytopeIntersector from the root of the scene graph instead of camera

2010-02-05 Thread Peter Hrenka

Hi Julien-Charles,

Julien-Charles Lévesque schrieb:

Hi Peter,

What do you mean by a degenerated polytope of volume 0 ? That polytope 
definitely doesn't have a null volume since I've been using it to select 
objects in my application and it works.


The four planes all have the same starting point because I want the 
polytope to be a pyramid coming out from a user's hand, so the planes 
-should- all intersect at the summit, no ?


You are right. I did not look closely enough and assumed
you where trying to build a parallel polytope.
The polytope looks to be alright.



Julien-Charles

On Thu, Feb 4, 2010 at 8:35 AM, Peter Hrenka 
p.hre...@science-computing.de mailto:p.hre...@science-computing.de 
wrote:


Hi Julien-Charles,

Julien-Charles Lévesque schrieb:

[...]


Here is my code... stripped down to a minimum. I assume that you
have a 4x4 matrix containing orientation of your selector
(lOrientation) and a vec3 containing it's position (lPosition).
I built the polytope to point in the direction of positive
y-axis. Sorry for the french variable names and comments here
and there... I don't think they hurt readability much at this
level :P

However, I wasn't able to extract a reliable 3x3 rotation matrix
from mouse coordinates. I can only say that this code works well
with the raw 3x3 orientation and position provided by my
tracker. Do you have any idea for a desktop variation ? I can
implement it. I could also integrate all this in the
examplekeyboardmouse, once I've figured out how to do it with a
mouse :P


I would suggest to control the rotation and position
using the keyboard. This should be enough for the
purpose of an osg-example. I think it would be nice
if the polytope would be visualized as a wireframe
model.
I also would suggest of creating a new osgpolytopeintersector-
example because nobody really looks into osgkeyboardmouse
when looking for polytope-intersection functionality...



Cheers,

Peter
--
Vorstand/Board of Management:
Dr. Bernd Finkbeiner, Dr. Roland Niemeier, 
Dr. Arno Steitz, Dr. Ingrid Zech

Vorsitzender des Aufsichtsrats/
Chairman of the Supervisory Board:
Michel Lepert
Sitz/Registered Office: Tuebingen
Registergericht/Registration Court: Stuttgart
Registernummer/Commercial Register No.: HRB 382196 



___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] [osgPPU] osgPPU cube map sample

2010-02-05 Thread Sebastien Nerig
Hi,

Thank you for the explanation

Sebastien

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23712#23712





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] [osgOcean] osgOcean Geometry

2010-02-05 Thread Kim Bale
Hi TM,

Erm don't get too excited, like I say I've only added the test cases onto a
sandbox directory on the svn.. Really all that is a new mipmapgeometry class
that supports shader positioning and a cobbled together test case that
updates the primitive levels. I haven't actually merged the code into the
library yet

Sorry to disappoint :(

Kim.

On 5 February 2010 03:44, Tian Ma tianxiao...@foxmail.com wrote:

 Good work Kim! I have update the svn code! A little real-time |-)
  :D


 Kim Bale wrote:
  Hi Paul,
 
  Yes you're right this is due to the rather inefficient method of updating
 the surface primitives and vertices that osgOcean uses at the moment.
 Explained here:
 
 
 
 http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/2009-December/036735.html(
 http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/2009-December/036735.html
 )
 
 
  Like I say in that post I have written a test case which significantly
 improves the performance of this area but haven't actually added it into the
 library code yet. This isn't helped by the fact that I keep forgetting to
 put the test code on the svn so other people can't see the approach.
 However, I WILL remember to do that tonight so if you want to see a solution
 for it you can have a go.
 
 
  I've done the hard bit, I just haven't had time to add it into the core
 library code. If you check the sandbox directory on the svn later this
 evening you can have a look.
 
 
  Regards,
 
 
  Kim.
 
 
 
  On 4 February 2010 13:13, Paul Palumbo  () wrote:
 
   I'm running osgOcean and I'm only interested into ocean surface effects
 (the geometry in particular). I also have a hard time limit on each frame
 time. However, with osgOcean, I'm seeing some large spikes in processing
 time that are causing me problems.
  
   In particular, I'm seeing the FFTOceanSurface::computeVertices routine
 (called every 50ms) taking around 17-25ms per call and
 FFTOceanSurface::computePrimitives routine (called when tile LOD changes)
 taking 10-15ms and I'm looking for a way to make this more real-time.
 These timing numbers are with osgOcean parameters using in the oceanExample
 code.
  
   Could the ocean surface geometry be defined at initialization at the
 scene graph level for each tile/frame rather than being redefined every 50ms
 as it doing now. In computePrimitives, couldn't the geometry only need to be
 regenerated for the times that changed LOD?
  
   Any advice would be appreciated.
  
   Thanks,
   Paul P.
  
   --
   Read this topic online here:
   http://forum.openscenegraph.org/viewtopic.php?p=23670#23670 (
 http://forum.openscenegraph.org/viewtopic.php?p=23670#23670)
  
  
  
  
  
   ___
   osg-users mailing list
()
  
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org(
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org)
  
 
 
   --
  Post generated by Mail2Forum


 --
 Read this topic online here:
 http://forum.openscenegraph.org/viewtopic.php?p=23708#23708





 ___
 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] [osgOcean] osgOcean Geometry

2010-02-05 Thread Kim Bale
Hi Peter,

This has come up a couple of times actually. It would be feasible I think
with the new method of updating the tile positions that I've added to the
sandbox.

Whilst I haven't put a lot of thought into it, I'm thinking that
the ellipsoid distortion could be added to tiles within the vertex shader,
so basically taking the same old tiles and merging it with a tile of offsets
that is passed in. Then instead of using a straight translation to position
the tiles as is done in the test case, you would then use some sort of
slight rotational transform instead.

I must confess it's not a priority at this time, as you can see my progress
is very slow at the moment.

Regards,

Kim.


On 5 February 2010 01:36, Peter Bear th3fly...@gmail.com wrote:

 Question, would that change make it possible to make a round earth using
 osgOcean. I noticed it talking about tiles in that post and it sparked my
 interest.

 Cheers,
 Peter

 --
 Read this topic online here:
 http://forum.openscenegraph.org/viewtopic.php?p=23706#23706





 ___
 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] Dynamic Uniform with ATI

2010-02-05 Thread Christiansen, Brad
Hi All,

 

I have run in to some trouble with a shader that uses a dynamically
updated uniform (updated rarely but it does change). Everything works as
expected on all nvidia cards I have tried but I cannot get it to work on
an ATI card (FirePro V5700). All systems are running WinXP. I know ATIs
OpenGL drivers are terrible, but has anyone come across this problem and
has a suggestion on how to fix it?

 

I have made a realy simple shader to replicate the problem:

 

uniform int numActiveLayers;  //updated dynamically

 

void main() {

  vec4 col = texture2D(textures[0], gl_TexCoord[0].st);

  if(numActiveLayers == 1) {  //at first, always set to 1

gl_FragColor = col;

  } else if(numActiveLayers  999){ //this condition is never true

 //} else if(1  999) { //if  I change to this it all works fine. It
only executes this block if I test against the uniform

 

//does nothing but causes the problem, which means it is still
executed. 

   //There is no texture in unit 1 so it is fine to fail but it
shouldn't execute

vec4 layerCol = texture2D(textures[1],gl_TexCoord[0].st);   

   // Even when it is failing because of the above line, the output
fragment is not red.

gl_FragColor = vec4(1,0,0,1);

  }

}

 

 

Any ideas would be greatly appreciated as I am completely stuck.

 

Cheers,

 

Brad




DISCLAIMER:---
This e-mail transmission and any documents, files and previous e-mail messages
attached to it are private and confidential. They may contain proprietary or 
copyright
material or information that is subject to legal professional privilege. They 
are for
the use of the intended recipient only.  Any unauthorised viewing, use, 
disclosure,
copying, alteration, storage or distribution of, or reliance on, this message is
strictly prohibited. No part may be reproduced, adapted or transmitted without 
the
written permission of the owner. If you have received this transmission in 
error, or
are not an authorised recipient, please immediately notify the sender by return 
email,
delete this message and all copies from your e-mail system, and destroy any 
printed
copies. Receipt by anyone other than the intended recipient should not be 
deemed a
waiver of any privilege or protection. Thales Australia does not warrant or 
represent
that this e-mail or any documents, files and previous e-mail messages attached 
are
error or virus free.
--

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] bad screen identifier

2010-02-05 Thread Sebastien Nerig
Hi,

When I launch my osg app this morning, I've got this error while creating the 
graphic context : 
 Win32WindowingSystem::getScreenInformation() - The screen identifier on the 
 Win32 platform must always use display number 0. Value received was 15
 Error: [screen #0] GraphicsWindowWin32::setPixelFormat() - No matching pixel 
 format found base on traits specified


I really do not understand because yesterday it worked perfectly ...


Code:
osg::GraphicsContext::WindowingSystemInterface* wsi = 
osg::GraphicsContext::getWindowingSystemInterface();
assert(wsi);

unsigned int width, height;
wsi-getScreenResolution(osg::GraphicsContext::ScreenIdentifier(0), width, 
height);

osg::ref_ptrosg::GraphicsContext::Traits traits = new 
osg::GraphicsContext::Traits;
traits-x = 0;
traits-y = 0;
traits-width = width;
traits-height = height;
traits-windowDecoration = false;
traits-doubleBuffer = true;
traits-sharedContext = 0;

osg::ref_ptrosg::GraphicsContext gc = 
osg::GraphicsContext::createGraphicsContext(traits.get());  
assert(gc.valid());



I tried to reboot my computer, but it always the same. Do you have any ideas ?

Thank you!

Cheers,
Sebastien

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23717#23717





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Stereo out of screen?

2010-02-05 Thread Nathan Schofield
Hi,

I've building a project with osg to render a terrain model in quad buffered 
stereo. It has been working great so far, and I have managed to achieve plenty 
of depth to the scene. The problem I am facing is trying to get some of the 
scene to appear out of the screen floating in front of the monitor - possibly a 
head-up-display? I managed to achieve a slight effect of this with the 
trackball camera and a single model, now I believe this is because the 
trackball camera takes into account the fusion distance value. 
How would I achieve this effect using different kinds of manipulators such as 
drive and flight, I have tried modifying the fusion distance manually on key 
press but to no avail.
Could someone please enlighten me as to how to achieve such an effect?

Cheers,
Nathan

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23718#23718





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Nightly Windows builds?

2010-02-05 Thread Paul Martz
Interesting... I ran a nightly build on 5 Feb at 00:05 (5 minutes past 
midnight) CET, and that was Feb 4 16:05 local time. Immediately after 
the build completed, I saw the results posted to the dashboard. Then I 
took the evening off and went to sleep. This morning 15:45 CET (7:45 
local time) they are no longer listed. What's up?


My builds are scheduled to run again on 6 Feb at 00:05, so I'll watch 
for the same behavior.

   -Paul

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Nightly Windows builds?

2010-02-05 Thread Jean-Sébastien Guay

Hi Paul,

Interesting... I ran a nightly build on 5 Feb at 00:05 (5 minutes past 
midnight) CET, and that was Feb 4 16:05 local time. Immediately after 
the build completed, I saw the results posted to the dashboard. Then I 
took the evening off and went to sleep. This morning 15:45 CET (7:45 
local time) they are no longer listed. What's up?


Click the Previous link at the top of the page to see builds from the 
previous day. Your build was at 16:05 local, and then you checked again 
at 7:45 local, so it switched to another day... :-)


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] Lets slowly update extension gl symbols to latest OpenGL specification with each submission.

2010-02-05 Thread Paul Martz

Wojciech Lewandowski wrote:
Lots of older OpenGL extensions are now included in OpenGL specification 
(rel. 3.2). I'd like to propose a small cleaning movement of OSG sources


Hi Wojtek --

I agree that the kind of scrubbing you've proposed would break backwards 
compatibility, as Gordon described. However, OSG definitely needs some 
clean up and fixes in the area of querying for feature support and 
obtaining the appropriate entry points.


I was waiting for Robert to chime in on this thread, but I think I speak 
on his behalf when I say he supports a clean up effort. In the thread 
OpenGL capture/logging in OSG from mid-December, Robert said: I 
would, however, be happy to see a more formalized system for extension 
setup, as the current distributed approach has let the styles of 
implementation diverge as a series of different developers have got 
their hands dirty contributing code.


So now we just need to decide exactly what we mean by clean up. :-)

First, I don't want to limit the discussion by using the word 
extension. We should consider cleaning up code that queries for the 
presence of OpenGL features. They might be extensions, or they might be 
core functionality.


In most any OpenGL literature that you read, querying for feature 
support at run time should be done as follows;


  If the feature is part of the run time GL version's core spec
Use the core interface
  else if an ARB extension supports the feature
Use the ARB interface
  else if an EXT extension supports the feature
Use the EXT interface
  else
Similar checks for possibly multiple vendor extensions

OSG should do this as well, but in most cases it doesn't. Instead, OSG 
simply checks for the availability of entry points and uses them if 
present. This is a dangerous approach, as many drivers contain entry 
points for the purpose of testing beta features. This is one thing I'd 
definitely like to see cleaned up.


(In fact, this is currently a bug in OSG. If I open a v3.0 context, OSG 
uses the v3.2 core FBO entry points exposed by my device driver, not the 
ARB FBO extension interface.)


I'd also like to see a function pointer name clean up effort. Function 
pointers should be named generically (glGenBuffers, not 
glGenBuffersARB or glGenBuffersEXT). In 90% of all features, we're 
just concerned with which feature it references, not which specific 
extension interface is being used. With an initialization system like I 
described in the pseudocode above, or even with OSG as it currently 
stands today, the function pointer could be loaded with just about any 
interface entry point, so it should have a name that isn't 
interface-specific.


Another thing to consider is the wrapper pattern currently employed in 
many of OSG's OpenGL function pointers. The wrapper pattern has the 
following form:


  void glFunctionWRAPPER( ... )
  {
if( _glFunction != NULL )
  _glFunction( ... );
else
  Log an error
  }

Checking on the validity of the pointer every time app code calls into 
the wrapper seems a little heavy. I'd rather see a system that lets 
calling code query for the presence or absence of a feature. If the 
feature is absent, calling code should avoid calling into the feature's 
function wrappers, eliminating the need for per-wrapper checks for 
function pointer validity. (I believe this is a better approach for 
calling code too, as that code will usually want to take one path or 
another based on the presence or absence of certain GL features.)


(Note that I'm not opposed to wrappers in general. An OpenGL wrapper 
system should probably be at the core of every major OpenGL app. It 
simply needs to be designed for lightweight production builds.)


There's the topic of centralization. I've proposed moving all OpenGL 
function pointers an related initialization into a single class. Among 
other reasons, this would make it easier for future developers to ensure 
that they're implementing feature query and initialization consistent 
with OSG's best practice. But Robert has expressed disagreement with 
this approach (again, see the thread OpenGL capture/logging in OSG). 
So for now, any type of new system we implement for feature querying and 
initialization will need to be cut and pasted across several source files.


Finally, another thing to consider is replacing our existing feature 
query infrastructure with something like GLEW. GLEW is lightweight, 
easily extensible, and already handles much of what we need for GL 
feature support. But we have discussed this in the past, and if I 
remember correctly Robert was opposed to GLEW on the grounds of the new 
third party dependency it would require.


Well, I know this is a bit more extensive that the slow, piece-by-piece 
clean up effort that you had in mind with your original post. But I 
wanted to throw this out there for consideration by you and the rest of 
the community.


If we can all come to some consensus on how to proceed, we can start 

Re: [osg-users] Nightly Windows builds?

2010-02-05 Thread Paul Martz

Jean-Sébastien Guay wrote:
Interesting... I ran a nightly build on 5 Feb at 00:05 (5 minutes past 
midnight) CET, and that was Feb 4 16:05 local time. Immediately after 
the build completed, I saw the results posted to the dashboard. Then I 
took the evening off and went to sleep. This morning 15:45 CET (7:45 
local time) they are no longer listed. What's up?


Click the Previous link at the top of the page to see builds from the 
previous day. Your build was at 16:05 local, and then you checked again 
at 7:45 local, so it switched to another day... :-)


Huh! Even though it's the _same_ day in CET...
   -Paul
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Lets slowly update extension gl symbols to latest OpenGL specification with each submission.

2010-02-05 Thread Chris 'Xenon' Hanson
 Good topic, Paul.

On 2/5/2010 9:02 AM, Paul Martz wrote:
 There's the topic of centralization. I've proposed moving all OpenGL
 function pointers an related initialization into a single class. Among
 other reasons, this would make it easier for future developers to ensure
 that they're implementing feature query and initialization consistent
 with OSG's best practice. But Robert has expressed disagreement with
 this approach (again, see the thread OpenGL capture/logging in OSG).
 So for now, any type of new system we implement for feature querying and
 initialization will need to be cut and pasted across several source files.

  I would be in support of _some_ centralization. I feel like maybe we could 
put generic
support code for this system in one place, and somehow call it from wherever it 
was
needed. Could we somehow come up with a template that did the dirty work for 
us, and just
employ the template in a distributed fashion? A basic template could do 
everything most
situation would need, and maybe a more advanced and customizable template with 
some sort
of callback or functor could be employed in situations that needed to go beyond 
the simple
case?

 Finally, another thing to consider is replacing our existing feature
 query infrastructure with something like GLEW. GLEW is lightweight,
 easily extensible, and already handles much of what we need for GL
 feature support. But we have discussed this in the past, and if I
 remember correctly Robert was opposed to GLEW on the grounds of the new
 third party dependency it would require.

  I'm not wholly opposed to GLEW.

  http://glew.sourceforge.net/

  I agree about more dependencies, but I also dislike re-inventing the wheel. I 
know GLEW
is attaining popular support, and the new OpenGL SuperBible uses it extensively 
(funny
joke!). So, it's not something that's a relative unknown.

-- 
Chris 'Xenon' Hanson, omo sanza lettere  Xenon AlphaPixel.com
PixelSense Landsat processing now available! http://www.alphapixel.com/demos/
There is no Truth. There is only Perception. To Perceive is to Exist. - Xen
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Nightly Windows builds?

2010-02-05 Thread Jean-Sébastien Guay

Hi Paul,


Huh! Even though it's the _same_ day in CET...


Yeah, well, it only knows about its own local timezone... Makes sense I 
think.


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] Trying out the directshow plugin - how to build the release version of BaseClasses?

2010-02-05 Thread Raymond de Vries

Hi,

That's very cool, congrats! Btw are the other presentations also made 
with the osg? Like Mur de médias?


cheers
Raymond



Serge Lages wrote:
And you can be sure that this plugin works like a charm, we're using 
it with 4 live streams everyday in a live TV show and we never had any 
problem ! ;)


http://www.tharsis-software.com/1-29972-Realisation.php

On Thu, Feb 4, 2010 at 6:56 PM, Raymond de Vries ree...@xs4all.nl 
mailto:ree...@xs4all.nl wrote:


Hi guys,

I would like to say a big 'thank you' for this nice plugin. After
quite some time installing SDKs and building I got the plugin
working :-)
For the record: I did this on Windows Vista 32 bit, Visual Studio
2008, Microsoft DirectX SDK (August 2009) and Windows SDK v6.0.


Cheers
Raymond



Serge Lages wrote:

I think it's one of the latest :
Microsoft DirectX SDK (August 2009)

On Wed, Feb 3, 2010 at 7:03 PM, Raymond de Vries
ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

   Hi,

   Ok, nice to hear. Which version of directx are you using? My
   directshow build on Vista, using directx August 2007,
resulted in
   a missing symbol...

   Cheers
   Raymond


   Serge Lages wrote:

   I am working on Windows 7 and it works like a charm
with the
   Win7 SDK.

   On Wed, Feb 3, 2010 at 6:49 PM, Raymond de Vries
   ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

  Hi guys,

  First of all, thanks a lot for your quick reply! As it
   turned out,
  I also had a more recent platform sdk on my system
(win vista).
  Out of habit I just installed the older one on each
system I
  develop on... And I had build the baseclasses once (long
   time ago)
  using the makefile...

  Thanks for your advice. I just built the BaseClasses
and now
  building osg svn, including directshow :-) Finders
crossed...

  I will try out the windows 7 sdk on my windows 7 machine
   soon too.

  Jason, ok, I understand it. Indeed I found your
message from a
  while ago. I only saw Cedric's name in the cmake
module, so
   that's
  why I thought you joined efforts. So thanks Cedric!

  One more thing for now: do I have (easy) access to
the 'current
  image' via the plugin?

  I will let you know how it goes...

  Cheers
  Raymond




  Jason Beverage wrote:

  Hi Raymond,

  Just wanted to give credit to Cedric for the osg
DirectShow
  plugin, I
  had sent out an email quite awhile about about
public
   interest
  in an
  open sourced Direct Show plugin but never got
around to
  releasing one.
   Kudos to Cedric for beating me to the punch :)

  Thanks,

  Jason

  On Wed, Feb 3, 2010 at 11:58 AM, Trajce Nikolov
  nikolov.tra...@gmail.com
mailto:nikolov.tra...@gmail.com
   mailto:nikolov.tra...@gmail.com
mailto:nikolov.tra...@gmail.com
   mailto:nikolov.tra...@gmail.com
mailto:nikolov.tra...@gmail.com
   mailto:nikolov.tra...@gmail.com
mailto:nikolov.tra...@gmail.com

  wrote:
the latest windows sdk has the
project files for
   all the
  configuration.
  build against it
  Nick

  http://www.linkedin.com/in/tnick


  On Wed, Feb 3, 2010 at 6:44 PM, Raymond de Vries
  ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:
  Hi, most likely
Cedric and/or Jason (Beverage),

  I would like to try out your directshow
plugin
   in svn,
  and now I am in the
  process of building the BaseClasses of
the 

Re: [osg-users] Trying out the directshow plugin - how to build the release version of BaseClasses?

2010-02-05 Thread Serge Lages
Yes everything you can see on our website is OSG based ! ;)

On Fri, Feb 5, 2010 at 5:39 PM, Raymond de Vries ree...@xs4all.nl wrote:

 Hi,

 That's very cool, congrats! Btw are the other presentations also made with
 the osg? Like Mur de médias?

 cheers
 Raymond



 Serge Lages wrote:

 And you can be sure that this plugin works like a charm, we're using it
 with 4 live streams everyday in a live TV show and we never had any problem
 ! ;)

 http://www.tharsis-software.com/1-29972-Realisation.php

 On Thu, Feb 4, 2010 at 6:56 PM, Raymond de Vries ree...@xs4all.nlmailto:
 ree...@xs4all.nl wrote:

Hi guys,

I would like to say a big 'thank you' for this nice plugin. After
quite some time installing SDKs and building I got the plugin
working :-)
For the record: I did this on Windows Vista 32 bit, Visual Studio
2008, Microsoft DirectX SDK (August 2009) and Windows SDK v6.0.


Cheers
Raymond



Serge Lages wrote:

I think it's one of the latest :
Microsoft DirectX SDK (August 2009)

On Wed, Feb 3, 2010 at 7:03 PM, Raymond de Vries
ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

   Hi,

   Ok, nice to hear. Which version of directx are you using? My
   directshow build on Vista, using directx August 2007,
resulted in
   a missing symbol...

   Cheers
   Raymond


   Serge Lages wrote:

   I am working on Windows 7 and it works like a charm
with the
   Win7 SDK.

   On Wed, Feb 3, 2010 at 6:49 PM, Raymond de Vries
   ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

  Hi guys,

  First of all, thanks a lot for your quick reply! As it
   turned out,
  I also had a more recent platform sdk on my system
(win vista).
  Out of habit I just installed the older one on each
system I
  develop on... And I had build the baseclasses once (long
   time ago)
  using the makefile...

  Thanks for your advice. I just built the BaseClasses
and now
  building osg svn, including directshow :-) Finders
crossed...

  I will try out the windows 7 sdk on my windows 7 machine
   soon too.

  Jason, ok, I understand it. Indeed I found your
message from a
  while ago. I only saw Cedric's name in the cmake
module, so
   that's
  why I thought you joined efforts. So thanks Cedric!

  One more thing for now: do I have (easy) access to
the 'current
  image' via the plugin?

  I will let you know how it goes...

  Cheers
  Raymond




  Jason Beverage wrote:

  Hi Raymond,

  Just wanted to give credit to Cedric for the osg
DirectShow
  plugin, I
  had sent out an email quite awhile about about
public
   interest
  in an
  open sourced Direct Show plugin but never got
around to
  releasing one.
   Kudos to Cedric for beating me to the punch :)

  Thanks,

  Jason

  On Wed, Feb 3, 2010 at 11:58 AM, Trajce Nikolov
  nikolov.tra...@gmail.com
mailto:nikolov.tra...@gmail.com
   mailto:nikolov.tra...@gmail.com
mailto:nikolov.tra...@gmail.com
   mailto:nikolov.tra...@gmail.com
mailto:nikolov.tra...@gmail.com
   mailto:nikolov.tra...@gmail.com
mailto:nikolov.tra...@gmail.com

  wrote:
the latest windows sdk has the
project files for
   all the
  configuration.
  build against it
  Nick

  http://www.linkedin.com/in/tnick


  On Wed, Feb 3, 2010 at 6:44 PM, Raymond de Vries
  ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:
  Hi, most likely
Cedric and/or Jason (Beverage),

  I would like to try out your directshow
plugin
  

Re: [osg-users] Trying out the directshow plugin - how to build the release version of BaseClasses?

2010-02-05 Thread Raymond de Vries

hmm, sweet. Incl multitouch :-)

Btw how do you do streaming with directshow? What do you use as server? 
Do you use a standard streaming protocol, or a custom one?
Btw2 how do I get the current image from the directshow? Do I need to 
get it from the texture, or is it possible to get it 'more low-level'? 
'more low-level is most likely better performing..


thnx for your thoughts
Raymond


Serge Lages wrote:

Yes everything you can see on our website is OSG based ! ;)

On Fri, Feb 5, 2010 at 5:39 PM, Raymond de Vries ree...@xs4all.nl 
mailto:ree...@xs4all.nl wrote:


Hi,

That's very cool, congrats! Btw are the other presentations also
made with the osg? Like Mur de médias?

cheers
Raymond



Serge Lages wrote:

And you can be sure that this plugin works like a charm, we're
using it with 4 live streams everyday in a live TV show and we
never had any problem ! ;)

http://www.tharsis-software.com/1-29972-Realisation.php

On Thu, Feb 4, 2010 at 6:56 PM, Raymond de Vries
ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

   Hi guys,

   I would like to say a big 'thank you' for this nice plugin.
After
   quite some time installing SDKs and building I got the plugin
   working :-)
   For the record: I did this on Windows Vista 32 bit, Visual
Studio
   2008, Microsoft DirectX SDK (August 2009) and Windows SDK v6.0.


   Cheers
   Raymond



   Serge Lages wrote:

   I think it's one of the latest :
   Microsoft DirectX SDK (August 2009)

   On Wed, Feb 3, 2010 at 7:03 PM, Raymond de Vries
   ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

  Hi,

  Ok, nice to hear. Which version of directx are you
using? My
  directshow build on Vista, using directx August 2007,
   resulted in
  a missing symbol...

  Cheers
  Raymond


  Serge Lages wrote:

  I am working on Windows 7 and it works like a charm
   with the
  Win7 SDK.

  On Wed, Feb 3, 2010 at 6:49 PM, Raymond de Vries
  ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
  mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

 Hi guys,

 First of all, thanks a lot for your quick
reply! As it
  turned out,
 I also had a more recent platform sdk on my
system
   (win vista).
 Out of habit I just installed the older one
on each
   system I
 develop on... And I had build the baseclasses
once (long
  time ago)
 using the makefile...

 Thanks for your advice. I just built the
BaseClasses
   and now
 building osg svn, including directshow :-)
Finders
   crossed...

 I will try out the windows 7 sdk on my
windows 7 machine
  soon too.

 Jason, ok, I understand it. Indeed I found your
   message from a
 while ago. I only saw Cedric's name in the cmake
   module, so
  that's
 why I thought you joined efforts. So thanks
Cedric!

 One more thing for now: do I have (easy)
access to
   the 'current
 image' via the plugin?

 I will let you know how it goes...

 Cheers
 Raymond




 Jason Beverage wrote:

 Hi Raymond,

 Just wanted to give credit to Cedric for
the osg
   DirectShow
 plugin, I
 had sent out an email quite awhile about
about
   public
  interest
 in an
 open sourced 

[osg-users] osgKeyboard

2010-02-05 Thread jago jagoc
Hi alls,
i would like to show a keybord 3d  as the text in  osgHud example. I
am working on the osgkeyboard's project:
 ...

osg::Group* getHUDScene() { return _HUDscene.get(); }

void KeyboardModel::CreateHUDKeyboard()
{
_HUDscene = new osg::Group;

osg::Projection* HUDProjectionMatrix = new osg::Projection;

HUDProjectionMatrix-setMatrix(osg::Matrix::ortho2D(0,1280,0,1024));

osg::MatrixTransform* HUDModelViewMatrix = new osg::MatrixTransform;

HUDModelViewMatrix-setMatrix(osg::Matrix::identity());

HUDModelViewMatrix-setReferenceFrame(osg::Transform::ABSOLUTE_RF);

_HUDscene-addChild(HUDProjectionMatrix);

HUDProjectionMatrix-addChild(HUDModelViewMatrix);

HUDModelViewMatrix-addChild(_scene);
\\scene is a osgroup* to the keyboard
}
...
int main(int , char **)
{

   viewer.setSceneData( keyboardModel-getHUDScene() );
return viewer.run();
}

When i run the program  i don't see the keyboard in the scene.
Any helps or pointer will be appreciate.

Best regards,
Jagovic
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Trying out the directshow plugin - how to build the release version of BaseClasses?

2010-02-05 Thread Raymond de Vries

Trajce Nikolov wrote:
 Btw2 how do I get the current image from the directshow? Do I need 
to get it from the texture, or is it possible to get it 'more 
low-level'? 'more low-level is most likely better performing..


I believe if you do texture-getImage() you will get it. Howevere, you 
might need to do some syncing between the DirectShow Image update and 
your image lookup
But I wonder/doubt whether that is quick enough, I would like to process 
the image in realtime, as close to the source as possible. I know I can 
make a directshow filter and insert it into a directshow graph or so. 
But that would result in some dependancies that I don't want/like.


regards
Raymond



-Nick


On Fri, Feb 5, 2010 at 6:56 PM, Raymond de Vries ree...@xs4all.nl 
mailto:ree...@xs4all.nl wrote:


hmm, sweet. Incl multitouch :-)

Btw how do you do streaming with directshow? What do you use as
server? Do you use a standard streaming protocol, or a custom one?
Btw2 how do I get the current image from the directshow? Do I need
to get it from the texture, or is it possible to get it 'more
low-level'? 'more low-level is most likely better performing..

thnx for your thoughts
Raymond


Serge Lages wrote:

Yes everything you can see on our website is OSG based ! ;)

On Fri, Feb 5, 2010 at 5:39 PM, Raymond de Vries
ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

   Hi,

   That's very cool, congrats! Btw are the other presentations
also
   made with the osg? Like Mur de médias?

   cheers
   Raymond



   Serge Lages wrote:

   And you can be sure that this plugin works like a
charm, we're
   using it with 4 live streams everyday in a live TV show
and we
   never had any problem ! ;)

   http://www.tharsis-software.com/1-29972-Realisation.php

   On Thu, Feb 4, 2010 at 6:56 PM, Raymond de Vries
   ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

  Hi guys,

  I would like to say a big 'thank you' for this nice
plugin.
   After
  quite some time installing SDKs and building I got
the plugin
  working :-)
  For the record: I did this on Windows Vista 32 bit,
Visual
   Studio
  2008, Microsoft DirectX SDK (August 2009) and
Windows SDK v6.0.


  Cheers
  Raymond



  Serge Lages wrote:

  I think it's one of the latest :
  Microsoft DirectX SDK (August 2009)

  On Wed, Feb 3, 2010 at 7:03 PM, Raymond de Vries
  ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
  mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl wrote:

 Hi,

 Ok, nice to hear. Which version of directx
are you
   using? My
 directshow build on Vista, using directx
August 2007,
  resulted in
 a missing symbol...

 Cheers
 Raymond


 Serge Lages wrote:

 I am working on Windows 7 and it works
like a charm
  with the
 Win7 SDK.

 On Wed, Feb 3, 2010 at 6:49 PM, Raymond
de Vries
 ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
  mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
 mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
   mailto:ree...@xs4all.nl mailto:ree...@xs4all.nl
  

Re: [osg-users] osgKeyboard

2010-02-05 Thread Trajce Nikolov
post your whole code . someone might help you
-Nick


On Fri, Feb 5, 2010 at 7:09 PM, jago jagoc jago...@gmail.com wrote:

 Hi alls,
 i would like to show a keybord 3d  as the text in  osgHud example. I
 am working on the osgkeyboard's project:
  ...

 osg::Group* getHUDScene() { return _HUDscene.get(); }

 void KeyboardModel::CreateHUDKeyboard()
 {
_HUDscene = new osg::Group;

osg::Projection* HUDProjectionMatrix = new osg::Projection;

HUDProjectionMatrix-setMatrix(osg::Matrix::ortho2D(0,1280,0,1024));

osg::MatrixTransform* HUDModelViewMatrix = new osg::MatrixTransform;

HUDModelViewMatrix-setMatrix(osg::Matrix::identity());

HUDModelViewMatrix-setReferenceFrame(osg::Transform::ABSOLUTE_RF);

_HUDscene-addChild(HUDProjectionMatrix);

HUDProjectionMatrix-addChild(HUDModelViewMatrix);

HUDModelViewMatrix-addChild(_scene);
\\scene is a osgroup* to the keyboard
 }
 ...
 int main(int , char **)
 {
 
   viewer.setSceneData( keyboardModel-getHUDScene() );
return viewer.run();
 }

 When i run the program  i don't see the keyboard in the scene.
 Any helps or pointer will be appreciate.

 Best regards,
 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] osgKeyboard

2010-02-05 Thread jago jagoc
Hi Nick,
this is the whole code :

#include osgViewer/Viewer
#include osgViewer/ViewerEventHandlers
#include osg/io_utils

#include osg/MatrixTransform
#include osg/Geode
#include osg/Group
#include osg/Switch
#include osg/Notify
#include osg/Geometry
#include osg/ShapeDrawable
#include osgText/Text

#include osgDB/Registry
#include osgDB/ReadFile
#include osgDB/WriteFile


class KeyboardModel : public osg::Referenced
{
public:

KeyboardModel() { createKeyboard(); }

osg::Group* getScene() { return _scene.get(); }

osg::Group* getHUDScene() { return _HUDscene.get(); }

void keyChange(int key,int value);

void CreateHUDKeyboard();

protected:

~KeyboardModel() {}

osg::Switch* addKey(osg::Vec3 pos, int key,const std::string
text,float width, float height);
osg::Switch* addKey(int key,osg::Switch* sw);

void createKeyboard();

typedef std::mapint, osg::ref_ptrosg::Switch  KeyModelMap;

osg::ref_ptrosg::Group_scene;
KeyModelMap _keyModelMap;
osg::ref_ptrosgText::Text _inputText;
osg::ref_ptrosg::Group_HUDscene;


};

void KeyboardModel::keyChange(int key,int value)
{
osg::notify(osg::INFO)  key value change, code=std::hex 
key  \t value= value  std::dec   std::endl;

// toggle the keys graphical representation on or off via osg::Swithc
KeyModelMap::iterator itr = _keyModelMap.find(key);
if (itr!=_keyModelMap.end())
{
itr-second-setSingleChildOn(value);
}

if (value)
{
// when a key is pressed add the new data to the text field

if (key0  key256)
{
// just add ascii characters right now...
_inputText-getText().push_back(key);
_inputText-update();
}
else if (key==osgGA::GUIEventAdapter::KEY_Return)
{
_inputText-getText().push_back('\n');
_inputText-update();
}
else if (key==osgGA::GUIEventAdapter::KEY_BackSpace ||
key==osgGA::GUIEventAdapter::KEY_Delete)
{
if (!_inputText-getText().empty())
{
_inputText-getText().pop_back();
_inputText-update();
}
}

}

}

osg::Switch* KeyboardModel::addKey(osg::Vec3 pos, int key,const
std::string text,float width, float height)
{

osg::Geode* geodeUp = new osg::Geode;
{
osgText::Text* textUp = new osgText::Text;
textUp-setFont(fonts/arial.ttf);
textUp-setColor(osg::Vec4(1.0f,1.0f,1.0f,1.0f));
textUp-setCharacterSize(height);
textUp-setPosition(pos);
textUp-setDrawMode(osgText::Text::TEXT/*|osgText::Text::BOUNDINGBOX*/);
textUp-setAlignment(osgText::Text::LEFT_CENTER);
textUp-setAxisAlignment(osgText::Text::XZ_PLANE);
textUp-setText(text);

geodeUp-addDrawable(textUp);
}

osg::Geode* geodeDown = new osg::Geode;
{
osgText::Text* textDown = new osgText::Text;
textDown-setFont(fonts/arial.ttf);
textDown-setColor(osg::Vec4(1.0f,0.0f,1.0f,1.0f));
textDown-setCharacterSize(height);
textDown-setPosition(pos);

textDown-setDrawMode(osgText::Text::TEXT/*||osgText::Text::BOUNDINGBOX*/);
textDown-setAlignment(osgText::Text::LEFT_CENTER);
textDown-setAxisAlignment(osgText::Text::XZ_PLANE);
textDown-setText(text);

geodeDown-addDrawable(textDown);
}

osg::Switch* model = new osg::Switch;
model-addChild(geodeUp,true);
model-addChild(geodeDown,false);

_scene-addChild(model);

_keyModelMap[key] = model;

pos.x() += width;

return model;

}

osg::Switch* KeyboardModel::addKey(int key,osg::Switch* sw)
{
_keyModelMap[key] = sw;
return sw;
}

void KeyboardModel::createKeyboard()
{
_scene = new osg::Group;

osg::Vec3 origin(0.0f,0.0f,0.0f);
osg::Vec3 pos=origin;

addKey(pos,osgGA::GUIEventAdapter::KEY_Control_L,Ctrl,2.0f,0.5f);
addKey(pos,osgGA::GUIEventAdapter::KEY_Super_L,Super,2.0f,0.5f);
addKey(pos,osgGA::GUIEventAdapter::KEY_Alt_L,Alt,2.0f,0.5f);
addKey(pos,osgGA::GUIEventAdapter::KEY_Space,Space,3.0f,1.0f);
addKey(pos,osgGA::GUIEventAdapter::KEY_Mode_switch,Switch,2.0f,0.5f);
addKey(pos,osgGA::GUIEventAdapter::KEY_Super_R,Super,2.0f,0.5f);
addKey(pos,osgGA::GUIEventAdapter::KEY_Menu,Menu,2.0f,0.5f);
addKey(pos,osgGA::GUIEventAdapter::KEY_Control_R,Ctrl,2.0f,0.5f);

osg::Vec3 middle(pos.x()+1.0f,0.0f,0.0f);

pos.x() = 0.0f;
pos.z() += 1.0f;

addKey(pos,osgGA::GUIEventAdapter::KEY_Shift_L,Shift,2.0f,0.5f);
addKey(pos,'\\',\\,1.0f,1.0f);
addKey('Z',addKey(pos,'z',Z,1.0f,1.0f));
addKey('X',addKey(pos,'x',X,1.0f,1.0f));
addKey('C',addKey(pos,'c',C,1.0f,1.0f));
addKey('V',addKey(pos,'v',V,1.0f,1.0f));
addKey('B',addKey(pos,'b',B,1.0f,1.0f));

Re: [osg-users] Lets slowly update extension gl symbols to latest OpenGL specification with each submission.

2010-02-05 Thread Paul Martz

Paul Martz wrote:
(In fact, this is currently a bug in OSG. If I open a v3.0 context, OSG 
uses the v3.2 core FBO entry points exposed by my device driver, not the 
ARB FBO extension interface.)


Open mouth, insert foot: This is not a bug in OSG. As everyone knows, 
FBO was part of v3.0. I was temporarily confused with geometry shaders. 
Sorry!

   -Paul

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] MatrixManipulator implementation

2010-02-05 Thread Miguel Lokida
Hi,

I would like to use a MatrixManipulator  in order to follow a node but without 
any automatic translation of the camera. Automatically only rotation is applied 
to follow the object. 
Of course when the user want to modify the view he can do it and the camera 
lets focus on the node. I think it is a sort of gluLookAt but I have not found 
the feature I want in all the MatrixManipulator implementation 
(NodeTrackerManipulation, trackballManipulator,...)

Is the feature I want is possible with the MatrixManipulator of OSG or should I 
implement my MatrixManipulator ?

Thank you.

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23736#23736





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Lets slowly update extension gl symbols to latest OpenGL specification with each submission.

2010-02-05 Thread Robert Osfield
Hi Paul et. al,

On Fri, Feb 5, 2010 at 4:02 PM, Paul Martz pma...@skew-matrix.com wrote:
 Finally, another thing to consider is replacing our existing feature query
 infrastructure with something like GLEW. GLEW is lightweight, easily
 extensible, and already handles much of what we need for GL feature support.
 But we have discussed this in the past, and if I remember correctly Robert
 was opposed to GLEW on the grounds of the new third party dependency it
 would require.

My opposition to API's like GLEW are:

  1) Don't typically support multiple graphics contexts - a critical
issue under Windows as the
  extension entry points can be different for each graphics context

  2) Centralized management of extensions via external libs doesn't
fit well with the ability to
  extend the OSG in 3rd party NodeKits, where the NodeKits support
extensions that that
  the OSG version didn't support when shipped - these 3rd party
NodeKits would be forced
  to only use the same version of the extension library that the
OSG was linked to.

  3) We need to be able to disable extensions when they don't work.

  4) Extra dependency

For sure we can do better than what we currently do in an adhoc way,
but it absolutely has to do the job better than the likes of GLEW, it
*has* to decentralized, it *has* to support multiple graphics
contexts, it *has* to extensible.  For all the flaws of the current
extension support in the OSG it does at least do all of these and has
proven workable for a decade now.  The attraction of GLEW and similar
libs is pretty skin deep.

Robert.
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] MatrixManipulator implementation

2010-02-05 Thread Jean-Sébastien Guay

Hi Miguel,


Is the feature I want is possible with the MatrixManipulator of OSG or should I 
implement my MatrixManipulator ?


I think you should subclass osgGA::NodeTrackerManipulator or just modify 
it in OSG to add a new TrackerMode to it that would do that. It falls 
within its scope of functionality I think.


Look at the code for NodeTrackerManipulator, you'll see that you just 
need to remove some calculations from getMatrix() and getInverseMatrix() 
to get what you want. So if you want your change to be useful to others, 
you could add a new TrackerMode to it, and if that's the active 
TrackerMode then you do the right thing.


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] Lets slowly update extension gl symbols to latest OpenGL specification with each submission.

2010-02-05 Thread Chris 'Xenon' Hanson
On 2/5/2010 11:16 AM, Robert Osfield wrote:
 For sure we can do better than what we currently do in an adhoc way,
 but it absolutely has to do the job better than the likes of GLEW, it
 *has* to decentralized, it *has* to support multiple graphics
 contexts, it *has* to extensible.  For all the flaws of the current
 extension support in the OSG it does at least do all of these and has
 proven workable for a decade now.  The attraction of GLEW and similar
 libs is pretty skin deep.

  Maybe then, we should start writing down the actual requirements of what we 
need, and
when that looks solid we can figure out how to achieve all of them.

 Robert.

-- 
Chris 'Xenon' Hanson, omo sanza lettere  Xenon AlphaPixel.com
PixelSense Landsat processing now available! http://www.alphapixel.com/demos/
There is no Truth. There is only Perception. To Perceive is to Exist. - Xen
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Lets slowly update extension gl symbols to latest OpenGL specification with each submission.

2010-02-05 Thread Paul Martz
Hi Robert -- Thanks for your comments on this. I'd really appreciate 
feedback on the other items I discussed in my email, before I proceed 
with any submissions, so more input is welcome.


Robert Osfield wrote:

On Fri, Feb 5, 2010 at 4:02 PM, Paul Martz pma...@skew-matrix.com wrote:

Finally, another thing to consider is replacing our existing feature query
infrastructure with something like GLEW. GLEW is lightweight, easily

...

  1) Don't typically support multiple graphics contexts - a critical
issue under Windows as the
  extension entry points can be different for each graphics context


Right, but something like GLEW might support multiple contexts.


  2) Centralized management of extensions via external libs doesn't
fit well with the ability to
  extend the OSG in 3rd party NodeKits, where the NodeKits support
extensions that that
  the OSG version didn't support when shipped - these 3rd party
NodeKits would be forced
  to only use the same version of the extension library that the
OSG was linked to.


This is really not an issue. We discussed something similar to this in 
OpenGL capture/logging in OSG and I'll paraphrase what I said there: 
External node kit developers can cook their own extension access 
solution until the extension is available (in core OSG or OSG's external 
feature support dependency).



  3) We need to be able to disable extensions when they don't work.


(I'd question whether or not this feature even works in OSG today, given 
that OSG doesn't even query the extension string for many of the 
extension features it uses. But...) This is an interesting and possibly 
useful feature, so it should definitely be in any solution that you 
endorse before we start coding a submission.


And finally regarding the dependency issue. It doesn't have to be a 
dependency any more than OpenThreads is a dependency. It could be an 
internal self-contained module. I know, I know, you're opposed to 
centralizing this. :-)

   -Paul


___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] [osgOcean] osgOcean Geometry

2010-02-05 Thread Peter Bear
Hi Kim,
It's good to hear it is possible. I was wondering about that on the grounds 
that it could possibly be used on a planetary level for things such as flight 
simulators myself. On a side note, it could be possible to use the tile method 
to do things such as progressive changes in the clarity of water as well, which 
could be useful for things such as the shift in water clarity from say a 
tropical island to somewhere which is more industrialized and has much dirtier 
water.


Kim Bale wrote:
 Hi Peter, 
 
 This has come up a couple of times actually. It would be feasible I think 
 with the new method of updating the tile positions that I've added to the 
 sandbox. 
 
 
 Whilst I haven't put a lot of thought into it, I'm thinking that 
 the ellipsoid distortion could be added to tiles within the vertex shader, 
 so basically taking the same old tiles and merging it with a tile of offsets 
 that is passed in. Then instead of using a straight translation to position 
 the tiles as is done in the test case, you would then use some sort of slight 
 rotational transform instead. 
 
 
 I must confess it's not a priority at this time, as you can see my progress 
 is very slow at the moment. 
 
 
 Regards,
 
 
 Kim.
 
 
 On 5 February 2010 01:36, Peter Bear  () wrote:
 
   Question, would that change make it possible to make a round earth using 
  osgOcean. I noticed it talking about tiles in that post and it sparked my 
  interest.
  
  Cheers,
  Peter
  
  --
  Read this topic online here:
  
  http://forum.openscenegraph.org/viewtopic.php?p=23706#23706 
  (http://forum.openscenegraph.org/viewtopic.php?p=23706#23706)
  
  
  
  
  
  
  ___
  osg-users mailing list
   ()
  http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org 
  (http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org)
  
  
  
 
 
  --
 Post generated by Mail2Forum


--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23742#23742





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Lets slowly update extension gl symbols to latest OpenGL specification with each submission.

2010-02-05 Thread Paul Martz

Paul Martz wrote:

  1) Don't typically support multiple graphics contexts - a critical
issue under Windows as the
  extension entry points can be different for each graphics context


Right, but something like GLEW might support multiple contexts.


For the record, GLEW does support multiple contexts:
http://www.opengl.org/sdk/libs/GLEW/
   -Paul



___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] osgText::Text Entents

2010-02-05 Thread Chris Innanen
Quick question on osgText...

Once an osgText::Text class is created and loaded with a string, font, and 
size... Is there a way to get the size and shape of the resulting graphics? I 
don't see an obvious accessor for this information, though it would seem that 
it would be missed. I'm guessing *I'M* the one missing it.

Info like: width, max height, max rise above baseline, max drop below baseline, 
font's max rise/drop, etc.

This information is invaluable for doing complex alignments of text.

Thanks,
 ~ Chris Innanen
 ~ Nonsanity

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23747#23747





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] osgText::Text Entents

2010-02-05 Thread Chris Innanen
Ack! Nevermind...

Only AFTER writing that did I bother to look up the inheritance tree at 
TextBase. THAT'S where all that info is available. :)

Must be snow-on-the-brain.

 ~ Chris Innanen
 ~ Nonsanity

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23748#23748





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] [3rdparty] [osgEarth] transparent_color image attribute not working

2010-02-05 Thread Nick Schultz
Hi,

I'm trying to display my own GeoTiffs, which are made up of 16 colors and white 
as the background.   

here is a portion of  my .earth file (had to turn '' into '[' for it to 
display properly): 


Code:
[image name=JF_60_2 driver=gdal]   
[min_level]8[/min_level]
C:\PugetSound\Images\jf2_tiled2.tif
[transparent_color] 255 255 255 0 [/transparent_color] 
[cache_enabled]false[/cache_enabled] 
[/image] 



The image is drapped correctly, however the white background is still present.  
I tried both 255 and 0 for the alpha channel (I'm not sure there is an alpha 
channel in my GeoTiff, is that the problem?) 

I also made sure that the white space is really 255 255 255 and not some 
offwhite. 

Any tips? 

Thanks, 
Nick 


Thank you!

Cheers,
Nick

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23749#23749





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] [3rdparty] osgearth crashes when I load a shape file

2010-02-05 Thread Nick Schultz
Hi glenn,

Also while playing with osgEarth, I got an error saying couldn't find ordinal 
63 in libexpat.dll.  Took me forever to find out what that meant, but it 
actually means that it couldn't find the dll file, whereas I thought it found 
the dll but something else was corrupt.  Not sure if you could make that error 
more discriptive but it could save a good couple hours or so trying to 
troubleshoot!  :P 


Thank you!

Cheers,
Nick

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23750#23750





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Example of geographical position

2010-02-05 Thread Tueller, Shayne R Civ USAF AFMC 519 SMXS/MXDEC
Tony,

Entity is just my own class that can represent an airplane, tank, or
whatever.

The member Entity-transform is an osg::MatrixTransform which you'll need
for moving models. 

entityGrp is an osg::Group*.

-Shayne

-Original Message-
From: osg-users-boun...@lists.openscenegraph.org
[mailto:osg-users-boun...@lists.openscenegraph.org] On Behalf Of Tony Vasile
Sent: Thursday, February 04, 2010 11:25 PM
To: osg-users@lists.openscenegraph.org
Subject: Re: [osg-users] Example of geographical position

Shayne,
   What is the type of Entity and entityGrp in the following code snippet?

Along with Robert's suggestion, you can use the following code snippet to
place a vehicle on a spheroid that has VPB terrain, into the scenegraph.
You'll need osgSim and osg::EllipsoidModel to do this.

Entity-lat = 36.4;
Entity-lon = -115.015;
Entity-alt = GetHeightOnTerrain(Entity-
lat, Entity-lon);
entityGrp-addChild(Entity-transform);

double GetHeightOnTerrain(double lat, double lon) {
   double X,Y,Z;
   double maxElevation = 13000 / 3.281;
   earth-convertLatLongHeightToXYZ(osg::DegreesToRadians(lat),
osg::DegreesToRadians(lon),maxElevation, X,Y,Z);
   double hat =
osgSim::HeightAboveTerrain::computeHeightAboveTerrain(terrain.get(),
osg::Vec3(X,Y,Z), -1);
   return (maxElevation - hat);
}

The earth is an osg::EllipsoidModel object and the terrain is a node
loaded in from the ive file build by VPB. The entity group node is simply
added to your scenegraph and you're ready to go.

Hopefully this will get you started...:)

-Shayne



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] [3rdparty] [osgEarth] transparent_color image attribute not working

2010-02-05 Thread Jason Beverage
Hey again Nick,

See my answer on the osgEarth mailing list.  Remove the quotes from
your transparent_color element and you should be good to go.

Jason

On Fri, Feb 5, 2010 at 6:27 PM, Nick Schultz schul...@engr.orst.edu wrote:
 Hi,

 I'm trying to display my own GeoTiffs, which are made up of 16 colors and 
 white as the background.

 here is a portion of  my .earth file (had to turn '' into '[' for it to 
 display properly):


 Code:
 [image name=JF_60_2 driver=gdal]
                [min_level]8[/min_level]
                C:\PugetSound\Images\jf2_tiled2.tif
                [transparent_color] 255 255 255 0 [/transparent_color]
                [cache_enabled]false[/cache_enabled]
    [/image]



 The image is drapped correctly, however the white background is still 
 present.  I tried both 255 and 0 for the alpha channel (I'm not sure there is 
 an alpha channel in my GeoTiff, is that the problem?)

 I also made sure that the white space is really 255 255 255 and not some 
 offwhite.

 Any tips?

 Thanks,
 Nick


 Thank you!

 Cheers,
 Nick

 --
 Read this topic online here:
 http://forum.openscenegraph.org/viewtopic.php?p=23749#23749





 ___
 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] dynamic_cast of referenced objects

2010-02-05 Thread Kevin Wilder
Hi,

My project is throwing an occasional unhandled win32 exception error and I've 
been trying to figure out why. There is no consistency in the timing so I 
assume that I have a dangling pointer somewhere. (I don't have a memory leak 
because the memory usage shown in the Windows Task Manager is fairly constant 
while my code is running.) 

I came upon a passage in the OpenSceneGraph Quick Start Guide that says:

Be careful when returning the address of an object from a function. If you do 
this incorrectly, the ref_ptr storing the memory address could go out of 
scope before the address is placed on the return stack.

I assume that this also applies when passing referenced objects to a 
function... But most of the examples of callback functions that I have seen on 
the web all use standard C++ pointers in the function definition, rather than 
ref_ptr. For example:

--- snip ---

void operator()( osg::Node* node, osg::NodeVisitor * nv )
{
  osg::MatrixTransform * MatrixXform = 
dynamic_castosg::MatrixTransform*(node) ;

if ( MatrixXform )

--- snip ---

Thinking that this may be the source of my dangling pointer, I tried to modify 
my own callback function definition to use referenced object pointers per the 
quick start guide's recommendations. Unfortunately, I got hung up on the 
dynamic_cast in the code above. I can't figure out how to cast the osg::node 
referenced object pointer into an osg::MatrixTransform referenced object 
pointer.

Is there an equivalant means of casting an osg::ref_ptrosg::node into an 
osg::ref_ptrosg::MatrixTransform when using referenced object pointers? I'm 
trying to do something like:

--- snip ---

void operator()( osg::ref_ptrosg::Node node, osg::ref_ptrosg::NodeVisitor 
nv )
{
  osg::ref_ptrosg::MatrixTransform MatrixXform = 
dynamic_castosg::ref_ptrosg::MatrixTransform(node) ;

if ( MatrixXform )

--- snip ---


Thanks for the help. I'm relatively new to OpenSceneGraph programming.

Cheers,

Kevin

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23753#23753





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] dynamic_cast of referenced objects

2010-02-05 Thread Jean-Sébastien Guay

Hi Kevin,

My project is throwing an occasional unhandled win32 exception error and I've been trying to figure out why. There is no consistency in the timing so I assume that I have a dangling pointer somewhere. 


I doubt you're on the right track with changing standard pointers to 
ref_ptrs in function arguments, but when unsure it's better to use 
ref_ptrs everywhere.


The right way to debug your error would be to compile a debug version 
and run your code in a debugger. Then the debugger would likely tell you 
exactly which pointer was left dangling, you'd have a stack trace, and 
it would be relatively easy to track down the cause. Just sprinkling 
ref_ptrs everywhere in the hope that it'll fix it is not a solution, IMHO.


But to answer your more concrete question:


Is there an equivalant means of casting an osg::ref_ptrosg::node into an 
osg::ref_ptrosg::MatrixTransform when using referenced object pointers? I'm trying 
to do something like:

--- snip ---

void operator()( osg::ref_ptrosg::Node node, osg::ref_ptrosg::NodeVisitor 
nv )
{
  osg::ref_ptrosg::MatrixTransform MatrixXform = 
dynamic_castosg::ref_ptrosg::MatrixTransform(node) ;

if ( MatrixXform )

--- snip ---


osg::ref_ptrosg::MatrixTransform MatrixXform =
dynamic_castosg::MatrixTransform*(node.get());

A ref_ptr is an object on the stack (not a pointer) that tracks a 
pointer. And ref_ptr::get() returns a raw pointer to the underlying 
object. So you can construct (or here, assign to) a ref_ptr from a raw 
pointer.


So from right to left:
1. You extract the raw Node* pointer from a ref_ptrNode
2. You dynamic_cast that to a MatrixTransform*
3. You assign that to a ref_ptrMatrixTransform
4. Bob is your uncle.

Note that in the process, the ref count of node will be incremented if 
it was really a MatrixTransform (i.e. if the assignment assigned 
something other than NULL), so your function will have 2 refs (one in 
the temporary ref_ptrNode, and one in the ref_ptrMatrixTransform). 
This is unnecessary, as the temporary ref_ptrNode in the function 
arguments guarantees that the object will not be deleted in the scope of 
the function. So you could do this instead:


osg::MatrixTransform* MatrixXform =
dynamic_castosg::MatrixTransform*(node.get());

As I said, storing it in a raw pointer is safe at that point because of 
the temporary ref_ptrNode in the function arguments which will be 
destroyed when the function ends.


So you see, ref_ptrs require a bit of work wrapping your mind around 
them, but it's not magic and it all works really well.


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] [3rdparty] osgearth crashes when I load a shape file

2010-02-05 Thread Glenn Waldron
That's probably a generic Windows error, and not something I could fix. In
any case the plan is to get rid of the expat dependency anyway and embed
something like tinyxml instead, making the problem moot.


Glenn Waldron : Pelican Mapping : +1.703.652.4791


On Fri, Feb 5, 2010 at 6:30 PM, Nick Schultz schul...@engr.orst.edu wrote:

 Hi glenn,

 Also while playing with osgEarth, I got an error saying couldn't find
 ordinal 63 in libexpat.dll.  Took me forever to find out what that meant,
 but it actually means that it couldn't find the dll file, whereas I thought
 it found the dll but something else was corrupt.  Not sure if you could make
 that error more discriptive but it could save a good couple hours or so
 trying to troubleshoot!  :P


 Thank you!

 Cheers,
 Nick

 --
 Read this topic online here:
 http://forum.openscenegraph.org/viewtopic.php?p=23750#23750





 ___
 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] Displaying elevation values while navigating terrain elevation files

2010-02-05 Thread Phanindra Talabathula
Hi,

Could someone give me pointers on how to display the latitude, longitude and 
elevation values as the user tries to navigate a terrain elevation file (flying 
thro' the elevation file is possible by using osgviewer after creating a db 
file using osgdem)

This facility would be something similar to what VTP does in Enviro.

Regards,
Phanindra

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=23757#23757





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org