ESRI.ArcGIS.ADF.IMS
TransformGeometryToScreen Method
See Also 
ESRI.ArcGIS.ADF.IMS.Geometry Namespace > Geometry Class : TransformGeometryToScreen Method




geometry
The geometry to transform.
extent
The Envelope representing the visible region
imageWidth
The width of the image in pixels that corresponds to the extent.
imageHeight
The height of the image in pixels that corresponds to the extent.
Transforms a geometry in map units to screen units. The object is modified by this method. Use the Clone method on the original Geometry object if you need to keep the original unmodified.

Syntax

Visual Basic (Declaration) 
Public Shared Sub TransformGeometryToScreen( _
   ByVal geometry As Geometry, _
   ByVal extent As Envelope, _
   ByVal imageWidth As Integer, _
   ByVal imageHeight As Integer _
) 
Visual Basic (Usage)Copy Code
Dim geometry As Geometry
Dim extent As Envelope
Dim imageWidth As Integer
Dim imageHeight As Integer
 
Geometry.TransformGeometryToScreen(geometry, extent, imageWidth, imageHeight)
C# 
public static void TransformGeometryToScreen( 
   Geometry geometry,
   Envelope extent,
   int imageWidth,
   int imageHeight
)

Parameters

geometry
The geometry to transform.
extent
The Envelope representing the visible region
imageWidth
The width of the image in pixels that corresponds to the extent.
imageHeight
The height of the image in pixels that corresponds to the extent.

Remarks

This method modifies the geometry object so that its coordinates and extent represent screen pixels, rather than map coordinates. The new pixel-based geometry will be created based on the input image dimensions and map envelope. If you want the geometry to correspond to screen pixels on the current map, be sure to use the extent and dimensions of the current MapView.

See Also

© 2010 All Rights Reserved.