POV-Ray : Newsgroups : povray.programming : Help with camera : Help with camera Server Time
1 Jun 2024 22:22:10 EDT (-0400)
  Help with camera  
From: David Curtis
Date: 15 Aug 2005 10:22:06
Message: <4300a50e@news.povray.org>
Hi, i've written a patch that adds an interactive opengl preview. I want to
release it soon, but i'm having problems with matching the pov and ogl
views.

This is the code that i'm using to get pov's horizontal aperture and
converting that to opengl's vertical aperture:

   VLength(Direction_Length, pCam->Direction);
   VLength(Right_Length, pCam->Right);
   Horizontal_Aperture = atan(Right_Length / Direction_Length);
   Vertical_Aperture = atan(height * tan(Horizontal_Aperture) / width);

This code has been taken from 3.6 docs and from Paul Bourke's web site.
I'm using gluPerspective to set fov, and i'm using gluLook_At to position
camera.

Is there anyone that can help me with this?

Send me an email, i'd be happy to share the patch source with anyone
interested.

Dave


Post a reply to this message

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