Filtering by Category: Pipeline

Creating Floor Plan Screenshots

As we craft the puzzle structure for RedFrame, it's very useful to have a birds-eye view of the environment so that we can better see how puzzles physically relate to one another. I spent some time over the weekend creating a simple Unity editor script that allows me to export two very large screenshots, one for each floor of our house environment. The script creates a new downward-facing camera, sets it to orthographic mode, and adjusts its near and far clips planes to cut out only the vertical section of the house that I'm interested in. It then manipulates the camera's projection matrix to produce an oblique projection. This oblique perspective makes it much easier to see walls and determine height, and has the fun side effect of making it feel like a top-down RPG. Rather than capturing an image with Unity's built-in Application.CaptureScreenshot method, I instead chose to render to a much larger off-screen RenderTexture with a square aspect ratio. This way I can guarantee that the resulting images will always be the same dimensions, regardless of how the Unity editor windows are set up.

I combined the two floor images in Photoshop as separate layers, and gave the top floor a slight drop shadow. I can easily toggle between the top and bottom floor by hiding the top layer. I've created additional layers in which I can create diagrams and notes. As the environment evolves, it'll be very easy to re-run the script in Unity, producing a new pair of screenshots that can be dropped into the same Photoshop file.

You can download my floor plan screenshot script here. It was written very quickly, so if you see room for improvement please let me know!

- Michael


Open Multiple App Instances in Mac OS X

We do all of our light baking for RedFrame on a beefy Mac Pro, but due to limitations in Maya and Mental Ray we have to run multiple instances in order to saturate the available processor cores. On Windows it's very simple to run multiple instances of a single application – this is the default behavior – but we work on OS X which only allows one instance of an app to be running at any given time. We've commonly used a messy workaround: duplicating the application on disk and keeping references to its many copies in the Dock.

Today I discovered a much better solution. It's possible to open an unlimited number of instances of an app through the terminal. To instantiate Maya 2012, I just execute the following command:

open -n /Applications/Autodesk/maya2012/

Using Platypus I bundled this command into an application that sits in the Dock, ready to spawn additional Maya instances on demand.

- Michael