span8
span4
span8
span4
The intention of this article is to show the steps for generating a workspace to read aGeoTIFFraster image file, convert it to aJPEG2000raster image file, and then reproject it from one coordinate system to another.
geotifftojpeg2000.fmwt.(contains completed workspace template)
06-07-NO.zip(含有原耳地球仪)
1. Generate the workspace
开始FME工作台。在“开始”选项卡中,选择“生成工作区”选项。
Workbench生成工作区选项
In the Generate Workspace dialog, fill in the following:
Reader:
Writer:
Generate workspace dialog settings for Reader and Writer
2. Run the Translation
Once the workspace is generated, click on the green play button in the toolbar to run the translation.
3. Inspect the output
通过右键单击Writer功能类型并选择Inspect选项或通过单击Writer Feature类型以及点击Inspect按钮的弹出菜单中,检查输出。
右键单击功能类型或弹出菜单的菜单,用于检查工作区的数据。
The FME Data Inspector will start, and a pre-filled dialog will be displayed. Click the ellipsis button to the right of Dataset and navigate to the newly created 06-07-NO.jp2 file to select it.
数据检查器对话框,单击省略号按钮以浏览到06-07-No.JP2
4. Determine coordinate system
在图像上的任何位置绘制一个框以显示光栅的属性。为此,请单击图像外部,然后按住鼠标按钮并将其拖到图像中,将出现一个蓝色框。您将知道整个图像被选中,因为整个图像上会有一个小点的网格。现在选择整个图像,在“功能信息”窗格中,您可以查看有关栅格的信息,包括坐标系,单元间距,扩展区,单元来源和频段。请注意,坐标系是UTM83-10。
06-07-NO.jp2 viewed in the Data Inspector. Note the UTM83-10 coordinate system
Note: To view your raster image with a basemap, go to Tools > FME Options > Background Map. Then select Stamen Maps as the Background Map Format, and in the parameters select either Terrain, Toner or Watercolor.
5. Reproject the raster into LL84
Add aCsmapReprojectortransformer after the GeoTIFF Feature Type Reader. The CsmapReprojector will be used to change the projection from UTM83-10 to LL84. In the parameters, leave the Source Coordinate System parameter as "Read from feature", as the coordinate system is already set to UTM83-10 on the source. Set the Destination Coordinate system to "LL84"
csmapreprojector参数,将目标坐标系设置为ll84
6. Update the filename to reflect reprojection
Add aStringConcatenatortransformer and connect it to the Reprojected Output port on the CsmapReprojector. We will use the StringConcatenator to concatenate "_LL84" to the fme_basename (which is a format attribute generated by FME that stores the output JPEG2000 name).
在参数中,在新属性的下拉菜单中选择fme_baseName。然后对于字符串类型,选择属性值然后将字符串值设置为fme_baseName。在字符串部件中的新行上,为字符串类型选择常量,并将字符串值设置为_ll84。这将将_ll84附加到源地理区文件名。
StringConcatenator parameters to add _LL84 to fme_basename
7. Run the workspace and inspect output
Run the workspace and Inspect 06-07-NO_LL84.jp2 with the Data Inspector. Select the entire image to see the coordinate system in the Feature Information Properties. It should now be in LL-WGS84.
在数据检查器中为06-07-no_ll84.jp2的功能信息。注意LL-WGS84坐标系。
Data Attribution
The data used here originates from open data made available by theCity of Vancouver, British Columbia. It contains information licensed under the Open Government License - Vancouver.
In the nextexercise, learn how to create create raster tiles to break up large raster images into manageable sections using the RasterTiler.
© 2019 Safe Software Inc |Legal