Timeline for How to check if an AABB is behind another AABB while isometric depth sorting?
Current License: CC BY-SA 4.0
6 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| May 21, 2024 at 23:24 | comment | added | Archduke | I don't need to slice any sprites, I recognize there will be certain instances where there's no way to render things correctly (e.g. three overlapping rectangular boxes), and I'm able to avoid those situations. I'm just looking for a way to make these two cases sort properly, particularly the first case, which should be doable. | |
| May 21, 2024 at 23:02 | comment | added | Blindman67 | @Archduke Without a z (depth) buffer you can not correctly render intersecting faces (box has 6 faces) unless you manually slice intersecting faces to sort parts of each face as needed. This becomes very complex very quickly. Same with a sprite. it is either in front of a face or behind, it can not go through a face unless you cut the faces (and sprite) where they intercept and draw each part in sorted order. | |
| May 21, 2024 at 22:22 | comment | added | Archduke | I have to do things this way because I'm using a 2D rendering interface (SDL2's native renderer) instead of using e.g. openGL where I have a zbuffer. To be clear though, I'm sorting 3D boxes and then rendering their associated sprites based on that sorting. | |
| May 21, 2024 at 20:17 | comment | added | Blindman67 | @Archduke The center, but it does not matter where as long as its the same for all sprites. Do note that the sprites are a 2D representation of a 3D object and can not intersect in the z direction (they are flat and have no depth) and (I assume) your AABB boxes are 3D and can intersect. It is unclear if you want to sort 3D boxes and 2D sprite, or just 2D sprites. Why not just use the zbuffer and forgo the sort | |
| May 21, 2024 at 18:57 | comment | added | Archduke |
What point on the sprite's AABB should sprite.pos be?
|
|
| May 21, 2024 at 17:25 | history | answered | Blindman67 | CC BY-SA 4.0 |