POV-Ray : Newsgroups : povray.general : Auto focus.. Server Time
28 Nov 2024 10:45:44 EST (-0500)
  Auto focus.. (Message 1 to 5 of 5)  
From: Raf256
Subject: Auto focus..
Date: 8 Mar 2007 12:08:35
Message: <45f04313@news.povray.org>
Can someone refresh my memory,

we have an object OBJ which is in front of the camera, how to auto focus on
it?

camera {
  #local POS = <1,2,3>; // camera position
  location <POS>

  #local FOC = .... ; // get the focal point

  blure_samples ...
  focal_point FOC

  rotate ...   translate.. // <-- some easy way to have this working too?
  // lets assume I grouped thoes into a #define TRANS = transform { .... }
}

-- 
Raf256

"Ustawowe ograniczenie liczby aptek to nie jest centralne sterowanie."


Post a reply to this message

From: dave vanhorn
Subject: Re: Auto focus..
Date: 8 Mar 2007 16:58:28
Message: <45f08704$1@news.povray.org>
> we have an object OBJ which is in front of the camera, how to auto focus 
> on
> it?
>
> camera {
>  #local POS = <1,2,3>; // camera position

Dosen't "look at" do that?   You still have to set the depth of focus of 
course, with the aperture.


Post a reply to this message

From: Alain
Subject: Re: Auto focus..
Date: 8 Mar 2007 19:25:30
Message: <45f0a97a$1@news.povray.org>
Raf256 nous apporta ses lumieres en ce 08-03-2007 12:10:
> Can someone refresh my memory,

> we have an object OBJ which is in front of the camera, how to auto focus on
> it?

> camera {
>   #local POS = <1,2,3>; // camera position
>   location <POS>

>   #local FOC = .... ; // get the focal point

>   blure_samples ...
>   focal_point FOC

>   rotate ...   translate.. // <-- some easy way to have this working too?
>   // lets assume I grouped thoes into a #define TRANS = transform { .... }
> }

Set focal_point to the location of that object. Easy if the object is created 
around the origin then translated, set the translation vector in a #declare and 
use that same value for the focal_point.
Something like:
#declare ObjLoc = <X,Y,Z>;
object{YourObject translate ObjLoc}
camera{... focal_point ObjLoc...}

-- 
Alain
-------------------------------------------------
A Bill of Rights is what the people are entitled to against every
government, and what no just government should refuse, or rest on inference.
Thomas Jefferson


Post a reply to this message

From: Raf256
Subject: Re: Auto focus..
Date: 9 Mar 2007 05:38:51
Message: <45f1393b@news.povray.org>
Alain <45f0a97a$1@news.povray.org> Friday 09 of March 2007 01:25

> Set focal_point to the location of that object. Easy if the object is
> created around the origin then translated, set the translation vector in a
> #declare and use that same value for the focal_point.

Not exacly. 

I ment - with using Trace to find out the *point on surface* of the object
witch is vissible in middle of camera view 

-- 
Raf256

"Ustawowe ograniczenie liczby aptek to nie jest centralne sterowanie."


Post a reply to this message

From: Alain
Subject: Re: Auto focus..
Date: 9 Mar 2007 20:05:52
Message: <45f20470$1@news.povray.org>
Raf256 nous apporta ses lumieres en ce 09-03-2007 05:40:
> Alain <45f0a97a$1@news.povray.org> Friday 09 of March 2007 01:25

>> Set focal_point to the location of that object. Easy if the object is
>> created around the origin then translated, set the translation vector in a
>> #declare and use that same value for the focal_point.

> Not exacly. 

> I ment - with using Trace to find out the *point on surface* of the object
> witch is vissible in middle of camera view 

In that case, trace from the camera location along the direction vector to your 
point of interest. Use the returned value as the focal_point of your camera. 
Call the trace with normal vector and test it to make sure you don't miss your 
object.

-- 
Alain
-------------------------------------------------

Did you know that Al Capone's business card said he was a used furniture dealer.


Post a reply to this message

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