VrayPhysicalCamera

Got questions, comments and/or feedback regarding Craft Director Studio? Post them here.
Forum rules
We only allow posts that
  • Is in English
  • Is related to our tools and the programs they support.

If these rules are not met you are most likely going to be banned.

Please Note:
  • New users will have their posts reviewed before being publicly available for other to see.
Post Reply
mannybmanago
Posts: 5
Joined: Tue Dec 08, 2009 7:38 am

VrayPhysicalCamera

Post by mannybmanago » Sat Dec 12, 2009 1:17 pm

Greetings,

This is my first post and I hope I get some response. We are using a LWF in our rendering and animation so we always use VrayPhysicalCamera, I haven't seen any tutorial using the VrayPhysicalCamera in the forum or in youtube. I already saw the "Turbo Tutorial - How to use V-Ray Maxwell f-render etc with CDS", but I hope to get extra help. An ordinary camera is fine, but VrayPhysicalCamera has different parameters, like FOV has no equivalent to VrayPhysicalCamera.

Regards,
Manny

Carl Buhre
Quality Assurance Consultant
Posts: 438
Joined: Mon Feb 25, 2008 12:59 pm
Location: Gothenburg, Sweden
Contact:

Re: VrayPhysicalCamera

Post by Carl Buhre » Mon Dec 14, 2009 2:55 pm

mannybmanago wrote:Greetings,

This is my first post and I hope I get some response. We are using a LWF in our rendering and animation so we always use VrayPhysicalCamera, I haven't seen any tutorial using the VrayPhysicalCamera in the forum or in youtube. I already saw the "Turbo Tutorial - How to use V-Ray Maxwell f-render etc with CDS", but I hope to get extra help. An ordinary camera is fine, but VrayPhysicalCamera has different parameters, like FOV has no equivalent to VrayPhysicalCamera.

Regards,
Manny
Hello Manny and welcome to the forum,

Are you using VRay in 3ds Max, Maya or Softimage? And which one of our Camera Tools are you trying to combine with the VRay camera? All of our tools? Because for the tools that add movement all you need to do is create a VRay camera, align it with our camera and link the two (parent it). But for FOV effects and such it's a little bit more tricky. Normally you would have to use the Connection Editor or Wire Parameters to link up the FOV value with the equivalent in VRay but I'm not that familiar with VRay so I'll have to try it out and see if I can find a solution.

I'll post more later.

Carl Buhre
Quality Assurance Consultant
Posts: 438
Joined: Mon Feb 25, 2008 12:59 pm
Location: Gothenburg, Sweden
Contact:

Re: VrayPhysicalCamera

Post by Carl Buhre » Mon Dec 14, 2009 4:51 pm

I tried VRay for 3ds Max 2009 and to me it seemed pretty straight forward for the focus effect. Target Distance to Target Distance.
FOV was trickier since it uses degrees so you have to use some math to convert the value when it's transferred.

mannybmanago
Posts: 5
Joined: Tue Dec 08, 2009 7:38 am

Re: VrayPhysicalCamera

Post by mannybmanago » Tue Dec 15, 2009 1:13 pm

We are using 3D Studio Max Design 2009/2010 and Vray as rendering engine. I tried but still failed connecting wires between Craft Cameras and VrayPhysicalCamera. Can you make a video demo in youtube, please. I think the "Craft Spline Speed-Controller - Part 1 - Turbo Tutorial" is a good example using vray physical camera.

Many newbies with craft animation like me would appreciate it and all the Vray users as well.

Thanks,
Manny

User avatar
Luigi Tramontana
Posts: 358
Joined: Mon May 19, 2008 11:32 am
Location: Gothenburg, Sweden
Contact:

Re: VrayPhysicalCamera

Post by Luigi Tramontana » Wed Dec 16, 2009 5:44 pm

Hi there Manny.

First I will cover Max, then Maya.

This is more tricky than is explained in the video, true true. As you mention, the reason being that Vray does not have an equivalent of FOV. It is very unfortunate that Max does not allow for the focal length to be wired and therefore it is a bit more difficult, but not horribly difficult ;)
In maya it is a little simpler (see below).

MAX:
Ok, so here is the solution you seek:

In the wire parameter dialog you get the Craft camera to push the FOV into the V-Ray camera, but you wire the FOV to "focal length" instead. Now here comes the "tricky" part. You must write the focal length as a function of the FOV. This is the function per se.
[focal length] = [film gate]/(2*tan(0.5*FOV))
[Film gate] is a constant which you find in the V-ray camera dialog (it is the dimension of the "actual" film, which most often is 36mm).
Now, if [film gate] is 36, you would think you are to write the following on the V-ray focal length side:
36/(2*tan(0.5*FOV))
However, Max is doing some funky conversions behind the scenes. You see, in max tan() wants DEGREES???, but FOV is c o n v e r t e d to radians for some inexplicable reason, so this is the formula you need, hehe.
36.0/(2.0*tan(0.5*FOV*180.0/3.1415))
Just copy it and paste it into the "focal length" expression field on the v-ray camera side in the "wire parameters" dialog.

Hope this solves your problem.


MAYA:
In maya you need to use expressions.
So:
1. Select the camera shape of the craft camera from which you wish to copy to the vray camera
2. open the attribute editor and right-click on the focal length.
3. select Create New Expression...
4. Copy the text in "Selected object and attribute" ([cameraname].focalLength)
5. Select the vray camera shape.
6. in the attribute editor you right-click on the "Focal Length" parameter in "Extra VRay Attributes"
7. select Create New Expression...
8. in the expression field you now paste the text you copied and put an equals sign on the very left side of the pasted text.
9. Then copy the text in "Selected object and attribute" ([VRayCameraname].vrayCameraPhysicalFocalLength)
Now it should say [VRayCameraname].vrayCameraPhysicalFocalLength = [cameraname].focalLength
10. Click on "Create". Now the VRay camera's focal length should change to the exact same value you have as focal length in the Craft Camera.


Good luck.
// Luigi Tramontana

mannybmanago
Posts: 5
Joined: Tue Dec 08, 2009 7:38 am

Re: VrayPhysicalCamera

Post by mannybmanago » Wed Dec 16, 2009 9:46 pm

Oh my...that's so tricky for me, I don't even know how the formula was derived...it's a good thing you are there guys! You have just made our life easier...A MILLION THANKS TO YOU...I will have to try this ASAP.

Vray fans, applause!!!

Regards,
Manny

Carl Buhre
Quality Assurance Consultant
Posts: 438
Joined: Mon Feb 25, 2008 12:59 pm
Location: Gothenburg, Sweden
Contact:

Re: VrayPhysicalCamera

Post by Carl Buhre » Thu Dec 17, 2009 2:15 pm

I've updated our help documentation with this. You can find the guide here:

http://docs.craftanimations.com/index.c ... ripts.html (click on VRay or "Combining Craft Cameras with VRayPhysicalCamera")

or you can go to the guide directly (without the side menu) using this link:
http://docs.craftanimations.com/scripts ... vrayOption

mannybmanago
Posts: 5
Joined: Tue Dec 08, 2009 7:38 am

Re: VrayPhysicalCamera

Post by mannybmanago » Wed Dec 23, 2009 10:02 pm

Hello again,

I tried and it works fine and thanks again. Would it be great if this will be in a script? Say I have to set up many cameras and of different types, then I have to do this all the time for each CDS camera to VrayPhysicalCamera. And in case I a change the VrayPhysicalCamera film gate, another I could run another script just to update the formula. I think this would be easy on you guys.

Thanks again for the support and Happy Holidays to all!!!

Regards,
Manny

mannybmanago
Posts: 5
Joined: Tue Dec 08, 2009 7:38 am

Re: VrayPhysicalCamera

Post by mannybmanago » Tue Jan 05, 2010 10:54 pm

Still no news with the Script?

Carl Buhre
Quality Assurance Consultant
Posts: 438
Joined: Mon Feb 25, 2008 12:59 pm
Location: Gothenburg, Sweden
Contact:

Re: VrayPhysicalCamera

Post by Carl Buhre » Thu Jan 07, 2010 9:57 am

mannybmanago wrote:Still no news with the Script?
You can probably use the Macro Recorder to record the script yourself. Just enable the Macro Recorder and do what you want to do and the commands will be listed in the Macro Listener.
Attachments
macrorecorder1.gif
Open the MAXScript Listener
macrorecorder1.gif (7.69 KiB) Viewed 25830 times
macrorecorder2.gif
Enable the MacroRecorder

Post Reply

Who is online

Users browsing this forum: No registered users and 12 guests