[gdal-dev] Question about create/createCopy drivers support

Frank Warmerdam warmerdam at pobox.com
Fri Jan 4 11:00:17 EST 2008


Daniele Romagnoli wrote:
> Hi list,
> I have a very trivial question for you. (please dont kill me :-P)
> Why some drivers only support createCopy method?
> I talk about, as an instance, the JP2KAK driver. Why it does not provide 
> the create method?

Daniele,

In order to support Create() a driver must support randomly ordered writing,
including situations like writing the imagery and then the projection, writing
some areas of imagery multiple times.  Writing bottom to top. etc.

For some formats this is not much of a problem.  For other formats this is
essentially impossible without collecting everything in some sort of temporary
file and writing it all out to the real file on close.

In the case of JPEG2000 data files, they must essentially be written top to
bottom in one pass, and once the georeferencing box has been written it is
hard to update it.

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 OSGeo, http://osgeo.org



More information about the gdal-dev mailing list