[mapserver-dev] mapscript_csharp: Map display extend changes after changing a value

Tamas Szekeres szekerest at gmail.com
Mon Apr 6 10:17:25 EDT 2009


Could you provide a mapscript example to demonstrate the problem? I couldn't
follow exactly why did you require to "have a memory object to track the map
extent for seamless display" and how it was implemented. I should also
mention that the various operations (like mapObj.draw) may change the extent
internally to have the extent width and height to match with the image width
and height for instance.


Best regards,

Tamas



2009/4/6 prak <prakashtilhoo at astuntechnology.com>

>
> Hi,
>
> I am working on an application using c# and mapscript_csharp.
>
> I have the following functions:
>
> 1) DrawMap that just creates an image that binds to picturebox.
>
> 2) Zoom-In/Zoom-out/Recentre/Reset using:
>
> I also have a memory object to track the map extent for seamless display.
>
> oIOMapObj.zoomPoint(zoom, new pointObj(oIOMapObj.width/2,
> oIOMapObj.height/2,0,0), oIOMapObj.width, oIOMapObj.height,
> oIOMapObj.extent, null);
>
> I allow user to change any value for the mapObj and after each change I
> draw the map by calling DrawMap .
>
> Before calling the DrawMap, I apply the extent to the Map.
>
> As long as I am changing values, the Map displayed works prefectly.
>
> However, after calling  Zoom-In/Zoom-out/Recentre/Reset and then DrawMap,
> the display does show a 'zoomed' map.
>
> But if I now make a value change, e.g. partials, and then call the DrawMap,
> after setting the extent appropriately, after the geoimageObj =
> oIOMapObj.draw(), my extent gets changed so that the displayed map gests
> different displayed extent.
>
> i.e the MapExtent values gets changed after geoimageObj = oIOMapObj.draw(),
> whenever there has been a previous oIOMapObj.zoomPoint(zoom, new
> pointObj(oIOMapObj.width/2, oIOMapObj.height/2,0,0), oIOMapObj.width,
> oIOMapObj.height, oIOMapObj.extent, null);
>
> And the displayed maps gets another extent, breaking the continuous from
> previous one.
>
> Grateful if anyone could please advise on correction.
>
> Thank you VERY MUCH !!
>
>
>
> --
> View this message in context:
> http://n2.nabble.com/mapscript_csharp%3A-Map-display-extend-changes-after-changing-a-value-tp2592794p2592794.html
> Sent from the Mapserver - Dev mailing list archive at Nabble.com.
>
> _______________________________________________
> mapserver-dev mailing list
> mapserver-dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20090406/b27c72cd/attachment.html


More information about the mapserver-dev mailing list