From a850046d7b6e76983e7b708136837c42b640a3a0 Mon Sep 17 00:00:00 2001 From: Juri Dispan Date: Sun, 29 Dec 2024 11:22:41 +0100 Subject: [PATCH] ppmdraw, ppmglobe, pnmmercator: add pages (#15357) * fix ci * ppmdraw, ppmglobe, pnmmercator: add pages * Apply suggestions from code review Co-authored-by: K.B.Dharun Krishna --------- Co-authored-by: K.B.Dharun Krishna --- pages/common/pnmmercator.md | 13 +++++++++++++ pages/common/ppmdraw.md | 13 +++++++++++++ pages/common/ppmglobe.md | 13 +++++++++++++ 3 files changed, 39 insertions(+) create mode 100644 pages/common/pnmmercator.md create mode 100644 pages/common/ppmdraw.md create mode 100644 pages/common/ppmglobe.md diff --git a/pages/common/pnmmercator.md b/pages/common/pnmmercator.md new file mode 100644 index 000000000..02f86f506 --- /dev/null +++ b/pages/common/pnmmercator.md @@ -0,0 +1,13 @@ +# pnmmercator + +> Perform Mercator transformations on Netpbm images. +> See also: `pnmglobe`. +> More information: . + +- Convert a rectangular projection worldmap to Mercator projection: + +`pnmmercator {{path/to/image.pnm}} > {{path/to/output.pnm}}` + +- Convert a Mercator projection worldmap to rectangular projection: + +`pnmmercator -inverse {{path/to/image.pnm}} > {{path/to/output.pnm}}` diff --git a/pages/common/ppmdraw.md b/pages/common/ppmdraw.md new file mode 100644 index 000000000..bab9f8c07 --- /dev/null +++ b/pages/common/ppmdraw.md @@ -0,0 +1,13 @@ +# ppmdraw + +> Draw lines, text and more on a PPM image by executing a script. +> Documentation on the utilized scripting language can be found by following the link below. +> More information: . + +- Draw on the specified PPM image by executing the supplied script: + +`ppmdraw -script '{{setpos 50 50; text_here "hello!"; }}' {{path/to/image.pnm}} > {{path/to/output.pnm}}` + +- Draw on the specified PPM image by executing the script in the specified file: + +`ppmdraw -scriptfile {{path/to/script}} {{path/to/image.pnm}} > {{path/to/output.pnm}}` diff --git a/pages/common/ppmglobe.md b/pages/common/ppmglobe.md new file mode 100644 index 000000000..e6ad7f760 --- /dev/null +++ b/pages/common/ppmglobe.md @@ -0,0 +1,13 @@ +# ppmglobe + +> Generate strips of an image suitable to be glued onto a sphere. +> See also: `pnmmercator`. +> More information: . + +- Transform an image to strips that can be cut out and glues onto a sphere: + +`ppmglobe {{number_of_strips}} {{path/to/image.ppm}} > {{path/to/output.ppm}}` + +- Use the specified color for the areas between the strips: + +`ppmglobe -background {{red}} {{number_of_strips}} {{path/to/image.ppm}} > {{path/to/output.ppm}}`