diff --git a/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-input.png b/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-input.png new file mode 100644 index 0000000000000000000000000000000000000000..3a9963d0fec8eef7eae409ac53432dc4eedd2fe6 --- /dev/null +++ b/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-input.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:93f0f9b67dcfba1d7eececffa3e102750d7f3e0acf1ad424c599e815c0d7bdec +size 552134 diff --git a/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-output1000.png b/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-output1000.png new file mode 100644 index 0000000000000000000000000000000000000000..a959bc578c13a2ff05ef1c79a83a492da6ba9076 --- /dev/null +++ b/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-output1000.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4869000c79db434ac3d086653a992a6337d877284d616335c04f57d959eb7682 +size 101363 diff --git a/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-output200.png b/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-output200.png new file mode 100644 index 0000000000000000000000000000000000000000..b3a9c93f01c93eba39477c4d3c74cf9ab7387bf0 --- /dev/null +++ b/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-output200.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9e33962e537390ae26c4f351aa1fd8f4fe41171e9ff6f84c5d11035360dc0f7a +size 104878 diff --git a/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-output50.png b/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-output50.png new file mode 100644 index 0000000000000000000000000000000000000000..6f4216bfe80d505ced8160399183a7509147be66 --- /dev/null +++ b/web/content/docs/tools/fileio/Mesh2Raster/Mesh2Raster-output50.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2ad7077fae93273a60c6013a8e30631d5c402207b3bacca9360116bc5d4462e1 +size 100804 diff --git a/web/content/docs/tools/fileio/Mesh2Raster/index.pandoc b/web/content/docs/tools/fileio/Mesh2Raster/index.pandoc new file mode 100644 index 0000000000000000000000000000000000000000..5b3321796b3d4a1a2756dbdb5c2296a83ab31578 --- /dev/null +++ b/web/content/docs/tools/fileio/Mesh2Raster/index.pandoc @@ -0,0 +1,73 @@ ++++ +date = "2019-12-03T00:00:00+01:00" +title = "Mesh2Raster" +author = "Karsten Rink" + +[menu] + [menu.tools] + parent = "Data Import/Export" ++++ + +## Introduction + +This utility generates an ASCII-raster file based on a 2D surface mesh. A raster is superimposed on the mesh and pixel values are set to the surface elevation at each pixel's position. If no mesh element is located beneath a pixel it's value is set to NODATA. + +The tool is part of the official [OpenGeoSys git repository](https://github.com/ufz/ogs). + +## Usage + +```bash + Mesh2Raster -i <string> -o <string> [-c <real>] + + +Where: + + -i <string>, --input-file <string> + (required) Mesh input file (*.vtu, *.msh) + + -o <string>, --output-file <string> + (required) Raster output file (*.asc) + + -c <real>, --cellsize <real> + edge length of raster cells in result +``` + +The parameter ```c``` specifies the cell size (i.e. pixel size) of the raster. While optional, it is still recommended to choose a value as the default will be set to the minimum edge length in the input mesh which for unstructured grids may result in a very fine and (extremely) large output raster. + +## Simple example + +**Input data:** + + + +The input mesh for this example is a homogeneous, unstructured triangle mesh with an average edge length of 100m. + +**Command:** +``` +Mesh2Raster -i input.vtu -o output.asc -c 50 +``` + +{ width=66% } +The generated output raster has a size of 340x333 pixels and represents the original surface well. Given the average edge length of 100m in the original mesh, an even smaller cellsize would not have contained more details but resulted in a larger file size.[^1] + +**Command:** +``` +Mesh2Raster -i input.vtu -o output.asc -c 200 +``` + + +The generated output raster has a size of 85x84 pixels and still represents the original surface reasonably well, despite visible undersampling. + +**Command:** +``` +Mesh2Raster -i input.vtu -o output.asc -c 1000 +``` + + +The generated output raster has a size of 17x17 pixels and shows severy undersampling. However, this is the resolution that a large number of weather data products are available at. + +## Application + +The resulting ASCII-rasters can be used to represent surface data in geographic information systems. In the absense of input data, a detailed raster can also be used by OpenGeoSys preprocessing tools to generate new surface meshes with different resolution or properties. + +[^1]: Conversely, a larger cellsize might result in artefacts due to undersampling, see [Nyquist criterion](https://en.wikipedia.org/wiki/Nyquist_rate).