POV-Ray : Newsgroups : povray.advanced-users : focal_point with camera transform? : Re: focal_point with camera transform? Server Time
26 Jun 2024 10:23:28 EDT (-0400)
  Re: focal_point with camera transform?  
From: Alain
Date: 9 Nov 2013 13:25:20
Message: <527e7e10$1@news.povray.org>

>
>> camera {
>>   perspective
>>   angle 60
>>
>>   location<0,7,7>
>>   look_at<0,0,-1>
>>
>>   focal_point <0.0,3.5,1>
>>          aperture 0.5
>>          blur_samples 100
>>          confidence .9
>>          variance 1/10000
>> }
>>
>> Then I do this, and it doesn't work:
>> camera {
>>   perspective
>>   direction <0,0,-1>
>>   angle 60
>>
>>   transform { matrix<1,0,0,0,1,0.1,0,-0.1,1,0,-1.75,-12> inverse }
>>
>>   focal_point <0.0,3.5,1>
>>          aperture 0.5
>>          blur_samples 100
>>          confidence .9
>>          variance 1/10000
>> }
>>
>> The reason why I am using direction with z negative is because I am using OpenGL
>> to generate the matrix, where Z goes towards the camera, not away.
>
>
> As soon as i wrote "Where Z goes towards the camera, not away." and hit "enter",
> it hit me.
>
> In the matrix above, i am translating -12 on the Z. Since direction is set to be
> negative, I need to compensate for that by changing this:
>
> focal_point <0.0,3.5,1>
>
> to this:
>
> focal_point <0.0,3.5,-11>
>
> -12-11=1, and 1 is where i want the focal point to be set up on Z.
>
> It seems to work? Am I heading down the right path?
>
>
>
>
Try defining your camera without focal blur and only add it after the 
transform.

Normaly, focal_point define an absolute location relative to the origin 
of the coordinate system.


Post a reply to this message

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