Repository navigation
generated_world: an organic ground texture, not the material grid - #966
Merged
Merged
Conversation
paint_surface painted each texel its nearest raster cell's colour, and the raster is a few metres a cell, so the ground showed the grid as squares. Material mode now blends the four cells around each texel at a position warped about a cell by low-frequency noise, with the blend's fractions jittered by finer noise and eased: classes meet along frayed, organic edges and a lone cell is a soft patch. Asphalt is not warped, so road edges stay straight. Risk and height are interpolated; occupancy keeps its cells. The rows paint in parallel under OpenMP (0.32 s for 2048^2, about what the nearest-cell paint took single-threaded).
transfix
force-pushed
the
feat/organic-ground-texture
branch
from
November 2, 2026 01:51
9063e07 to
10d267e
Compare
transfix
enabled auto-merge (squash)
November 2, 2026 01:51
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #964. Review that first; this PR's own change is the top commit, 9063e07.
The baked ground texture showed the material raster's grid as squares. The raster is a few metres a cell (385 cells over 1.2 km), and
paint_surfacegave each texel its nearest cell's colour.What changes (
cvc::world::paint_surface)CVC_USING_OPENMP). A 2048² texture takes 0.32 s, about what the old nearest-cell paint took single-threaded; single-threaded the new paint is about 1.2 s. Every texel depends only on its position, so the result is the same on any thread count.Testing (Windows, MSVC 14.44)
WorldGenerated.SurfaceIsInterpolatedNotCellschecks two things:The old nearest-cell paint fails the boundary check, because every texel of a cell got the same colour.
world_generated_test: all 7 tests pass.A close-up
arigl snapshotofterrain_lab.arishows grass, scree and dirt meeting in organic shapes instead of a grid, with the roads unchanged.