[Gdal-dev] Complex Data Types

Frank Warmerdam warmerdam at pobox.com
Tue Aug 22 15:24:20 EDT 2006


Matt Hanson wrote:
> I'm a little confused with regard to GDAL's handling of complex data 
> types.  As there is no built in complex types for C++ what is RasterIO 
> expecting as a buffer type when using the GDT_C* data types?   Would it 
> simply be a pointer of twice the normal length?

Matt,

Essentially the complex data types are passed around as pairs of the
basic data type.  So an array of GDT_CInt16 would be an array of GInt16's
but with two values (real followed by imaginary) for each value.

So, the answer to your question is "yes".

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
and watch the world go round - Rush    | President OSGF, http://osgeo.org




More information about the Gdal-dev mailing list