[osg-users] When optimizing with LOD changes, should I change UV map resolutions?

2008-07-10 Thread rpingry
Hello All,

I have been trying to get my scenes to run faster, balancing my scene graphs
using LOD.  I use quite a bit of UV mapping in my models, and they can be
fairly high res because I want them to look good up close.  There are
usually several instances of the same model in the scene, all pointing to
the same scene graph.  I was wondering about the best way to create LOD
changes for them.  I was going to cut out some polygons, but I was also
thinking of cutting the resolution back on the UV maps.  Is this valuable?
On first assessment, it seems it would be, but then I realize that it might
cause MORE of a memory usage, and the graphics card (or OSG) might be doing
this kind of optimization anyway (dropping image map resolutions based on
pixel size or whatever).  What are your recommendations?

-- Thanks for everything
 Rick
Check us out at http://fringe-online.com/
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] When optimizing with LOD changes, should I change UV map resolutions?

2008-07-10 Thread Robert Osfield
Hi Rick,

The most efficient LOD's will be the ones created by specialist tools,
or even a decent modeller.  The aim of the lower level of details
subgraphs would be to represent the subgraph with less of everything -
less nodes, less separate state, less geometry, smaller textures,
simpler shaders etc.   The ideal would be collapsing down to a single
osg::Geode/osg::Geometry and with a single osg::StateSet and a single
Texture.Using a texture atlas is a good way to collapse separate
textures down into a single texture.  osgUtil::Optimizer has a texture
atas builder that could help with this.

Robert.

On Thu, Jul 10, 2008 at 2:08 PM,  [EMAIL PROTECTED] wrote:
 Hello All,

 I have been trying to get my scenes to run faster, balancing my scene graphs
 using LOD.  I use quite a bit of UV mapping in my models, and they can be
 fairly high res because I want them to look good up close.  There are
 usually several instances of the same model in the scene, all pointing to
 the same scene graph.  I was wondering about the best way to create LOD
 changes for them.  I was going to cut out some polygons, but I was also
 thinking of cutting the resolution back on the UV maps.  Is this valuable?
 On first assessment, it seems it would be, but then I realize that it might
 cause MORE of a memory usage, and the graphics card (or OSG) might be doing
 this kind of optimization anyway (dropping image map resolutions based on
 pixel size or whatever).  What are your recommendations?

 -- Thanks for everything
 Rick
 Check us out at http://fringe-online.com/
 ___
 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] When optimizing with LOD changes, should I change UV map resolutions?

2008-07-10 Thread Paul Martz
Robert's comment regarding texture atlas usage in low-res LOD children is an
excellent suggestion.
 
Going further, your post begs the question: Do you suspect that texture
memory usage is the bottleneck to your performance? One way to test this (if
you haven't already done so) is to set the OSG environment variable to limit
the maximum texture dimension to something ridiculously small. If your app
runs faster with this setting, then texture memory usage might be causing
performance problems, and you might need to address that in some way.
 
You should keep in mind that most OpenGL device drivers are smart enough to
page out large mipmap levels when they are not in use.
 
Another thing to keep in mind is that a texture never needs to be larger
than its max representation on-screen. For example, it's pointless to have a
2kx2k texture applied to an object that will never subtend more than 500x500
pixels.
 
Hope that helps.
   -Paul
 


  _  

From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: Thursday, July 10, 2008 7:09 AM
To: OpenSceneGraph Users
Subject: [osg-users] When optimizing with LOD changes,should I change UV map
resolutions?


Hello All,
 
I have been trying to get my scenes to run faster, balancing my scene graphs
using LOD.  I use quite a bit of UV mapping in my models, and they can be
fairly high res because I want them to look good up close.  There are
usually several instances of the same model in the scene, all pointing to
the same scene graph.  I was wondering about the best way to create LOD
changes for them.  I was going to cut out some polygons, but I was also
thinking of cutting the resolution back on the UV maps.  Is this valuable?
On first assessment, it seems it would be, but then I realize that it might
cause MORE of a memory usage, and the graphics card (or OSG) might be doing
this kind of optimization anyway (dropping image map resolutions based on
pixel size or whatever).  What are your recommendations?

-- Thanks for everything
 Rick
Check us out at http://fringe-online.com/ 

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


Re: [osg-users] When optimizing with LOD changes, should I change UV map resolutions?

2008-07-10 Thread Rick Pingry
Wow, the ability to limit the maximum texture memory sounds like it would
really help.  What/where might I find that environment variable?

-- Rick

On Thu, Jul 10, 2008 at 11:26 AM, Paul Martz [EMAIL PROTECTED] wrote:

  Robert's comment regarding texture atlas usage in low-res LOD children is
 an excellent suggestion.

 Going further, your post begs the question: Do you suspect that texture
 memory usage is the bottleneck to your performance? One way to test this (if
 you haven't already done so) is to set the OSG environment variable to limit
 the maximum texture dimension to something ridiculously small. If your app
 runs faster with this setting, then texture memory usage might be causing
 performance problems, and you might need to address that in some way.

 You should keep in mind that most OpenGL device drivers are smart enough to
 page out large mipmap levels when they are not in use.

 Another thing to keep in mind is that a texture never needs to be larger
 than its max representation on-screen. For example, it's pointless to have a
 2kx2k texture applied to an object that will never subtend more than 500x500
 pixels.

 Hope that helps.
-Paul


  --
 *From:* [EMAIL PROTECTED] [mailto:
 [EMAIL PROTECTED] *On Behalf Of *
 [EMAIL PROTECTED]
 *Sent:* Thursday, July 10, 2008 7:09 AM
 *To:* OpenSceneGraph Users
 *Subject:* [osg-users] When optimizing with LOD changes,should I change UV
 map resolutions?

   Hello All,

 I have been trying to get my scenes to run faster, balancing my scene
 graphs using LOD.  I use quite a bit of UV mapping in my models, and they
 can be fairly high res because I want them to look good up close.  There are
 usually several instances of the same model in the scene, all pointing to
 the same scene graph.  I was wondering about the best way to create LOD
 changes for them.  I was going to cut out some polygons, but I was also
 thinking of cutting the resolution back on the UV maps.  Is this valuable?
 On first assessment, it seems it would be, but then I realize that it might
 cause MORE of a memory usage, and the graphics card (or OSG) might be doing
 this kind of optimization anyway (dropping image map resolutions based on
 pixel size or whatever).  What are your recommendations?

 -- Thanks for everything
  Rick
 Check us out at http://fringe-online.com/


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




-- 
 Rick
Check us out at http://fringe-online.com/
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] When optimizing with LOD changes, should I change UV map resolutions?

2008-07-10 Thread Robert Osfield
On Thu, Jul 10, 2008 at 5:13 PM, Rick Pingry [EMAIL PROTECTED] wrote:
 Wow, the ability to limit the maximum texture memory sounds like it would
 really help.  What/where might I find that environment variable?

You can list the env vars by doing:

   osgviewer --help-env

One of the entries will be:

  OSG_MAX_TEXTURE_SIZE   Set the maximum size of textures.


So you do something like:

  set OSG_MAX_TEXTURE_SIZE=64
  myapp mymodel.fmt

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


Re: [osg-users] When optimizing with LOD changes, should I change UV map resolutions?

2008-07-10 Thread Paul Martz
The OSG Ref Man v2.2 (www.osgbooks.com) has a complete reference of OSG
environment variables. The one you want is OSG_MAX_TEXTURE_SIZE.
   -Paul

 




From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Rick Pingry
Sent: Thursday, July 10, 2008 10:14 AM
To: OpenSceneGraph Users
Subject: Re: [osg-users] When optimizing with LOD changes,should I
change UV map resolutions?


Wow, the ability to limit the maximum texture memory sounds like it
would really help.  What/where might I find that environment variable?
 
-- Rick


On Thu, Jul 10, 2008 at 11:26 AM, Paul Martz
[EMAIL PROTECTED] wrote:


Robert's comment regarding texture atlas usage in low-res
LOD children is an excellent suggestion.
 
Going further, your post begs the question: Do you suspect
that texture memory usage is the bottleneck to your performance? One way to
test this (if you haven't already done so) is to set the OSG environment
variable to limit the maximum texture dimension to something ridiculously
small. If your app runs faster with this setting, then texture memory usage
might be causing performance problems, and you might need to address that in
some way.
 
You should keep in mind that most OpenGL device drivers are
smart enough to page out large mipmap levels when they are not in use.
 
Another thing to keep in mind is that a texture never needs
to be larger than its max representation on-screen. For example, it's
pointless to have a 2kx2k texture applied to an object that will never
subtend more than 500x500 pixels.
 
Hope that helps.
   -Paul
 




From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
[EMAIL PROTECTED]
Sent: Thursday, July 10, 2008 7:09 AM
To: OpenSceneGraph Users
Subject: [osg-users] When optimizing with LOD
changes,should I change UV map resolutions?


Hello All,
 
I have been trying to get my scenes to run faster,
balancing my scene graphs using LOD.  I use quite a bit of UV mapping in my
models, and they can be fairly high res because I want them to look good up
close.  There are usually several instances of the same model in the scene,
all pointing to the same scene graph.  I was wondering about the best way to
create LOD changes for them.  I was going to cut out some polygons, but I
was also thinking of cutting the resolution back on the UV maps.  Is this
valuable?  On first assessment, it seems it would be, but then I realize
that it might cause MORE of a memory usage, and the graphics card (or OSG)
might be doing this kind of optimization anyway (dropping image map
resolutions based on pixel size or whatever).  What are your
recommendations?

-- Thanks for everything
 Rick
Check us out at http://fringe-online.com/ 


___
osg-users mailing list
osg-users@lists.openscenegraph.org

http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org






-- 
 Rick
Check us out at http://fringe-online.com/ 


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