User Tools

Site Tools


map_suite_wpf_desktop_edition_projection_samples

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
map_suite_wpf_desktop_edition_projection_samples [2015/09/08 02:13]
admin
map_suite_wpf_desktop_edition_projection_samples [2017/03/17 02:11] (current)
tgwikiupdate
Line 1: Line 1:
-====== Map Suite Wpf Desktop Edition Projection Samples ======+====== ​ Map Suite Wpf Desktop Edition Projection Samples ​ ======
  
 +{{section>​upgrade_map_suite_to_10.0}}
  
- 
-==== Custom Parameters Projection ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Custom Parameters Projection ​ ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Custom Paramters Projection.jpg?​300x180}} {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Custom Paramters Projection.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WpfDesktopEditionSample_CustomParametersProjection_CS_110124.zip|View Source]] ​ +<div content>​ 
-{{:File:​WpfDesktopEditionSample_CustomParametersProjection_CS_110124.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WpfDesktopEditionSample_CustomParametersProjection_CS_110124.zip|View Source]] 
 +{{filehistory:​WpfDesktopEditionSample_CustomParametersProjection_CS_110124.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]] [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]]
- +\\ 
- ​Samples Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Wpf Desktop Edition|Wpf \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: Desktop \\  Web \\  Silverlight \\  Services \\  Wpf \\ ]]//   ​| ​In today’s Wpf project, we learn more about projection and how to handle a special case where the projection information in the PRJ file of a shapefile is not found as an EPSG or ESRI code in the spatial reference web site (www.spatial-reference.org). The strategy in this case is to build a proj4 string based on the parameters found in the PRJ file. Note that you must pay special attention to the false easting or northing parameters as they are always expressed in meters even if the projection is in another unit such as feet. For this example, we show how to convert from the local projection in Lambert Conformal Conic with regional specific parameters to Geodetic (WGS84) to match the World Map Kit.+[[Map Suite Samples Alternate Languages | Need it in another language?]] 
 +</div> 
 +In today’s Wpf project, we learn more about projection and how to handle a special case where the projection information in the PRJ file of a shapefile is not found as an EPSG or ESRI code in the spatial reference web site (www.spatial-reference.org). The strategy in this case is to build a proj4 string based on the parameters found in the PRJ file. Note that you must pay special attention to the false easting or northing parameters as they are always expressed in meters even if the projection is in another unit such as feet. For this example, we show how to convert from the local projection in Lambert Conformal Conic with regional specific parameters to Geodetic (WGS84) to match the World Map Kit. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Custom Rotation Projection ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Custom Rotation Projection ​ ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Custom Rotation Projection.jpg?​300x180}} {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Custom Rotation Projection.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WpfDesktopEditionSample_CustomRotationProjection_CS_110127.zip|View Source]] ​ +<div content>​ 
-{{:File:​WpfDesktopEditionSample_CustomRotationProjection_CS_110127.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WpfDesktopEditionSample_CustomRotationProjection_CS_110127.zip|View Source]] 
 +{{filehistory:​WpfDesktopEditionSample_CustomRotationProjection_CS_110127.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]] [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]]
- +\\ 
- ​Samples Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Wpf Desktop Edition|Wpf \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: Desktop \\  Web \\  Silverlight \\  Services \\  Wpf \\ ]]//   ​| ​In today’s project, we show how to create your own projection class that allows projecting a layer from any internal projection to any external while doing a rotation at the same time. Having the capability to apply those two operations in one step may come handy if the original layer was created in a different projection with the north at an angle and you want to align it on the base map. This is a Wpf project and you will need references to MapSuiteCore.dll and WpfDesktopEdition.dll to run it.+[[Map Suite Samples Alternate Languages | Need it in another language?]] 
 +</div> 
 +In today’s project, we show how to create your own projection class that allows projecting a layer from any internal projection to any external while doing a rotation at the same time. Having the capability to apply those two operations in one step may come handy if the original layer was created in a different projection with the north at an angle and you want to align it on the base map. This is a Wpf project and you will need references to MapSuiteCore.dll and WpfDesktopEdition.dll to run it. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Distance Query on WrapDatelineMode ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Distance Query on WrapDatelineMode ​ ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Distance Query On Wrap Dateline Mode.jpg?​300x180}} {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Distance Query On Wrap Dateline Mode.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WpfDesktopEditionSample DistanceQueryOnWrapDatelineMode CS 110112.zip|View Source]] ​ +<div content>​ 
-{{:File:​WpfDesktopEditionSample DistanceQueryOnWrapDatelineMode CS 110112.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WpfDesktopEditionSample DistanceQueryOnWrapDatelineMode CS 110112.zip|View Source]] 
 +{{filehistory:​WpfDesktopEditionSample DistanceQueryOnWrapDatelineMode CS 110112.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: Wpf ]] [[Map Suite Samples Applies To|Applies To: Wpf ]]
- +\\ 
- CS 110112.zip|C#​ Download]]\\ \\ //[[Map Suite Samples Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Wpf Desktop Edition|Wpf \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: Wpf \\ ]]//   ​| ​In this Wpf sample is on the same theme as the previous sample WrapDatelineMode. Here we show how to take advantage of the projection class WrapDatelineProjection for doing spatial query when on a “virtual map”. From this spatial query example, the developer should understand how the same principle using the same projection class can be applied for other operations such as Spatial Queries, Identify etc. In order to run this sample, you will need the latest Dev Daily Build for Wpf with references to MapSuiteCore.dll and WpfDesktopEdition.dll.+[[Map Suite Samples Alternate Languages | Need it in another language?]] 
 +</div> 
 +In this Wpf sample is on the same theme as the previous sample WrapDatelineMode. Here we show how to take advantage of the projection class WrapDatelineProjection for doing spatial query when on a “virtual map”. From this spatial query example, the developer should understand how the same principle using the same projection class can be applied for other operations such as Spatial Queries, Identify etc. In order to run this sample, you will need the latest Dev Daily Build for Wpf with references to MapSuiteCore.dll and WpfDesktopEdition.dll. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Google Map to Geodetic ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Google Map to Geodetic ​ ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample GoogleMapToGeodetic.jpg?​300x180}} {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample GoogleMapToGeodetic.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WpfDesktopEditionSample GoogleMapToGeodetic CS 110420.zip|View Source]] ​ +<div content>​ 
-{{:File:​WpfDesktopEditionSample GoogleMapToGeodetic CS 110420.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WpfDesktopEditionSample GoogleMapToGeodetic CS 110420.zip|View Source]] 
 +{{filehistory:​WpfDesktopEditionSample GoogleMapToGeodetic CS 110420.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]] [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]]
- +\\ 
- ​Samples Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Wpf Desktop Edition|Wpf \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: Desktop \\  Web \\  Silverlight \\  Services \\  Wpf \\ ]]//   ​| ​In today’s Wpf project, we are showing a trick for getting the current extent of the map with Google Map as an image and displaying it on a map in decimal degrees unit. You may be in a situation where you want the details and accuracy of Google Map, especially the satellite view but want to have it displayed on your map in decimal degrees. In this sample, you will see how to get the Google Map image and create the accompanying world file for decimal degrees. Notice that we are realizing an affine transformation on the image to go to Geodetic as illustrated in the case 3  \\ http://​en.wikipedia.org/​wiki/​World_file#​Definition. You can also use this technique for any other background maps such as Bing Map, Open Street Map using Spherical Mercator. ​ \\ Warning: It is possible to use a world file with parameters for a Geodetic system from an image originally in Spherical Mercator due to some similar projection characteristics. Applying the same operation for other projections such as Lambert or UTM will not work.+[[Map Suite Samples Alternate Languages | Need it in another language?]] 
 +</div> 
 +In today’s Wpf project, we are showing a trick for getting the current extent of the map with Google Map as an image and displaying it on a map in decimal degrees unit. You may be in a situation where you want the details and accuracy of Google Map, especially the satellite view but want to have it displayed on your map in decimal degrees. In this sample, you will see how to get the Google Map image and create the accompanying world file for decimal degrees. Notice that we are realizing an affine transformation on the image to go to Geodetic as illustrated in the case 3  \\ http://​en.wikipedia.org/​wiki/​World_file#​Definition. You can also use this technique for any other background maps such as Bing Map, Open Street Map using Spherical Mercator. ​ \\ Warning: It is possible to use a world file with parameters for a Geodetic system from an image originally in Spherical Mercator due to some similar projection characteristics. Applying the same operation for other projections such as Lambert or UTM will not work. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Local Datum UTM ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Local Datum UTM  ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Local Datum UTM.jpg?​300x180}} {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Local Datum UTM.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WpfDesktopEditionSample LocalDatumUTM CS 110310.zip|View Source]] ​ +<div content>​ 
-{{:File:​WpfDesktopEditionSample LocalDatumUTM CS 110310.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WpfDesktopEditionSample LocalDatumUTM CS 110310.zip|View Source]] 
 +{{filehistory:​WpfDesktopEditionSample LocalDatumUTM CS 110310.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]] [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]]
- +\\ 
- ​Samples Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Wpf Desktop Edition|Wpf \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: Desktop \\  Web \\  Silverlight \\  Services \\  Wpf \\ ]]//   ​| ​The purpose of this Wpf sample is to get familiar with the concept of datum and datum shift in UTM and Geographic coordinates. Using local data, you might be required to apply datum transformation to your data to go from an old datum to a more recent datum. Here we are taking the example of Australia which went to change its datum (from AGD84 to GDA94) for its mapping purposes. We show how to apply the datum transformation in both the longitude/​latitude coordinate system and in the local UTM systems (AMG based on AGD84 and MGA based on GD94). See the code and read with attention the comments in the MouseMove event where all the projection logic is taken place. Notice that the correction is about 200 meters. Once you understand for the case of Australia, you will be able to apply the same principles for your own datums in UTM. For further reading: ​ \\ http://​www.cage.curtin.edu.au/​~will/​datum.html ​ \\ http://​www.usq.edu.au/​course/​material/​SVY3107/​lectures/​Breeze/​SVY2106amgmgafund/​index.html+[[Map Suite Samples Alternate Languages | Need it in another language?]] 
 +</div> 
 +The purpose of this Wpf sample is to get familiar with the concept of datum and datum shift in UTM and Geographic coordinates. Using local data, you might be required to apply datum transformation to your data to go from an old datum to a more recent datum. Here we are taking the example of Australia which went to change its datum (from AGD84 to GDA94) for its mapping purposes. We show how to apply the datum transformation in both the longitude/​latitude coordinate system and in the local UTM systems (AMG based on AGD84 and MGA based on GD94). See the code and read with attention the comments in the MouseMove event where all the projection logic is taken place. Notice that the correction is about 200 meters. Once you understand for the case of Australia, you will be able to apply the same principles for your own datums in UTM. For further reading: ​ \\ http://​www.cage.curtin.edu.au/​~will/​datum.html ​ \\ http://​www.usq.edu.au/​course/​material/​SVY3107/​lectures/​Breeze/​SVY2106amgmgafund/​index.html 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Projection by Analyzing Prj File ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Projection by Analyzing Prj File  ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​ProjectionReadingPrjFile.jpg?​300x180}} {{wpfedition:​codesamples:​ProjectionReadingPrjFile.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WebEditionSample_ProjectionReadingPrjFile_CS_110526.zip|View Source]] ​ +<div content>​ 
-{{:File:​WebEditionSample_ProjectionReadingPrjFile_CS_110526.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WebEditionSample_ProjectionReadingPrjFile_CS_110526.zip|View Source]] 
 +{{filehistory:​WebEditionSample_ProjectionReadingPrjFile_CS_110526.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]] [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]]
- +\\ 
- ​Samples Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Web Edition|Web \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: Desktop \\  Web \\  Silverlight \\  Services \\  Wpf \\ ]]//   ​| ​This project demonstrates how to use the new ConvertPrjToProj4 function to dynamically project shapefiles based on the contents of their .prj file.  This is one of the most requested new features of MapSuite 5.0. In the past, you were required to know the EPSG number or proj4 string in order to use the Proj4Projection class. ​ The new ConvertPrjToProj4 method used in this sample will determine a shapefile'​s projection at runtime by analyzing the contents of the .prj file.  This will enable the developer to build applications that allow users to dynamically add shapefiles with various projections and reproject them dynamically at runtime. ​ \\  \\  \\ Note:  There is also a ConvertProj4ToPrj function that can be used to build a .prj file from a proj4 string. ​ This is not covered in this sample, but could be useful in the future.+[[Map Suite Samples Alternate Languages | Need it in another language?]] 
 +</div> 
 +This project demonstrates how to use the new ConvertPrjToProj4 function to dynamically project shapefiles based on the contents of their .prj file.  This is one of the most requested new features of MapSuite 5.0. In the past, you were required to know the EPSG number or proj4 string in order to use the Proj4Projection class. ​ The new ConvertPrjToProj4 method used in this sample will determine a shapefile'​s projection at runtime by analyzing the contents of the .prj file.  This will enable the developer to build applications that allow users to dynamically add shapefiles with various projections and reproject them dynamically at runtime. ​ \\  \\  \\ Note:  There is also a ConvertProj4ToPrj function that can be used to build a .prj file from a proj4 string. ​ This is not covered in this sample, but could be useful in the future. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Projection Distance LineStyle ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Projection Distance LineStyle ​ ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Projection Distance LineStyle.jpg?​300x180}} {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Projection Distance LineStyle.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WebEditionSample_ProjectionDistanceLineStyle_CS_100902.zip|View Source]] ​ +<div content>​ 
-{{:File:​WebEditionSample_ProjectionDistanceLineStyle_CS_100902.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WebEditionSample_ProjectionDistanceLineStyle_CS_100902.zip|View Source]] 
 +{{filehistory:​WebEditionSample_ProjectionDistanceLineStyle_CS_100902.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]] [[Map Suite Samples Applies To|Applies To: Desktop \ Web \ Silverlight \ Services \ Wpf ]]
- +\\ 
- ​Samples Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Web Edition|Web \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: Desktop \\  Web \\  Silverlight \\  Services \\  Wpf \\ ]]//   ​| ​This Web project is similar to the project “Distance Line Style”. Here we show how to use a projection of choice different from the projection used on the map. For example, you may have your map using Google map as a background. Google map uses Spherical Mercator projection which is not ideal for distance measurements,​ that is why using a more appropriate projection for distance measurement such as State Plane will give more accurate results. The CustomDistanceLineStyle inheriting from LIneStyle has the logic built in to have the distance calculated based on a projection of choice instead of the projection of the map. \\   \\ As for the previous project “Distance Line Style”, you can see how the DrawCore function is overridden for the a specific need of style: displaying the distance label on each line segment making up a LineShape. In addition to the overriding of the DrawCore function, you will find useful some geometry functions such as GetPointOnLine to find the midpoint of a line segment and GetAngleFromTwoVertices to incline correctly the labels according to the orientation of each line segment. You will notice that the CustomDistanceLineStyle works for features made of LineShape and you will have to slightly modify to have it working with MultilineShape.+[[Map Suite Samples Alternate Languages | Need it in another language?]] 
 +</div> 
 +This Web project is similar to the project “Distance Line Style”. Here we show how to use a projection of choice different from the projection used on the map. For example, you may have your map using Google map as a background. Google map uses Spherical Mercator projection which is not ideal for distance measurements,​ that is why using a more appropriate projection for distance measurement such as State Plane will give more accurate results. The CustomDistanceLineStyle inheriting from LIneStyle has the logic built in to have the distance calculated based on a projection of choice instead of the projection of the map. \\   \\ As for the previous project “Distance Line Style”, you can see how the DrawCore function is overridden for the a specific need of style: displaying the distance label on each line segment making up a LineShape. In addition to the overriding of the DrawCore function, you will find useful some geometry functions such as GetPointOnLine to find the midpoint of a line segment and GetAngleFromTwoVertices to incline correctly the labels according to the orientation of each line segment. You will notice that the CustomDistanceLineStyle works for features made of LineShape and you will have to slightly modify to have it working with MultilineShape. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Wrap Dateline Mode ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Wrap Dateline Mode  ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Wrap Dateline Mode.jpg?​300x180}} {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Wrap Dateline Mode.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WpfEditionSample WrapDatelineMode CS 110110.zip|View Source]] ​ +<div content>​ 
-{{:File:​WpfEditionSample WrapDatelineMode CS 110110.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WpfEditionSample WrapDatelineMode CS 110110.zip|View Source]] 
 +{{filehistory:​WpfEditionSample WrapDatelineMode CS 110110.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: Wpf ]] [[Map Suite Samples Applies To|Applies To: Wpf ]]
- +\\ 
- CS 110110.zip|C#​ Download]]\\ \\ //[[Map Suite Samples Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Wpf Desktop Edition|Wpf \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: Wpf \\ ]]//   ​| ​In this Wpf project, we show a new property of Overlay, WrapDatelineMode. When you set this property to WrapDatelineMode.WrapDateline,​ the overlay will display to the right or left as you continuously pan west or east. This is very useful when dealing with world maps and you want to display the pacific rim as one extent. You have to be aware that this feature comes with some limitations. For example, on the “virtual” maps, the world coordinates are no longer valid and you need a special projection that we created (WrapDatelineProjection) to have the world coordinates displaying correctly. In order to run this sample, you will need the latest Dev Daily Build for Wpf with references to MapSuiteCore.dll and WpfDesktopEdition.dll.+[[Map Suite Samples Alternate Languages | Need it in another language?]] 
 +</div> 
 +In this Wpf project, we show a new property of Overlay, WrapDatelineMode. When you set this property to WrapDatelineMode.WrapDateline,​ the overlay will display to the right or left as you continuously pan west or east. This is very useful when dealing with world maps and you want to display the pacific rim as one extent. You have to be aware that this feature comes with some limitations. For example, on the “virtual” maps, the world coordinates are no longer valid and you need a special projection that we created (WrapDatelineProjection) to have the world coordinates displaying correctly. In order to run this sample, you will need the latest Dev Daily Build for Wpf with references to MapSuiteCore.dll and WpfDesktopEdition.dll. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Distance Query on Projected Layers ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Distance Query on Projected Layers ​ ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Web Edition Sample Distance Query On Projected Layers.png?​300x180}} {{wpfedition:​codesamples:​Map Suite Web Edition Sample Distance Query On Projected Layers.png?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_DesktopEditionSample DistanceQueryOnProjectedLayers CS 101228.zip|View Source]] ​ +<div content>​ 
-{{:File:​DesktopEditionSample DistanceQueryOnProjectedLayers CS 101228.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_DesktopEditionSample DistanceQueryOnProjectedLayers CS 101228.zip|View Source]] 
 +{{filehistory:​DesktopEditionSample DistanceQueryOnProjectedLayers CS 101228.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: MVC \ Desktop \ Web \ Silverlight \ Services \ Wpf ]] [[Map Suite Samples Applies To|Applies To: MVC \ Desktop \ Web \ Silverlight \ Services \ Wpf ]]
- +\\ 
- ​Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Desktop Edition|Desktop \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: MVC \\  Desktop \\  Web \\  Silverlight \\  Services \\  Wpf \\ ]]//   ​| ​In this sample, we learned how to use the method GetFeaturesWithDistanceOf when the data is projected. We just input the unit which is projected to, do not need to mind what the real unit is for the internal data before projection. ​ It works fine with Map Suite Assemblies 4.5.54.0 or later.+[[Map Suite Samples ​Alternate Languages | Need it in another language?]] 
 +</div> 
 +In this sample, we learned how to use the method GetFeaturesWithDistanceOf when the data is projected. We just input the unit which is projected to, do not need to mind what the real unit is for the internal data before projection. ​ It works fine with Map Suite Assemblies 4.5.54.0 or later. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Graticule with Projection ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Graticule with Projection ​ ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Graticule with Google Projection.jpg?​300x180}} {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Graticule with Google Projection.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WpfDesktopEditionSample_GraticuleWithGoogleProjection 101005.zip|View Source]] ​ +<div content>​ 
-{{:File:​WpfDesktopEditionSample_GraticuleWithGoogleProjection 101005.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WpfDesktopEditionSample_GraticuleWithGoogleProjection 101005.zip|View Source]] 
 +{{filehistory:​WpfDesktopEditionSample_GraticuleWithGoogleProjection 101005.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: MVC \ Desktop \ Web \ Silverlight \ Services \ Wpf ]] [[Map Suite Samples Applies To|Applies To: MVC \ Desktop \ Web \ Silverlight \ Services \ Wpf ]]
- +\\ 
- ​Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Wpf Desktop Edition|Wpf \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: MVC \\  Desktop \\  Web \\  Silverlight \\  Services \\  Wpf \\ ]]//   ​| ​In today’s Wpf project, we explore more features of GraticuleAdornmentLayer which shows meridians and parallels at various intervals based on the zoom level. Being natively in Geodetic, GraticuleAdornmentLayer can be set to any projection. In this project’s example, you have the graticule showing with World Map Kit in Spherical Mercator (Google Map projection). Also, not how easily you can change the appearance with properties such as GraticuleLineStyle and GraticuletextFont.+[[Map Suite Samples ​Alternate Languages | Need it in another language?]] 
 +</div> 
 +In today’s Wpf project, we explore more features of GraticuleAdornmentLayer which shows meridians and parallels at various intervals based on the zoom level. Being natively in Geodetic, GraticuleAdornmentLayer can be set to any projection. In this project’s example, you have the graticule showing with World Map Kit in Spherical Mercator (Google Map projection). Also, not how easily you can change the appearance with properties such as GraticuleLineStyle and GraticuletextFont. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- 
- 
-==== Wrap Dateline Mode With Projection ==== 
 <div sampleitem>​ <div sampleitem>​
 +====  Wrap Dateline Mode With Projection ​ ====
 +<div screenshot>​
 {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Wrap Date Line Mode with Projection.jpg?​300x180}} {{wpfedition:​codesamples:​Map Suite Wpf Desktop Edition Sample Wrap Date Line Mode with Projection.jpg?​300x180}}
-\\  +</​div>​ 
-[[Source_Code_WpfDesktopEdition WrapDatelineModeWithProjection CS 110510.zip|View Source]] ​ +<div content>​ 
-{{:File:​WpfDesktopEdition WrapDatelineModeWithProjection CS 110510.zip|C#​ Download}} ​| [[Map Suite Samples Alternate Languages | Need it in another language?]] \\ \\ +<div download_viewsource_buttons>​ 
 +[[Source_Code_WpfDesktopEdition WrapDatelineModeWithProjection CS 110510.zip|View Source]] 
 +{{filehistory:​WpfDesktopEdition WrapDatelineModeWithProjection CS 110510.zip|C#​ Download}} 
 +</​div>​ 
 +<div sample_otherlinks>​
 [[Map Suite Samples Applies To|Applies To: MVC \ Desktop \ Web \ Silverlight \ Services \ Wpf ]] [[Map Suite Samples Applies To|Applies To: MVC \ Desktop \ Web \ Silverlight \ Services \ Wpf ]]
- +\\ 
- ​Alternate Languages|Need it in another language?​]]/​/   | [[Map Suite Wpf Desktop Edition|Wpf \\ \\ ]]//[[Map Suite Samples Applies To|Applies To: MVC \\  Desktop \\  Web \\  Silverlight \\  Services \\  Wpf \\ ]]//   ​| ​In this Wpf project, we show a new property of Overlay, WrapDatelineMode. This property that allows to continuously pan west or east with world map was already available in the dev branch. This concept was shown in the previous sample “WrapDatelineMode”. Now it is fully supported in Map Suite 5 and you can see in this sample how the behavior for the map in both Decimal Degrees (Lat/Long) and Spherical Mercator (Google Map/Bing map projection). In order to run this sample, you will need the latest release for Wpf with references to MapSuiteCore.dll and WpfDesktopEdition.dll.+[[Map Suite Samples ​Alternate Languages | Need it in another language?]] 
 +</div> 
 +In this Wpf project, we show a new property of Overlay, WrapDatelineMode. This property that allows to continuously pan west or east with world map was already available in the dev branch. This concept was shown in the previous sample “WrapDatelineMode”. Now it is fully supported in Map Suite 5 and you can see in this sample how the behavior for the map in both Decimal Degrees (Lat/Long) and Spherical Mercator (Google Map/Bing map projection). In order to run this sample, you will need the latest release for Wpf with references to MapSuiteCore.dll and WpfDesktopEdition.dll. 
 +</​div>​
 </​div>​ </​div>​
  
 ---- ----
- +{{page>​map_suite_services_edition_projection_samples}}
map_suite_wpf_desktop_edition_projection_samples.1441678385.txt.gz · Last modified: 2015/09/08 02:13 by admin