compute frustum collision #13

Open
opened 2026-02-19 04:44:28 +00:00 by jaynuine · 1 comment
Owner

currently we're relying on the projection's z distance to the camera to determine whether to draw a vertex, as we would not want to draw vertices that stand behind the camera ; but merely checking for projection.z >= 0 sometimes behaves weirdly, so either projection.z is not being computed correctly or there is more to this that i have overlooked

currently we're relying on the projection's z distance to the camera to determine whether to draw a vertex, as we would not want to draw vertices that stand behind the camera ; but merely checking for `projection.z >= 0` *sometimes* behaves weirdly, so either `projection.z` is not being computed correctly or there is more to this that i have overlooked
jaynuine added this to the todo project 2026-02-19 04:44:28 +00:00
Author
Owner

in the case of projection.z lying between 0 and focal_length, what should we do ?
for convenience, we probably wouldnt want to render the vertex ; but any segments that are only partially out of bounds should still be rendered, so such vertices should still be included in the projections array and a check should be deferred to draw_segments to ensure that a part of the segment is actually visible (which could be the case even if either or both vertices weren't, as the segment between the two may cross the screen)

in the case of projection.z lying between 0 and focal_length, what should we do ? for convenience, we probably wouldnt want to render the vertex ; but any segments that are only partially out of bounds should still be rendered, so such vertices should still be included in the projections array and a check should be deferred to draw_segments to ensure that a part of the segment is actually visible (which could be the case even if either or both vertices weren't, as the segment between the two may cross the screen)
jaynuine added this to the bonus milestone 2026-02-27 02:24:11 +00:00
Sign in to join this conversation.
No labels
bug
mlx
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
jaynuine/fdf#13
No description provided.