Introduction to Maya - Rendering in Arnold
This course will look at the fundamentals of rendering in Arnold. We'll go through the different light types available, cameras, shaders, Arnold's render settings and finally how to split an image into render passes (AOV's), before we then reassemble it i
# 1 21-06-2016 , 04:26 PM
Registered User
Join Date: Oct 2014
Posts: 10

Changing the Film Gate

I am trying to modify the Maya camera's film gate attribute in which I have 2 almost similar film backs with the same values in terms of its aperture values etc but both with a slightly different naming.
For eg. the film backs naming are '35mm Default' and '35mm Delivery'

So in my current scene, it was set to '35mm Default' and I am writing a check in which it will pop up a drop-down list that contains 'Delivery' naming and user is to select the correct film back from there, in this case, it will be '35mm Delivery'

And so, my question is - how do I change such film backs/gates via coding? I tried turning on 'Echo all commands' but while it shows AEwhichCameraFilmback... it does not seems to have a variable that states the naming of the film back.

Can anyone kindly give me any advice?

# 2 27-06-2016 , 03:35 PM
Gen's Avatar
Super Moderator
Join Date: Dec 2006
Location: South FL
Posts: 3,522
If you run a “whatIs AEwhichCameraFilmback”, it leads to a procedure in an attribute editor template named AEwhichCameraFilmbackNew that’s found in the Maya installation files. Here you can see the proc that creates the contents of the drop down menu and the different procs called to update the UI. Most likely you can extend this or implement this in a custom window.


- Genny
__________________
::|| My CG Blog ||::
::|| My Maya FAQ ||::
# 3 28-06-2016 , 04:15 PM
Registered User
Join Date: Oct 2014
Posts: 10

If you run a “whatIs AEwhichCameraFilmback”, it leads to a procedure in an attribute editor template named AEwhichCameraFilmbackNew that’s found in the Maya installation files. Here you can see the proc that creates the contents of the drop down menu and the different procs called to update the UI. Most likely you can extend this or implement this in a custom window.

Hi there, I have actually tried that and it does not populates the list of available formats.
The script - AEwhichCameraFilmbackNew, executes the option upon selecting a certain filmback option in the list while using the horizontal and vertical aperture along with the lens squeeze as the variables for it

# 4 30-06-2016 , 12:21 AM
Gen's Avatar
Super Moderator
Join Date: Dec 2006
Location: South FL
Posts: 3,522
Works here. I just copied the highlighted bit to a new proc that makes a custom window. The default procs can be edited to accommodate your custom UI.
user added image


- Genny
__________________
::|| My CG Blog ||::
::|| My Maya FAQ ||::
# 5 30-06-2016 , 05:02 PM
Registered User
Join Date: Oct 2014
Posts: 10
Okay... I was planning to do it in more pythonic way

But is there a way to get the globalFilmbackTable() in python terms?
I tried to do it in Mel terms such as AEcameraFilmbackNew.globalFilmbackTable(); but it returns an error


Last edited by salik89; 30-06-2016 at 05:09 PM.
# 6 03-07-2016 , 07:16 PM
Gen's Avatar
Super Moderator
Join Date: Dec 2006
Location: South FL
Posts: 3,522
Hmm then you might run into some problems since MEL isn’t an OOP language. The globalFilmbackTable proc is not accessible globally so either change that declaration or write similar code (in Python or otherwise).


- Genny
__________________
::|| My CG Blog ||::
::|| My Maya FAQ ||::
# 7 04-07-2016 , 05:34 PM
Registered User
Join Date: Oct 2014
Posts: 10
Yep, that will be right unless I changed it into a global proc in which it is not advisable to..

Posting Rules Forum Rules
You may not post new threads | You may not post replies | You may not post attachments | You may not edit your posts | BB code is On | Smilies are On | [IMG] code is On | HTML code is Off

Similar Threads