2

Is there some standard way of obtaining bounding box of an S-57 chart, e.g., for one downloaded from https://www.charts.noaa.gov/InteractiveCatalog/nrnc.shtml?

0

3 Answers 3

3

Each layer could have a different bounding box.

GDAL has support for S-57 and its ogrinfo tool can show you the bounding box per layer.

For example (with grep to filter out the relevant lines:

$ ogrinfo -so -al US5SC25M.000 | grep -E '(Layer name|Extent)'
Layer name: DSID
Layer name: ADMARE
Extent: (-79.902793, 32.503085) - (-79.357460, 32.807348)
Layer name: ACHARE
Extent: (-79.902793, 32.503085) - (-79.357460, 32.807348)
Layer name: BCNLAT
Extent: (-79.902793, 32.503085) - (-79.357460, 32.807348)
Layer name: BCNSPP
Extent: (-79.902793, 32.503085) - (-79.357460, 32.807348)
Layer name: BRIDGE
Extent: (-79.902793, 32.503085) - (-79.357460, 32.807348)
Layer name: BOYLAT
Extent: (-79.902793, 32.503085) - (-79.357460, 32.807348)
Layer name: BOYSAW
Extent: (-79.902793, 32.503085) - (-79.357460, 32.807348)
Layer name: BOYSPP
Extent: (-79.902793, 32.503085) - (-79.357460, 32.807348)
...
0
0

Another way to obtain the real map polygons which sometimes consist of more than 4 points is to visit the NOAA charts interactive map which displays them.

NOAA maps

In the network console you will find a request to https://www.charts.noaa.gov/InteractiveCatalog/data/enc.json which consists of all maps including the coordinates which you can postprocess accordingly.

Network console

0
  1. Download the S-57 ENC file A.000.
  2. Convert the S-57 ENC file A.000 to shapefiles with ogr2ogr:

ogr2ogr -skipfailures -where "OGR_GEOMETRY='POLYGON' or OGR_GEOMETRY='MULTIPOLYGON'" -oo SPLIT_MULTIPOINT=ON -oo RETURN_LINKAGES=ON -oo LNAM_REFS=ON -mapFieldType StringList=String,IntegerList=String "OUTPUT DIRECTORY" A.000

  1. You will get many shapefiles in "OUTPUT DIRECTORY" and one of them is also M_COVR.shp, which is, by definiton, "A geographical area that describes the coverage and extent of spatial objects". This is what you are looking for!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.