[Marble-devel] Re: altitude profiles

Niko Sams niko.sams at gmail.com
Mon Oct 4 21:45:05 CEST 2010


On Sun, Oct 3, 2010 at 19:51, Torsten Rahn <tackat at t-online.de> wrote:
> Am Sonntag, 3. Oktober 2010 16:54:16 schrieb Niko Sams:
>> On Mon, Sep 27, 2010 at 20:20, Bernhard Beschow
>>
>> <bbeschow at cs.tu-berlin.de> wrote:
>> > If you're looking for a conversion tool, there is gdal, which should be
>> > part of your distribution. To convert a single file, issue:
>> >
>> > gdal_translate -ot UInt16 -of GIF SRTM_fB03_n051e013.tif
>> > SRTM_fB03_n051e013.gif
>> >
>> > Note that converting to PNG didn't deliver correct results for me. Gdal
>> > also provides a retiling utility, which I didn't try, though.
>>
>> I successfully converted the file to a 16 Bit PNG (gif doesn't support 16
>> bit). But I can't read it with QImage as that doesn't support 16 Bit.
>> So I think using TileLoader and TextureTile is problematic - or do you
>> know a way
>> to solve this issue?
>
> IIRC originally we had TextureTile inheriting from AbstractTile (which is
> still in the source tree from what I can see). Nowadays just StackedTile
> inherits from AbstractTile.
>
> Maybe you could create a DemTile (DEM = DigitalElevationModel) that inherits
> from AbstractTile and have the TileLoader deal with AbstractTiles?

Then I need a different format, I would prefer using QImage for reading.

The data could be encoded not using grayscale but a standard ARGB Image,
that way I could work with TextureTile and QImage.

Niko


More information about the Marble-devel mailing list