POV-Ray : Newsgroups : povray.general : Camera problem : Re: Camera problem Server Time
5 Nov 2024 09:26:37 EST (-0500)
  Re: Camera problem  
From: Christopher James Huff
Date: 16 May 2003 22:11:46
Message: <cjameshuff-C479F8.21121716052003@netplex.aussie.org>
In article <3ec51a9b$1@news.povray.org>,
 "Texel" <gsm### [at] netcourriercom> wrote:

> camera {
>    location <150.000000,100.000000,200.000000>
>    up <-0.182860,0.952424,-0.243825>
>    right <-4/3,0,0>     // for the right hand
>    look_at <144.285538,96.952240,192.380676>
> }

Probably unrelated to your problem, but either the right or the up 
vector looks wrong. Its length is very close to 1, as it should be, but 
it is not perpendicular to the right vector, it is tilted a little to 
the left. Non-perpendicular vectors are occasionally useful, but very 
rarely. And you might want to use "direction" instead of "look_at". The 
look_at feature does some internal calculations that may change your 
other settings, and I'm guessing you had to compute the look_at point 
from the direction anyway (location + direction*something to do with 
FOV? Or just location + direction*10?). As I recall from some recent 
discussion, one of those side effects is that non-perpendicular vectors 
get straightened out.

You mention you use quaternions to store the orientation...it may be 
easier to convert it to a matrix transform and use POV-Ray's internal 
transformations instead of computing the camera vectors. BTW, know of 
any good websites explaining the math of quaternions and how they apply 
to rotations?

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: chr### [at] tagpovrayorg
http://tag.povray.org/


Post a reply to this message

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