[osg-users] CEGUI

2007-07-03 Thread [EMAIL PROTECTED]
Hi,
 I tried to run the osgcegui example, and no GUI was rendered.

All the GUI creation code was taken from CEGUI example (which works).
I didn't get any errors from CEGUI or OSG.

I also tried to set the renderGUI function as post callback of the camera with 
no better results.

any ideas?

is it something with the Zbuffer? or Z position of the GUI?

thanks,
 Guy.
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Re: [osg-users] Slightly OT: coordinate system use for globe sized app.

2007-07-03 Thread Robert Osfield

Hi Chris,

On 7/3/07, Dorosky, Christopher G [EMAIL PROTECTED] wrote:

I need to pick a new coordinate system to expand my app to a single world
database, kinda like google earth.

I was thinking of using ECEF as my internal coordinate system.
Anybody have any hints / suggestions as to something better?


When you build an osgdem database with the --geocentric option it
builds the database in Earth Center Earth Fixed (ECEF) coordinate
system.  With a geocentric database the problems you have to deal with
are precision and which way is up (for simulator aspect).

To solve the precision issue use a MatrixTransform above each tile
that places the tile from its local origin (0,0,0 at the center of the
tile) to its final position in geocentric space.

To know which way is up decorate the database with a
osg::CoordinateSystemNode and attach an EllipsoidModel to it describe
the shape of the earth.  Manipulators like Drive, Flight and
TerrainManipulators all use the CoordinateSystemNode to know which way
is up and behave accoridingly.

Robert.
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] Override manipulator keyboard/mouse events functionality

2007-07-03 Thread Robert Osfield

Hi Nelson,

On 7/3/07, Cysneros, Nelson SPAWAR [EMAIL PROTECTED] wrote:

by replacing this line:


// set the view
sceneView-setViewMatrix(kbmcb-getViewMatrix());

With my own calculated matrix based on the kbmcb values.



You can still do this with osgViewer::Viewer :


 osgViewer::Viewer viewer;

 viewer.setSceneData(osgDB::readNodeFile(cow.osg));

 viewer.realize();

 while(!viewer.done())
 {

viewer.getCamera()-setViewMatrix(myViewMatrix);

 viewer.frame();

 }


Note, no Camera Manipulator is registered, so nobody is setting the
view matrix other than your setViewMatrix call.



I'm also confused about the billboard examples ( and other examples simular
to it).  Looks like they never added anytype of Manipulator to the camera.
and I'm wondering how the camera manipulation is being done?  Is their a
default manipulator that comes with the osgViewer::Viewer?


viewer.run() used my main of the examples is great short hand for
writing a quick example, but it does hide a bit of what's going under
the hood, run is effectively (psudo code here)

viewer.run() is equivilant to :


  viewer.realize();

  if (viewer doesn't have a camera manipulator)
  {
   viewer.addCameraManipulator(new TrackballBall)
  }

  while(!viewer.done())
  {
 viewer.frame();
  }


Robert.
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] CEGUI

2007-07-03 Thread Robert Osfield

Hi Guy,

The osgcegui example was my abortive attempt at getting CEGUI to work
in a well that integrates well with the OSG.  I say abortive because
CEGUI really is a bit brain dead when it comes to managing multiple
graphics contexts and multi-threading, its can't do it at all and
doesn't look like it'll ever do it without a major rewrite.

Some OSG users have got CEGUI to work with the OSG, and there are some
suggestions in the osg-users archives about this.

Personally I was unimpressed with CEGUI, its just not well designed or
implemented library, its makes too many assumptions and restrictions
on its usage to make it particularly useful beyond single window,
single threaded games.  I certainly wouldn't recommend it.

Robert.

On 7/3/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:



Hi,
 I tried to run the osgcegui example, and no GUI was rendered.

All the GUI creation code was taken from CEGUI example (which works).
I didn't get any errors from CEGUI or OSG.

I also tried to set the renderGUI function as post callback of the camera
with no better results.

any ideas?

is it something with the Zbuffer? or Z position of the GUI?

thanks,
 Guy.
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] osg-2.0 and multigen openflight 16.0 shader example world

2007-07-03 Thread Brede Johansen

Hi,

If you refer to the Creator gallery world model I believe it only
works with cg shaders.  The osgviewer doesn't support cg shaders out
of the box.  The glsl version of the bumbmap shaders in the gallery
doesn't use the tangent and binormal information so it only works for
geometry in the xy plane.

Regards,
Brede

On 7/3/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:

Which options must be choosen in osgviewer to see the expected result of a bump 
mapped world (openflight 16.0)?

Jetzt Handykosten senken mit klarmobil - 14 Ct./Min.! Hier klicken
http://produkte.shopping.freenet.de/handy_voip_isdn/klarmobil/index.html?pid=730025

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


[osg-users] is it possible to add new texture layers in run time to an osga ???

2007-07-03 Thread David _

Hi

i´ve got an osgdem generated pagelod island and i would like to add texture 
layers to it in order to show streets, different locations, etc...


i know how to generate the osga with different texture layers but i need to 
do add this layers in run-time, is it possible??


maybe there might be problems because the island is a pagelod object which 
is which is essentially a lot of smaller objects with smaller textures and 
the new texture layer is just one file


help here would be very aprreciated

sorry for my english

_
Acepta el reto MSN Premium: Correos más divertidos con fotos y textos 
increíbles en MSN Premium. Descárgalo y pruébalo 2 meses gratis. 
http://join.msn.com?XAPID=1697DI=1055HL=Footer_mailsenviados_correosmasdivertidos


___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] is it possible to add new texture layers in run time to an osga ???

2007-07-03 Thread Robert Osfield

Hi David,

osgdem has the --layer option which allows you to specify multiple
textures and have these built directly into the paged databases.

Alternatively you could use a TexGenNode to generate tex coords for
you and then decorate the scene with the overlay textures.

Another alternative would be to render the roads etc. into a texture
and then apply this on to the scene use the osgSim::OverlayNode.

Robert.

On 7/3/07, David _ [EMAIL PROTECTED] wrote:

Hi

i´ve got an osgdem generated pagelod island and i would like to add texture
layers to it in order to show streets, different locations, etc...

i know how to generate the osga with different texture layers but i need to
do add this layers in run-time, is it possible??

maybe there might be problems because the island is a pagelod object which
is which is essentially a lot of smaller objects with smaller textures and
the new texture layer is just one file

help here would be very aprreciated

sorry for my english

_
Acepta el reto MSN Premium: Correos más divertidos con fotos y textos
increíbles en MSN Premium. Descárgalo y pruébalo 2 meses gratis.
http://join.msn.com?XAPID=1697DI=1055HL=Footer_mailsenviados_correosmasdivertidos

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] CEGUI

2007-07-03 Thread Emmanuel Roche

By the way, sure CEGUI is not recommendable but is there another good
possibility you would recommend to build GUIs in OSG ?

Manu.


2007/7/3, Robert Osfield [EMAIL PROTECTED]:


Hi Guy,

The osgcegui example was my abortive attempt at getting CEGUI to work
in a well that integrates well with the OSG.  I say abortive because
CEGUI really is a bit brain dead when it comes to managing multiple
graphics contexts and multi-threading, its can't do it at all and
doesn't look like it'll ever do it without a major rewrite.

Some OSG users have got CEGUI to work with the OSG, and there are some
suggestions in the osg-users archives about this.

Personally I was unimpressed with CEGUI, its just not well designed or
implemented library, its makes too many assumptions and restrictions
on its usage to make it particularly useful beyond single window,
single threaded games.  I certainly wouldn't recommend it.

Robert.

On 7/3/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:


 Hi,
  I tried to run the osgcegui example, and no GUI was rendered.

 All the GUI creation code was taken from CEGUI example (which works).
 I didn't get any errors from CEGUI or OSG.

 I also tried to set the renderGUI function as post callback of the
camera
 with no better results.

 any ideas?

 is it something with the Zbuffer? or Z position of the GUI?

 thanks,
  Guy.
 ___
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

[osg-users] OSG books

2007-07-03 Thread Paul Martz
Hi OSGers --
 
On an experimental basis, I'm going to try direct sales of OSG documentation
from my Web site: www.skew-matrix.com. Select Books from the menu on the
left.
 
When you order an OSG book in hardcopy, I'll give you access to the PDF for
free. This isn't such a big deal for the Quick Start Guide, but should be a
great deal for the reference Manual.
 
Because this is an experiment, to keep the Web programming simple, I can't
accept orders from outside the US, or from Alaska, Hawaii, or Colorado. If
your delivery address is in one of those regions, you should order from
Lulu.com.
 
For more info about OSG books, go to www.osgbooks.com.
 
Also, just a reminder about OSG training to be held in Huntsville, Alabama
this September. Register now to receive the discounted price. Tuition goes
up for registration after July 9. To register, visit www.skew-matrix.com and
select Training from the menu on the left.
 
Thanks,
 
Paul Martz
Skew Matrix Software LLC
http://www.skew-matrix.com http://www.skew-matrix.com/ 
303 859 9466
 
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Re: [osg-users] ViewerEventHandlers problem with custom GUIEventHandlers

2007-07-03 Thread Panagiotis Papadakos
Well I modified the osgkeyboard example, and added a StatHandler so that main 
now is:

int main(int , char **)
{
osgViewer::Viewer viewer;

osg::ref_ptrKeyboardModel keyboardModel = new KeyboardModel;

viewer.addEventHandler(new KeyboardEventHandler(keyboardModel.get()));
viewer.addEventHandler(new osgViewer::StatsHandler);
viewer.setSceneData( keyboardModel-getScene() );

return viewer.run();
}

But still pressing s, presses the s key in the virtual keyboard and also shows 
stats.

I didn't have this problem with osgProducer::Viewer but appeared when I ported 
to osgViewer::Viewer.

On Monday 02 July 2007 21:48, Jeremy L. Moles wrote:
 On Mon, 2007-07-02 at 21:32 +0300, Panagiotis Papadakos wrote:
  Hi Jeremy and thanks for your quick response.
 
  I think you have a point there. But even if I inverse my handler, things
  again do not work. I also tried setting setHandled to true but again
  nothing!

 I looked at the code and StatsHandler works on KEYDOWN; so, just make
 sure your event handler is front of the StatsHandler when  you add it to
 the viewer (either by hand or by calling push_front()) and return true
 on that event and you should be okay. Alternatively, you can call:

   statsHandler-setKeyEventTogglesOnScreenStats()

 ...to change it from S to something else.

  On Monday 02 July 2007 21:04, Jeremy L. Moles wrote:
   On Mon, 2007-07-02 at 20:55 +0300, Panagiotis Papadakos wrote:
Hello everybody!
   
I have an OSGKeyboardEventHandler : public osgGA::GUIEventHandler
keyboard handler, whose handle method returns true when for example
's' is pressed. My problem is  that because I have also added the
osgViewer::StatsHandler to my viewer i also see the stats printed on
my screen! Am I doing something wrong? Thank you.
  
   I would guess that one does key press (perhaps yours), and the other
   release (perhaps StatsHandler). I haven't checked the source to
   confirm, but I bet this is what is happening...
  
   ___
   osg-users mailing list
   osg-users@openscenegraph.net
   http://openscenegraph.net/mailman/listinfo/osg-users
   http://www.openscenegraph.org/

-- 
Papadakos Panagiotis
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] ViewerEventHandlers problem with custom GUIEventHandlers

2007-07-03 Thread Robert Osfield

Hi Panagiotis,

The behavior difference you are seeing is down to the osgViewer using
the Chain of Responsibility Design Pattern for passing on events, the
just of it is that viewer passes events to all event handlers
regardless of whether the event has been handled or not.  The approach
pushes the responsibility for checking to see if the event has been
handled on to the event handlers themselves.  They can check this via
the GUIEventAdapter::getHandled() method.  If an event handler returns
true then the Handled bool is automatically set to true.

The problem that you have observed arises when an event handler has
been updated to filter out already handled events, some of the osgGA
event handles like the camera manipulators had been updated, but not
all - the osgGA::StatsManipulator and osgViewer::ViewerEventHandlers
hadn't been updated for 2.0.  I have just gone through these event
handlers and added in the appropriate code  - mostly checks like:

 if (ea.getHandled()) return false;

Added to the *::handle(..)  methods.

With this change your code example:

int main(int , char **)
{
  osgViewer::Viewer viewer;

  osg::ref_ptrKeyboardModel keyboardModel = new KeyboardModel;

  viewer.addEventHandler(new KeyboardEventHandler(keyboardModel.get()));
  viewer.addEventHandler(new osgViewer::StatsHandler);
  viewer.setSceneData( keyboardModel-getScene() );

  return viewer.run();
}

Will result in the StasHandler getting events but discarding them as
they have already been handled by the KeyboardEventHandler.  If
however, you change the order, then the stats will work and the
keyboard handler will work as the later doesn't check for
getHandled().  In this instance this is what you want, and the new
Chain of Responsibility approach is working as intended giving you the
flexibility to control how events are handled.

Robert.

On 7/3/07, Panagiotis Papadakos [EMAIL PROTECTED] wrote:

Well I modified the osgkeyboard example, and added a StatHandler so that main
now is:

int main(int , char **)
{
osgViewer::Viewer viewer;

osg::ref_ptrKeyboardModel keyboardModel = new KeyboardModel;

viewer.addEventHandler(new KeyboardEventHandler(keyboardModel.get()));
viewer.addEventHandler(new osgViewer::StatsHandler);
viewer.setSceneData( keyboardModel-getScene() );

return viewer.run();
}

But still pressing s, presses the s key in the virtual keyboard and also shows
stats.

I didn't have this problem with osgProducer::Viewer but appeared when I ported
to osgViewer::Viewer.

On Monday 02 July 2007 21:48, Jeremy L. Moles wrote:
 On Mon, 2007-07-02 at 21:32 +0300, Panagiotis Papadakos wrote:
  Hi Jeremy and thanks for your quick response.
 
  I think you have a point there. But even if I inverse my handler, things
  again do not work. I also tried setting setHandled to true but again
  nothing!

 I looked at the code and StatsHandler works on KEYDOWN; so, just make
 sure your event handler is front of the StatsHandler when  you add it to
 the viewer (either by hand or by calling push_front()) and return true
 on that event and you should be okay. Alternatively, you can call:

   statsHandler-setKeyEventTogglesOnScreenStats()

 ...to change it from S to something else.

  On Monday 02 July 2007 21:04, Jeremy L. Moles wrote:
   On Mon, 2007-07-02 at 20:55 +0300, Panagiotis Papadakos wrote:
Hello everybody!
   
I have an OSGKeyboardEventHandler : public osgGA::GUIEventHandler
keyboard handler, whose handle method returns true when for example
's' is pressed. My problem is  that because I have also added the
osgViewer::StatsHandler to my viewer i also see the stats printed on
my screen! Am I doing something wrong? Thank you.
  
   I would guess that one does key press (perhaps yours), and the other
   release (perhaps StatsHandler). I haven't checked the source to
   confirm, but I bet this is what is happening...
  
   ___
   osg-users mailing list
   osg-users@openscenegraph.net
   http://openscenegraph.net/mailman/listinfo/osg-users
   http://www.openscenegraph.org/

--
Papadakos Panagiotis
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


[osg-users] Making Node::dirtyBound() virtual

2007-07-03 Thread Paul Martz
Hi Robert -- Would you object strongly to making dirtyBound() a virtual
function?
 
In my custom node, I need to catch when the bounding box changes and make
some modifications to the scene graph as a result.
 
Currently, I'm overriding computeBounds() to do this. But because
computeBounds() is const, I have to cast away const in order to perform
non-const operations like modifying scene graph data. It turns out this
doesn't work anyway, because thread collisions occur in multithread
situations.
 
Dirtying the bounding box seems to be an inherently non-const operation. Yet
there doesn't appear to be a way for code to act on that change in a
non-const way. Changing the declaration of dirtyBound() to virtual would
allow custom Nodes to take non-const action on the bounding box change.
 
Paul Martz
Skew Matrix Software LLC
http://www.skew-matrix.com http://www.skew-matrix.com/ 
303 859 9466
 
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Re: [osg-users] Making Node::dirtyBound() virtual

2007-07-03 Thread Robert Osfield

Hi Paul,

dirtyBound() is something that can be called multiple times, but will
only set a flag so is quite cheap.  The computeBounds() will just be
called on demand and therefore should only be called once per frame.
computeBounds() is the place where I would stick my changes, its
virtual for a good reason.

Robert.

On 7/3/07, Paul Martz [EMAIL PROTECTED] wrote:



Hi Robert -- Would you object strongly to making dirtyBound() a virtual
function?

In my custom node, I need to catch when the bounding box changes and make
some modifications to the scene graph as a result.

Currently, I'm overriding computeBounds() to do this. But because
computeBounds() is const, I have to cast away const in order to perform
non-const operations like modifying scene graph data. It turns out this
doesn't work anyway, because thread collisions occur in multithread
situations.

Dirtying the bounding box seems to be an inherently non-const operation. Yet
there doesn't appear to be a way for code to act on that change in a
non-const way. Changing the declaration of dirtyBound() to virtual would
allow custom Nodes to take non-const action on the bounding box change.

Paul Martz
Skew Matrix Software LLC
http://www.skew-matrix.com
303 859 9466

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] ViewerEventHandlers problem with custom GUIEventHandlers

2007-07-03 Thread Panagiotis Papadakos
Thank you Robert! Now everything is Ok!
On Tuesday 03 July 2007 16:18, Robert Osfield wrote:
 Hi Panagiotis,

 The behavior difference you are seeing is down to the osgViewer using
 the Chain of Responsibility Design Pattern for passing on events, the
 just of it is that viewer passes events to all event handlers
 regardless of whether the event has been handled or not.  The approach
 pushes the responsibility for checking to see if the event has been
 handled on to the event handlers themselves.  They can check this via
 the GUIEventAdapter::getHandled() method.  If an event handler returns
 true then the Handled bool is automatically set to true.

 The problem that you have observed arises when an event handler has
 been updated to filter out already handled events, some of the osgGA
 event handles like the camera manipulators had been updated, but not
 all - the osgGA::StatsManipulator and osgViewer::ViewerEventHandlers
 hadn't been updated for 2.0.  I have just gone through these event
 handlers and added in the appropriate code  - mostly checks like:

   if (ea.getHandled()) return false;

 Added to the *::handle(..)  methods.

 With this change your code example:

 int main(int , char **)
 {
osgViewer::Viewer viewer;

osg::ref_ptrKeyboardModel keyboardModel = new KeyboardModel;

viewer.addEventHandler(new KeyboardEventHandler(keyboardModel.get()));
viewer.addEventHandler(new osgViewer::StatsHandler);
viewer.setSceneData( keyboardModel-getScene() );

return viewer.run();
 }

 Will result in the StasHandler getting events but discarding them as
 they have already been handled by the KeyboardEventHandler.  If
 however, you change the order, then the stats will work and the
 keyboard handler will work as the later doesn't check for
 getHandled().  In this instance this is what you want, and the new
 Chain of Responsibility approach is working as intended giving you the
 flexibility to control how events are handled.

 Robert.

 On 7/3/07, Panagiotis Papadakos [EMAIL PROTECTED] wrote:
  Well I modified the osgkeyboard example, and added a StatHandler so that
  main now is:
 
  int main(int , char **)
  {
  osgViewer::Viewer viewer;
 
  osg::ref_ptrKeyboardModel keyboardModel = new KeyboardModel;
 
  viewer.addEventHandler(new
  KeyboardEventHandler(keyboardModel.get())); viewer.addEventHandler(new
  osgViewer::StatsHandler);
  viewer.setSceneData( keyboardModel-getScene() );
 
  return viewer.run();
  }
 
  But still pressing s, presses the s key in the virtual keyboard and also
  shows stats.
 
  I didn't have this problem with osgProducer::Viewer but appeared when I
  ported to osgViewer::Viewer.
 
  On Monday 02 July 2007 21:48, Jeremy L. Moles wrote:
   On Mon, 2007-07-02 at 21:32 +0300, Panagiotis Papadakos wrote:
Hi Jeremy and thanks for your quick response.
   
I think you have a point there. But even if I inverse my handler,
things again do not work. I also tried setting setHandled to true but
again nothing!
  
   I looked at the code and StatsHandler works on KEYDOWN; so, just make
   sure your event handler is front of the StatsHandler when  you add it
   to the viewer (either by hand or by calling push_front()) and return
   true on that event and you should be okay. Alternatively, you can call:
  
 statsHandler-setKeyEventTogglesOnScreenStats()
  
   ...to change it from S to something else.
  
On Monday 02 July 2007 21:04, Jeremy L. Moles wrote:
 On Mon, 2007-07-02 at 20:55 +0300, Panagiotis Papadakos wrote:
  Hello everybody!
 
  I have an OSGKeyboardEventHandler : public osgGA::GUIEventHandler
  keyboard handler, whose handle method returns true when for
  example 's' is pressed. My problem is  that because I have also
  added the osgViewer::StatsHandler to my viewer i also see the
  stats printed on my screen! Am I doing something wrong? Thank
  you.

 I would guess that one does key press (perhaps yours), and the
 other release (perhaps StatsHandler). I haven't checked the source
 to confirm, but I bet this is what is happening...

 ___
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/
 
  --
  Papadakos Panagiotis
  ___
  osg-users mailing list
  osg-users@openscenegraph.net
  http://openscenegraph.net/mailman/listinfo/osg-users
  http://www.openscenegraph.org/

 ___
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/

-- 
Papadakos Panagiotis
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] ViewerEventHandlers problem with custom GUIEventHandlers

2007-07-03 Thread Panagiotis Papadakos
One more question though.
Why we use KEYUP in ViewerEventHandlers.cpp and KEYDOWN in all other handlers?
Why not be consistent?
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


RE: [osg-users] Making Node::dirtyBound() virtual

2007-07-03 Thread Paul Martz
 dirtyBound() is something that can be called multiple times, 
 but will only set a flag so is quite cheap.

I see what you mean when you say dirtyBound() could be called multiple times
per frame, so my idea of overriding it wouldn't produce a very efficient
solution.

 The 
 computeBounds() will just be called on demand and therefore 
 should only be called once per frame.
 computeBounds() is the place where I would stick my changes, 
 its virtual for a good reason.

Okay, but because computeBounds() is const, I have to cast away const in
order to perform operations on the scene graph within this function.
Furthermore, when I do this, I see crashes in multidisplay environments,
probably due to a thread collision caused by modifying the scene graph in
one thread while another accesses the same part of the scene graph.

Taking a look at CullVisitor, it's not clear to me how you ensure that
computeBounds() is only called once per frame in multidisplay environments
(where multiple cull traversals would be running concurrently). Can you
explain how this is handled?
   -Paul

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] CEGUI

2007-07-03 Thread Jeremy L. Moles
On Tue, 2007-07-03 at 12:43 +0200, Emmanuel Roche wrote:
 By the way, sure CEGUI is not recommendable but is there another good
 possibility you would recommend to build GUIs in OSG ?

I'm working on one myself. :) Just need time... time... who ever has
enough? At any rate, if you don't use CEGUI there really isn't much
else. Hopefully I can have the osgHUD NodeKit working in the coming
months.

 Manu.
 
 
 2007/7/3, Robert Osfield [EMAIL PROTECTED]:
 Hi Guy,
 
 The osgcegui example was my abortive attempt at getting CEGUI
 to work 
 in a well that integrates well with the OSG.  I say abortive
 because
 CEGUI really is a bit brain dead when it comes to managing
 multiple
 graphics contexts and multi-threading, its can't do it at all
 and
 doesn't look like it'll ever do it without a major rewrite. 
 
 Some OSG users have got CEGUI to work with the OSG, and there
 are some
 suggestions in the osg-users archives about this.
 
 Personally I was unimpressed with CEGUI, its just not well
 designed or
 implemented library, its makes too many assumptions and
 restrictions 
 on its usage to make it particularly useful beyond single
 window,
 single threaded games.  I certainly wouldn't recommend it.
 
 Robert.
 
 On 7/3/07, [EMAIL PROTECTED]  [EMAIL PROTECTED] wrote:
 
 
  Hi,
   I tried to run the osgcegui example, and no GUI was
 rendered.
 
  All the GUI creation code was taken from CEGUI example
 (which works). 
  I didn't get any errors from CEGUI or OSG.
 
  I also tried to set the renderGUI function as post callback
 of the camera
  with no better results.
 
  any ideas?
 
  is it something with the Zbuffer? or Z position of the GUI? 
 
  thanks,
   Guy.
  ___
  osg-users mailing list
  osg-users@openscenegraph.net
  http://openscenegraph.net/mailman/listinfo/osg-users
  http://www.openscenegraph.org/
 
 ___ 
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/
 
 ___
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] Luminance Component Drawing / Camera Defocussing effect

2007-07-03 Thread Harash Sharma
Hi Mr. Robert. 
   
 Thanks for the guidance on this issue. I have gone through the 
osgDistortion example and was able to render the monochrome image. But my 
requirement to process the captured image remained as it is. What I tried was:
  1. Two Cameras were created -- one that renders the scene to a texture, and a 
second one that renders the texture on to the screen. 
   
 But in this case, the accessibility to the image was not available. Next I 
attached an image object to the rendering camera. This image was set as the 
texture image and used by the second camera to render the processed image on to 
the screen. Camera-setPostDrawCallback was used to grab the image at every 
frame. When I did this, to my amazement, the framerate dropped from around 70 
fps to 1 fps. 
   
 I don't know if what I am doing is proper. If so, then is this drop in 
framerate expected. I am using 1024x1024 image size and to test I have applied 
no processing at all. 
   
Further, I am using a osgViewer::CompositeViewer. In this I want to have 2 
views -- one that renders the usual colored scene while the other one that 
displays the processed monochrome scene. I am able to create the two views, but 
would like to take your guidance as to how to dynamically make one of them 
active while disabling the other one. 
   
 Thanks in advance.
   
  Regards
   
  Harash
   
 

   
-
Moody friends. Drama queens. Your life? Nope! - their life, your story.
 Play Sims Stories at Yahoo! Games. ___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Re: [osg-users] LightPointNode and shaders

2007-07-03 Thread Markus Hein

Hi Brad,


Can shaders be added to a osg::LightPointNode?

I'm trying to add both a vertex and fragment shader (pointsprite) but I
just don't see any effect.
  

I don't have problems with shader based pointsprites on nvidia hardware.

don't forget this line:

stateset-setMode(GL_VERTEX_PROGRAM_POINT_SIZE, osg::StateAttribute::ON);

hope it helps.

Markus
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


RE: [osg-users] OSG books

2007-07-03 Thread Cysneros, Nelson SPAWAR
Paul,
 
The books cover OSG version 2.0?
 
Thanks
 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Paul Martz
Sent: Tuesday, July 03, 2007 5:06 AM
To: 'osg users'
Subject: [osg-users] OSG books


Hi OSGers --
 
On an experimental basis, I'm going to try direct sales of OSG
documentation from my Web site: www.skew-matrix.com. Select Books from
the menu on the left.
 
When you order an OSG book in hardcopy, I'll give you access to
the PDF for free. This isn't such a big deal for the Quick Start Guide,
but should be a great deal for the reference Manual.
 
Because this is an experiment, to keep the Web programming
simple, I can't accept orders from outside the US, or from Alaska,
Hawaii, or Colorado. If your delivery address is in one of those
regions, you should order from Lulu.com.
 
For more info about OSG books, go to www.osgbooks.com.
 
Also, just a reminder about OSG training to be held in
Huntsville, Alabama this September. Register now to receive the
discounted price. Tuition goes up for registration after July 9. To
register, visit www.skew-matrix.com and select Training from the menu on
the left.
 
Thanks,
 
Paul Martz
Skew Matrix Software LLC
http://www.skew-matrix.com http://www.skew-matrix.com/ 
303 859 9466
 

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

RE: [osg-users] OSG books

2007-07-03 Thread Paul Martz
Hi -- The OSG Quick Start Guide is geared for OSG v2.0, yes. But, as a quick
start guide, the treatment of v2.0 features is pretty lightweight.
 
The OSG Reference Manual v1.2 is for v1.2, of course. A new reference manual
for v2.0 is in the works and should be available sometime this summer.
   -Paul
 


  _  

From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Cysneros, Nelson
SPAWAR
Sent: Tuesday, July 03, 2007 10:40 AM
To: osg users
Subject: RE: [osg-users] OSG books


Paul,
 
The books cover OSG version 2.0?
 
Thanks
 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Paul Martz
Sent: Tuesday, July 03, 2007 5:06 AM
To: 'osg users'
Subject: [osg-users] OSG books


Hi OSGers --
 
On an experimental basis, I'm going to try direct sales of OSG documentation
from my Web site: www.skew-matrix.com. Select Books from the menu on the
left.
 
When you order an OSG book in hardcopy, I'll give you access to the PDF for
free. This isn't such a big deal for the Quick Start Guide, but should be a
great deal for the reference Manual.
 
Because this is an experiment, to keep the Web programming simple, I can't
accept orders from outside the US, or from Alaska, Hawaii, or Colorado. If
your delivery address is in one of those regions, you should order from
Lulu.com.
 
For more info about OSG books, go to www.osgbooks.com.
 
Also, just a reminder about OSG training to be held in Huntsville, Alabama
this September. Register now to receive the discounted price. Tuition goes
up for registration after July 9. To register, visit www.skew-matrix.com and
select Training from the menu on the left.
 
Thanks,
 
Paul Martz
Skew Matrix Software LLC
http://www.skew-matrix.com http://www.skew-matrix.com/ 
303 859 9466
 

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

[osg-users] Bounding Rect in Screen Space

2007-07-03 Thread Pecoraro, Alexander N
Is there an easy way to calculate the bounding rectangle of an object in
screen space? I'm hoping for some easy function that I could pass my
osg::Node to and have it return the bounding rectangle of the pixels
that it covers.

Thanks.

Alex
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] ViewerEventHandlers problem with custom GUIEventHandlers

2007-07-03 Thread Robert Osfield

On 7/3/07, Panagiotis Papadakos [EMAIL PROTECTED] wrote:

One more question though.
Why we use KEYUP in ViewerEventHandlers.cpp and KEYDOWN in all other handlers?
Why not be consistent?


I have no answer to that one.  Some were written five years ago, some
in the last few months.  In general they should be consistent.

Robert.
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] Making Node::dirtyBound() virtual

2007-07-03 Thread Robert Osfield

Hi Paul,

On 7/3/07, Paul Martz [EMAIL PROTECTED] wrote:

Okay, but because computeBounds() is const, I have to cast away const in
order to perform operations on the scene graph within this function.


Casting away const'ness is should be see as advanced usage, some
that most usage models won't require, but if you know what your are
doing and that it won't break any threading then you'll be OK to just
go ahead and cast away constness.


Furthermore, when I do this, I see crashes in multidisplay environments,
probably due to a thread collision caused by modifying the scene graph in
one thread while another accesses the same part of the scene graph.


Well you'll need to write the code so its thread safe... one way
around this is to stick a viewer-getSceneData()-getBound() before
the call to renderingTraversals();  Crude way of forcing a single
threading computeBound() but effective.


Taking a look at CullVisitor, it's not clear to me how you ensure that
computeBounds() is only called once per frame in multidisplay environments
(where multiple cull traversals would be running concurrently). Can you
explain how this is handled?


The computeBounds() themselves just compute a bounding volume they
don't actually modify anything.  The getBound itself does the
modification of the cached bounding volume, and can do so virtual of
the _boundingBox/_boundingSphere being mutable.  The getBound does try
to make the serialize the access to the bounding volume variable,
rather it lets multiple threads go and do the compute and lets them
all apply their values - they will all compute the same values anyway
so there isn't any danger in this.

Robert.
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] Luminance Component Drawing / Camera Defocussing effect

2007-07-03 Thread Robert Osfield

Hi Harash,

I'm afraid I can't walk you through this, I have time to point you in
the direction but no more than this.

Robert.

On 7/3/07, Harash Sharma [EMAIL PROTECTED] wrote:

Hi Mr. Robert.

   Thanks for the guidance on this issue. I have gone through the
osgDistortion example and was able to render the monochrome image. But my
requirement to process the captured image remained as it is. What I tried
was:
1. Two Cameras were created -- one that renders the scene to a texture, and
a second one that renders the texture on to the screen.

   But in this case, the accessibility to the image was not available. Next
I attached an image object to the rendering camera. This image was set as
the texture image and used by the second camera to render the processed
image on to the screen. Camera-setPostDrawCallback was used to grab the
image at every frame. When I did this, to my amazement, the framerate
dropped from around 70 fps to 1 fps.

   I don't know if what I am doing is proper. If so, then is this drop in
framerate expected. I am using 1024x1024 image size and to test I have
applied no processing at all.

  Further, I am using a osgViewer::CompositeViewer. In this I want to have 2
views -- one that renders the usual colored scene while the other one that
displays the processed monochrome scene. I am able to create the two views,
but would like to take your guidance as to how to dynamically make one of
them active while disabling the other one.

   Thanks in advance.

Regards

Harash



 
Moody friends. Drama queens. Your life? Nope! - their life, your story.
 Play Sims Stories at Yahoo! Games.


___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


RE: [osg-users] Making Node::dirtyBound() virtual

2007-07-03 Thread Paul Martz
Understood. Very enlightening.

Okay, back to the drawing board. I ought to be able to come up with a
solution now that I have this info. Thanks.
   -Paul




 Hi Paul,
 
 On 7/3/07, Paul Martz [EMAIL PROTECTED] wrote:
  Okay, but because computeBounds() is const, I have to cast 
 away const 
  in order to perform operations on the scene graph within 
 this function.
 
 Casting away const'ness is should be see as advanced usage, 
 some that most usage models won't require, but if you know 
 what your are doing and that it won't break any threading 
 then you'll be OK to just go ahead and cast away constness.
 
  Furthermore, when I do this, I see crashes in multidisplay 
  environments, probably due to a thread collision caused by 
 modifying 
  the scene graph in one thread while another accesses the 
 same part of the scene graph.
 
 Well you'll need to write the code so its thread safe... one 
 way around this is to stick a 
 viewer-getSceneData()-getBound() before the call to 
 renderingTraversals();  Crude way of forcing a single 
 threading computeBound() but effective.
 
  Taking a look at CullVisitor, it's not clear to me how you 
 ensure that
  computeBounds() is only called once per frame in multidisplay 
  environments (where multiple cull traversals would be running 
  concurrently). Can you explain how this is handled?
 
 The computeBounds() themselves just compute a bounding volume 
 they don't actually modify anything.  The getBound itself 
 does the modification of the cached bounding volume, and can 
 do so virtual of the _boundingBox/_boundingSphere being 
 mutable.  The getBound does try to make the serialize the 
 access to the bounding volume variable, rather it lets 
 multiple threads go and do the compute and lets them all 
 apply their values - they will all compute the same values 
 anyway so there isn't any danger in this.
 
 Robert.

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


[osg-users] PointSprites = small feature culling = ClusterCullingCallback

2007-07-03 Thread sherman wilcox

I'm using osg::PointSprites on an ellipsoid. To overcome terrain
intersection problems between the sprites and the ellipsoid I disabled
depth testing on the sprites. Problem solved. However, I then have the
problem of sprites showing through the ellipsoid when you spin the
globe around such that the sprites are on the other side of the globe.
So, I decided to use osg::ClusterCullingCallback to solve that
problem. Followed the example in osgfadetext but the cluster culling
didn't work. After some debugging I discovered that disabling small
feature culling was preventing the Cluster culling from working. But,
if I don't disable small feature culling the point sprites don't
display.

What should I do here?

BTW, I'm disabling small feature culling via:
viewer.getCamera()-setCullingMode(osg::CullSettings::VIEW_FRUSTUM_SIDES_CULLING);
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


[osg-users] osgdem: avoid recreating temporary files

2007-07-03 Thread Sullivan, Joseph (CDR)
Hello,
Looking for ways to save time when running osgdem:   If you need to run
osgdem on the same set (or subset) of files twice, is there anything you
can do to skip creating the temporaryfile_original.tif series?
Thanks!
Joe
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


[osg-users] OSG 2.0 Singularity in osgSim::OverlayNode

2007-07-03 Thread KSpam
There is a singularity in OverlayNode.cpp in the 
traverse_VIEW_DEPENDENT_WITH_ORTHOGRAPHIC_OVERLAY method.  This singularity 
is evident when frustum_axis (line 1463) approaches lookVector (line 1465).  
To resolve this, I added the following code following sideVector.normalize() 
(line 1476):

if (sideVector.length()  1.0)
{
sideVector = osg::Vec3d(1.0, 0.0, 0.0);
}

Is this a reasonable fix?

Thanks,
Justin
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


[osg-users] Fix for Windows version pfb plugin

2007-07-03 Thread John Swan-Stone
Here is the corrected CMakeLists.txt file for the Windows XP 
VisualStudio 8 SP1 version of 'Plug 3d pfb' Performer plugin.

INCLUDE_DIRECTORIES( ${PERFORMER_INCLUDE_DIR} )

SET(TARGET_SRC
ReaderWriterPFB.cpp
ConvertFromPerformer.cpp
)

SET(TARGET_H
ConvertFromPerformer.h
)

IF(MSVC)
SET(TARGET_EXTERNAL_LIBRARIES
libpfdu-util
)
ELSE(MSVC)
SET(TARGET_EXTERNAL_LIBRARIES
pfdu pfutil
)
ENDIF(MSVC)

SET(TARGET_LIBRARIES_VARS PERFORMER_LIBRARY )

 end var setup  ###
SETUP_PLUGIN(pfb)
B.t.w. These lines in the CMakeLists.txt file for the 'Plug other qt' 
quicktime plugin doesn't do anything.

IF(WIN32)
SET(CMAKE_SHARED_LINKER_FLAGS_DEBUG 
${CMAKE_SHARED_LINKER_FLAGS_DEBUG} /NODEFAULTLIB:MSVCRT)

ENDIF(WIN32)
I.e. /NODEFAULTLIB:MSVCRT doesn't show up in the generated vcproj files. 
 Poking around a little shows me some lines in the 'Plug image gif' 
CMakeLists.txt file like:

IF(MSVC)
SET_TARGET_PROPERTIES(${TARGET_DEFAULT_PREFIX}${TARGET_NAME} 
PROPERTIES LINK_FLAGS_DEBUG /NODEFAULTLIB:MSVCRT)

ENDIF(MSVC)
Which do add the /NODEFAULTLIB:MSVCRT to the build settings but does it 
in an obscure way by putting it in Additional options of the Command 
Line page of the Property pages for that project 
(http://www.cs.utexas.edu/~jss/OSG/bug1.jpg) instead of in the 'Ignore 
Specific Library' line of the Input page of the Property pages for that 
project (http://www.cs.utexas.edu/~jss/OSG/bug2.JPG).  I don't know how 
to tell CMake to put the NODEFAULTLIB in the 'Ignore Specific Library' 
line.  Does anyone?


If you modify this slightly ...

IF(MSVC)
SET_TARGET_PROPERTIES(${TARGET_DEFAULT_PREFIX}${TARGET_NAME} 
PROPERTIES LINK_FLAGS_DEBUG /NODEFAULTLIB:LIBCMT)

ENDIF(MSVC)
... and replace the IF(WIN32) lines described above for the Quicktime 
CMakelists.txt then 'Plug other qt' will link on windows without warning.


John.
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] CEGUI

2007-07-03 Thread Himar Carmona

 Hi,  Jeremy:

 i don't know if this can be of interest to you, but if it can help you...

 The book DirectX 9 User Interfaces: Design and Implementation is the only
reference i have found that explain how to do a GUI with DirectX from ground
up. You can avoid the directX things, the book has some (short) comments
about the pitfalls to avoid when designing a GUI. The GUI developed in the
book seems quite similar than the one that ships with DirectX
(coincidence?), but there will not be many issues doing that with OSG.

Of course, i have nothing to do with the author or the publisher. This is
not 'propaganda', just knowledge interchange. :)

 I haven't found any other reference about the topic of designing GUIs.
Have you?

Cheers.

2007/7/3, Jeremy L. Moles [EMAIL PROTECTED]:


On Tue, 2007-07-03 at 12:43 +0200, Emmanuel Roche wrote:
 By the way, sure CEGUI is not recommendable but is there another good
 possibility you would recommend to build GUIs in OSG ?

I'm working on one myself. :) Just need time... time... who ever has
enough? At any rate, if you don't use CEGUI there really isn't much
else. Hopefully I can have the osgHUD NodeKit working in the coming
months.

 Manu.


 2007/7/3, Robert Osfield [EMAIL PROTECTED]:
 Hi Guy,

 The osgcegui example was my abortive attempt at getting CEGUI
 to work
 in a well that integrates well with the OSG.  I say abortive
 because
 CEGUI really is a bit brain dead when it comes to managing
 multiple
 graphics contexts and multi-threading, its can't do it at all
 and
 doesn't look like it'll ever do it without a major rewrite.

 Some OSG users have got CEGUI to work with the OSG, and there
 are some
 suggestions in the osg-users archives about this.

 Personally I was unimpressed with CEGUI, its just not well
 designed or
 implemented library, its makes too many assumptions and
 restrictions
 on its usage to make it particularly useful beyond single
 window,
 single threaded games.  I certainly wouldn't recommend it.

 Robert.

 On 7/3/07, [EMAIL PROTECTED]  [EMAIL PROTECTED] wrote:
 
 
  Hi,
   I tried to run the osgcegui example, and no GUI was
 rendered.
 
  All the GUI creation code was taken from CEGUI example
 (which works).
  I didn't get any errors from CEGUI or OSG.
 
  I also tried to set the renderGUI function as post callback
 of the camera
  with no better results.
 
  any ideas?
 
  is it something with the Zbuffer? or Z position of the GUI?
 
  thanks,
   Guy.
  ___
  osg-users mailing list
  osg-users@openscenegraph.net
  http://openscenegraph.net/mailman/listinfo/osg-users
  http://www.openscenegraph.org/
 
 ___
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/

 ___
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

[osg-users] Rendering threads and scene graph updates.

2007-07-03 Thread Himar Carmona

Hi,

 i'm working with OSG on Windows. I'm designing a Geo viewer that use OSG
internally for rendering purposes, and i have some questions about how the
modification of the scene graph must be done to be safe with the cull and
draw traversals.

 After reading the Quick Start Guide and the DatabasePager code and looking
at the osg mail archive, what i've found so far is that it is possible to
modify the scene graph inside an update callback and that it is the
recommended approach (viewer seems to treat databasePager as a special case
and don't use update callback). I'm right with that or have i misunderstood
something?

 Until now i have been working with a render thread that i start after the
window is created. But after reading a comment in the checkevents method of
GraphicsWindowWin32 that says it must be called from the main thread and
knowing that Win32 don't like much that different threads access the message
loop (as checkevents does), i'm thinking about the possibilty of doing the
render from the main thread (e.g. using WM_TIMER and calling viewer::frame()
, i don't have access to the app message loop). Is this possible? The
examples i have seen so far use either a render thread (osgviewerMFC) or a
custom message loop (osgViewerGLUT).

 I'm seeking for the possibility of avoiding to implement a custom Update
Callback for doing the updates of the scenegraph, and make the changes
directly to the scenegraph. It will free me for implementing the changes
queues in the update callback (a solution mentioned in a two years old osg
mail message) and will simplify my design greatly. The Quick Start Guide
mentioned that this is possible, but also mentioned that this requires
modifications to the main rendering loop. What else have to be keep in mind?


 Thanks in advance,
Himar.
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Re: [osg-users] Luminance Component Drawing / Camera Defocussing effect

2007-07-03 Thread Harash Sharma
Hi Mr. Robert,
   
  I understand your plausibility of time, but at least can you indicate if 
the reduction in frame rate to 1fps when rendering to an image expected.
   
 Thanks
   
  Regards
   
  Harash

Robert Osfield [EMAIL PROTECTED] wrote:
  Hi Harash,

I'm afraid I can't walk you through this, I have time to point you in
the direction but no more than this.

Robert.

On 7/3/07, Harash Sharma wrote:
 Hi Mr. Robert.

 Thanks for the guidance on this issue. I have gone through the
 osgDistortion example and was able to render the monochrome image. But my
 requirement to process the captured image remained as it is. What I tried
 was:
 1. Two Cameras were created -- one that renders the scene to a texture, and
 a second one that renders the texture on to the screen.

 But in this case, the accessibility to the image was not available. Next
 I attached an image object to the rendering camera. This image was set as
 the texture image and used by the second camera to render the processed
 image on to the screen. Camera-setPostDrawCallback was used to grab the
 image at every frame. When I did this, to my amazement, the framerate
 dropped from around 70 fps to 1 fps.

 I don't know if what I am doing is proper. If so, then is this drop in
 framerate expected. I am using 1024x1024 image size and to test I have
 applied no processing at all.

 Further, I am using a osgViewer::CompositeViewer. In this I want to have 2
 views -- one that renders the usual colored scene while the other one that
 displays the processed monochrome scene. I am able to create the two views,
 but would like to take your guidance as to how to dynamically make one of
 them active while disabling the other one.

 Thanks in advance.

 Regards

 Harash



 
 Moody friends. Drama queens. Your life? Nope! - their life, your story.
 Play Sims Stories at Yahoo! Games.


 ___
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


   
-
Boardwalk for $500? In 2007? Ha! 
Play Monopoly Here and Now (it's updated for today's economy) at Yahoo! Games.___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

[osg-users] FadeText and Backdrop

2007-07-03 Thread Fábio Mierlo

Hi,

I'm using osg 2.0.0 and when I use FadeText with Backdrop
it don't fade the shadow.

Follow a screenshot:

http://stackedboxes.org/~fmierlo/OSG/fadetext_backdrop.jpg
___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] OSG books

2007-07-03 Thread Rizzen
Hi Paul,

I have the Quick Start Guide and I must say the quality of the book is
impressive, you really do get down to using OSG quickly. Though for the
simple examples, but it is a start for all new members of OSG. :) It
also acts as a mini reference for some of the older members who don't
work  full time with OSG, the hobbiest I refering too.

The only concern I have about the official Reference is that it is for
OSG 1.2, and we are sitting at OSG 2.0 which is also a major version
change, thus plenty nice new features and some API changes, particularly
to the use of SimpleViewer, etc thats helps with better integration with
many widget libraries. I believe the new interface will work better with
GTKMM and GTK+, as the older interface was a real pain to use. Though I
discover ease of use when I have free time at the end of the year.

What is your plans regarding a reference for OSG 2.0?

Rizzan

Paul Martz wrote:
 Hi OSGers --
  
 On an experimental basis, I'm going to try direct sales of OSG
 documentation from my Web site: www.skew-matrix.com
 http://www.skew-matrix.com. Select *Books* from the menu on the left.
  
 When you order an OSG book in hardcopy, I'll give you access to the
 PDF for free. This isn't such a big deal for the /Quick Start Guide/,
 but should be a great deal for the /reference Manual/.
  
 Because this is an experiment, to keep the Web programming simple, I
 can't accept orders from outside the US, or from Alaska, Hawaii, or
 Colorado. If your delivery address is in one of those regions, you
 should order from Lulu.com.
  
 For more info about OSG books, go to www.osgbooks.com
 http://www.osgbooks.com.
  
 Also, just a reminder about OSG training to be held in Huntsville,
 Alabama this September. Register now to receive the discounted price.
 Tuition goes up for registration after July 9. To register, visit
 www.skew-matrix.com http://www.skew-matrix.com and select *Training
 *from the menu on the left.
  
 Thanks,
  
 Paul Martz
 *Skew Matrix Software LLC*
 http://www.skew-matrix.com http://www.skew-matrix.com/
 303 859 9466
  
 

 ___
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


Re: [osg-users] OSG books

2007-07-03 Thread Rizzen
Arg

You already answered my question for my previous email, but with a
global snag.

Which summer are you refering to? Northern or southern hemisphere? If
southern hemisphere summer, looking at Dec 2007? If northern hemisphere
summer, looking at July 2007 or July 2008?

Also another thing, if one buys the PDF, can one print a few pages, so
one can work on the OSG projects when away from electronic equipment,
like when you on a wilderness trip for a few weeks.

Rizzen

Paul Martz wrote:
 Hi -- The /OSG Quick Start Guide/ is geared for OSG v2.0, yes. But, as
 a quick start guide, the treatment of v2.0 features is pretty lightweight.
  
 The /OSG Reference Manual v1.2/ is for v1.2, of course. A new
 reference manual for v2.0 is in the works and should be available
 sometime this summer.
-Paul
  

 
 *From:* [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] *On Behalf Of
 *Cysneros, Nelson SPAWAR
 *Sent:* Tuesday, July 03, 2007 10:40 AM
 *To:* osg users
 *Subject:* RE: [osg-users] OSG books

 Paul,
  
 The books cover OSG version 2.0?
  
 Thanks
  

 -Original Message-
 *From:* [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] *On Behalf Of
 *Paul Martz
 *Sent:* Tuesday, July 03, 2007 5:06 AM
 *To:* 'osg users'
 *Subject:* [osg-users] OSG books

 Hi OSGers --
  
 On an experimental basis, I'm going to try direct sales of OSG
 documentation from my Web site: www.skew-matrix.com
 http://www.skew-matrix.com. Select *Books* from the menu on
 the left.
  
 When you order an OSG book in hardcopy, I'll give you access
 to the PDF for free. This isn't such a big deal for the /Quick
 Start Guide/, but should be a great deal for the /reference
 Manual/.
  
 Because this is an experiment, to keep the Web programming
 simple, I can't accept orders from outside the US, or from
 Alaska, Hawaii, or Colorado. If your delivery address is in
 one of those regions, you should order from Lulu.com.
  
 For more info about OSG books, go to www.osgbooks.com
 http://www.osgbooks.com.
  
 Also, just a reminder about OSG training to be held in
 Huntsville, Alabama this September. Register now to receive
 the discounted price. Tuition goes up for registration after
 July 9. To register, visit www.skew-matrix.com
 http://www.skew-matrix.com and select *Training *from the
 menu on the left.
  
 Thanks,
  
 Paul Martz
 *Skew Matrix Software LLC*
 http://www.skew-matrix.com http://www.skew-matrix.com/
 303 859 9466
  

 

 ___
 osg-users mailing list
 osg-users@openscenegraph.net
 http://openscenegraph.net/mailman/listinfo/osg-users
 http://www.openscenegraph.org/

___
osg-users mailing list
osg-users@openscenegraph.net
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/