Tuesday, October 4, 2011

Light Manipulator for internal fluid light

At long last I've finished my MEL script that adds a directional light as a controler for a fluids internal light.

You must first select the fluid and then run the script.

This version creates a directional light and locator that whose translation is locked and whose visibility is off. At some point I might update it to exclude the creation of these two nodes.

Here's the code. I'll provide a link to download the file shortly.


string $fluidSelected[0] = `ls -sl `;
string $lightManipulator = "lightManipulator";
string $fluidAndLightMainipulator = $fluidSelected[0] + "_" + $lightManipulator;  //gets name of fluid and add "lightManipulater"
loadPlugin "C:/Program Files/Autodesk/Maya2012/bin/plug-ins/decomposeMatrix";
createNode decomposeMatrix -n decomposeM;
pickWalk -d down; //selects shape node of fluid conatiner
vector $fluidShapeLightVector = `getAttr ($fluidSelected[0] +".directionalLight")`; //retrieves vector value of fluids internal light
directionalLight -n $fluidAndLightMainipulator;// creates light that will be the manipulator
string $fluidAndLightMainipulatorProxy = $fluidAndLightMainipulator + "Proxy";
directionalLight -n $fluidAndLightMainipulatorProxy; // creates light that will be moved by manipulator
connectAttr -f ($fluidAndLightMainipulator + ".rotate") ($fluidAndLightMainipulatorProxy + ".rotate");
setAttr -lock true ($fluidAndLightMainipulatorProxy + ".t");
setAttr ($fluidAndLightMainipulatorProxy + "Shape" + ".overrideEnabled") 1;
setAttr ($fluidAndLightMainipulatorProxy + "Shape" + ".overrideVisibility") 0;
spaceLocator -n lightLocation;
setAttr lightLocation.translate ($fluidShapeLightVector.x) ($fluidShapeLightVector.y) ($fluidShapeLightVector.z);
connectAttr -f lightLocationShape.worldMatrix[0] decomposeM.inputMatrix;
setAttr lightLocationShape.overrideEnabled 1;
setAttr lightLocationShape.overrideVisibility 0;
string $fluidSelectedShapeArry[0] = `listRelatives -s $fluidSelected`;
string $fluidSelectedShape = $fluidSelectedShapeArry[0];
print $fluidSelectedShape;
connectAttr -f decomposeM.outputTranslate ($fluidSelectedShape + ".directionalLight");

vector $indtialLocatorTranslate = `getAttr lightLocation.translate`;
float $initialRotation[] = `angleBetween -euler -v1 0 0 1 -v2 ($indtialLocatorTranslate.x) ($indtialLocatorTranslate.y) ($indtialLocatorTranslate.z)`;
setAttr ($fluidAndLightMainipulator + ".rotate") $initialRotation[0] $initialRotation[1] $initialRotation[2];
select -r lightLocation;
select -add ($fluidAndLightMainipulatorProxy);
parent;
select -r fluid1_lightManipulator ;
select -add ($fluidSelected[0]) ;
parent;

Tuesday, September 20, 2011

Air/Fuel Ratio explained by Duncan Brinsmead

So the principal scientist at Autodesk, the man who invented Maya's Dynamics toolset. Personally answered my question on the Air/Fuel Ratio setting! Geeeeek out!

Here's the link.

Air/Fuel explanation

The downside to this event is that he explained something I've been doing wrong and now I'll feel like I have to update my reel...again.

Sunday, September 18, 2011

Lessons learned

I'm going to post this in the interest of lessons learned.

The Treasure Island shoot was a total disaster. I was given a call time of 12 noon and my shot did roll 'till 6pm so I sat around doing nothing all day but watch the crew. By the time we rolled tape I was in a foul mood and to top it all off they didn't block the scene out like i had requested and the camera work was so shaky (to cover the lack of real action) that it will be impossible to pull a good matchmove from the footage.

The lesson is: to VFX supervise you need to INSIST on planning and be an asshole on set sometimes.

Oh well.

Sunday, August 28, 2011

good day tomorrow

VFX supervising tomorrow out at Treasure Island. I'll be creating a light probe, match moving and turning a warehouse exterior into a restaurant. Should be fun. I'll update with cool images.

Also, I've finally figured out all the peices for my fluid directionalLight manipulator. Took about two weeks longer than expected but learned a lot along the way.

I'll make the script available as soon as I cobble it all together.




Thursday, August 25, 2011

Remote desktop access!

The cranky IT guy just got a lot of slack from me. I was able to remote access the graphics station. This is potentially huge. I can set up a fluid sim to cache and then set it off to render from home before going to sleep. Also - if working from home I can set up the render to take place at work so no more sending large QT files over Yousendit. Nice.

It was recently pointed out to me that all this can be done with a .bat file as well using render description files but I'll need to research this one a bit more.

Next up is the custom built render farm. Two pc (core i7) home builds connected to my main workstation. Managed by Autodesks backburner and started from home over the weekend. Much less stress on deadline.

When I get the .bat system worked out I'll produce a tutorial.

Tuesday, August 16, 2011

No fire on set so here you go

After messing around with Maya and fluid effects I decided to go with a 2d solution and busted out the After Effects and Particular (Peder Norby is Sweden's answer to Thomas Knoll...funny on so many levels.)



I think this works perfectly. I overthought this and spent a lot of time in 3d when AE was the obvious solution

Sunday, August 14, 2011

matchmove results from GOT shoot

Here's some matchmoved results from the I (Almost) Got Away With It shoot.



I was on vacation and couldn't supervise but the crew (and director did great). Much easier than prior shows.