[postgis-users] Proposed SQL interface for PGRaster

Mark Cave-Ayland mark.cave-ayland at ilande.co.uk
Wed Dec 6 04:53:59 PST 2006


Hi Markus,


On Wed, 2006-12-06 at 12:40 +0100, Markus Schaber wrote:

> I think it's better to always store in the current machine endianness,
> for performance reasons.

I agree, that would definitely give the best performance.

> Only the binary input/output functions need to either specify the
> endianness via a flag, or always use network byte order.

That would be one solution, but I think Steve is planning to output just
the raw JPEG/TIFF/whatever binary image; from section 1 of the proposal:
"PGRaster data shall always be input and output in one of the supported
image formats, without additional headers, wrapping protocols, or other
auxilliary data".

A quick scan of the GDAL API hints that GDAL itself converts between
file/native data types when returning raster bands as C arrays. So if
pgraster were to link directly against GDAL, this suggests that it
should be possible to hide endian-ness from the pgraster implementation
which should solve the problem entirely.


Kind regards,

Mark.





More information about the postgis-users mailing list