[gdal-dev] Get Image Endianness

Alejandro Mostovoi ahmostovoi at gmail.com
Wed Feb 3 13:15:00 EST 2010


Thanks, the read of the image is resolved.
But my app shows information about an open image, one data of that
information is (or will be) the endianness of the image, I mean, the format
of the image shouldn't be significant.
I need some method o struct that return the endianness of the image.

Thanks again.
Alejandro.


On 3 February 2010 15:03, Frank Warmerdam <warmerdam at pobox.com> wrote:

> Alejandro Mostovoi wrote:
>
>> Hi All,
>>
>> I need to know the image endianness.
>> I search for in api's help and list but can't find anything.
>>
>> Any idea?
>>
>
> Alejandro,
>
> As mentioned by others the on-disk endianess varies by format and sometimes
> by file in a format.  The endianess of data returned by the GDAL API is
> always
> local machine order. So if you read a big endian file on a little endian
> system, the RasterIO() calls will return the data to the application in
> little
> endian byte order.
>
> Best regards,
> --
>
> ---------------------------------------+--------------------------------------
> I set the clouds in motion - turn up   | Frank Warmerdam,
> warmerdam at pobox.com
> light and sound - activate the windows | http://pobox.com/~warmerdam<http://pobox.com/%7Ewarmerdam>
> and watch the world go round - Rush    | Geospatial Programmer for Rent
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20100203/850306b3/attachment.html


More information about the gdal-dev mailing list