POV-Ray : Newsgroups : povray.general : Bounce vectors : Re: Bounce vectors Server Time
29 Jul 2024 12:24:47 EDT (-0400)
  Re: Bounce vectors  
From: Le Forgeron
Date: 13 Jul 2011 04:55:08
Message: <4e1d5d6c$1@news.povray.org>
Le 13/07/2011 04:57, Some Yahoo nous fit lire :
> I'm looking for a way to calculate the bounce off the interior of a
> sphere...
> 
> 
> I have a position, a velocity vector and my sphere is hollow and
> centered at the origin.
> 
> I'm pretty sure that Velocity=-Velocity is not right, though in my head
> it seems logical.

Velocity := -Velocity is correct only when position & Velocity are
aligned (you came through the center of the sphere, you go back to it)

For other positions, you need to find the intersection point on the
sphere and mirror the velocity in regard to the normal of the sphere at
that point.


Post a reply to this message

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