Sunday, March 29, 2009

Monsters vs. Aliens vs. Apathy

There are a only a handful of animated films that I have intentionally avoided for one reason or another. In some cases, the animation style was just too off-putting. In others, it was the apparent quality of the film as a whole that turned me off.

In the case of Monsters vs. Aliens, however, I simply didn't care. Not about the plot, and not about the characters. While I got a few minor chuckles when I watched the early trailers, nothing in them raised my interest to the point where I felt myself saying, "I have to see this!" In fact, the film was so far off my radar that I frequently found myself saying, "Oh yeah...I forgot that was coming out," when friends would ask about it.

And that's another thing: almost nobody in my animation circle was talking about it. It wasn't a hot topic like many past films had been, so those moments were friends would ask about the film were few and far between. Hence the forgetting.

Anyone else feel the same way? Chime in! Anyone see it? If so, what are your thoughts?

Friday, March 27, 2009

tweenMachine 2.03

tweenMachine 2.03 is published. It fixes a problem that has prevented Maya versions in the 200X series from using the special tick color feature. If you run into any issues, drop a note here (still haven't got the contact page on my site updated yet).

Thursday, March 26, 2009

Booleans, ternary operators, and max

I ran into a situation today that initially stumped me. I needed to take a list of unknown size, check each item in the list to see if it could be found in a line of text, and return a single True or False if any one item in the list matched that check. Oh, and if the list was empty, that had to be addressed appropriately as well. And I wanted to do it in the smallest way possible.

Originally I'd hacked together a short four or five line function that did the job. However, after coming back to the code for some other updates, I noticed that said function was only being called once, so I began looking for ways to nix that function and do the job more directly. Part of the challenge was that this comparison I needed to do was part of an existing if statement, and it had to remain so due to the way the rest of the code worked. In short, the comparison went like this (in pseudo-Python):

thisList = ["list", "of", "unknown", "length"]
if not ":" in line and not anythingInThisList in line:
do stuff
else:
do other stuff

The first thing I tried to figure out was a way to get a single True or False out of a list of various Boolean values. On a whim, I tried to use the built-in max function. I'd used max before in standard numeric comparisons, but never with Booleans. Not surprisingly, it worked quite well.

>>> max(True, False)
True
>>> max([False, False, True, False])
True

Getting the necessary Boolean list to pass to max was a no-brainer thanks to Python's list comprehensions. Here's an example that quickly shows if a given word contains any vowels:

>>> vowels = ["a", "e", "i", "o", "u"]
>>> max([v in "sadness" for v in vowels])
True
>>> max([v in "shhhh" for v in vowels])
False

This process alone solved most of my problem. However, I couldn't always be sure that my list of things to look for would contain anything. The variable containing the list was set by an argument in a function definition, and that argument defaulted to None if no other data came through. That meant that I had to somehow force the output of the max comparison to False if the variable was None, or let it do its thing if not.

That got my thoughts going toward ternary operators. For those who don't know, many programming languages offer a condensed one-line shortcut for the standard if-else comparison, called a ternary operator. In short, it turns this:

if statement:
doThis
else:
doThat

into this:

statement ? doThis : doThat

Not long ago I dug around to see if Python supported anything like this, and sure enough it does (as of one of the more recent versions, but I forget which one), although it isn't in the standard documentation from what I could see. At any rate, the above example would look like this using Python's approach to the ternary operator:

doThis if statement else doThat

With that applied to my max comparison, the end result looked something like this (and I hope this all ends up on a single line in the blog post):

# "line" is the line of text
# "y" is either None or a list of items to find in "line"

max([x in line for x in y] if y is not None else [False])

The reason that False needs to be encapsulated inside a list is because max needs a list of items through which to iterate, even if that list only contains a single item.

It's also possible to generate the Boolean list using the map function and a lambda, and the code isn't that much longer:

max(map(lambda x:x in line, y) if y is not None else [False])

Sneak peek at upcoming RFX project

I had the opportunity to work on a cool project at Reel FX last summer. We were awarded a contract to construct a series of sculptures to coincide with the opening of a new light rail station not far from the studio. Part of the prep phase involved posing some 3D models in Maya, with the resulting models to be used as templates for the final sculptures, and I had the honor of creating the needed poses under the watchful eye of Brandon Oldenburg, VP of Creative at Reel FX, who designed the installation.

Work is well underway on construction of the sculptures, although I can't give any more details at this time regarding what they'll be. However, if you happened to pop into Reel FX during the last month or two, you probably would have seen a work-in-progress version of one small portion of one sculpture sitting in our main atrium. If you didn't...I'm so sorry. Other than that, I can only say this: they will be BIG!

For more info, and a sneak peek at some of the smaller components of the installation (not to scale, in case you're wondering), check out the official site for the Deep Ellum Gateway Project. With the opening of the new station slated for September of this year, I imagine more info about the installation will come along any day now.

Friday, March 20, 2009

Yoono

Just discovered a nifty add-on for Firefox: Yoono.  It sits in a thin sidebar in the main window, and lets me hook up to pretty much everything: chat, social sites, RSS feeds, etc.  I'm even writing and posting this blog entry from it.  Pretty slickaroonie, I must say.  :)

All right, enough geekin'.  For now, anyway. ;)

Wednesday, March 18, 2009

Changing styles, changing times

Imagine if the Merrie Melodies short "One Froggy Evening" were created by today's animation production system. It's very possible that it would turn out very differently, as one blogger speculates via a series of hypothetical notes that might come back from a review session with today's content critics.

What do you think? Do you think that the creation of such a film today is likely to generate that kind of response...that kind of over-analyzation of details that, in the end, really don't matter because it's all fantasy?

At some level, I feel that we are excessively critical with some of the things we create in the name of entertainment. Even in the realm of animation, we don't always allow ourselves to let go and let loose, to just let certain things be nonsensical and come out of left field. Why not?

Think about this: if that film were made as a live-action story (with a CG frog, naturally), matching the appropriate details of the animated version as closely as possible, how would we feel about it? Would we be as willing to accept the presented absurdities and disregard certain glossed-over details like we do with the animated presentation?

I don't know that there are any firm answers, but I've got some thoughts. It's late, though, and I need my beauty sleep (yeah, right....like it's done me much good so far!). More postulating to come later...