Tuesday, June 17, 2014

Houdini - Duplicating curves

Since the last update on the procedural terrain I have been trying to duplicate my original curve into several others religiously but without much success. The internet overall had been of little help with this as in most solutions the premise was to simply create another curve. So instead of creating a curve I decided to UV all my surfaces and combine the result into the final mesh.

Simple projection
Projection with a measure and curve length calculation for non-stretched UV's.
For the duplication of the curve I tried various different methods of which nodes like the ForEach, wireBlend and copy gave me the best results. However, they didn't allow me the bend the curve farther away with each instance and so they weren't what I was going to use. Then -magically- a colleague approached me after reading this blog and sent me a file in which he had made a small example scene with a curve, a VOPSOP with several point to point calculations and a blendShape node that would blend the copies between the two -in this case- 'blend to' nodes. This was a fantastic solution which I was able to incorporate immediately.

Turns out the sweep node has a 'group output' check box which I am going to use for unique UV sets for the amount of sweeped curves I'm projecting, though I still have an issue using the measure node to calculate the exact length of each individual curve. Somewhere along the way my copyGroups from the copy node are going missing and I can't refer to them anymore.

The interpolation of the duplicates from the copy node is calculated using the in- and output of the VOPSOP.
Stretched mapping as the UV calculation is using only the length of the first curve.
Holes in the surface where the group selection only calculates the height of the vertices of the lower located mesh.

Another few things I definitely want to apply before I start building the trenches are:
  • Create non-stretched UV's for the additional 3 sweeped curves using the length of the line used for the sweep and the measured length of the curve.
  • Ability to adjust the sweep distance for each individual curve so I can determine the amount of land they smooth out.
  • Find a way to get rid of the holes that are currently created in the landscape mesh. I know these are created by a group selection a tiny bit back up the selection creation grouping but I can't seem to figure out how to make that selection smaller.
  • Create a polygonal bridge between the existing sweeps so I can create a selection for the area's between the trenches. This may become handy for the distribution of details later.
That was it again. Thanks for reading.

Tuesday, June 10, 2014

Great War Frontline in Houdini

My internship is awesome and since it's coming to an end I guess I can go into a little more detail than I did before. I haven't signed NDA's for everything but I'm still trying to be as careful as I can, obviously.

I touched compositing on two series and was allowed to do some vfx on one of those also. I baked animation caches and wrangled with shots for a little over two weeks with so much troubleshooting I filled two 200-paged notepads. Learned a metric ton about why this stuff can go so wrong and since end of February I've been working on a full feature film which name I unfortunately can't mention. At least... I think that's what the NDA I signed said. Better safe than sorry.

Save the practical knowledge, I've also learned so much about film pipeline I can't fathom to think I could remember it all in a month's time. Fortunately I've been keeping a day journal and summarizing everything I'm picking up here and there so I can visualize what has passed my way. Working with Linux every day, talking to all the talented people at Grid and being allowed far more responsibility than I had first anticipated really pays off. I feel like a sponge; continually collecting knowledge.

But anyways, now that's covered I'll follow this up with some stuff I've been working on this weekend. I might have mentioned before that I still have a school related retake left to do and as this weekend was a long one where our team didn't have to do any overtime I figured it would be a nice opportunity to start my Houdini project. During the past couple of weeks I've also managed to squeeze some time into PFTrack, Boujou, Matchmover, Composite, Fusion and Nuke, but nothing quantifiable has come from those efforts. Just a lot of stuff that's really not worth showing.

A while ago I went about and wrote this big document in which I explained the how and what. In case you are interested in reading this document, you can contact me via mail. Below are some samples of what you'll find in it.

Sources to the information gathered in this document are covered in a list that occupies the last two pages.

During this weekend I managed to create a procedural displacement map, but realized I could also do it in a VOPSOP as it offers the same nodes as the VOPCOP. I was also told it would be much faster if I'd create my height map in the same geo group but I haven't been able to crosscheck this with my scene. Both compile almost immediately unless I increase my grid size with a factor twenty. Then it won't compile at all.

Displacement map in VOPCOP
For the image below I used an anti-alias noise node on top of a cell noise node to create this hilly landscape. The cell noise node allows me to make it really flat (almost countryside-like) or change the spectrum entirely and go mountainous. The anti-alias noise node allows for an uneven landscape and offers different noise option to tone it. Then I thought it would be cool add rivers by creating a veins node.

Displacement map in VOPSOP
What comes after this is taken from a lecture posted on YouTube by my teacher, Kim Goossen, as it is a well documented way of projecting curves on a surface, creating a point selection tool out of this and smoothing surfaces using color id's created with attributes. Next to this he also takes the effort to troubleshoot certain problems that occur during this and offers different ways of achieving the same result.

Curvesweep point selection.

Color ID'd to calculate the size and height of the final points.
I am currently looking into a way to copy my original curve to create three parallel curves to each side and bend their ends away by using a parabola function per control point. So far with the help of a friend I've come to the function below... though I'm pretty sure this won't work for each point as I've only managed to get two correct solutions out of it. The rest were off by decimals.

y = ((x-(n/2)+1)²) / 4

It is still not correct however and I'm leaning towards using a different method (which has been suggested by a different friend) that would assist me in reaching the same solution otherwise. Still, I really want to make this function work and apply it to my curves. Would be great to see it work.

As a final to this wall of text I want to refer to my previous blogpost where I addressed the idea for a short. After giving it some thought I've figured it's better too look ahead but not too far. Each idea that looks like a great one often turns out to be one I don't want to finish. My best bet for now is to write each one down, fool around and learn as much as I can to properly visualize what I am capable of finishing in half a year than to be going with each fantastical idea. It's a sad realization but a necessary one.

Anyways, that was it for now. Updates are long and far apart but they'll keep coming.

Thanks for reading,

ps. as icing on the cake I was offered my first real industry job at Grid for the summer holiday! Weeee! Not sure what my job title will be but it'll be awesome regardless! I should totally celebrate.