POV-Ray : Newsgroups : povray.general : How to set the view to the object width? : How to set the view to the object width? Server Time
26 Apr 2024 13:57:26 EDT (-0400)
  How to set the view to the object width?  
From: Kima
Date: 21 Sep 2019 17:35:07
Message: <web.5d86968bd4ff5744ecc0fada0@news.povray.org>
I tried to set the camera location to fix the view to the object width using
this formula

direction_length = 0.5 * right_length / tan(angle / 2) where right_length

as

#declare o1 = sphere { <0,0,0>,1 pigment{color rgb<0,0,1>} finish{phong 1} }
#declare l1 = min_extent(o1);
#declare l2 = max_extent(o1);
#declare lx=0.25*(l2.x-l1.x)/-0.8559934009;

camera {location <0,0,lx> look_at <0,0,0> angle 30}
light_source {<2,5,-5> color rgb<1,1,1>  }

object{o1}

but lx should at least 10 times larger to view the whole object. Where is my
mistake?


Post a reply to this message

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