height_field: the height field with its casts, query and mover - #7
Merged
Merged
Conversation
aephysics.height_field, Box3D's height_field.c in Aether: heights quantised to a global range so neighbouring fields line up, a material per cell with holes, the edge flags of every triangle against its four neighbours, either winding; the overlap, the ray and shape casts by a DDA walk of the swept box's leading corner through the cells, the character mover's planes and the box query. test_height_field.ae: the reference's create, index mapping on an asymmetric grid, winding normals, flat-field ray, overlap at the surface, the vertical casts straddling a cell boundary, the shape and ray casts against a brute force over every triangle of a wave, and the back side culled for both windings (the file roundtrip is not ported); plus the flags of a ridge and of holes, a scaled field, the box query, the mover. 113 checks. bench/height_field.ae against bench/height_field_box3d.c on a 512 x 512 wave with holes: the same hits and sums on every phase; the box query at parity, the ray walk 1.4x, the build 1.5x, the shape cast 2.1x.
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.
The ninth layer: Box3D's height_field.c as
aephysics.height_field.HEIGHT_FIELD_HOLE, edge flags per triangle against the diagonal and the four neighbours, either winding (get_height_field_triangleswaps the edge bits with the vertices).test_height_field.ae: the reference's subtests minus the file roundtrip, with the shape and ray casts checked against a brute force over every triangle of a wave (600 + 200 casts), plus the flags of a ridge and of holes, a scaled field, the query and the mover. 113 checks.bench/height_field.aevsbench/height_field_box3d.c(512 x 512 wave with holes): identical hits and sums; query at parity, rays 1.4x, build 1.5x, shape casts 2.1x. Recorded inbench/RESULTS.md.