| 7 | == Rendering Lines Over Dateline == |
| 8 | |
| 9 | When lines are read from a projected data source, and reprojected into geographic coordinates for rendering it is common the have lines drawn across the width of the map. For instance, if the world is rendered, Siberia line segments may stretch across the map from -180 to +180 since line segments that cross the dateline will suddenly go from near -180 to near +180. This is discussed in #15. |
| 10 | |
| 11 | A solution has been put in place to attempt to do special processing when reprojecting vectors from projected coordinates to geographic coordinates (msProjectShape()). Basically, preference is given to rewrapping shapes so that they cross the dateline rather than warping to the other side of the world. In the case of a small linestring or polygon crossing the dateline it may end up with extents like -185 to -175 longitude rather than a bit of stuff between -175 and -180 and a bit of stuff between 175 and 180. This logic is found in msTestNeedWrap() and msProjectShapeLine() in mapproject.c. |
| 12 | |
| 13 | In the case of world spanning polygons this logic can sometimes mis-fire resulting in features getting stretched over more than 360 degrees. |
| 14 | |
| 15 | == Some Related Tickets == |
| 16 | |
| 17 | * #15 - dateline wrapping of drawn vectors |
| 18 | * #25 - BBOX that crosses the dateline |
| 19 | * #723 - Three reprojection bugs |
| 20 | * #740 - WMS client requests with non-square pixels |
| 21 | * #3111 - WMS Reprojection misses stuff near the dateline |