Hi guys, Hi Martin,
the last road pics were inspiring to me. I thought about a procedural tarmac instead of using image maps. Then I thought about painted lines and how they would look like on a 3D texture. Then I thought about making the whole road procedural.... and although it's much too early to call this a winner, I've yet made some progress already and so I am showing it here.
I can put this road anywhere on the planet just by moving some vectors. What's next is to make it rotate-able, add some cracks, thin layers of dust maybe... some procedural grass perhaps growing out of those cracks... and so on, to make it a decent render in the end :)
Cheers,
Frank
Winner! ,-)
Hi FrankB
Your road is very good!
Are You able to make curves?
ciao
Naoo
@Naoo: no, not yet. You can paint the tarmac along curves, but not those lines.
Here is a version I did awhile back.
http://forums.planetside.co.uk/index.php?topic=4052.0
Very nice, Frank.
I used simple shape shaders to define the shape, line markings and displacement, no images. The surface was just 3 power fractals stretched along the Z, the direction the road runs.
I had some success in making bends in tests by using redirects along the X, there are some problems with the way I tried it, namely that a fractal is very random, even when set at a flat range of scales. I'll post a cheap method in a bit for bends in the road but it's difficult to control convincingly...
I assume you're using a functional method here, X or Z to scalar, or some such?
* Regarding rotation. Should be an easy enough job with a rotate Y vector or, even simpler, with the 'shader array' node. Set the shader array to one single instance copy of the input shader(one column/one row) and there's a 360 degree rotation value built in to it. You can move the position of the shader with the position values of the same node. :)
Quote from: FrankB on March 02, 2011, 12:25:28 PM
@Naoo: no, not yet. You can paint the tarmac along curves, but not those lines.
Couldn't the road be warped or redirected, if using a 'get position in texture' as the base get node?
Ogre; That's one wild looking network!
I should have been more precise. Of course the road and the lines can be curved: either the way ogre did it with a sine function (if I remember correctly), or through warping it altogether somehow (haven't tried). But that's not what I meant. I meant the lines will not follow along where you "paint" the road.
Cheers,
Frank
Quote from: Ogre on March 02, 2011, 12:31:43 PM
Here is a version I did awhile back.
http://forums.planetside.co.uk/index.php?topic=4052.0
I wasn't aware of this work. Nice you did something like this already 3 years ago!
fascinating stuff...looking forward to seeing this progress!
I just feel that eventually, this will lead to a super-highway in the near future ...nice work Frank.
This seems like another combined effort, and worthwhile following. I don't like roads, but TG2 they're ok. Now if anyone can figure out a way to restrict a procedural road to a given height within certain restraints (and perhaps a rough painted shader to not get roads everywhere), and also flatten that area perpendicular to the flow of the road, we have a way to get winding roads along mountainsides... with the smoothing function it is possible to even the road a bit, but in rough country there should be another way, perhaps by merging highest (thinking aloud here)... interesting.
Intrigued by the international road workers' efforts, I thought I'd do something as well. Based on Ogre's blue setup, but trying to warp. Here's a dirty first draft, but I won't hijack but start another thread as soon as I have something decent.