[Gdal-dev] tileindex location field: width 80

Frank Warmerdam fwarmerdam at gmail.com
Fri Jul 15 11:03:57 EDT 2005


On 7/14/05, Bart van den Eijnden <BEN at syncera-itsolutions.nl> wrote:
> Hi list,
> 
> normally I always use absolute paths in a tileindex when using Mapserver.
> 
> Why is the width the location field created by ogrtindex only 80? This is not long enough for my absolute paths in some cases ....
> 
> Is there a way to overrule it or do I need to manually adapt the tileindex afterwards?

Bart,

There is no special reason why the width is 80.  I have upped it to 200. 
One workaround would be to pre-create the index file using other
tools,and then use ogrtindex to append to it.  But if you can build from
source, doing so from CVS should resolve the issue.

Or changing your local tree to have the following in ogrtindex.cpp:

        if( poDstDS->GetLayerCount() == 0 )
        {
            OGRFieldDefn oLocation( pszTileIndexField, OFTString );
            
            oLocation.SetWidth( 200 );                       // new line

            poDstLayer = poDstDS->CreateLayer( "tileindex" );
            poDstLayer->CreateField( &oLocation, OFTString );
        }


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    | Geospatial Programmer for Rent



More information about the Gdal-dev mailing list