Wednesday, December 28, 2011

Christmas Lights

The decorative lights the neighbors put on their bushes and houses for Christmas and the last work of Sam (the initials) inspired me to do the following exercise. I decided to write our initials with a LED rope.

Unfortunately I could not use the letters from Sam. I needed single stroke letters, so they could be used as a path for a cylinder which represents a rope.
I was not able to find a single stroke font, so I had to make one myself. Obviously, 3ds Max was a bad choice for font manipulation due to its poor set of vector graphics tools. Instead, I used Inkscape, a perfect app for vector  manipulations.

First, I needed to find a prototype font that would have a fancy shape that would go well with the festive mood of Christmas. Monotype Corsiva seemed to be the best match.



I traced the letters from inside. Then I simplified the resulting path and made the curves more round remembering that the LED rope is rigid and does not bend very well:

(the curly tail of the S letter was eventually given up)


I am sure you've noticed that the paths intersect. The intersection spots required more work. In real life ropes do not go through each other; instead they lay on top of each other. More bezier curve editing after the import - and the paths were not flat anymore:


 


The next step was to make a LED material.

It should be a self-illuminating material, since the rope emits light.
I used Architectural Material. For bump map I used the bump map from Transparent Plastic material.


For diffuse and intensity maps I used a gradient ramp, since it is the base of any light. The light part represented a light bulb, and the dark part was a plastic wrap cord. Since the rope is round, the inside bulbs are visible from any point of view. Thus, I used a linear white-red gradient and mirrored it along its light end. Also I turned the gradient 90 degrees on the VW axis and added some noise to imitate the slightly uneven structure of the plastic wrap.


I rendered my sample LED cylinder, and it looked like a Santa Clause cane, not like a LED rope! The gradient step was way too small.


How to make it bigger? 

I applied the Unwrap UVW modifier and adjusted the UVW map to make the gradient look proper. It was a mistake, since I planned to copy my cylinder around for each letter. Once I started messing up with UVW map, it got converted from being flexible to being fixed. This means that the UVW map got attached to the object vertices. Since every letter cylinder has a different length, its UVW map got streched or shrunk. This made my material be unevenly distributed on each letter (the N letter map distortions were exaggerated a bit to make them more clear):


This approach would require me to adjust a UVW map of the every letter, and the results would not be consistent. Not good.
While looking for a workaround I went again through the Gradient Ramp options. And I discovered the Size field!


It was exactly the value I needed to manipulate in order to adjust the real gradient size.
Here is what I got as a result! A LED rope shaped in the form of our initials!



Happy New Year!

No comments:

Post a Comment