PDA

View Full Version : Mine Passage - Need Turbulence Displacement to Remain Static Through a Morph



JBT27
01-28-2014, 06:58 AM
I am animating a mine passage extending, like a timelapse of mining a vein. Starting with a subD'd square section tube, I want to have the passage extend, but use turbulence, etc., for displacement to give the detailed rock look. But, I need that rock to remain static as the mine extends. The only way I can find to make this work is to simply keyframe the passage stretching along Z; with Node Displacement Order set to Before World Displacement, and the procedural set to World Coords, it works well enough. As mine passages are reasonably straight, I can get away with it.

But I wanted to use morphs, first off, and then tried DP's Spline Deformer, but both of thos carry the procedural with them, like the rock is stretching, even with the procedural set to World Coords.

Any ideas how I can use more sophisticated animation (for curving passages) but still keep the procedural displacement static - so effectively animating the larger displacement through a static finer displacement?

Thanks.

Julian.

ernpchan
01-28-2014, 11:49 AM
What about revealing your object via an animated alpha/clip map?

JBT27
01-29-2014, 03:36 PM
That's certainly a more common way, but in this case, I need the passage to extend whilst the rock face remains visible - so the rock face is moving and the passage is getting longer. So a clip or alpha map does not work for this. Animating stretch is still the only way that does what I need, and as long as the passages are straight, it works. Still don't get why the displacement is moving with the mesh even with world coords set on the displacement procedural.

Thanks for the thought.

Julian.

XswampyX
01-29-2014, 04:04 PM
Works here?

119714

Try it. :)

JBT27
01-29-2014, 04:15 PM
Well that's freaky - I set one up just like that, but it dragged the displaced texture with the morph, no matter what. Tried again, and yeah, it does work - which I guess may suggest that spline deforming it may work. Again, I could not get that to work. Clearly it does for morphs as least, so I guess I must have got thrown by something - thanks.

Julian.

JoePoe
01-29-2014, 06:27 PM
Yes the displacement is staying put for me too...... BUT....

I think there may be a secondary problem.

Any stretching will change the "resolution" of the displacement. Yes?
In XswampyX's example, the displacement in the render at frame two is much crisper that the render at frame 10.
Makes sense. In frame 2 all those polys are squished up tight and much more spread out later on. Even at the high render SubD level this could get pretty pronounced as the stretching continues.

So instead of a morph or stretching, I would just start with a tube long enough for what you need in the end. Use DP's Spline Deformer and just push it along the spline out ahead of the camera as needed. :)

JBT27
01-30-2014, 04:16 PM
Yes, that's what the main problem would have been - stretching, even slightly, showed as a kind of 'fizzing' when procedurals were set to World Coords. That said, I have DP's Spline Deformer working, by pumping a scalar into the Shift Extend input - the fizzing does not happen with this, and it's not using World Coords. Looks OK - pretty much what I need, except that the receding face is very sharp where it meets the walls and only softens towards the end of the extend - I guess that is a subD bunching thing, and cannot think how to keep it softer all the way along. Tried weight mapping just the face and adjacent polys, but it's hard to control. For what I'm doing, I can live with the sharpness and light it out.

I'll post a scene later, but thanks for all the help.

Julian.

JBT27
01-31-2014, 08:47 AM
Huh ... the morph that worked yesterday does not work today - again, the procedural travels with it, instead of the polys passing through it. Switching between local and world coords for the displacement makes no difference. It does with bump mapping, where the polys do pass through the procedural set to world, but not the displacement. The complexity of the mines means morphs is probably the easiest way to choreograph the animation - multiple spline deformers driving passages and shafts that all need to connect does not seem like a straightforward way. I'm almost inclined to have to go with relatively smooth tubes and bump mapping, as the displacement seems so unpredictable - bit of a head banger so far.

The stretching polys undoubtedly play a part, but if the procedural is set to world coords, I still don't get why I am seeing features travel with the morph - at least sometimes they do, sometimes not. Very flakey.

Julian.

JoePoe
01-31-2014, 09:04 AM
Hmmm, well you might consider posting your scene so we can fight the actual bear rather than trying to recreate it. :)

JBT27
01-31-2014, 09:09 AM
Aye - I'm just bundling a couple up and going to post.

Julian.

JBT27
01-31-2014, 09:32 AM
OK - the zip contains two content directories: one using DP SplineDeformer, which works OK using the Shift Extend input - there's a problem with the mined face being flattened and sharp where it meets the passage walls, but that's a minor detail for now.

The other is today's which uses a morph again, a version of which worked fine a couple of days ago when yourself, JoePoe, highlighted that it worked for you and I tried it again. I still don't know why it didn't, but the fact it's happening again is odd - of course, it's entirely likely I'm making assumptions and being a total noob :)

There are three morphs, and I'm using them from the nodal editor, rather than MorphMixer. I have tried MM, but it makes no difference.

I want to have some displacement so that passages and shafts are not perfect - the bump mapped procedurals are OK and I suspect the client will be fine with them, but I want a little more organic going on - mine passages are lumpy things, especially older ones like these. But, the passages and shafts need to be animated as they extend, and the displacement has to stay put; there are a lot of shafts and passages that link each other, and the growth needs to happen sequentially with lots of control to push the camera in to certain spots at certain times.

Much appreciated on any help.

Julian.

JBT27
01-31-2014, 10:18 AM
One thing just occurred: I'm pumping the morph and the turbulence into an Add node - so I guess if the morph values are added to the turbulence values, the turbulence is going to move with the morph.

Julian.

JoePoe
01-31-2014, 11:01 AM
Ha! Just came back with the same conclusion. Went with Morph Mixer and no travel.

But the resolution issue is still there of course.... see below.
During an animation the actual displacement may not move in world space but the resolution change could look like movement of a different sort.

JBT27
01-31-2014, 12:18 PM
Many thanks for looking into that, and for testing it - yes, Morph Mixer does work, and clearly the Add node, when you stop to think about it, is bound to move the displacement with the morph. I can't see a way around that, but someone far more knowledgeable than me (and possibly better at maths - that won't be hard) might come up with a node tree to do that - I get a hint that it should be possible to counter the movement of the morph and apply that to the turbulence so it remains steady, relative to the morph ... but I can't run with any more time on this now.

In wireframe, the poly stretching is very apparent, so yes, there is always going to be some twitching. DP's SplineDeformer using Shift Extend is a solid way around that, apart from the difficulty of the end cap being flattened with very sharp edges.

And I left this one to the end because I had it all worked out in my tiny brain cell - that'll learn me!

Thanks again - much appreciated.

Julian.