py-gdalogr-cookbook icon indicating copy to clipboard operation
py-gdalogr-cookbook copied to clipboard

Typo. in world2pixel()?

Open tbnorth opened this issue 8 years ago • 0 comments

At clip-a-geotiff-with-shapefile

  pixel = int((x - ulX) / xDist)
  line = int((ulY - y) / xDist)

Shouldn't that second xDist be yDist? Of course they're almost always equal, so the above will usually work.

Thanks for the great resource.

tbnorth avatar Jul 27 '16 20:07 tbnorth