Twist and Shear

Started by oggyb, December 22, 2006, 12:02:32 PM

Previous topic - Next topic

oggyb

When I've used this shader so far I've only been able to get it to bend in one direction.  What should I do to make it wobble all over the place?

I've tried layering them with different directionality but this doesn't seem to work.

Thanks.
Matt.

oggyb


efflux

I don't think you can do this because it will simply pull one way. It's one of the reasons I want to get deeper into TG with function nodes but I'm having problems with that. The TG2 UI is excellent. Very simple and I think it wont be long before people start to want to go further which your query is an example of. At the moment I'm after more info about why I can't see internal networks.

Tangled-Universe

#3
I'm also not able to see internal networks  ???
I'm wondering what I'm doing wrong, no matter which node I try (I know some don't have internal networks, like fake stone shader), it never shows shows up...
Anybody a guess?

TIA

Martin

Oshyan

Twist and Shear is a particular displacement shader designed to displace the terrain in one direction. To get more control over lateral displacement use a Redirect Shader and plug your displacement shader (a Power Fractal for example) into the input of the axis which you want displacement to be on. Plugging it into X and Z only will cause lateral but not vertical displacement. You control the strength and other aspects of the displacement in your displacement source shader, e.g. Power Fractal.

- Oshyan

oggyb

Thanks a lot Oshyan, I'll try that now.

efflux

#6
Thanks JavaJones (or Oshyan as I now see your name is). Thats a cool technique but what if we want the displacement to be relevant to planet surface (altitude) rather than X,Y,Z?

Also, what about this internal networks thing? There is mention on another thread of seeing the internal network of a fake stones shader but I can't see any internal networks of any shaders. I'm still using the free version. I was kind of holding off a bit from moving to the Deep version because of crashes but I'm learning to just keep saving.  It seems to be UI related. I just lose UI control and TG2 freezes up or suddenly closes. I have to keep booting my PC. The Mac version doesn't seem so bad. I want to experiment a bit to see how function nodes can work. We have a tremendous amount of control in Mojo with nodes so this is what interests me about TG because the rest of TG is better than Mojo except that we could do with a few more fractals and a curve graph node. I'm guessing those features will come in time.

MeltingIce

You could always try using a bunch of heightfields if you are close enough to the terrain and apply different shear shaders to each of them.  Just an easier way to go about doing it, you might not get as good results though as Oshyan's method.

MeltingIce Network | Wii Number: 3881 9574 8304 0277

Oshyan

Efflux there are no internal nodes in the Fake Stones. I think someone got confused. ;)

There are no limitations in the free version as far as the node network is concerned, so you should have access to the internal networks just fine. Relatively speaking there are actually quite few nodes with internal networks. To test if it's working for you try adding an Object or Population. Both have internal networks. Right-click the node in the network view and go to Internal Network or press the internal network button next to the name of the node when you are viewing its settings panel.

If you want to just restrict displacement to certain slopes or altitudes you can use a Distribution Shader as a Blend Shader for the displacement node.

- Oshyan

efflux

#9
OK Oshyan. That confused me on the other thread. It seems to work as you say.

Thanks a lot! I've got that now with the distribution shader. That has to be the only shader I never tested. There is another way in Mojo which is maybe going too far here but in this image:



I got values of displacement and largest feature size in one material to increase (or decrease displacement in Mojo's case ::) - just one of the many problems) in value with height by adding output from an altitude node. Mojo has the curve graph so I was able to have the values modulate about as well. We don't have the curve graph in TG2 but we have enough to play with anyway. It's things like this that makes me wonder how much under the hood of TG2 I can get.

efflux

Just to explain further my comment about Mojo. The land materials displace on an inverse orientation from water and objects. You have to displace by negative values to displace outwards. So your land displacements are screwed up for use on objects and water without reversing the displacement orientation. Nobody seems to think it's a problem ???

efflux

#11
oggyb.

I'm experimenting with the distribution shader to get overhangs all around. It's tricky to build a planet this way and it's the same in Mojoworld because if the underlying terrain has a lot of roughness or small feature size then when displaced a lot in all directions, the mesh gets in a mess. In that extreme Mojoworld example, the underlying terrain is very smooth so it pulls out more smoothly but it's still a bit messy because it's so extreme and best avoided to that extreme. However if you can displace the whole terrain out without using a fractal you can get smoother results (haven't tried this in TG2 yet). The simple twisting or shearing of the terrain in one direction stops the mesh all clashing. It creates nicer looking results.

By the way I wish we could get spiky terrain like that Mojoworld example but with full planet fractals. It's sparse convolution fractal with a curve applied. Sparse convolution would not be totally necessary but a curve graph node would definitely be the best addition to TG2 possible in my opinion.

My PC has seized up again. I know TG2 is not finished yet but unfortunately it's the most unstable app I have ever used.

Oshyan

Yeah, I understand your frustration. It's doubly so for us because none of this showed up in alpha testing, and we do have a fairly good-sized test group. But all this extreme and random instability was not seen before release. It seems like there may have been some recent changes that are at the root of some of these issues, so perhaps it was just a case of lack of time to test everything fully. But it will get sorted out, of that you can be sure.

As far as the trickiness of displacements as regards roughness and "out of control geometry", I think this is just one of the issues that has to be wrestled with. But we definitely want to make it easier to create these interesting, other-worldly terrains and shapes and development time will go into this in the future. In the meantime play around with the Compute Terrain/Compute Normal settings - Patch Size, Smoothing, etc. and you may get some interesting results. There is a good amount of power in there already and the end product will have even more.

I think Mojo now in 3rd edition has had some time to mature and really focus on exposing the engine's power. Over time I think we'll largely eclipse Mojo's capability, but I imagine there are things Mojo can do that TG2 might not be able to for a while.

- Oshyan

efflux

OK.

I took things to extreme using the distribution shader and displacing the higher area which actually has no fractal just a displacement shader set to lateral only with a constant attached and I messed with the displacement shaders multiplier. The terrain was smooth so as to avoid problem areas but you can still see some. I'm just testing to extreme and I know oggyb probably wants realistic stuff but you could just tame it down and add more roughness etc.


Oshyan

Wow, that's really cool looking. Unlike anything I've seen from TG2 so far. Maybe not realistic, but unique, and that's good! :)

- Oshyan