Re: [osg-users] vpb: Spherical terrains?
Hi Guys, I also want to create the moon model for my project. But I am not able to find any data sources till now. Glenn, can you tell me the source of the imagery you have used for generating the terrain. Are there any free data sources for the moon imagery ? RJ Alejandro Aguilar Sierra wrote: Hi Glenn, Yes, thanks. Using more accurate moon metrics osgdem --geocentric --whole-globe -t moontex.tif -d moon_tiled.tif \ -l 10 \ --radius-equator 1737100 --radius-polar 1735970 \ -v 0.257 \ -o lunasph.ive I got the attached images. Regards, --A. On Tue, Sep 30, 2008 at 11:23 AM, Glenn Waldron [EMAIL PROTECTED] wrote: Alejandro, Try adding --radius-polar in addition to --radius-equator. Glenn ___ 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: Spherical terrains?
Looks like your question was meant to be directed at Alejandro instead of me.. Glenn On Sat, Nov 22, 2008 at 3:34 AM, Rahul Jain [EMAIL PROTECTED] wrote: Hi Guys, I also want to create the moon model for my project. But I am not able to find any data sources till now. Glenn, can you tell me the source of the imagery you have used for generating the terrain. Are there any free data sources for the moon imagery ? RJ Alejandro Aguilar Sierra wrote: Hi Glenn, Yes, thanks. Using more accurate moon metrics osgdem --geocentric --whole-globe -t moontex.tif -d moon_tiled.tif \ -l 10 \ --radius-equator 1737100 --radius-polar 1735970 \ -v 0.257 \ -o lunasph.ive I got the attached images. Regards, --A. On Tue, Sep 30, 2008 at 11:23 AM, Glenn Waldron [EMAIL PROTECTED] wrote: Alejandro, Try adding --radius-polar in addition to --radius-equator. Glenn ___ 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 mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] vpb: Spherical terrains?
On Wed, Oct 8, 2008 at 1:58 AM, Alejandro Aguilar Sierra [EMAIL PROTECTED] wrote: I think vpb should have a set of well documented and flexible parameters that allow to use it for any planetary terrain, otherwise we will need --geoecentric-mars, --geoecentric-mercury, etc. I don't think anyone of us would disagree with this sentiment. Especially if you are willing to help with this effort :-) By the way, which algorithms is using vpb to deal with LOD and terrain paging? It's basically just a quad tree, and some threading. The pole looks weird. Is there any way to fix it? Poles are little bit awkward to fix with the simple quad tree approach used by the OSG (and many other whole whole techniques.) We could certainly do more to try and alleviate this problem by better sampling around the poles when building the terrain. Anisotropic filtering can help at runtime. Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] vpb: Spherical terrains?
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Robert Osfield The pole looks weird. Is there any way to fix it? Poles are little bit awkward to fix with the simple quad tree approach used by the OSG (and many other whole whole techniques.) We could certainly do more to try and alleviate this problem by better sampling around the poles when building the terrain. Anisotropic filtering can help at runtime. Robert. The problem is that the projection is not even close to linear at the poles, meaning that the mipmapping hardware does the wrong thing, anisotropic filtering may help, but you'll still get the weirdness, it will just be reduced. This is a limitation in using lat/long style texture projections as it means the pole is represented by a line in texture space rather than a point. For the earth this is not normally a problem because few people go to the poles and they are usually covered in ice and snow ( so have a very dull and uniform appearance ). For other planetary bodies in the solar system, sometimes the poles are very interesting though. In the past I've has success using a Azimuthal Equidistant projection ( http://en.wikipedia.org/wiki/Azimuthal_equidistant_projection ) for each hemisphere to bypass this problem for rendering planetary bodies. The problem with this is that the projection becomes less linear the further away from the projection points ( east and west 'poles' in my case ). I also know that other people have had success with a polyhedron based projection. The simplest would be using a cubemap style projection. These have the advantage that they use a number of linear projections, so any distortion could be corrected by use of the 4th texture coordinate. Colin. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] vpb: Spherical terrains?
On Wed, Oct 8, 2008 at 3:44 AM, Robert Osfield [EMAIL PROTECTED] wrote: I think vpb should have a set of well documented and flexible parameters that allow to use it for any planetary terrain, otherwise we will need --geoecentric-mars, --geoecentric-mercury, etc. I don't think anyone of us would disagree with this sentiment. Especially if you are willing to help with this effort :-) Sure. Where should I start? Poles are little bit awkward to fix with the simple quad tree approach used by the OSG (and many other whole whole techniques.) We could certainly do more to try and alleviate this problem by better sampling around the poles when building the terrain. Anisotropic filtering can help at runtime. As Colin Middleton points out, that filtering will not be enough. I am willing to help on implementing the polyhedron based projection. I know of a few papers and references, including and adaptation of the ROAM algorithm to the cube projection. But since I am a newbie as osg (and vpb) developer I just need some directions and links. Regards, -- A. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] vpb: Spherical terrains?
Hi Alejandro, On Wed, Oct 8, 2008 at 2:49 PM, Alejandro Aguilar Sierra [EMAIL PROTECTED] wrote: Sure. Where should I start? The wiki... ;-) I will actually be doing docs on VTP in the next month so it probably worth waiting till I get this done then adding to bits that could deserve with more info. Poles are little bit awkward to fix with the simple quad tree approach used by the OSG (and many other whole whole techniques.) We could certainly do more to try and alleviate this problem by better sampling around the poles when building the terrain. Anisotropic filtering can help at runtime. As Colin Middleton points out, that filtering will not be enough. I am willing to help on implementing the polyhedron based projection. I know of a few papers and references, including and adaptation of the ROAM algorithm to the cube projection. But since I am a newbie as osg (and vpb) developer I just need some directions and links. Using a substantially different terrain division algorithm would require a major rewrite of VirtualPlanetBuilder, and it's not just a little bit of code that is straight forward to learn and easy to tinker with. The papers you might come across we just scratch the surfaces on the actual details required for implementation of highly scalable terrain generation. VPB can handle terrabytes of source and output data, there's only a few pieces software in the world that currently does this for terrain, and VPB is the only open sourced one I'm aware of. Handling terrabytes of moziaced multi-resolution data is the hard part that few bits of software handle. So... jumping to a new scheme is not easy at all, and the papers won't help you, and rather than look for grand all encompassing solutions look for smaller solutions, and there are some such as changing the sample dimensions on polar tiles that will actually solve most of the problem with massive changes or long learning curves. Robert. ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] vpb: Spherical terrains?
Hi Robert: It's not my intention to jump into a new scheme, but using current vpb algorithms, it should be possible to do a few adaptations to better deal with spherical terrains, that's all. Ok I will wait until there is a minimal set of documents about vpb at the wiki, next month. Regards, -- A. On Wed, Oct 8, 2008 at 9:15 AM, Robert Osfield [EMAIL PROTECTED] wrote: Hi Alejandro, On Wed, Oct 8, 2008 at 2:49 PM, Alejandro Aguilar Sierra [EMAIL PROTECTED] wrote: Sure. Where should I start? The wiki... ;-) I will actually be doing docs on VTP in the next month so it probably worth waiting till I get this done then adding to bits that could deserve with more info. Poles are little bit awkward to fix with the simple quad tree approach used by the OSG (and many other whole whole techniques.) We could certainly do more to try and alleviate this problem by better sampling around the poles when building the terrain. Anisotropic filtering can help at runtime. As Colin Middleton points out, that filtering will not be enough. I am willing to help on implementing the polyhedron based projection. I know of a few papers and references, including and adaptation of the ROAM algorithm to the cube projection. But since I am a newbie as osg (and vpb) developer I just need some directions and links. Using a substantially different terrain division algorithm would require a major rewrite of VirtualPlanetBuilder, and it's not just a little bit of code that is straight forward to learn and easy to tinker with. The papers you might come across we just scratch the surfaces on the actual details required for implementation of highly scalable terrain generation. VPB can handle terrabytes of source and output data, there's only a few pieces software in the world that currently does this for terrain, and VPB is the only open sourced one I'm aware of. Handling terrabytes of moziaced multi-resolution data is the hard part that few bits of software handle. So... jumping to a new scheme is not easy at all, and the papers won't help you, and rather than look for grand all encompassing solutions look for smaller solutions, and there are some such as changing the sample dimensions on polar tiles that will actually solve most of the problem with massive changes or long learning curves. Robert. ___ 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: Spherical terrains?
Hi Alejandro, VPB developed focused on earth data, so --geocentric automatically sets up the earth sizes, so I guess this is probably where things go adrift. I haven't personally worked with non earth data yet, but it should be possible to add better accounting of non earth data, although I can't say without reviewing the data more closely how transparently we can archive this. Perhaps a --geoecentric-moon etc could be done as a fallback if it can't be detected for automatically, or as you've done just point users to manually specifying the radius-polar and radius-equator. Robert. On Wed, Oct 1, 2008 at 7:37 AM, Alejandro Aguilar Sierra [EMAIL PROTECTED] wrote: Hi Glenn, Yes, thanks. Using more accurate moon metrics osgdem --geocentric --whole-globe -t moontex.tif -d moon_tiled.tif \ -l 10 \ --radius-equator 1737100 --radius-polar 1735970 \ -v 0.257 \ -o lunasph.ive I got the attached images. Regards, --A. On Tue, Sep 30, 2008 at 11:23 AM, Glenn Waldron [EMAIL PROTECTED] wrote: Alejandro, Try adding --radius-polar in addition to --radius-equator. Glenn ___ 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: Spherical terrains?
Hi Robert, Alejandro, I haven't personally worked with non earth data yet, but it should be possible to add better accounting of non earth data, although I can't say without reviewing the data more closely how transparently we can archive this. Perhaps a --geoecentric-moon etc could be done as a fallback if it can't be detected for automatically, or as you've done just point users to manually specifying the radius-polar and radius-equator. Sorry for hijacking this thread, but I was wondering about this lately... Eventually, I would like to make a small game in my spare time where I would like to use VPB to generate some (fictional) planets for me, and I was wondering if that was possible. It seems it is... I assume radius-polar is the radius from the center of the planet to one of the poles, so perpendicular to radius-equator, is that right? So the only possible shape is an ellipsoid (with a sphere being the case where both radii are equal). Another question I had was what tools I would use to generate the height maps. They would need to be in some projection similar to Earth maps I would guess (Mercator?) and then, VPB would map that with the radii that I specified automatically? Does anyone have suggestions of tools that would allow me to handle such large and potentially detailed height maps while having artistic control over shape of the land? Anyways, I was just toying with the idea, not actually doing anything yet, but the possibilities seem interesting. Thanks, J-S -- __ Jean-Sebastien Guay[EMAIL PROTECTED] 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] vpb: Spherical terrains?
Alejandro, Try adding --radius-polar in addition to --radius-equator. Glenn On Tue, Sep 30, 2008 at 12:13 PM, Alejandro Aguilar Sierra [EMAIL PROTECTED] wrote: Hi Robert, Actually the original data has all the information needed, I gess. It's the height map of Earth's Moon, taken from http://pubs.usgs.gov/of/2006/1367/ $ gdalinfo ULCN2005_lpo.txt Driver: AAIGrid/Arc/Info ASCII Grid Files: ULCN2005_lpo.txt Size is 5760, 2880 Coordinate System is `' Origin = (-180.000,90.000) Pixel Size = (0.0625000,-0.0625000) Corner Coordinates: Upper Left (-180.000, 90.000) Lower Left (-180.000, -90.000) Upper Right ( 180.000, 90.000) Lower Right ( 180.000, -90.000) Center ( 0.000, 0.000) Band 1 Block=5760x1 Type=Int16, ColorInterp=Undefined NoData Value=-32768 I converted this file to GeoTiff gdal_translate -of GTiff -co TILED=YES ULCN2005_lpo.txt moon_tiled.tif Then applied osgdem with a previous false color texture I had generated. osgdem --geocentric --whole-globe -t moonrbw2_tex.tif -d moon_tiled.tif \ -l 5 \ --radius-equator 1735000 \ -v 0.60 \ -o lunarsph.ive errlog2 The result is rather weird (attached). The texture image in this test is smaller than the DEM file, just 1024x512 (attached, level 2). What am I doing wrong? Thanks in advance. -- A. On Mon, Sep 29, 2008 at 9:32 AM, Robert Osfield [EMAIL PROTECTED] wrote: Hi Alejandro, The GDAL error that is produced suggests that you are trying to apply a transform to the data when the data doesn't have an geocentric infomation associated with it - which boils down to it can't transform data when it doesn't know what coordinate system it's starting off in. You need to use imagery/dems with coordinates system or apply them manually. Robert. On Mon, Sep 29, 2008 at 3:00 PM, Alejandro Aguilar Sierra [EMAIL PROTECTED] wrote: Hello: As recommended in this forum, I installed both osg and vpb from svn and I was able to reproduce the example with the Punget terrain. Now I want to try it with planets, starting with the moon. I started trying with these parameters --geocentric --spherical --radius-equator 1735000 but I get this error: ERROR 1: Unable to compute a transformation between pixel/line and georeferenced coordinates for moon_heigth.tif. There is no affine transformation and no GCPs. I assume I could add that transformation in a world file or creating a geotiff file, but I am not sure how to do that. I also assume that the bluemarble options only works at Earth scale, as in this example: http://www.andesengineering.com/BlueMarbleViewer/ Sorry if these are faqs, I am a newvbie and there is not much documentation about this subject. I will appreciate any advice. Regards, -- Alejandro Sierra ___ 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 mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org -- Glenn Waldron : Pelican Mapping : http://pelicanmapping.com : +1.703.652.4791 ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
[osg-users] vpb: Spherical terrains?
Hello: As recommended in this forum, I installed both osg and vpb from svn and I was able to reproduce the example with the Punget terrain. Now I want to try it with planets, starting with the moon. I started trying with these parameters --geocentric --spherical --radius-equator 1735000 but I get this error: ERROR 1: Unable to compute a transformation between pixel/line and georeferenced coordinates for moon_heigth.tif. There is no affine transformation and no GCPs. I assume I could add that transformation in a world file or creating a geotiff file, but I am not sure how to do that. I also assume that the bluemarble options only works at Earth scale, as in this example: http://www.andesengineering.com/BlueMarbleViewer/ Sorry if these are faqs, I am a newvbie and there is not much documentation about this subject. I will appreciate any advice. Regards, -- Alejandro Sierra ___ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
Re: [osg-users] vpb: Spherical terrains?
Hi Alejandro, The GDAL error that is produced suggests that you are trying to apply a transform to the data when the data doesn't have an geocentric infomation associated with it - which boils down to it can't transform data when it doesn't know what coordinate system it's starting off in. You need to use imagery/dems with coordinates system or apply them manually. Robert. On Mon, Sep 29, 2008 at 3:00 PM, Alejandro Aguilar Sierra [EMAIL PROTECTED] wrote: Hello: As recommended in this forum, I installed both osg and vpb from svn and I was able to reproduce the example with the Punget terrain. Now I want to try it with planets, starting with the moon. I started trying with these parameters --geocentric --spherical --radius-equator 1735000 but I get this error: ERROR 1: Unable to compute a transformation between pixel/line and georeferenced coordinates for moon_heigth.tif. There is no affine transformation and no GCPs. I assume I could add that transformation in a world file or creating a geotiff file, but I am not sure how to do that. I also assume that the bluemarble options only works at Earth scale, as in this example: http://www.andesengineering.com/BlueMarbleViewer/ Sorry if these are faqs, I am a newvbie and there is not much documentation about this subject. I will appreciate any advice. Regards, -- Alejandro Sierra ___ 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