OpenSceneGraph Forum Forum Index OpenSceneGraph Forum
Official forum which mirrors the existent OSG mailing lists. Messages posted here are forwarded to the mailing list and vice versa.
 
   FAQFAQ    SearchSearch    MemberlistMemberlist    RulesRules    UsergroupsUsergroups    RegisterRegister 
 Mail2Forum SettingsMail2Forum Settings  ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
   AlbumAlbum  OpenSceneGraph IRC ChatOpenSceneGraph IRC Chat   SmartFeedSmartFeed 

How to? - gdal_translate .asc to geoTiff and osgdem to flat terrain


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> VirtualPlanetBuilder [vpb]
View previous topic :: View next topic  
Author Message
tim (tim paige)
User


Joined: 25 Feb 2009
Posts: 31
Location: San Diego

PostPosted: Thu Apr 07, 2011 12:05 am    Post subject:
How to? - gdal_translate .asc to geoTiff and osgdem to flat terrain
Reply with quote

Hi,

My starting file of interest is an ASC file with the following gdalinfo

Driver: AAIGrid/Arc/Info ASCII Grid
Files: sd_1_3_110805.asc
Size is 11880, 9720
Coordinate System is `'
Origin = (-117.900000000000010,33.399999999999991)
Pixel Size = (0.000092592592593,-0.000092592592593)
Corner Coordinates:
Upper Left (-117.9000000, 33.4000000)
Lower Left (-117.9000000, 32.5000000)
Upper Right (-116.8000000, 33.4000000)
Lower Right (-116.8000000, 32.5000000)
Center (-117.3500000, 32.9500000)
Band 1 Block=11880x1 Type=Float32, ColorInterp=Undefined
NoData Value=-9999

Then I would translate to a tiff
Code:
gdal_translate sd_1_3_110805.asc lj.tif


Then I used osgdem
Code:
osgdemd --cs "+proj=latlong +datum=WGS84" -d sd_1_3_110805.asc -l 6 -v 2 -o lj.ive


I would like to translate that file to one suitable for creating a flat terrain for use with osgOcean. Doing anything less than specifying geocentric yields a nice terrain database that is 180 degrees out, so I give up on that.

My desire is to take my interesting combination of bathymetric and topographic elevation data (which I can view geocentrically correctly) and make a flat terrain which will still allow me to get lat lon and alt usage. I would like to be able to "fly" above and below my section of ocean which I hope to place in the area of interest while moving around.

In this "ocean centric" world, I have had problems finding my terrain with reference to my ocean and model.

Ongoing questions...
1. what may I use for gdal_translate to get in shape for flat terrain?
2. could I do it all with osgdem?
3. why is my conversion "backwards" unless I specify geocentric?
4. If I use a geocentric model... what would be appropriate to use in order to get my landmass in a position suitable for my fixed ocean?
5. Does a getBoundingSpere on a geocentric terrain model return the center of the earth? Or does it return the center of the peaks and valleys of the model? (either way I have been unsuccessful in moving mountains such that they are visible with my ocean)

I am using "bathymetryDEM" located at...
[url] http://seafloor.csumb.edu/SFMLwebDATA_s.htm#LJ [/url]
Thank you!

Many cheers,
tim[/code]
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> VirtualPlanetBuilder [vpb] All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum

Similar Topics
Topic Author Forum Replies Posted
No new posts Osgdem created terrains not displayin... D.J. Caldwell General 3 Wed Oct 24, 2018 7:32 pm View latest post
No new posts How to set the transparency for one o... adrianj General 0 Tue Feb 06, 2018 3:19 am View latest post
No new posts How to get height above terrain in la... smp General 2 Thu Dec 28, 2017 12:25 pm View latest post
No new posts Terrain Deformation as per Road Profile umesh VirtualPlanetBuilder [vpb] 0 Mon Dec 04, 2017 4:44 pm View latest post
No new posts Camera collision with terrain ht11 General [3rdparty] 0 Fri Oct 13, 2017 7:34 am View latest post


Board Security Anti Bot Question MOD - phpBB MOD against Spam Bots
Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP