[gdal-dev] RasterIO Writing Packed RGB data

Martin Chapman chapmanm at pixia.com
Thu Aug 6 18:08:42 EDT 2009

Answered my on question: It is:


outputDataset->RasterIO(GF_Write, 0, 0, width, height, buffer, width,
height, GDT_Byte, numBands, NULL, 3, 3 * width, 1);





From: gdal-dev-bounces at lists.osgeo.org
[mailto:gdal-dev-bounces at lists.osgeo.org] On Behalf Of Martin Chapman
Sent: Thursday, August 06, 2009 3:51 PM
To: gdal-dev at lists.osgeo.org
Subject: [gdal-dev] RasterIO Writing Packed RGB data


I'm using the RasterIO method on the GDALDataset object and trying to write
a buffer where the pixels are packed as RGBRGBRGB etc. and having trouble
figuring out what parameters to pass as the pixel, line and band space.  My
desired output is a 3 band geotiff and the source and dest datatype is byte.
Can anyone point me the write direction on how to use those parameters in
this case?


Thanks in advance,


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20090806/a825dd9a/attachment.html

More information about the gdal-dev mailing list