RE: [Scripting] camera parameters

Date : Wed, 30 Apr 2008 10:19:29 -0400
To : <XSI(at)Softimage.COM>
From : "Stephen Blair" <Stephen_Blair(at)Softimage.COM>
Subject : RE: [Scripting] camera parameters
shouldn't you be using the same units, instead of mm here and in there?


From: owner-xsi(at)Softimage.COM [mailto:owner-xsi(at)Softimage.COM] On Behalf Of Byron Nash
Sent: Wed 30 April 2008 9:39 AM
To: XSI(at)Softimage.COM
Subject: Re: [Scripting] camera parameters

I did some searching on the list and found this equation for determining the FOV from the filmback and aperature.

(aTan ((filmback width/2) / focal length)) * 2 = fov (horizontal)

I'm doing something wrong because my results aren't close to what they should be.

In my case, the Focal Length in XSI is 14mm and the Film Aperture is 0.3465 x 0.1949in.

(aTan( ( 0.3465 / 2 ) / 14 ) ) * 2 = 1.417 ??

What am I missing other than lots more math in school?

On Tue, Apr 29, 2008 at 9:18 PM, Byron Nash <byronnash(at)gmail.com> wrote:
No Sam, that's not what I'm up to but your problem is what I'm looking for. That's not very encouraging that you have to find a work around. I'm doing some work on the XSI-to-AE script during downtime. The script doesn't work when the projection plane is animated. I'm trying to build in all the error functionality that wasn't there to start with. Do you still have any of that code you wrote laying around? I have no idea how the math works to generate those numbers so I'm pretty much fumbling around in the dark.


On Tue, Apr 29, 2008 at 5:34 PM, Sam Cuttriss <cuttriss(at)whiskytree.com> wrote:
let me guess, you are trying to render an animated camera X% oversized?

i ran into the same thing recently and almost lost my mind at 3 in the morning.
i think my email to the list was censored (probably for the best)

it seens the proj plane is only calculated when the camera properties is open?
after trying a list of simple options as long as my arm i ended up writing a scop that did all the trig and set the values.
which was frustrating considering the value i wanted was laughing at me onscreen but unattainable.

_sam


Byron Nash wrote:
Thanks Matt, that did the trick. Any idea why when I have an _expression_ on the Projection Plane distance(linking it to another camera), that the FOV value doesn't change when I access it's value in scripting?

On Tue, Apr 29, 2008 at 4:30 PM, Matt Lind <mlind(at)carbinestudios.com <mailto:mlind(at)carbinestudios.com>> wrote:

   try this instead:
       LogMessage( oCamera.Name );
   LogMessage( oCamera.Parameters( "projplane" ).value );
               Matt
       
       ------------------------------------------------------------------------
       *From:* owner-xsi(at)Softimage.COM
       [mailto:owner-xsi(at)Softimage.COM
       <mailto:owner-xsi(at)Softimage.COM>] *On Behalf Of *Byron Nash
       *Sent:* Tuesday, April 29, 2008 1:18 PM
       *To:* xsi(at)Softimage.COM
       *Subject:* [Scripting] camera parameters

       I'm having trouble with the second line I've pasted below. The
       first line properly returns the name of the camera in the
       newCam variable. I can't figure out why it doesn't work in the
       second line even though I've tested it in another script.

       logmessage(newCam.name);                              logmessage(newCam.camera.projplane.value);

       What I'm trying to do is check whether the Projection Plane is
       turned on for this camera.

       Thanks.


       --        Byron Nash




--
Byron Nash

---
Unsubscribe? Mail Majordomo(at)Softimage.COM with the following text in body:
unsubscribe xsi



--
Byron Nash



--
Byron Nash

Search the XSI List archives here or use the advanced search form to search across mailing lists. Searching help is available.
This site supposedly brought to you by Benjamin Grosser and the Imaging Technology Group.