Re: [osg-users] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-14 Thread Chris Hanson
On Wed, Mar 14, 2012 at 9:46 AM, Aurelien Albert <
aurelien.alb...@alyotech.fr> wrote:

> 1. I need to manage multiple "terrain layers". A layer is made of
> elevation data and texture data. So I think to build a terrain database for
> each "terrain layer" and then add all these database in the same scene
> graph. This allow the user to rebuild / show / hide only selected "terrain
> layers"
> Is there any technical / performance problems to use multiple terrain
> database nodes in the same scene graph ? I know there will be some
> rendering artifacts because a (X;Y) point can have different altitudes (one
> from each "terrain layer") but this is not my question, I wondering about
> TileID management for example.
>

  I've done it before without problems.


> 2. Some "terrain layers" have elevation data relative to another one. Is
> there anyway to manage that using osgTerrain ? I think I can "add" the 2
> elevation data using GDAL before database creation, but I would prefer to
> do that at runtime.
>

  Not really. You should consider looking into osgEarth. It might have a
way to do this since it builds the terrain on the fly.


> 3. Is there any "invalid elevation value" management to "cut holes" in
> source elevation data and then build a database with holes inside ? (not
> simple shape holes as square)
>

  I don't remember how VPB handles this anymore. I know I've done it though.


> 4. Is there any way to build a "texture only database" (no elevation data)
> and then add / remove it (as a colorlayer on pre-loaded terrain database)
> at runtime ?
>

  This is something osgEarth is MUCH better suited to doing.


>
>
> Thank you!
>
> Cheers,
> Aurelien
>
> --
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=46268#46268
>
>
>
>
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>



-- 
Chris 'Xenon' Hanson, omo sanza lettere. xe...@alphapixel.com
http://www.alphapixel.com/
Training • Consulting • Contracting
3D • Scene Graphs (Open Scene Graph/OSG) • OpenGL 2 • OpenGL 3 • OpenGL 4 •
GLSL • OpenGL ES 1 • OpenGL ES 2 • OpenCL
Digital Imaging • GIS • GPS • Telemetry • Cryptography • Digital Audio •
LIDAR • Kinect • Embedded • Mobile • iPhone/iPad/iOS • Android
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-14 Thread Aurelien Albert
Thanks for your quick answers !

I'm considering using VPB instead of osgEarth for performance issue : we need 
to provide a smooth user experience at 30-60 fps on midrange hardware.

And since a lot of data are static, I think VPB should give us better 
performance, but maybe am I wrong ?

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





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


Re: [osg-users] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-14 Thread Chris Hanson
>
> I'm considering using VPB instead of osgEarth for performance issue : we
> need to provide a smooth user experience at 30-60 fps on midrange hardware.
> And since a lot of data are static, I think VPB should give us better
> performance, but maybe am I wrong ?
>

  Have you TRIED osgEarth?

  You can use VPB-built static terrin baselayers in osgEarth, and use
osgEarth's dynamic terrain layers only where needed. You can also use
osgEarth to apply dynamic imagery sources onto static VPB terrain layers.


>
> --
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=46282#46282
>
>
>
>
>
> ___
> osg-users mailing list
> osg-users@lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>



-- 
Chris 'Xenon' Hanson, omo sanza lettere. xe...@alphapixel.com
http://www.alphapixel.com/
Training • Consulting • Contracting
3D • Scene Graphs (Open Scene Graph/OSG) • OpenGL 2 • OpenGL 3 • OpenGL 4 •
GLSL • OpenGL ES 1 • OpenGL ES 2 • OpenCL
Digital Imaging • GIS • GPS • Telemetry • Cryptography • Digital Audio •
LIDAR • Kinect • Embedded • Mobile • iPhone/iPad/iOS • Android
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-15 Thread Aurelien Albert

>  Have you TRIED osgEarth? 


Yes, in the past I've been working about 8 month on a osgEarth based project.

We used a 2 GB dataset, and performance was really bad until the cache is 
filled.

The new project I'm starting will use dataset about to 5-20 GB, in local 
storage (with some single files up to 4 GB).

So I'm a little afraid about performance using osgEarth, and the resulting 
cache size.

Also, a have a restriction : the dataset coordinate system is selected by the 
end-user, and not necessary a geoid. If I remember well, osgEarth can work only 
with a geoid.

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





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


Re: [osg-users] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-15 Thread Aurelien Albert

> You can use VPB-built static terrin baselayers in osgEarth, and use 
> osgEarth's dynamic terrain layers only where needed. You can also use 
> osgEarth to apply dynamic imagery sources onto static VPB terrain layers. 


Hum, I've missed that in my previous project... you are probably right, it 
might be the best idea.

I'll check coordinates system mangement in osgEarth to see if it fits our 
requirements.

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





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


Re: [osg-users] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-15 Thread Eric Zaremba
Hi,

At the question

Aurelien wrote:
> 3. Is there any "invalid elevation value" management to "cut holes" in source 
> elevation data and then build a database with holes inside ? (not simple 
> shape holes as square)


You say

Chris Hanson wrote:
> I don't remember how VPB handles this anymore. I know I've done it though.


The need of drill hole in my terrains is the thing which prevent me to use 
osgEarth or VPB until now. If you can remember how to do it, it will be a great 
improvement in my projects.

Thank you!

Cheers,
Eric

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





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


Re: [osg-users] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-15 Thread Chris Hanson
>
> Chris Hanson wrote:
> > I don't remember how VPB handles this anymore. I know I've done it
> though.
>
>
  I recall what I did -- I actually used a crazy rendering trick to avoid
the need for holes in the terrain.

  I believe you could mark the hole areas in your drape image with a
special color and then have a custom shader that discarded fragments when
that color was detected. If that won't work, there's probably other ideas I
could consult with you on.

-- 
Chris 'Xenon' Hanson, omo sanza lettere. xe...@alphapixel.com
http://www.alphapixel.com/
Training • Consulting • Contracting
3D • Scene Graphs (Open Scene Graph/OSG) • OpenGL 2 • OpenGL 3 • OpenGL 4 •
GLSL • OpenGL ES 1 • OpenGL ES 2 • OpenCL
Digital Imaging • GIS • GPS • Telemetry • Cryptography • Digital Audio •
LIDAR • Kinect • Embedded • Mobile • iPhone/iPad/iOS • Android
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-15 Thread Robert Osfield
Hi Aurelien,

On 14 March 2012 15:46, Aurelien Albert  wrote:
> 3. Is there any "invalid elevation value" management to "cut holes" in source 
> elevation data and then build a database with holes inside ? (not simple 
> shape holes as square)

There is the osgTerrain::ValidValueOperator base that can be used to
set valid values for data by assigning an instance of one of it's
subclass to the osgTerrain::layer, the osgTerrain::NoDataValue is the
subclass that probably does what you need.

VirtualPlanetBuilder reads the no data values from GDAL and uses this
internally, but I've just done a quick code review and can't spot an
entry in VPB for setting the osgTerrain::NoDataValue.

As for multiple terrain layers, VirtualPlanetBuilder and osgTerrain
were written with assumption that their would only be one elevation
layer per tile.  One could possible play with using a SwitchLayer in
osgTerrain and add support for this in VirtualPlanetBuilder to achieve
the ability to have multiple elevation layers, however, this obviously
requires to modifications to VirtaulPlanetBuilder and osgTerrain.

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


Re: [osg-users] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-15 Thread Jason Beverage
Hi Eric,

osgEarth can do everything you've mentioned you need to do.  You can
add/remove layers at runtime, cut holes in the terrain using the masking
feature and run at 60 fps.  When you say that performance was bad until
you've filled the cache in osgEarth, you're making a good point.
 Everything that VPB does in it's preprocessing step osgEarth is doing at
runtime and caching as it goes along.  So a fully cached osgEarth is very
similar to a VPB built database.

That being said, you'll get MUCH better performance (in both osgEarth at
runtime and VPB at build time) if you take some relatively simple steps to
make sure you're GIS is optimized, see
http://osgearth.org/wiki/DataPreparation
Basically you need to take the time to reproject your data up front and
ensure that it's in a fast format that can support fast tiled reads (like a
tiled geotiff with overviews or an ECW or JPEG2000).

I'm looking at a 1.2 GB ECW file in osgEarth right now with no cache at all
and it's crazy fast.

Thanks,

Jason

On Thu, Mar 15, 2012 at 12:01 PM, Eric Zaremba  wrote:

> Hi,
>
> At the question
>
> Aurelien wrote:
> > 3. Is there any "invalid elevation value" management to "cut holes" in
> source elevation data and then build a database with holes inside ? (not
> simple shape holes as square)
>
>
> You say
>
> Chris Hanson wrote:
> > I don't remember how VPB handles this anymore. I know I've done it
> though.
>
>
> The need of drill hole in my terrains is the thing which prevent me to use
> osgEarth or VPB until now. If you can remember how to do it, it will be a
> great improvement in my projects.
>
> Thank you!
>
> Cheers,
> Eric
>
> --
> Read this topic online here:
> http://forum.openscenegraph.org/viewtopic.php?p=46309#46309
>
>
>
>
>
> ___
> 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] [vpb] Multiple terrain layers and relative altitude heightmap

2012-03-19 Thread Eric Zaremba
Ok, thank you, I will take a look at all of that.

Eric

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





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