GenerateContours ================ .. currentmodule:: globalmapper .. py:function:: GenerateContours (GM_LayerHandle_t32 aLayer, GM_ContourParams_t aContourParms) -> GM_Error_t32, GM_LayerHandle_t32 Generates contours from loaded elevation data and creates a new vector layer with the results. The returned layer handle must be closed with :doc:`CloseLayer<../load/globalmapper.CloseLayer>` when you are done with it. The *aContourParms* parameter can accept the contour interval size in meters or in feet; if is provided in a different unit, it will be automatically converted into meters. :param GM_LayerHandle_t32 aLayer: Layer to get elevations from or gm.NULL for topmost layer at each point :param GM_ContourParams_t aContourParms: Parameters for generating contours :returns: Error Code :rtype: GM_Error_t32 :return: Created contour layer :rtype: GM_LayerHandle_t32 Example ------- The following is an example of GenerateContours.:: err, contour_layer = gm.GenerateContours(layer, contour_params) For more context refer to :doc:`the tutorial page on full example scripts<../sampleCode/DemoMisc>`.