[gdal-dev] Instructions for a new writing driver?
Even Rouault
even.rouault at spatialys.com
Wed Jul 5 04:59:19 PDT 2023
(resending to list)
The CSV driver is actually not that simple to follow since it has tricks
to support updates through the OGREditableLayer mechanism. The GMT one
(ogr/ogrsf_frmts/gmt) might be a better start for a creation & append
only driver. But basically, the only common thing with your own code
will be the fact that you have to implement the 2 virtual methods of
interest: OGRLayer::CreateField() ,d OGRLayer::ICreateFeature() and
declare a few capabilities in OGRLayer::TestCapability()
Unless you want to implement update capabilities (if the format allows
it, which is generally not the case for a text based format), it might
be simpler to have 2 distinct OGRLayer sub-classes for read-only and
write-only operations.
Even
Le 05/07/2023 à 13:21, Laurențiu Nicola via gdal-dev a écrit :
> Hi,
>
> I think your best bet would be to take inspiration from an existing
> driver, like the CSV one (which shouldn't be too different from the
> hypothetical SPF driver in the docs).
>
> Laurentiu
>
> On Wed, Jul 5, 2023, at 14:17, Abel Pau wrote:
>>
>> Hi, following instructions about creating a new driver I found that
>>
>> https://gdal.org/tutorials/vector_driver_tut.html
>>
>>
>>
>> But I need to create a driver that can also write from any vector
>> it’s own format.
>>
>> So, the inverse sense of the html I found.
>>
>>
>> There is any other place I can follow any instructions to fill all
>> function classes to create this part of the driver (the one that
>> writes it’s own format)?
>>
>> Thanks in advance!
>>
>>
>> _______________________________________________
>> gdal-dev mailing list
>> gdal-dev at lists.osgeo.org
>> https://lists.osgeo.org/mailman/listinfo/gdal-dev
>>
>
>
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/gdal-dev
--
http://www.spatialys.com
My software is free, but my time generally not.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20230705/074bc099/attachment.htm>
More information about the gdal-dev
mailing list