[gdal-dev] Re: randyqiuxy@hotmail.com

Yilmaz Arslanoglu yilmaz.arslanoglu at gmail.com
Sun Oct 11 09:57:14 EDT 2009


I'm very sorry, I made a wrong copy-paste in the subject field I think :)

On Sun, Oct 11, 2009 at 3:53 PM, Yilmaz Arslanoglu
<yilmaz.arslanoglu at gmail.com> wrote:
> Hi Randy;
>
> Did you check that you set the GDAL_DATA configuration correctly?
>
> If it is the case, then here is the previous answer from Frank:
>
> "This might be accomplished by setting the GDAL_DATA configuration
> variable either via the environment or the CPLSetConfigOption()
> function.  Were you using ogrinfo from an environment like
> OSGeo4W or FWTools that sets up the environment carefully?"
>
> And my question was:
> ---------------------------------
>
> Hello everybody;
>
> First of all, I would like to say that I am quite new in S-57 format
> and GDAL/OGR libraries.
>
> As a starting point, I downloaded the source codes and built the whole
> GDAL library on my computer,
> using the "nmake" of Visual Studio 2008.
>
> Now:
>
> poDS = OGRSFDriverRegistrar::Open( "US5LA24M.000", FALSE );
> for (int i = 0; i < poDS->GetLayerCount(); i++)
>   printf("layer %d: %s\n", i, poDS->GetLayer(i)->GetLayerDefn()->GetName());
>
> When I try to list the layer names of a datasource with the code snippet above,
> I get the following result:
>
> layer 0: DSID
> layer 1: Point
> layer 2: Line
> layer 3: Area
> layer 4: Meta
>
> However, the utility application "ogrinfo" gives a quite different
> result as follows:
> (when run with command  "ogrinfo US5LA24M.000" )
>
> 1: DSID (None)
> 2: ACHARE
> 3: BCNLAT (Point)
> 4: BCNSPP (Point)
> 5: BUISGL
> ...
> ...
> ...
> 49: M_QUAL (Polygon)
> 50: C_ASSO (None)
>
> I examined the source code of "ogrinfo" under the "gdal-1.6.2\apps\"
> directory, however,
> I could not find a difference in terms of listing the layers in the dataset.
>
> What could be the problem, is there a point that I'm missing?
>


More information about the gdal-dev mailing list