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
24 Apr 2024 01:02:30 EDT (-0400)
  Re: How to set the view to the object width?  
From: Bald Eagle
Date: 21 Sep 2019 20:40:00
Message: <web.5d86c27d756e04084eec112d0@news.povray.org>
"Bald Eagle" <cre### [at] netscapenet> wrote:
> I haven't worked out a solution yet, or maybe I have in the past and can't
> remember / locate it (yet), but at:


I still haven't found what I'm looking for - I could swear that I had written
some code to do this already....


but if you take a look at:

http://news.povray.org/web.591ae6ba4e850994c437ac910%40news.povray.org

I do some calculations to find what radius is always at least 1 pixel wide, and
thus always visible.

If you define that radius to be the image_width, and then work backwards, you
should wind up with a camera position.


I'll see if I can work it out after I get some sleep, but if you're going to
hammer away at this, I always find that a diagram, a spreadsheet, and some good
#debug directives in the code really help me work this kind of thing out lots
faster.

(also, see: http://news.povray.org/58f60d9e%241%40news.povray.org to avoid any
atan problems   ;)   )


Post a reply to this message

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