|
![](/i/fill.gif) |
Wasn't it wyleu who wrote:
>As always the posting of the question very qickly leads to an answer
>
>#declare Sphere =
>sphere {
> <0,0,0>, 1
> pigment { rgb <1,0,0> }
>}
>#declare Min = min_extent ( Sphere );
>#declare Max = max_extent ( Sphere );
>object { Sphere }
>box {
> Min, Max
> pigment { rgbf <1,1,1,0.5> }
>}
>
>
>
>However this is a bounding box of an object, can I extract the co-ordinates of
>the bounding box as it's projected onto the viewing plane so I can provide
>these as co-ordinates to a function like html ISMAP and USEMAP to allow
>hypertext like functions from web background pages?
Be aware that min_extent and max_extent doesn't always produce efficient
bounds for an object if there's awkward CSG going on. POV will produce a
slab that is guaranteed to contain the object, but there's no guarantee
that it will fit snugly.
Consider this:
#declare Object = difference {
sphere { <0,0,0>, 1}
box {<-2,-2,-2><0.7,2,2>}
pigment { rgb <1,0,0> }
}
#declare Min = min_extent ( Object );
#declare Max = max_extent ( Object );
object { Object }
box {
Min, Max
pigment { rgbf <1,1,1,0.5> }
}
--
Mike Williams
Gentleman of Leisure
Post a reply to this message
|
![](/i/fill.gif) |