POV-Ray : Newsgroups : povray.general : How to set the view to the object width? : Re: How to set the view to the object width? Server Time
2 May 2024 21:19:26 EDT (-0400)
  Re: How to set the view to the object width?  
From: Bald Eagle
Date: 22 Sep 2019 14:40:01
Message: <web.5d87bf98756e04084eec112d0@news.povray.org>
"Kima" <nomail@nomail> wrote:

> > // angle = 2* atan2( (0.5 * right_length), direction_length)

> one side is
> direction_length and one side is right_length

Which is what?

(half of the view).

And there is the answer.  Because Right is usually a unit vector, but the view
frustum is twice as wide as that.

> Tangent
> defines their ratio. Where does the "0.5" come from?

So you use 0.5*right in your trig to get the _half angle_, and then multiply by
two to get - the full angle.

Don't feel bad.
I go through this EVERY TIME.











I'll just throw a few keywords here to make searching for this post easier in
the future.

Bald Eagle Kima camera angle half_angle full_angle distance_vector right_vector
half_vector


Post a reply to this message

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