Click or drag to resize

GM_Utility Class

Contains functions and datatypes from Global Mapper Interface that don't have any other home
Inheritance Hierarchy
SystemObject
  GlobalMapperGM_Utility

Namespace:  GlobalMapper
Assembly:  GlobalMapperWrapperNET (in GlobalMapperWrapperNET.dll) Version: 19.1.0.0 (19.1.0.0)
Syntax
C#
public static class GM_Utility

The GM_Utility type exposes the following members.

Methods
  NameDescription
Public methodStatic memberAddAreaToVectorLayer
Adds a area feature to a loaded vector layer
Public methodStatic memberAddCustomAreaClass
Adds a new custom area classification.
Public methodStatic memberAddCustomShader
Adds a new custom shader for possible use for elevation layer display
Public methodStatic memberAreColorsEqual
Compares equality of colors not including the A value
Public methodStatic memberCalcAreaElevStats
Calculate the elevation statistics within a given area
Public methodStatic memberCalcBearing
Calculates the bearing in radians between two points. The points can either be specified as lat/lon values or in the current projection.
Public methodStatic memberCalcDistance
Calculates the great-circle distance in meters between two points. The points can either be specified as lat/lon values or in the current projection.
Public methodStatic memberCalcEnclosedArea
Calculates the enclosed area of a region in square meters.
Public methodStatic memberCalcProjectedLocation
Calculates the location of a new point projected from a start point along a given bearing.
Public methodStatic memberCalcScaleRectangle
Calculate the rectangle in global coordinates required to draw at the provided scale to the given device of the given size.
Public methodStatic memberCalcViewShed
Performs a view-shed analysis on loaded elevation data (not implemented on WinCE)
Public methodStatic memberCalcVolumeAlongLine
Calculates the cut-and-fill volumes along a given line (not implemented on WinCE)
Public methodStatic memberCalcVolumeOfArea
Calculates the cut-and-fill volumes within a given area (not implemented on WinCE)
Public methodStatic memberCalcWorldRectSize
Calculates the width and height of a rectangle in the current projection. The rectangle can either be specified or the last drawn rectangle can be used.
Public methodStatic memberConvertCoordGroundToPixel
Convert a coordinate between the current projection and a pixel coordinate. The conversion space can be either the last drawn coordinate space or the caller can provide the coordinate space to work in.
Public methodStatic memberConvertCoordGroundToPixelDouble
Convert a coordinate between the current projection and a pixel coordinate. The conversion space can be either the last drawn coordinate space or the caller can provide the coordinate space to work in.
Public methodStatic memberConvertCoordGroundToPixelWithOrientation
Convert a coordinate between the current projection and a pixel coordinate. The conversion space can be either the last drawn coordinate space or the caller can provide the coordinate space to work in.
Public methodStatic memberConvertCoordGroundToPixelWithOrientationDouble
Convert a coordinate between the current projection and a pixel coordinate. The conversion space can be either the last drawn coordinate space or the caller can provide the coordinate space to work in.
Public methodStatic memberConvertCoordLayerGroundToPixel
Convert a coordinate between layer pixel space and the current projection.
Public methodStatic memberConvertCoordLayerPixelToGround
Convert a coordinate between layer pixel space and the current projection.
Public methodStatic memberConvertCoordPixelToGround
Convert a coordinate between pixel space and the current projection. The conversion space can be either the last drawn coordinate space or the caller can provide the coordinate space to work in.
Public methodStatic memberConvertCoordPixelToGroundDouble
Convert a coordinate between pixel space and the current projection. The conversion space can be either the last drawn coordinate space or the caller can provide the coordinate space to work in.
Public methodStatic memberConvertCoordPixelToGroundWithOrientation
Convert a coordinate between pixel space and the current projection. The conversion space can be either the last drawn coordinate space or the caller can provide the coordinate space to work in.
Public methodStatic memberConvertCoordPixelToGroundWithOrientationDouble
Convert a coordinate between pixel space and the current projection. The conversion space can be either the last drawn coordinate space or the caller can provide the coordinate space to work in.
Public methodStatic memberCreateBufferArea
Create a buffer area some distance around the specified feature (not implemented on WinCE)
Public methodStatic memberCreateS63UserPermitFile
Create a S-63 user permit file for use by clients to request encrypted S-63 chart files from data providers for loading with Global Mapper or your Global Mapper SDK-based application.
Public methodStatic memberDrawGridLines
Draws grid lines (either lat/lon or in the view projection) for the specified location.
Public methodStatic memberDrawGridLinesEx
Draws grid lines (either lat/lon or in the view projection) for the specified location.
Public methodStatic memberGenerateContours
Generates contours for the given layer(s) (not implemented on WinCE)
Public methodStatic memberGenerateContoursEx
Generates contours for the given layer(s) (not implemented on WinCE)
Public methodStatic memberGenerateDensityGrid
Generate a density (heat) grid for points from the given layer (not implemented on WinCE)
Public methodStatic memberGenerateElevationGrid(GM_LayerList_t, GM_GridGenSetup_t, GM_Layer_t)
Generates an elevation grid by triangulating and gridding 3D vector layers (not implemented on WinCE)
Public methodStatic memberGenerateElevationGrid(GM_LayerList_t, GM_GridGenSetup_t, GM_Layer_t, GM_Layer_t)
Generates an elevation grid by triangulating and gridding 3D vector layers (not implemented on WinCE)
Public methodStatic memberGenerateRoughnessGrid
Generates a roughness grid from the given land cover layer (not implemented on WinCE)
Public methodStatic memberGenerateWatershed
Performs a watershed/drainage/stream calculation based on the provided elevation layer(s) (not implemented on WinCE)
Public methodStatic memberGetBackgroundColor
Gets the color used for background pixels when drawing and exporting
Public methodStatic memberGetElevationOverrides
Retrieves the elevation adjusment options to use for a given elevation layer
Public methodStatic memberGetElevationShaders
Returns a list of the available elevation shaders in type GM_CustomShader_t*
Public methodStatic memberGetFilterString
Returns a string containing the filter to use in a Windows file open dialog box for all of the types supported for loading from this DLL.
Public methodStatic memberGetLastDrawnScale
Return the scale value (i.e. 24000.0 for 1:24K) that data was last rendered at
Public methodStatic memberGetLocationColor
Retrieves the color at a given location from a provided layer or from the list of currently loaded raster and elevation layers (topmost layer first).
Public methodStatic memberGetLocationElevation
Retrieves the elevation at a given location from a provided layer or from the list of currently loaded elevation layers (topmost elevation layer first).
Public methodStatic memberGetMACAddress
Returns a string containing the MAC address of the current machine. May need to provide this to get a license file generated.
Public methodStatic memberGetMiscOption
Gets the current value of an advanced/miscellaneous option. For most types return is GM_MiscOptVal_t8
Public methodStatic memberGetOnlineLayerZoomScale
Determine the zoom scale that will be used to draw/export from a provided tiled online layer for a given bounds.
Public methodStatic memberGetPathProfile
Retrieves a list of elevations along a path in the provided layer or from the list of currently loaded elevation layers (topmost elevation layer first).
Public methodStatic memberGetPathProfileLOS
Retrieves a list of elevations along a path in the provided layer or from the list of currently loaded elevation layers (topmost elevation layer first). Can also perform a line-of-sight calculation and return additional information about a 3D path (not implemented on WinCE).
Public methodStatic memberGetPathProfileLOSEx
Retrieves a list of elevations along a path in the provided layer list or from the list of currently loaded elevation layers (topmost elevation layer first). Can also perform a line-of-sight calculation and return additional information about a 3D path.
Public methodStatic memberGetRasterDisplayOptions
Retrieves the options to use when displaying the given raster layer
Public methodStatic memberGetSDKBuildDate
Returns the date that this SDK was built. Use this to provide more resolution for beta releases than GM_GetSDKVersion provides.
Public methodStatic memberGetSDKVersion
Returns the version of this SDK. The version is obtained by taking the major version number times 100 and adding the minor version number. For example, version 1.04 would be returned as 104.
Public methodStatic memberGetShaderDisplayOptions
Retrieves the options to use for the elevation shaders [returns const GM_ShaderOptions_t*]
Public methodStatic memberGetVerticalDisplayOptions
Retrieves the options to use when displaying gridded elevation data. [returns const GM_VerticalDisplayOptions_t*]
Public methodStatic memberIsRegistered
Returns TRUE if the current user is registered or currently using a demo license.
Public methodStatic memberLoadMapLayoutFile
Loads a map layout from a .gm_layout file to setup elevation legend, scale, feature legend, and north arrow
Public methodStatic memberMapCatalogAddFile
Adds a new map to the map catalog from a file on disk
Public methodStatic memberMapCatalogAddLayer
Adds a new map to the map catalog from a loaded layer
Public methodStatic memberMapCatalogChangeMapOrder
Moves a map from one index (0-based) in the map list to another
Public methodStatic memberMapCatalogCreate
Creates a new map catalog layer for adding map layers to
Public methodStatic memberMapCatalogDisableMap
Disables/enables a map in a catalog (use GM_GetMapCatalogInfo to get the map count)
Public methodStatic memberMapCatalogGetInfo
Retrieves information and statistics about the catalog (use GM_GetLayerInfo for generic information)
Public methodStatic memberMapCatalogGetMapInfo
Retrieves information about a map in a catalog (use GM_GetMapCatalogInfo to get the map count)
Public methodStatic memberMapCatalogRemoveMap
Removes the map at the given index from the catalog
Public methodStatic memberMapCatalogSave
Saves a map catalog layer to a file on disk
Public methodStatic memberMapCatalogSetDisplayInfo
Sets when the layers in a map catalog should be displayed
Public methodStatic memberMapCatalogSetMapOption
Sets an option for a map in a map catalog, like the native projection. The data passed in depends on the option type.
Public methodStatic memberProjectPoint
Projects a point from one projection to another
Public methodStatic memberProjectPointAtElev
Projects a point from one projection to another at a fixed elevation above the ellipsoid.
Public methodStatic memberProjectPointFromECEF
Projects a point from ECEF (earth-centered earth-fixed) to a projection
Public methodStatic memberProjectPointList
Projects a list of points from one projection to another
Public methodStatic memberProjectPointToECEF
Projects a point from a projection to ECEF (earth-centered earth-fixed)
Public methodStatic memberProjectRectangle
Projects a rectangle from one projection to another
Public methodStatic memberRemoveCustomShader
Removes a custom shader
Public methodStatic memberRunScript
Runs a Global Mapper script (.gms) or workspace (.gmw), either from a file or from script text
Public methodStatic memberSaveWorkspace
Saves a list of loaded layers and display options to a workspace (GMW) file
Public methodStatic memberSaveWorkspaceEx
Saves a list of loaded layers and display options to a workspace (GMW) file
Public methodStatic memberSelectFile
Displays a file dialog that allows the user to select a file to load.
Public methodStatic memberSelectFont
Select a font. Displays a dialog allowing the user to graphically select a font.
Public methodStatic memberSetBackgroundColor
Sets the color to be used for background pixels when drawing and exporting
Public methodStatic memberSetChildLayerOpCallback
Sets the callback function to call whenever a child layer is loaded or closed
Public methodStatic memberSetElevationOverrides
Sets the elevation adjustment options to use for a given elevation layer
Public methodStatic memberSetLicenseKey
Use to provide the distribution license XML key that you were provided when purchasing a distribution license. Will return GM_Error_NotRegistered if the key could not be validated.
Public methodStatic memberSetMemoryLimit
Sets the amount of available memory below which loads should fail and return (GM_Error_LowMemory). Set to zero to reset to no memory limit checking. [WinCE only]
Public methodStatic memberSetMessageCallback
Sets the function to call to display error and warning messages generated during SDK operations. If a message callback is provided, a message dialog will not be shown, instead the callback function will be called with the error or warning message that would have been displayed.
Public methodStatic memberSetMessageCallbackEx
Sets the function to call to display error and warning messages generated during SDK operations. If a message callback is provided, a message dialog will not be shown, instead the callback function will be called with the error or warning message that would have been displayed.
Public methodStatic memberSetMiscOption
Sets an advanced/miscellaneous option to use during operation. Returns the previous value.
Public methodStatic memberSetMiscOptionEx
Sets an advanced/miscellaneous option to use during operation. Returns the previous value.
Public methodStatic memberSetOrientation
Allows for drawing data with a direction other than north to the top of the screen for most projections. A value of 0.0 is the default and implies no rotation. Technically, the orientation value is the number of degrees to rotate the rendered data counter-clockwise.
Public methodStatic memberSetProgressCallback
Returns the current progress callback function.
Public methodStatic memberSetQuickPDFUnlockCode
Sets the QuickPDF library (http://www.quickpdflibrary.com/) unlock code (required for PDF/GeoPDF support)
Public methodStatic memberSetRasterDisplayOptions
Sets the options to use when displaying the given raster layer
Public methodStatic memberSetRegistryKey
Sets the base registry key from which settings should be stored/read. Settings will be stored in and read from "HKEY_CURRENT_USER\Software\*aKeyName*\Global Mapper".
Public methodStatic memberSetSettingsFilePath
Sets the path where to store settings files, like custom_datums.txt, etc.
Public methodStatic memberSetShaderDisplayOptions
Sets the options to use for the elevation shaders (call GM_GetShaderDisplayOptions to initialize)
Public methodStatic memberSetVectorDrawScale
Specifies the extra scaling factor to apply to line widths, point symbols, and fonts when drawing. This is useful when printing to try and keep vector features the same size as displayed.
Public methodStatic memberSetVerticalDisplayOptions
Sets the options to use when displaying gridded elevation data. If you're not going to change everything, it's suggested that you first call GM_GetVerticalDisplayOptions to initialize the structure to the current settings.
Top
Fields
  NameDescription
Public fieldStatic memberMAX_NON_REGISTERED_VECTOR_IDX
Number of Vector features of a given type you can access when not registered
Top
See Also