It seems that the challenge of sorting polygons and objects remains unsolved despite advancements in hardware accelerated graphics technology. This issue may persist for quite some time.
The root of the problem lies in the fact that graphic cards do not inherently sort polygons or objects. Essentially, the graphics card operates based on instructions to draw objects and their corresponding pixels. In addition, it maintains a zbuffer (or depthbuffer) which stores pixel distances from the camera. Subsequently, when rendering subsequent objects, the graphics card compares these distances and omits drawing objects that are farther away (unless this feature is disabled).
While this approach significantly enhances performance and enables seamless intersections between solid objects, it poses challenges when dealing with transparency. When rendering two transparent objects where A should appear behind B, specific instructions must be provided to ensure correct sequencing during rendering. Without automatic polygon sorting by the graphics card, manual intervention is required to address such scenarios.
This aspect necessitates a deep understanding of the rendering process and the need for customization based on individual requirements.
In three.js, enabling the material.transparent = true
property facilitates proper object sequencing to render transparent objects effectively. However, managing intersecting transparent objects presents a more complex challenge that may require additional manipulation.