From: Gavin Kistner Date: 2005-06-03T23:46:23+09:00 Subject: Re: [ANN] librend 0.0.1 --Apple-Mail-6--83668632 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed On Jun 3, 2005, at 12:26 AM, Ilmari Heikkinen wrote: > There are also renderer "layers"; the renderer draws Views, which > have a > viewlist. The viewlist is composed of [camera, scene, effects]-tuples, > which the renderer draws in order, clearing the depth buffer between > them. So it's possible to draw a perspective-projected scene first, > followed by e.g. name markers, and then an ortho-projected HUD on top. If the Text labels are positioned at the centroid of the object they are labeling, and the cameras for each views are matched to the same world space, this is an effective way of visually layering the content. However, the downside of this technique is that EVERY label is always visible, even if the part if fully occluded by other geometry. Another (math-intensive) solution is to offset the pivot point of the text so that it rotates about the center of the object being labelled, but offset towards the camera the distance necessary for the billboarded bounding box of the text to fully clear the geometry of the object being labeled. As other objects move in front of the part/label, the label will be occluded along with the rest of the part. Deriving the billboarding code, pivot offset/rotation, and box-on- geometry collision detection is left as an exercise to the reader ;) -- "Contrary to what most people say, the most dangerous animal in the world is not the lion or the tiger or even the elephant. It's a shark riding on an elephant's back, just trampling and eating everything they see." -- Jack Handey --Apple-Mail-6--83668632--