Export RASTER FAILS
GM_CALEDO
Global Mapper User
Hi, I don't know why, the jpeg i want to create do not have file extension and its size is really small...
Here is my script:
GLOBAL_MAPPER_SCRIPT VERSION=1.00
DEFINE_PROJ PROJ_NAME="LAMCC_RGNC91-93_NEW_CALEDONIA"
Projection LAMBERT
Datum RESEAU_GEODESIQUE_DE_NOUVELLE_CALEDONIE_91_93
Zunits NO
Units METERS
Xshift 0.000000
Yshift 0.000000
Parameters
1.000000000 /* scale factor at central meridian
-20 40 0.000 /* 1st standard parallel
-22 20 0.000 /* 2nd standard parallel
166 0 0.000 /* central meridian
-21 30 0.000 /* latitude of the origin
400000.000 /* false easting (meters)
300000.000 /* false northing (meters)
END_DEFINE_PROJ
IMPORT TYPE="SHAPEFILE" FILENAME="u:\rasters\500\GM\shp\coupures.shp"\
LAYER_DESC="coupures" LOAD_PROJECTION PROJ_NAME="LAMCC_RGNC91-93_NEW_CALEDONIA"
IMPORT_WMS WMS_SERVER_URL="https://psud.nc/geodata/public/server/qgisPSUD/DFA/Carte_Topo/wms"\
WMS_SERVICE="WMS" WMS_LAYER="voi_voirie_l20170531152637833"\
LAYER_DESC="voi_voirie_l20170531152637833"
IMPORT_WMS WMS_SERVER_URL="https://psud.nc/geodata/public/server/qgisPSUD/DFA/Carte_Topo/wms"\
WMS_SERVICE="WMS" WMS_LAYER="voi_voirie_s20170531152637974"\
LAYER_DESC="voi_voirie_s20170531152637974"
EXPORT_RASTER FILENAME="U:\Rasters\500\GM\jpg\" TYPE="JPEG" GEN_WORLD_FILE="YES"\
INC_VECTOR_DATA="NO" SPATIAL_RES_METERS="1,1"\
OVERWRITE_EXISTING="YES"\
POLYGON_CROP_FILE="u:\rasters\500\GM\shp\coupures.shp"\
POLYGON_CROP_FILE_PROJ="LAMCC_RGNC91-93_NEW_CALEDONIA"\
POLYGON_CROP_USE_EACH="YES"\
POLYGON_CROP_NAME_ATTR="FEUILLE"
Here is my script:
GLOBAL_MAPPER_SCRIPT VERSION=1.00
DEFINE_PROJ PROJ_NAME="LAMCC_RGNC91-93_NEW_CALEDONIA"
Projection LAMBERT
Datum RESEAU_GEODESIQUE_DE_NOUVELLE_CALEDONIE_91_93
Zunits NO
Units METERS
Xshift 0.000000
Yshift 0.000000
Parameters
1.000000000 /* scale factor at central meridian
-20 40 0.000 /* 1st standard parallel
-22 20 0.000 /* 2nd standard parallel
166 0 0.000 /* central meridian
-21 30 0.000 /* latitude of the origin
400000.000 /* false easting (meters)
300000.000 /* false northing (meters)
END_DEFINE_PROJ
IMPORT TYPE="SHAPEFILE" FILENAME="u:\rasters\500\GM\shp\coupures.shp"\
LAYER_DESC="coupures" LOAD_PROJECTION PROJ_NAME="LAMCC_RGNC91-93_NEW_CALEDONIA"
IMPORT_WMS WMS_SERVER_URL="https://psud.nc/geodata/public/server/qgisPSUD/DFA/Carte_Topo/wms"\
WMS_SERVICE="WMS" WMS_LAYER="voi_voirie_l20170531152637833"\
LAYER_DESC="voi_voirie_l20170531152637833"
IMPORT_WMS WMS_SERVER_URL="https://psud.nc/geodata/public/server/qgisPSUD/DFA/Carte_Topo/wms"\
WMS_SERVICE="WMS" WMS_LAYER="voi_voirie_s20170531152637974"\
LAYER_DESC="voi_voirie_s20170531152637974"
EXPORT_RASTER FILENAME="U:\Rasters\500\GM\jpg\" TYPE="JPEG" GEN_WORLD_FILE="YES"\
INC_VECTOR_DATA="NO" SPATIAL_RES_METERS="1,1"\
OVERWRITE_EXISTING="YES"\
POLYGON_CROP_FILE="u:\rasters\500\GM\shp\coupures.shp"\
POLYGON_CROP_FILE_PROJ="LAMCC_RGNC91-93_NEW_CALEDONIA"\
POLYGON_CROP_USE_EACH="YES"\
POLYGON_CROP_NAME_ATTR="FEUILLE"
Answers
-
sorry, I use the V17.0
-
Note that your script has many parts. It is complex.
Suggest that you simplify the problem by working manually, rather than with a script, until you verify what works and what isn't working for you.
So, you could set your projection and load one or both of your WMS layers, zoom to your area and export a raster file. If that works, add more of your steps, like loading the shapefile and exporting again. Then try exporting to your cropped area, and so on.
You can save a workspace file for each step in your process and use that information as a reference as you build towards your complete project.
-
Maybe it's a bug because i've simplified my script and imported a raster instead of the wms.
Categories
- 13K All Categories
- 5.8K Features Discussion
- 350 Downloading Imagery
- 1.3K Elevation Data
- 385 Georeferencing Imagery Discussion
- 652 GM Script Language
- 56 User Scripts
- 115 GPS Features
- 421 Projection Questions
- 835 Raster Data
- 1.4K Vector Data
- 6.7K Support
- 181 Announcement and News
- 939 Bug Report
- 562 SDK
- 1.2K Suggestion Box
- 3.7K Technical Support
- 579 Other Discussion
- 132 GIS Data Sources
- 27 Global Mapper Showcase
- 244 How I use Global Mapper
- 110 Global Mapper Forum Website

