EXPORT2KML

Export to Google Earth KML or KMZ


EnvironmentsPYTHON :: EASI :: MODELER
Batch ModeYes
Quick linksDescription :: Parameters :: Parameter descriptions :: Details :: Related

Back to top

Description


EXPORT2KML lets you export raster, vector, and bitmap data to KML or KMZ format. Exporting the data to KML or KMZ format allows you to view the data in virtual globe programs, such as Google Earth.
Back to top

Parameters


Name Type Length Value range
InputRaster: Input raster channel(s) Raster port 0 - 3  
InputBitmap: Input bitmap channel(s) or layer(s) Bitmap port 0 - 1  
InputVector Integer 0 - 48  
Output File Name String 0 -    
InputMask: Area mask Any port 0 - 4
Z-value Field String 0 -    
Use Selection (Focus only) Boolean 1 - 1 TRUE | FALSE
Default: FALSE

* Required parameter
Back to top

Parameter descriptions

InputRaster: Input raster channel(s)

Specifies the channel(s) in the input file to be exported. Only channels that have a pixel depth of 8U can be exported. You can specify one channel or three channels for export. EXPORT2KML generates an error if the number of channels is not 0, 1, or 3.

If you export one channel and it contains metadata on PCT information, a pseudocolored image corresponding to the PCT information is displayed in Google Earth. When three channels are specified, the system processes the result into an RGB colored image. The order in which you list the channels dictates the color output of each channel. For example, if you specify 10, 2, and 8, channel 10 becomes red, channel 2 becomes green, and channel 8 becomes blue.

InputBitmap: Input bitmap channel(s) or layer(s)

Specifies the bitmap channel or layer to be exported. Only one bitmap can be specified.

InputVector

Specifies the input vector segment(s) to be exported.

EXPORT2KML can export up to 1024 vector segments.

In addition, EXPORT2KML can export topological data and can convert topological polygons to whole polygons and topological lines to lines.

Output File Name

Specifies the name of the KML or KMZ output file. The KMZ file is a compressed (zipped) KML file.

InputMask: Area mask

Specifies the areas of the data to be exported.

You can define these areas using two types of mask boundaries: bitmap and vector.

For a bitmap mask, you can specify the number of the bitmap segment that you want to use. All of the pixels within the specified segment, having a pixel value of 1, define the area where input data has to exist to be exported.

For a vector mask, you can specify the number of the vector segment that you want to use as a mask. If the segment is a polygon layer, EXPORT2KML clips the input data along the polygon boundary. If the segment is not a polygon layer, EXPORT2KML uses the extents of the segment to define the mask area.

Note: EXPORT2KML chooses a bitmap segment over a vector segment for defining the mask area, if both segments share the same segment number.

Z-value Field

Specifies a z-value for the lines designated for export.

By specifying a z-value or leaving it blank, you can manipulate the look of lines in Google Earth. EXPORT2KML processes the z-value of lines using the KML-supported altitudeMode and tessellate tags.

If you specify the z-value with a z-coordinate or attribute value, EXPORT2KML sets the altitudeMode to absolute and does not specify tessellate. This results in lines appearing in Google Earth at the specified z-value. The lines dip out of sight in areas where the Google Earth elevation value is higher than the z-value.

If you do not specify the z-value, EXPORT2KML sets altitudeMode to ClampToGround and tessellate to 1. This results in the lines appearing on the ground and contouring to the underlying Google Earth terrain.

Use Selection (Focus only)

Allows you to export only selected shapes from the current view in CATALYST Professional Focus. Default value is FALSE.

Note: This parameter is available only through the Focus Algorithm Librarian and applies to vectors and thematic rasters (rasters with associated attributes).
Back to top

Details

During the export, EXPORT2KML can perform the following tasks:

If you are exporting data that is not in Lat/Long WGS84 projection, EXPORT2KML detects and reprojects the data to Lat/Long WGS84 during the export.

For rasters and bitmaps, EXPORT2KML applies the following settings during the reprojection:

If you want to specify your own reprojection settings, you can run REPROJ before you run EXPORT2KML. However, if your files have no projection, EXPORT2KML cannot reproject your files and will therefore generate an error.

Using built-in GDB technology, EXPORT2KML detects the pixel size of rasters and bitmaps and tiles them to 256x256 pixels. The tiles are saved as a subset to the newly created KML file. When the KML file is viewed in Google Earth, the tiles are pulled in when a greater resolution is necessary.

During the export, EXPORT2KML creates the KML file and a folder bearing the same name as the KML file but appended with "_files". For example, if the KML file name is irvine, the folder name becomes "irvine_files". The KML file and the folder appear in the directory location that you specified. If you specify KMZ as the export format, the KMZ contains the KML file and folder in compressed form. The folder contains tiles and overviews of the KML file. These tiles and overviews are used as super-overlays by Google Earth for optimal display.

© PCI Geomatics Enterprises, Inc.®, 2026. All rights reserved.