diff --git a/docs/user-guide/cartography.md b/docs/user-guide/cartography.md index 7faeca1cf6..4b193cb376 100644 --- a/docs/user-guide/cartography.md +++ b/docs/user-guide/cartography.md @@ -107,36 +107,37 @@ leaves the marker as it was. An SVG is drawn once into an image of its proportio its longer side, or as many as it says up to 700, and kept as a PNG is. Its shapes, gradients, patterns, clip paths and masks are drawn. One with filters (a blur, a shadow), text, images or links to other files (a ``, a paint or a style sheet from elsewhere) isn't taken, as they -aren't drawn; nor is a file read. What an SVG costs to draw is what it -paints, not its size: a few kilobytes of dashes finer than a pixel, or of see-through shapes piled -up, can take minutes. So one with more to draw than a 2048 × 2048 image isn't taken either, nor -one past 10,000 elements or 200,000 points of its shapes once each `` is counted where it -repeats, nor one with a marker on a shape inside another marker (drawn on each of its vertices -wherever it is), nor one whose style sheets and `style` attributes, or whose elements' attributes, -take more than some twenty milliseconds to read (a sheet of some 900 short rules, or 4,000 -attributes on one element; a `style` a `` repeats counts each time) or that declares an entity -holding a tag. An arc is counted as the curves it is drawn with, more the larger its radius: one of -more than 200 curves isn't taken, nor is a circle, an ellipse or a rounded corner whose radius is -in em or ex, which may come to any size. A radius in % is counted as that share of the -largest size the SVG gives itself; such a radius isn't taken either when the SVG's own width or -height is in em or ex and it has no `viewBox`, or when the width or height of a `` or -`` inside it, or of an `` inside it with no `viewBox`, is in em or ex or past 100%. An -`` with a `viewBox` takes the % from it whatever its own size. Each image is decoded once -until RustGIS restarts, and kept decoded, at most 700 pixels a side: in all at most 256 -megapixels of different marker images and 128 MiB once decoded (as many images as it keeps, at -177 × 177 each), so that a crafted file can't hold it for minutes; past it a new image is -refused, or drawn as a circle, with a notice saying so, until RustGIS is restarted. A vector -export keeps a compressed copy of each image it draws, at most about as much again (some 256 MiB -in all), which counts too and leaves less for new images. -Its size is its width, and it is as tall as its proportions make it, as QGIS draws a raster image -marker; the symbol's fill and outline don't show. It turns with **Rotation**, is ringed when -selected, and is kept in the project file. A project that has one opens only in a RustGIS that +aren't drawn; nor is a file read. What an SVG costs to draw is what it paints, not its size: a few +kilobytes of dashes finer than a pixel, or of see-through shapes piled up, can take minutes. So an +SVG with more to draw than a 2048 × 2048 image isn't taken either, nor one past 10,000 elements or +200,000 points of its shapes once each `` is counted where it repeats, nor one with a marker on +a shape inside another marker (drawn on each of its vertices wherever it is), nor one whose style +sheets and `style` attributes, or whose elements' attributes, take more than some twenty +milliseconds to read (a sheet of some 900 short rules, or 4,000 attributes on one element; a `style` +a `` repeats counts each time) or that declares an entity holding a tag. An arc is counted as +the curves it is drawn with, more the larger its radius: one of more than 200 curves isn't taken, +nor is a circle, an ellipse or a rounded corner whose radius is in em or ex, which may come to any +size. A radius in % is counted as that share of the largest size the SVG gives itself; such a radius +isn't taken either when the SVG's own width or height is in em or ex and it has no `viewBox`, or +when the width or height of a `` or `` inside it, or of an `` inside it with no +`viewBox`, is in em or ex or past 100%. An `` with a `viewBox` takes the % from it whatever its +own size. Each image is decoded once until RustGIS restarts, and kept decoded, at most 700 pixels a +side: in all at most 256 megapixels of different marker images and 128 MiB once decoded (as many +images as it keeps, at 177 × 177 each), so that a crafted file can't hold it for minutes; past it a +new image is refused, or drawn as a circle, with a notice saying so, until RustGIS is restarted. A +vector export keeps a compressed copy of each image it draws, at most about as much again (some 256 +MiB in all), which counts too and leaves less for new images. + +An image marker's size is its width, and it is as tall as its proportions make it, as QGIS draws a +raster image marker; the symbol's fill and outline don't show. It turns with **Rotation**, is ringed +when selected, and is kept in the project file. A project that has one opens only in a RustGIS that draws them. An image that doesn't decode draws a circle, so the point still shows; opening a project, map file or layer file, or adding styles, says which layers and styles have such an image, or one too large to keep. A PDF or SVG export keeps the image once, however many points and lines -draw it (in an SVG each place is a `` of it, a clone in a vector editor). The **Layers** -pane, its legend and the editors' previews (the symbol's, the strokes' and the fills') show the -image too, whole within their patch and not turned: +draw it (in an SVG each place is a `` of it, a clone in a vector editor), and a PDF of several +pages keeps it once for all of them. The **Layers** pane, its legend and the editors' previews (the +symbol's, the strokes' and the fills') show the image too, whole within their patch and not turned. +By command: ```text layer.marker={"layer":"Schools","image":"iVBORw0KGgo…","size":16} @@ -373,20 +374,20 @@ layer.strokeLevels={"layer":"Roads","on":true} A stroke can draw markers or hash marks along the line instead of a line, as railways, boundaries and directions of flow are drawn: its **Draw** menu picks **Line**, **Markers** or **Hash marks**. -Markers take a **Shape** (a character of a font too, as for points) and a **Size**; hash marks a **Length**, crossing the line square at an -**Angle** of 0°. **Place** puts them at intervals along the line (**Interval** apart, counted from -its start), at its vertices or its inner ones, at either end or both, or in its middle. **With the -line** turns each mark with the line's direction; the **Angle** turns it further, clockwise. Marks -take the stroke's colour, its width as a hash mark's line (or a marker's outline, by command), and -its offset to either side. Stack them with line strokes: a casing, a core and ticks across it. A -marker can also be an image, with **Image…** under **Shape** or by command (`"image"`, a PNG, JPEG -or SVG as base64 of at most 2 MiB; a PNG or JPEG of at most 2048 × 2048 pixels, an SVG with no -more to draw than such an image): as wide as its **Size** and as tall as its proportions make it, -turned with the line, the stroke's colour and outline left out; selected, each is framed. An image -a file gave that can't be drawn (too large to keep, one that doesn't decode, that has too many -pixels or that is an SVG RustGIS can't draw) shows as a circle; changing the strokes in the pane -makes it the circle, and says so. One past what RustGIS decodes until it restarts shows as a -circle and is kept as it is. By command, `"markers"` on a stroke: +Markers take a **Shape** (a character of a font too, as for points) and a **Size**; hash marks a +**Length**, crossing the line square at an **Angle** of 0°. **Place** puts them at intervals along +the line (**Interval** apart, counted from its start), at its vertices or its inner ones, at either +end or both, or in its middle. **With the line** turns each mark with the line's direction; the +**Angle** turns it further, clockwise. Marks take the stroke's colour, its width as a hash mark's +line (or a marker's outline, by command), and its offset to either side. Stack them with line +strokes: a casing, a core and ticks across it. A marker can also be an image, with **Image…** under +**Shape** or by command (`"image"`, a PNG, JPEG or SVG as base64 of at most 2 MiB; a PNG or JPEG of +at most 2048 × 2048 pixels, an SVG with no more to draw than such an image): as wide as its **Size** +and as tall as its proportions make it, turned with the line, the stroke's colour and outline left +out; selected, each is framed. An image a file gave that can't be drawn (too large to keep, one that +doesn't decode, that has too many pixels or that is an SVG RustGIS can't draw) shows as a circle; +changing the strokes in the pane makes it the circle, and says so. One past what RustGIS decodes +until it restarts shows as a circle and is kept as it is. By command, `"markers"` on a stroke: ```text layer.lineStrokes={"layer":"Railways","strokes":[{"color":"#333333","width":1.5},{"color":"#333333","width":1,"markers":{"mark":"hash","size":6,"interval":10}}]} diff --git a/docs/user-guide/data-formats.md b/docs/user-guide/data-formats.md index 4a360e2ed6..74e45c0a7a 100644 --- a/docs/user-guide/data-formats.md +++ b/docs/user-guide/data-formats.md @@ -340,7 +340,7 @@ Scripts use `service.import {"url":"…","name":"My OGC Layer"}` and | OGC API Features | Collections | Their items downloaded as GeoJSON, following the service's `next` pages up to 100,000 features, or more on a computer with more memory (see Environments in the analysis guide; a command such as `service.add` waits a minute at most) | | OGC API Tiles | Collections' map and vector tiles; a landing page's dataset map tiles | A tile layer in WebMercatorQuad, from the tile template the tileset advertises (its `item` link; `…/tiles/WebMercatorQuad/{z}/{y}/{x}`, the usual path, when that can't be read), keeping the tiles link's query (a token), map tiles in the server's image format, vector tiles drawn layer by layer in colours of their own | | WCS 1.0 / 2.0 (a 1.1 service is asked in 1.0) | Coverages, with their bounds | A raster: GetCoverage of the map's view within the coverage's bounds (or its whole extent: `"bbox": "full"`), as a GeoTIFF in the coverage's own projected system when RustGIS reads it, else in EPSG:4326, at most 2048 pixels on a side | -| ArcGIS REST | FeatureServer and MapServer layers; a MapServer's map; an ImageServer; a VectorTileServer | Layers queried as GeoJSON, or in protocol buffers (`f=pbf`, smaller and quicker to read) when the layer's description lists them and names its record limit (the description read first, or given up on after 15 seconds; a first protocol buffer page that can't be fetched or read has the layer read in GeoJSON, with a notice saying why), page by page past the server's record limit (`resultOffset`) up to 100,000 features or more on a computer with more memory (in protocol buffers, also no more than a quarter of the computer's memory once read, from 512 MB, the web app's limit, up to 3 GB; a later page past it ends the read with a notice, and the first page is always kept, within the reader's own limits for a page) (a command such as `service.add` waits a minute at most for the features), where the layer supports paging (ArcGIS Server 10.3 and later; otherwise up to the record limit); a layer comes in drawn as its description's `drawingInfo` says when its renderer is a simple one (fill, line and marker symbols, dashes), by the unique values of one field (as Unique Values, with the service's labels and its default symbol for the rest) or by class breaks (as Graduated Colors with the service's bounds and labels), others keeping RustGIS's symbol with a notice; a picture marker draws its image at its width, its height following the image's own proportion (without a width, its height is taken as its width, with a notice), and one whose image isn't in its description, or isn't a PNG or JPEG of at most 2 MiB of base64 and 2048 × 2048 pixels that RustGIS can decode (within the pixels and memory of marker images it decodes until it restarts), is a circle, grey or, among classes, in a ramp's colours, with a notice; and with its transparency whatever its renderer (a description that can't be read, or a query asking for its own `resultOffset` or `resultRecordCount`, which skips it, keeps RustGIS's symbol with a notice saying why); a map as its tile cache when it is Web Mercator's pyramid, else exported images; an ImageServer as exported images; a VectorTileServer as its MapLibre style | +| ArcGIS REST | FeatureServer and MapServer layers; a MapServer's map; an ImageServer; a VectorTileServer | Layers queried as GeoJSON, or in protocol buffers (`f=pbf`, smaller and quicker to read) when the layer's description lists them and names its record limit (the description read first, or given up on after 15 seconds; a first protocol buffer page that can't be fetched or read has the layer read in GeoJSON, with a notice saying why), page by page past the server's record limit (`resultOffset`) up to 100,000 features or more on a computer with more memory (in protocol buffers, also no more than a quarter of the computer's memory once read, from 512 MB, the web app's limit, up to 3 GB; a later page past it ends the read with a notice, and the first page is always kept, within the reader's own limits for a page) (a command such as `service.add` waits a minute at most for the features), where the layer supports paging (ArcGIS Server 10.3 and later; otherwise up to the record limit); a layer comes in drawn as its description's `drawingInfo` says when its renderer is a simple one (fill, line and marker symbols, dashes), by the unique values of one field (as Unique Values, with the service's labels and its default symbol for the rest) or by class breaks (as Graduated Colors with the service's bounds and labels), others keeping RustGIS's symbol with a notice; a picture marker draws its image at its width, its height following the image's own proportion (without a width, its height is taken as its width, with a notice), and one whose image isn't in its description, or isn't a PNG, JPEG or SVG of at most 2 MiB of base64 that RustGIS can draw (a PNG or JPEG of at most 2048 × 2048 pixels by area, an SVG as [image markers](cartography.md#symbology) take one; within the pixels and memory of marker images it decodes until it restarts), is a circle, grey or, among classes, in a ramp's colours, with a notice; and with its transparency whatever its renderer (a description that can't be read, or a query asking for its own `resultOffset` or `resultRecordCount`, which skips it, keeps RustGIS's symbol with a notice saying why); a map as its tile cache when it is Web Mercator's pyramid, else exported images; an ImageServer as exported images; a VectorTileServer as its MapLibre style | A long list stops at its first 2,000 layers, and a note says how many the service has. An OGC API service stops at its first 2,000 collections instead, and each can make up to three layers diff --git a/docs/user-guide/maps.md b/docs/user-guide/maps.md index 1fc23d2719..9b8fc79781 100644 --- a/docs/user-guide/maps.md +++ b/docs/user-guide/maps.md @@ -79,17 +79,18 @@ files, and exported maps are drawn turned and tilted. A tilted map keeps the sca of the view: nearer ground is larger, farther ground smaller and drawn coarser, fading into fog and, past about 72 degrees, a sky above the horizon. Labels stay upright, and those too far away to read are left out. Point markers stand upright, facing you, as MapLibre's circles do, smaller -with distance (aggregated, masked, blended or diagrammed point layers, and layers of more than 50,000 points, -keep their markers on the ground). Extruded layers (Style › Extrusion) stand up in perspective on a tilted -map, as in MapLibre: walls lit by the way they face and darker toward their foot, roofs at their -height, with the labels of extruded features on their roofs. While a tilted map moves, the -picture drawn last is laid over the ground and the extrusions and markers are moved with it, and the map is -drawn again once it settles. `map.setBearing` sets the bearing (`{"bearing": 90}` -puts east at the top; `{"by": 15}` turns it further), `map.setPitch` the pitch (`{"pitch": 60}`, -or `{"by": 10}`), `map.resetNorth` faces north and looks straight down, and `map.goToXY` takes a -`bearing` and a `pitch` too. Page layout map frames take their own bearing and pitch (see -[Layouts](layouts.md)), and the globe turns and tilts the same way: tilted, its camera swings -back about the centre of view, so the horizon comes into sight past the curve of the Earth. +with distance and fading into the fog, image markers too (aggregated, masked, blended or diagrammed +point layers, and layers of more than 50,000 points, keep their markers on the ground). Extruded +layers (Style › Extrusion) stand up in perspective on a tilted map, as in MapLibre: walls lit by the +way they face and darker toward their foot, roofs at their height, with the labels of extruded +features on their roofs. While a tilted map moves, the picture drawn last is laid over the ground +and the extrusions and markers are moved with it, and the map is drawn again once it settles. +`map.setBearing` sets the bearing (`{"bearing": 90}` puts east at the top; `{"by": 15}` turns it +further), `map.setPitch` the pitch (`{"pitch": 60}`, or `{"by": 10}`), `map.resetNorth` faces north +and looks straight down, and `map.goToXY` takes a `bearing` and a `pitch` too. Page layout map +frames take their own bearing and pitch (see [Layouts](layouts.md)), and the globe turns and tilts +the same way: tilted, its camera swings back about the centre of view, so the horizon comes into +sight past the curve of the Earth.
![Countries extruded by population on a map tilted 55° and turned 20°, lit and shaded, with labels on their roofs](https://assets.rustgis.app/images/extrusion.webp)