GIS的积累
It is never to late to learn

导航

 

Polygon Example

' Create the RasterExtractionOp object
Dim pExtractionOp As IExtractionOp
Set pExtractionOp = New RasterExtractionOp

' Declare the input dataset object
Dim pInputDataset As IGeoDataset

' Call function to open a dataset
Set pInputDataset = OpenRasterDataset  ("D:\Spatialdata", "inputdata")

' Declare a polygon object
Dim pPolygon As IPolygon

' Call function to get a selected polygon from graphics  layer
Set pPolygon = GetSelectedPolygonFromLayer()

' Declare the output dataset
Dim pOutputDataset As IGeoDataset

' Call the method
Set pOutputDataset = pExtractionOp.Polygon  (pInputDataset, pPolygon, True)
posted on 2010-10-29 15:01  GIS的学习  阅读(261)  评论(0编辑  收藏  举报