Friday, June 05, 2009

a few bits and bobs to start the summer

I've been pretty bad about posting with any regularity. Been a bit busy with the family and a lot of the things I've been working on aren't terribly conducive to interesting blog posts, some MEL scripting and playing around in XSI, Nuke, etc. Hopefully I'll get more up to speed this summer.
A few random things . . .

1) added a couple new things to my reel. Again. Not a ton of new stuff, just some 3d tracking stuff and some bits of the Nick stuff (which never got used). Here's a quick hit of a couple of the many Nick pieces we did. (FYI, I modeled a bunch of it, rigged much of it, and animated all of the first bits and some of the last bits)


2) Rich and I did another quick Ilksville thing, "half-shell smile". Trying to keep chugging along with it. It's tough cuz we've both been busy. Got one more cooking as we speak.
larger version here
BTW, congrats to Rich on his installation at the Artomatic show! If you're in DC in the next month or so, go and check it out!

3)Here are a few of the doodles from Corel Painter that I've been playing with.

click for larger

4) I've also gone back to modeling a bit more of the Psychemy guy. As I've talked a bit in my animation class at NYU about modeling for animation (however briefly), maybe I'll post up some of the modeling process for the body and such.

5) After a big of a hassle with distributors, I've finally reorganized things to get The Needful Head DVD a proper home. It may take a few days to for things to get sorted with Amazon, but once it's all working, rest assured, I will pass along all the relevant links.

Thursday, April 23, 2009

3 channel dirt passes

Another technical post about using multiple channels in one image to allow more control in post production, this time with dirt maps (I know some people/software use the term to refer to ambient occlusion maps, but I'm talking here about actual dirt or grime).

The basic premise here being 2-fold: 1) the use dirt maps to create a more realistic look, rather than worrying about bump maps and the like, and 2) to be able to use generic dirt maps to create a bunch of different looks in the final render by combining them in one rgb pass.
I'm going on the basic premise here that often in production you don't actually need bump maps to rough up a surface. Adding dirt to the specular/color components is often just fine to create a rough surface look. This technique is actually applicable if you do use bump maps, you'd just add another pass of three combined bump maps in the color channels (more later).

So what am I talking about? Let's say we have the following image:
(click for larger images)
and we want to dirty it up to get something like this:

Just a bit of dirt to give it some texture or character.
If you knew what you wanted, etc. you could just add the dirt maps to the spec shader, tweak it out to get what you want and render. But the way I'm approaching this allows for loads of changes in post and requires little thought in 3D. This isn't necessarily for every shot or production, but its really useful when you just want to generally dirty stuff up.
Here's how we do it, again using multiple channels to hold multiple images.

This scene in Maya is super simple: Just a sphere and some lights.

I've got three different dirt maps that vary in the size and "frequency" of the dirt (it's basically just black and white images of splotches and splooches if you know what I mean). Here's what they look like mapped onto the sphere:

So I have 3 B&W dirt maps. I map them individually to the R, G and B color channels of a material or surface shader. (one to R, one to G, etc) This will give me a false color image with 3 different images in each of the color channels which I'll pull apart later in post. I also have my spec shader and my color shader.

If I was clever, I would have done the combining of the images in photoshop to get something like this:

Then I would map each channel to the corresponding channel in the dirt material. But I'm wasn't clever here and used each image separately in Maya. No real difference, just more parts.
Then I'll set up my render layers. One for color, one for spec, and one for the dirt.

And here are my renders. Again the dirt will be pulled apart to give us more options in post.

So onto Shake (though, of course, After Effects or Nuke or whatever could be used). . .
The idea is that I'll use each channel of the dirt map separately and get 3 dirt maps from this, which I'll use to muck up both the color and the spec passes.
The basic operation I'll use in Shake is a "reorder" which just puts one channel into all of the other channels (ex. red channel into red, green and blue channels). I keep the alpha. I use a "compress" node to dial up the blacks and whites to the values I want (like transparency but just with color).

Here is the comp below. I've pulled two of the channels of the dirt on the left side, multiplied them together (we want only the dark bits) and multiplied them to the spec pass. This roughs up the spec. Then on the right side, I just copied the dirt nodes, changed the compression a bit and multed them to the color pass to dirty that up a bit also. Then I "added" the dirtied spec to the dirtied color.

Here are the passes once I've tweaked them in Shake (color, spec, dirt):



Once again, here is the final result, with the spec added to the color and both roughed up by the dirt maps.

I know it seems like a lot of work to do this in post rather than doing it in the render, but in fact, once you get the hang of it, it's actually easier and certainly more flexible. For example, I can instantly change both the look and intensity of the dirt right in Shake.

If I wanted to include bump mapping in this, I would simply create three bump nodes in Maya with a basic texture and map the color ouputs of those into the R, G and B channels of another shader (say, a surface shader) to get a "super bump" pass. I could then dial up and down any of the three bump maps in post the same way.
As I said, this isn't always the most efficient technique for every job, but if you export out the dirt map shader, you can instantly add grunge to any object you like and then have some more specific control in post.

Thursday, April 02, 2009

Watch out for the render ninjas . . .

On ur computrz, ajustin ur gamma.

a bit of painting. . . and jealousy

. . . So the other day I checked out the blog of this dude, Mark Behm, and I was blown away. I LOVE his paintings. I scroll down a bit and turns out he's also an awesome illustrator. Ok, makes sense. Keep scrolling and see that he's also a sick sculptor. Wow. Turns out he's also an amazing 3D modeler and texture artist. What? And he's got videos that demonstrate that some of his paintings are done in, like, 10 minutes. On screen. Man oh man, that's impressive! I click on a link and it turns out that he also animates feature films. Ok . . . now I want to kill this guy.
What the hell? Sooooo much talent. I linked to his site over there ------>
He is the first person I've linked to that I don't actually know. Does he care? Probably not. Too busy doing all that fancy art stuff of his better than 99.99% of people in the industy. Dick.

Anyways . . . he inspired me to realize that I suck, so I've decided to try being a bit more serious about drawing and painting. Not too serious, cuz then i might feel foolish, but a bit. Of course, ACTUALLY painting is a big step. So, instead, I'm gonna try to do a quick number in Corel Paint each day. Only for 30 mins or so (ok maybe an hour) just to try to get back in the swing of things, that is, to the degree that I was ever in the swing of things. Here are my first few efforts. If I ever do anything thereafter that I decide I like, I'll post it, but certainly not daily. This is more of a public benchmark for myself, I guess, to see if I get better later.

the "under coat". This is the stuff I forgot that I don't really know how to do well. . .

this is with muck painted over the last image.

today I saw a stupid trailer for "Wolverine" and then did this.

Hopefully next week I'll be able to post up some new Ilksvilles and maybe some other work. Otherwise, you can find me staring at this guy's blog and crying . . .

Monday, March 30, 2009

Been way too long - Ilksville update, doodles, etc

It's been a while since I've posted, mostly not my Fault. We moved (only 10 blocks, but the hassle is still pretty much the same). Been working a ton. Teaching twice a week. Daughter's first birthday. Ex-cet-er-a, Ex-cet-er-a.
But I'm back and I promise to never to be gone for so long. Until such time as I need to be.
Anyways, I'll post a couple of technical things later, but just a quick catch up.

• Been playing a bit in Sketchbook Pro. Really cool program. So simple. I know Photoshop can do all kinds of crazy things and you can make your own brushes and defrost your Xmas turkey and blah blah, but all I really want is something to doodle in that can reasonably simulate pencils, rollerball pens and some markers. I love that there is almost no interface and almost no options other than transparency. Great for quick little sketches, storyboarding doodles and the like. Wouldn't do a serious image in it, but great for jotting down ideas.


• On another app note, just finished a serious 3D tracking gig and got to say PFTrack is still my favorite 3D tracker. As if you care.

• Rich and I are back on Ilksville, after much delay. Spent a day or so adding some front and back cards, cleaning up the sound and reframing the older ones and another day making a new one, "one woman show". Believe it or not, this is STILL just audio we picked up while we were hanging out. No "acting". (you'll see what I mean when you hear it). Rich and I planning to start carrying around the audio recorder more often to build up our library of stuff. There's a couple more we can work with from what we have, but the well is running dry.

You can see the bigger versions of all the revamped clips here (temporarily).

• Would love to be able to post some stuff I've worked on the last year. Maybe soon. I'll just post a pic of one of the numerous Nickelodeon things I animated for a "rebrand" effort at Freestyle. Brian Drucker has bunches of images of it here. He designed it, so I'll let him show it off. My goodness, he has a lot of cool work on his site.

Saturday, January 31, 2009

Wrapping a 3D object in post

Another long technical post. Studio work brings it out in me. This one is for Rich.

Been working for the last few weeks on a big broadcast thing (can't say what). But came across a situation in Maya that I've come across a few time before and never had a good solution for. It's probably that I'm just dense and there is an easy solution, and I've certainly never researched it extensively, but it's kind of annoying. Here's the situation:

I have a circular object (or a sphere, or a spiral or whatever) and I need it flowing or spinning around an object. Normally, not a problem, I'd just put the center object (or a card with video of the object) in the 3D scene and render it that way. Just did that recently on shot with faces inside 3D bubbles. But often, as is the case here, the video that needs to go inside (or sandwiched between) the 3D object(s), needs to be put there by someone else after the 3D render, in the edit.

In this case we've got clips of talent and video that hasn't even been shot yet, let alone color corrected or finalized in any way. So I need to somehow make a tool kit that allows for things to go IN FRONT OF AND BEHIND ONE OBJECT AT THE SAME TIME in an easy way that an Avid editor can do without much instruction from me.



Example. How do I comp this assuming things are moving around and flowing, etc.









The most obvious way is to just mask things by hand (ie. lay the 3D on top and mask out the back sections). But in these shots I'm working on, there are LOTS of pieces and they're all spinning and moving,etc. Don't want to ask someone else to do it and I definitely don't want to get stuck with it. The other solution is to just reframe stuff or change the shots. That would make me feel JV, and wasn't really an option here.
So I thought about for a few minutes and came up with two solutions, both kind of similar, but slightly different in terms of workflow:
1) create a depth shader for the 3D objects that is binary. That is, beyond a certain distance it's black and in front of that distance it's white. Then I'd render the scene normally and use the output of the shader to mask either the front or the back.
2) use the camera clipping planes to chop the render in half and render two separate passes, one for the front half and one for the back half.

I ended up choosing route #2 because it seemed to be the easier thing to pass off to the guys in post. I also KNOW what will come out, basically. The renders on this project are relatively simple, etc, so I think it'll work just fine. I think there are advantages to both methods, and I suspect now that the depth based solution would be the more robust one in many cases, but granting that, here's how I created a workable solution:

As I said, the objects and cameras are moving around, so I needed something a bit more flexible than just typing in numbers. I wrote a script that creates a distance tool between an object (can be whatever transform you want) and the camera. The script just uses some conditional nodes to pump in the distance to the object's pivot to the far and near clipping planes and switches them based on an attribute in a null group. So I can just select the circle (or a locator parented to the circle) and the camera and run the script. Then I set up render layers with the switch set to "near" and then "far" and render the two layers. I get the scene rendered with just the front and then just the back and I can just hand off those two renders.









In post you just sandwich some video in between these two renders. Easy to understand, I hope, for the editors.








viola!

Here's the script I wrote: zbw_splitPlane.mel
Some limitations of my method (which is why I'll probably redo it the masking method, at some point) are that you won't get reflections (I don't think) from objects in front of the split plane. Not really a problem in my shots, cuz there's almost no reflection and things are really zipping around.
The only thing I could see possibly going wrong the masking/depth method would be that things crossing (front/back) could create issues when you actually want to see something in back, but it is occluded by an object in front. There would be no way to get images of JUST the things in back.
Anyways, if anyone has any other thoughts or ideas or solutions for this type of thing, I'd love to hear them.
As always, re: scripts, my code is inelegant and usually just me hunting and pecking around for ideas that work. Don't judge me, just love me.