Flat plane

classic Classic list List threaded Threaded
7 messages Options
Adam Adam
Reply | Threaded
Open this post in threaded view
|

Flat plane

Is there an easy way to create a single flat plane of a specified dimension like 10kmx10km with no elevation?  A hackish way would be to create all the height field files with no elevation, but I was hoping there was a better way.
gwaldron gwaldron
Reply | Threaded
Open this post in threaded view
|

Re: Flat plane

osgEarth always requires a real geospatial context. So you need to specify an actual 10km^2 region of the earth in a flat projection. You can do so with <profile> tag (see http://wush.net/trac/osgearth/wiki/MapElementProfile for a state-plane example).

The samples "arc_imagery_roads_utm.earth" and "dc_state_plane.earth" demonstrate this usage.

Glenn
Glenn Waldron / Pelican Mapping
Adam Adam
Reply | Threaded
Open this post in threaded view
|

Re: Flat plane

It looks like the utm projection is what I'm looking for, however, with this map:
<map name="Flat plane" type="projected">
   <profile srs="epsg:26917" xmin="0" ymin="0" xmax="10000" ymax="10000"/>
</map>

Nothing is displayed, but with:
<map name="test" type="geocentric">
</map>

I get a blank sphere.

Maybe it would help if I told you the goal.  Basically it is to have a single plane that different parts of the globe are placed onto.  Would it just be removing and adding layers at run time? There will be no height fields.
gwaldron gwaldron
Reply | Threaded
Open this post in threaded view
|

Re: Flat plane

When I run your Flat Plane map file, I get a flat white 10km x 10km plane. In any case, I'm not understanding your goal as you've stated it.

Glenn

Glenn Waldron / Pelican Mapping
Adam Adam
Reply | Threaded
Open this post in threaded view
|

Re: Flat plane

Ah, well I'm a bit off current due to the compile error I posted previously, but that may work as I hoped now.
I'll try to explain the goal again.

One mode of operation is essentially a large flat map, however, the images displayed on it will change.  The user may want to look at Boston, then DC, then NYC.  All the geotiff etc will be displayed on top of this flat plane.  Obviously I could re-create the entire map every time they moved the location, but I was hoping for an easier way.
gwaldron gwaldron
Reply | Threaded
Open this post in threaded view
|

Re: Flat plane

If you care about the spatial coordinates, creating a new MapNode each time will be easier than what you're trying to do. After all, a MapNode can have one and only one spatial profile. Each geotiff is going to have geospatial extents that need to match up with the terrain (regardless of whether you are populating a heightfield).

If you don't care about the spatial context, you could try using the OSG driver and treat each geotiff as an unreferenced image. Of course, the map coordinates will be meaningless if you do this.
(http://wush.net/trac/osgearth/wiki/TileSourcePluginOSG)

Glenn
Glenn Waldron / Pelican Mapping
Adam Adam
Reply | Threaded
Open this post in threaded view
|

Re: Flat plane

Ok thanks.  This mode is a rather odd one, and I'm still not sure which will be better.

Thanks for the tips.

Adam