POV-Ray : Newsgroups : povray.general : Trace()? : Re: Trace()? Server Time
20 Nov 2024 02:39:12 EST (-0500)
  Re: Trace()?  
From: Mahalis
Date: 13 Nov 2001 18:11:55
Message: <3bf1a8bb$1@news.povray.org>
I didn't exactly mean 'colliding' as in 'running into'; I meant 'colliding'
as in 'intersecting'.

--

//Mahalis
camera{location<0,0.25,-2> look_at 0.5*y} #declare T=texture{pigment{crackle
scale 0.5 rotate 90 turbulence 0.75 color_map{[0 rgb 1][0.05 rgb 1][0.1
rgb<1,0.25,1>][0.25 rgbf 1][1 rgbf 1]}} finish{ambient 1}} #declare
c=difference{torus{0.5,0.1 rotate -90*x}box{<0.7,0,0.2>,<-0.7,-0.7,-0.2>}}
merge{object{c translate<0.5,0.5,0>} object{c translate<-0.5,0.5,0>}
cylinder{<1,0.5,0>,<1,0,0>,0.1} cylinder{<-1,0.5,0>,<-1,0,0>,0.1}
cylinder{0.5*y,0,0.1} texture{T}}
--


"Warp" <war### [at] tagpovrayorg> wrote in message
news:3bf0d894@news.povray.org...
> Mahalis <don### [at] fakeycom> wrote:
> : Could anyone explain to me exactly how one uses the trace() function to
> : detect object collisions?
>
>   If you mean that you want to detect if an object collided with another
> object, regardless of shape, then that's one of the most difficult things
> to do. Tracing can help a bit, but that's only perhaps 0.1% of everything
you
> need for that.
>
> --
> #macro N(D,I)#if(I<6)cylinder{M()#local D[I]=div(D[I],104);M().5,2pigment{
> rgb M()}}N(D,(D[I]>99?I:I+1))#end#end#macro M()<mod(D[I],13)-6,mod(div(D[I
> ],13),8)-3,10>#end blob{N(array[6]{11117333955,
> 7382340,3358,3900569407,970,4254934330},0)}//                     - Warp -


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.