From 5f692a4a4160fcae615e807d5e8c7e5b85702792 Mon Sep 17 00:00:00 2001 From: Michael Kreil Date: Sun, 10 Mar 2024 21:06:08 +0100 Subject: [PATCH] docs: fix links and format --- readme.md | 2 +- v01/container/readme.md | 6 +++--- v02/container/readme.md | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/readme.md b/readme.md index 043a406..d00f2cf 100644 --- a/readme.md +++ b/readme.md @@ -3,7 +3,7 @@ ## Versions - [**v2.0**](v02/readme.md) <- current version -- [v1.0](v01) +- [v1.0](v01/container/readme.md) ## Implementations diff --git a/v01/container/readme.md b/v01/container/readme.md index 5f84211..0387aff 100644 --- a/v01/container/readme.md +++ b/v01/container/readme.md @@ -11,7 +11,7 @@ The file is composed of several parts: - **index** of these tiles 4. **index** of all blocks -

+

## file @@ -79,7 +79,7 @@ The file is composed of several parts: - Each `block` contains data of up to 256x256 (= 65536) `tile`s. - Levels 0-8 can be stored with one `block` each. level 9 might contain 512x512 `tile`s so 4 `block`s are necessary. -

+

- Each `block` contains the concatenated `tile` blobs and ends with a `tile_index`. - Neither the order of `block`s in the `file` nor the order of `tile`s in a `block` matters as long as their indexes are correct. @@ -96,7 +96,7 @@ The file is composed of several parts: - `tile`s are read horizontally then vertically - `j = (row - row_min)*(col_max - col_min + 1) + (col - col_min)` -

+

- identical `tile`s can be stored once and referenced multiple times to save storage space - if a `tile` does not exist, the length of `tile` is zero diff --git a/v02/container/readme.md b/v02/container/readme.md index aa9c397..0ded6b2 100644 --- a/v02/container/readme.md +++ b/v02/container/readme.md @@ -60,8 +60,8 @@ The Versatiles Container format consists of four main components: | 30 | 4 | i32 | bbox max y (10⁷ × lat) | | 34 | 8 | u64 | offset of [Metadata](#32-metadata-chunk) | | 42 | 8 | u64 | length of [Metadata](#32-metadata-chunk) | -| 50 | 8 | u64 | offset of [Block Index](#34-block-index) | -| 58 | 8 | u64 | length of [Block Index](#34-block-index) | +| 50 | 8 | u64 | offset of [Block Index](#34-block-index) | +| 58 | 8 | u64 | length of [Block Index](#34-block-index) | @@ -166,7 +166,7 @@ The Versatiles Container format consists of four main components: | 12 + 33*i | 1 | u8 | `row_max` (0..255) | | 13 + 33*i | 8 | u64 | offset of Block in file | | 21 + 33*i | 8 | u64 | length of [Tile Blobs](#331-tile-blobs) | -| 29 + 33*i | 4 | u32 | length of [Tile Index](#332-tile-index) | +| 29 + 33*i | 4 | u32 | length of [Tile Index](#332-tile-index) | - Since a Block consists only of [Tile Blobs](#331-tile-blobs) appended by the [Tile Index](#332-tile-index), the length of Block must be the sum of the lengths of the [Tile Blobs](#331-tile-blobs) and the [Tile Index](#332-tile-index). - Note: To efficiently find the Block containing the tile you are looking for, use a data structure such as a "map", "dictionary" or "associative array" and fill it with the data from the Block Index.