Skip to content

Conversation

@kylebarron
Copy link
Member

@kylebarron kylebarron commented Dec 17, 2025

The mesh is lined up with the upper and left edges of the raster. So if we give the raster the same width and height as the number of pixels in the image, it'll be omitting the last row and column of pixels.

To account for this, we add 1 to both width and height when generating the mesh. This also solves obvious gaps in between neighboring tiles in the COGLayer.

Closes #56

@kylebarron kylebarron merged commit 8d3f288 into main Dec 17, 2025
1 check passed
@kylebarron kylebarron deleted the kyle/fix-off-by-one-error-in-raster-layer-mesh branch December 17, 2025 23:07
@ds-release-bot ds-release-bot bot mentioned this pull request Jan 26, 2026
kylebarron pushed a commit that referenced this pull request Jan 26, 2026
🤖 I have created a release *beep* *boop*
---


<details><summary>0.2.0</summary>

##
[0.2.0](v0.1.0...v0.2.0)
(2026-01-26)


### Features

* Mosaic tile layer
([#184](#184))
([acc6904](acc6904))
* Update land-cover example text
([#163](#163))
([790b5f5](790b5f5))


### Bug Fixes

* handle lowercase units
([#195](#195))
([918c241](918c241))


### Performance Improvements

* remove unnecessary object creation
([#181](#181))
([62c0c23](62c0c23))
</details>

<details><summary>deck.gl-geotiff: 0.2.0</summary>

##
[0.2.0](deck.gl-geotiff-v0.1.0...deck.gl-geotiff-v0.2.0)
(2026-01-26)


### Features

* Allow user-defined texture loader in COGLayer
([#101](#101))
([010e800](010e800))
* Direct rendering of paletted COG in Land Cover example
([#102](#102))
([5d8d6f1](5d8d6f1))
* Generic projection handler & NLCD example
([#81](#81))
([f2bf383](f2bf383))
* **geotiff:** Set up texture mapping from tiff tags to luma.gl texture
format
([#98](#98))
([9e766c3](9e766c3))
* Infer default COG render pipeline based on GeoTIFF metadata
([#154](#154))
([8fddeec](8fddeec))
* Mosaic tile layer
([#184](#184))
([acc6904](acc6904))
* Parse GeoTIFF ColorMap tag
([#116](#116))
([0bb7eed](0bb7eed))
* Pass geographic bounds in onGeoTIFFLoad callback
([#130](#130))
([d0e3677](d0e3677))
* Set up namespace exports
([#148](#148))
([933561c](933561c))
* Shader module system and dynamic injection
([#120](#120))
([7f40813](7f40813))
* Stabler `renderPipeline` inference with props placeholder
([#157](#157))
([61a46cc](61a46cc))
* Support varied input for GeoTIFF source
([#128](#128))
([cbcd1e4](cbcd1e4))


### Bug Fixes

* Ensure `loadTexture` returns `Texture`, not `TextureProps`
([#113](#113))
([20ce0c0](20ce0c0))
* handle lowercase units
([#195](#195))
([918c241](918c241))
* throw error when maxError is non-positive
([#151](#151))
([e57d17e](e57d17e)),
closes
[#18](#18)


### Performance Improvements

* Only compute COG bounds when the user supplies onGeoTIFFLoad callback
([#137](#137))
([125de6f](125de6f))
* remove unnecessary object creation
([#181](#181))
([62c0c23](62c0c23))
</details>

<details><summary>deck.gl-raster: 0.2.0</summary>

##
[0.2.0](deck.gl-raster-v0.1.0...deck.gl-raster-v0.2.0)
(2026-01-26)


### Features

* combine debug layer into main layer
([#49](#49))
([4d388df](4d388df))
* Extract TileMatrixSet definition from GeoTIFF object
([#50](#50))
([bde296c](bde296c))
* Generic projection handler & NLCD example
([#81](#81))
([f2bf383](f2bf383))
* Infer default COG render pipeline based on GeoTIFF metadata
([#154](#154))
([8fddeec](8fddeec))
* initial RasterLayer and RasterDebugLayer
([#40](#40))
([4a28770](4a28770))
* Set up namespace exports
([#148](#148))
([933561c](933561c))
* Set up shader injection through RasterLayer
([#99](#99))
([d7714e3](d7714e3))
* Shader module system and dynamic injection
([#120](#120))
([7f40813](7f40813))
* Stabler `renderPipeline` inference with props placeholder
([#157](#157))
([61a46cc](61a46cc))
* Update land-cover example text
([#163](#163))
([790b5f5](790b5f5))


### Bug Fixes

* Fix off-by-one error in RasterLayer mesh generation
([#63](#63))
([8d3f288](8d3f288))
* move deck.gl dependencies to peer dependencies
([#43](#43))
([4877f2f](4877f2f))
* throw error when maxError is non-positive
([#151](#151))
([e57d17e](e57d17e)),
closes
[#18](#18)
</details>

<details><summary>deck.gl-zarr: 0.2.0</summary>

##
[0.2.0](deck.gl-zarr-v0.1.0...deck.gl-zarr-v0.2.0)
(2026-01-26)


### Features

* Set up namespace exports
([#148](#148))
([933561c](933561c))


### Bug Fixes

* move deck.gl dependencies to peer dependencies
([#43](#43))
([4877f2f](4877f2f))
</details>

<details><summary>raster-reproject: 0.2.0</summary>

##
[0.2.0](raster-reproject-v0.1.0...raster-reproject-v0.2.0)
(2026-01-26)


### Features

* Set up namespace exports
([#148](#148))
([933561c](933561c))


### Bug Fixes

* move deck.gl dependencies to peer dependencies
([#43](#43))
([4877f2f](4877f2f))
* throw error when maxError is non-positive
([#151](#151))
([e57d17e](e57d17e)),
closes
[#18](#18)
</details>

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: ds-release-bot[bot] <116609932+ds-release-bot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cross-tile gaps when rendering COG in tiled mode

2 participants