Subject:
|
Re: LDForge - dev. plans and call for help
|
Newsgroups:
|
lugnet.cad
|
Date:
|
Wed, 31 Mar 2010 21:56:52 GMT
|
Viewed:
|
23776 times
|
| |
| |
--snip--
|
Sorting by the distance to the centroid is only an approximation, but its
good enough to look pretty good for transparent polygons. Its not good
enough to be used as the primary means of hiding geometry thats farther away
from the viewer.
--Travis
|
Out of interest which centroid do you use? I would have thought that the
bounding box center was better than the centre of all corner points (since these
cluster around areas of high detail) but youve presumably tried different
centroid algorithms.
Tim
|
|
Message has 1 Reply: | | Re: LDForge - dev. plans and call for help
|
| (...) For transparency, LDView sorts triangles, and only triangles, not parts. So the centroid of each triangle is (p1 + p2 + p3) * (1/3). All transparent geometry in the whole model goes into one big list of triangles. While I'm at it, I calculate (...) (15 years ago, 31-Mar-10, to lugnet.cad.dev, FTX)
|
Message is in Reply To:
| | Re: LDForge - dev. plans and call for help
|
| (...) The only polygons that LDView sorts are transparent ones. Everything else is handled by the OpenGL depth buffer (glEnable(GL_DEPTH_TEST), followed by glDepthFunc(GL_LEQUAL)). Transparent polygons need to be sorted before being drawn, and (...) (15 years ago, 31-Mar-10, to lugnet.cad, FTX)
|
12 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|