[Gdal-dev] Using SetSpatialFilter() on MapInfo .tab files

Tamas Szekeres szekerest at gmail.com
Wed Nov 8 06:00:12 EST 2006

AFAIK you should set a rectangle area as a spatial filter, and you
will get the features falling onto this area.


2006/11/8, Mir Hassan Ali <mirhassanali at gmail.com>:
> Hi,
> I am trying to set Spatial Filter on a MapInfo tab file (using the C#
> wrapper for GDAL). I am working with Projected Coordinate System and want to
> set the filter for the point defined by coordinates
> 393544.0 377079.0
> I am using the following code to set the filter
> layer.SetSpatialFilter(new Geometry(ogr.wkbUnknown , "POINT(393544.0
> 377079.0)", 0, null , null));
> But after settign the filter I get feature count = 0 whereas it should be 2
> for the particular point.
> I am getting this pair of coordinates from a LLPG(Local land and property
> gazetteer). Do I need to transform these coordinates in some way before
> setting the filter or is there something else I am doing wrong?
> Please will someone guide me regarding this problem.
> Thanks and Kind Regards
> Mir Hassan Ali
> _______________________________________________
> Gdal-dev mailing list
> Gdal-dev at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/gdal-dev

More information about the Gdal-dev mailing list