Posts

Macdonald's Ebi TVC 2014

Image
Here's a TV commercial I was part of. Most of the work I was involved in, were rotoscoping the girls out of their background on their original footage, and removing portions of clips visible under their hair accesories.

Jewl Changi Airport Brand Story

Image
Here's a TV branding project that Iceberg Design undertook, and I was involved in. My shots were just creating, laying out and rendering the coloured balls shots where lady touches her lips to the balls against the black background (0:29 - 0:30). In the ending shot in the background where lines appear and form the final logo (1:09 - 1:15), I generated the lines and refined them under the art direction of the creative director.

My Answer on Quora: What is the standard lens length in Maya 3D?

Image
I chanced upon a question on Quora: Question:  What is the standard lens length in Maya 3D? I decided to answer that, and here is my reply. I hope it sheds some light to people wanting to know how to establish a relationship between camera settings in the real world and the virtual counterpart in Maya. Answer:  Indeed, many artists with no experience in photography will not be able to easily understand the relationships between focal length and sensor sizes / ratios. Having worked in the "camera department" on Hollywood films, it has given me great insight into the relationships between the physical camera and the virtual one in Maya. Maya does not make it easier. What we know in the VFX/Film world as "sensor size" / "film back" / "film format", is known in Maya as "Camera Aperture". This attribute is found in any Maya camera's shape node. In the attribute editor under the Film Back section you will see: Film Gate, Camera...

Distance Between 2 Positions in 3D Space

The ability to find the distance between 2 points in 3D space is a really important function I need to use time and again. I found this website that is really helpful with clear explanations on the use of the formula. http://darkvertex.com/wp/2010/06/05/python-distance-between-2-vectors/ From the webpage I learnt the formula for the distance d between points A (expressed as Ax, Ay, Az) and B (expressed as Bx, By, Bz), would be expressed as such: d = √   Ax-Bx 2  + Ay-By 2  + Az-Bz 2    I was going to use the distance function on an expression in Maya, so I had to write it with MEL commands: vector $a = `xform -q -ws -a -rp "objA"`; vector $b = `xform -q -ws -a -rp "objB"`; // doing the additions and squaring first $myDist = `pow ($a.x-$b.x) 2` + `pow ($a.y-$b.y) 2` + `pow ($a.z-$b.z) 2`;  // applying the square root $myDist = `sqrt $myDist`;  I hope you it helps if you are looking for the same information. Additional notes: I am w...

Adding ObjectID Pass to Render Output in Maya Part 2: The Script

In my previous post , Autodesk's article showed us how to create an ObjectId pass in our scene. In the last post I also posted a snippet of PyMel script that creates a unique Id number for each object so each one will turn up a uniquely different colour from its neighbour in the objectId pass. However the process still needed us to manually create a Mental Ray Output Pass in the camera's Mental Ray section. Since then I have gone on to write a PyMel script to automate the process. So here is the script. # -- code start -- from pymel.core import * def uniqObjIdAssign():     # Written by Patrick Woo     # usage:        # - make sure mental ray is loaded, and set as your current renderer     # - select the camera     # - then select all the objects to give unique objectIDs to, and run this script     # for more info go to:     # http://patrickvfx.blogspot.com/2014/11/adding-objectid-pass-to-ren...

Adding ObjectID Pass to Render Output in Maya

Image
(This article has a second part, with a more complete script, which you should check out later.  Read part 2 of this article ) So I was trying to find out how to generate ObjectIDs for Mental Ray renders in Maya. Peering into render passes and render layers settings, I could not find an objectId setting or preset. So I had to search the Internet for some answers. Here's a little help from Autodesk folks on how to generate object ID pass for your mental ray renders. http://knowledge.autodesk.com/support/maya/troubleshooting/caas/sfdcarticles/sfdcarticles/How-do-I-obtain-an-object-ID-pass.html Quoting from the page: -- start quote -- To obtain an object ID pass, please follow these steps: Select all the objects that you wish to include in the pass, and execute the following MEL script: addAttr -ln miLabel -at long -k 1; This will add a new attribute called “MI Label” for all the objects in the Extra Attributes section. Once you create a different MI Label for ...

Unity 3D Test with a Serial Port Ranging Sensor

Image
I've trying my hands at working with Unity3D, and getting used to the workflow, including scripting and working with external input devices. In this video I successfully get Unity to receive input from a Ranging Sensor connected to the computer via a serial port. When I put my hand within range, the code triggers the small cubes to move up, and the larger cube to turn red and rotating. After removing my hand for about 4 seconds the cubes are programmed to fall back to their original positions. The ranging sensor chips were programmed by someone else before hand. In the future I want to look into programming these chips as well! :)