jumpinjackie / mapguide-rest

REST Extension for MapGuide Open Source
GNU Lesser General Public License v2.1
26 stars 14 forks source link

Generate PNG by sending Lower Left x,y and Upper right x, y #177

Open saivaradula opened 6 years ago

saivaradula commented 6 years ago

Hello Jackie:

The below URL generates PNG image with x, y GET http://localhost/mapguide/rest/library/Samples/Sheboygan/Maps/Sheboygan.MapDefinition/image.png?x=-87.73&y=43.74&scale=12000&width=1024&height=768&dpi=96

We would like to generate a png image within Lower Left x,y and Upper right x, y for example

GET http://localhost/mapguide/rest/library/Samples/Sheboygan/Maps/Sheboygan.MapDefinition/image.png?x1=-87.73&y1=43.74&x2=-86.73&y2=45.74&scale=12000&width=1024&height=768&dpi=96

Please modify the request parameter to generate png within bounding box.

Thanks,

jumpinjackie commented 6 years ago

The reason we ask for x and y instead of a bounding box is because specifying a bounding box would clash with one of the other existing display parameters. If you specify a bounding box along with scale, width, height and dpi then one of these 4 parameters has to give way.

We could modify this operation to allow one of the following:

saivaradula commented 6 years ago

So, the second option would be a good one that resolves the issue. if possible can you please let me know how request URL would be with the second option.

saivaradula commented 6 years ago

Jackie:

I think the second option will give the best solution for the image zooming.