Planetside Software Forums

General => Image Sharing => Topic started by: Volker Harun on August 23, 2009, 03:21:57 PM

Title: Just a few steps ... to procedural craters ...
Post by: Volker Harun on August 23, 2009, 03:21:57 PM
Once ... while working on some functions ... it happened that TG2 rendered the following image:
Title: Re: Just a few steps
Post by: Volker Harun on August 23, 2009, 03:24:11 PM
Not even 24 hours later ... a guy, let us call him Frank, asked if it  were possible to use those functions for craters ...

TG2 offered a mask:
Title: Re: Just a few steps
Post by: Volker Harun on August 23, 2009, 03:26:48 PM
This is now 20 minutes ago ... and the first procedural crater function is arising ...

to be continued  ;D ;D ;D  ;)
Title: Re: Just a few steps
Post by: FrankB on August 23, 2009, 03:36:11 PM
Juhuuu!
Title: Re: Just a few steps
Post by: Tangled-Universe on August 23, 2009, 03:52:43 PM
The second one looks like bullet-holes ;D
An easy to use procedural crater shader would be awesome!
What functionality do your craters share with the crater shader within TG2?
Title: Re: Just a few steps
Post by: Volker Harun on August 23, 2009, 03:59:57 PM
Martin ... I cannot recall to have visited the crater shader.
Seriously, I am at the very beginning ... having at the moment two functions that share the same 'geology' but have very different parameters.
;) As soon as I understand, what I have done, there will be as much functionality as reasonable.
For a decent rim, I'll need a third function, I guess.

Volker ;)
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on August 23, 2009, 04:15:06 PM
Okay ... first of all, the overall scale of the functions resize the diameter of the craters and the width of the rim.

There are two displacements used. One for the rim, and one for the crater itself ...

About the relation of rim and crater, I'll have to fiddle around a bit ;) ...
Title: Re: Just a few steps ... to procedural craters ...
Post by: Naoo on August 23, 2009, 05:17:21 PM
Hi

The "20-minutes-ago-crater" are very cool!


ciao
Naoo
Title: Re: Just a few steps ... to procedural craters ...
Post by: trailgirl on August 23, 2009, 06:08:00 PM
I love those voronoi circles, especially the last one, great texture too.
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on August 23, 2009, 06:38:25 PM
Thanks  :D :D :D

An Update ... Same Point of view ...

It is reduced to one, more simple function that handles the following inputs:
- Overall scale of the craters (image has 10m, the crater in the lower left corner has a diameter of 8m)
- Prominence of craters (from standalone to flow into each other like in the image)
- Width of rim
- Steepness of the rim

Is there anything that should be included?

;) Volker Harun
Title: Re: Just a few steps ... to procedural craters ...
Post by: FrankB on August 23, 2009, 06:44:22 PM
Geil!
Title: Re: Just a few steps ... to procedural craters ...
Post by: Tangled-Universe on August 23, 2009, 06:54:14 PM
Looking great so far!

It would be great to be able to selectively displace the rim and/or crater.
But I'm pretty sure that's possible.

Quote from: FrankB on August 23, 2009, 06:44:22 PM
Geil!

lol
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on August 23, 2009, 07:02:13 PM
Ah - yes - the outputs ...

- overall mask of the crater (for shading ...)
- mask of the inner
- mask of the rim (in the above image, the rim has some perlin gaps)

Thanks ;D

Volker

Title: Re: Just a few steps ... to procedural craters ...
Post by: Gannaingh on August 24, 2009, 02:06:38 AM
THis look very promising...also extremely cool, I am especially fond of the first one.
Title: Re: Just a few steps
Post by: Falcon on August 24, 2009, 02:32:18 AM
Quote from: Volker Harun on August 23, 2009, 03:26:48 PM
This is now 20 minutes ago ... and the first procedural crater function is arising ...

to be continued  ;D ;D ;D  ;)

I want these for my moon scenery! tgc, please... :-)
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on August 24, 2009, 06:12:15 AM
@darthvader ... me, too ;)

@falcon ... In fact, I am thinking of a simple crater shader, which can be downloaded from NWDA (http://www.nwdanet.com/) for free. It will have less masks and will not include the following:

At the moment a testrender is going for the warper, which gives some distortions to the shape of the craters ... accordingly there will be the possibility to 'randomize' the rims' appearance and displacement parameters ... And of course, I am trying to give you some presets ;D

Volker
Title: Re: Just a few steps ... to procedural craters ...
Post by: cyphyr on August 24, 2009, 06:20:28 AM
Astonishing and synchronous :)
I knew it could be done and in fact that was my next endeavor after finishing the procedural planet :)
Thankyou
Richard
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on August 24, 2009, 06:55:01 AM
Dam*%& .... The craters got an infection with amoebiae ...  ;)  ;D ;D
Title: Re: Just a few steps ... to procedural craters ...
Post by: domdib on August 24, 2009, 07:33:00 AM
Now that is a seriously interesting looking terrain - and the surface shader is lovely too.
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on August 24, 2009, 10:06:08 AM
Here is a preview of a simplified crater function, I just dropped it onto a simple fractal terrain.
It might be available soon. Just needs a checkup, clearance and documentation (maybe) ;D

Volker
Title: Re: Just a few steps ... to procedural craters ...
Post by: Tangled-Universe on August 24, 2009, 10:14:41 AM
The principle looks good so far!
How does it look when you make a huge crater? Like half the size of the mountains in the background for example and make it intersect with the mountain.

Cheers,
Martin
Title: Re: Just a few steps ... to procedural craters ...
Post by: littlecannon on August 24, 2009, 10:26:32 AM
Hi Volker... Top stuff. My brother asked the other day if it was possible to randomly spray craters anywhere, to which I said "no, not at the moment"... It seems that all our minds are inter-connected in some way... Crater on. ;D

Simon.
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on August 24, 2009, 12:43:22 PM
@TU: They just blend with the terrain ... when using a displacement along normal, you might encouter very distorted displacements. I recommend to use a vertical displacement.
Nonetheless a matter of taste.

@Simon: In fact, two years ago, Efflux and me were already quite close to the solution.
Title: Re: Just a few steps ... to procedural craters ...
Post by: Henry Blewer on August 24, 2009, 01:22:57 PM
This crater function would be great. I've tried to make a cratered moon, but became frustrated trying to get the craters placed. (Gave up at number 8) A procedural node clip would be super.
Title: Re: Just a few steps ... to procedural craters ...
Post by: tee on August 25, 2009, 04:46:05 PM
Don't log on for a day and look what happens something gets invented, cool stuff
Title: Re: Just a few steps ... to procedural craters ...
Post by: Henry Blewer on August 25, 2009, 09:18:46 PM
I noticed that also. I missed a fifteen hour stretch. It took me almost an hour to get caught up. I have bookmarked several threads to go back to. It's like taking several college level majors at once. Cloud theory, landscape 101, 202, and 303, function derivatives, and water dynamics. All cool stuff.
Title: Re: Just a few steps ... to procedural craters ...
Post by: acolyte on November 02, 2009, 02:32:24 AM
So what's going on with this one? Volkor, can you post your setup so I can figure out how to use these craters on my project?
Title: Re: Just a few steps ... to procedural craters ...
Post by: acolyte on November 02, 2009, 12:16:04 PM
VOLKER, PLEASE UPDATE AND RELEASE!!! :)

I really need this for a project and I'm at a stopping point until I can figure this out. I tried going in last night and messing around with the Voronoi stuff I could find in the function nodes but couldn't get anything to work? Anyone have any clue as to how Volker is doing this? I would just wait for a commercial release on NWDA but I need to get going on this. Thanks guys!
Title: Re: Just a few steps ... to procedural craters ...
Post by: Henry Blewer on November 02, 2009, 01:18:10 PM
Volker comes and goes here. When he's posting, he puts up dazzling images and confounds us with his use of function nodes. Then you don't hear from him in a while. He is a very busy man.

If you need a large group of craters, I would make a very large grey shade image map. The depths would be controlled by the whiteness of the 'craters' A second image map could be used to make the rim displacements and mound debris where you think it looks right. Further displacement could be made using power fractals using just the rims of the first image map as a mask to control where the displacement would be. Similar methods are used by other 3D apps. I'll help as I can.
Title: Re: Just a few steps ... to procedural craters ...
Post by: acolyte on November 02, 2009, 01:27:19 PM
Thanks njeneb, you are a life saver! I'm a 3d modeler, so i'm fairly familiar with mapping and masks, but what has baffled me for the past few weeks is how to connect the nodes properly in Terragen. So what i'm gathering from what you said, is to just make some basic grayscale height maps and save them out as targas or something like that and plug them into a displacement shader? I'm still a little confused as to whether I need to do a heightfield or a shader setup. I would prefer the craters to be generated procedurally, but if i'm painting a map this won't be the case, right? So in essence, I would have to paint a map large enough to cover the entire planet if I wanted them everywhere, correct? Any help you could provide in regards to a simple explanation of the node connections would be greatly appreciated for these kinds of craters. :)
Title: Re: Just a few steps ... to procedural craters ...
Post by: Henry Blewer on November 02, 2009, 04:25:44 PM
The displacement would use an image map shader. The terrain power fractal could be used. At the bottom is the blend by shader. Connect a multi-shader to this. (try it, a small node network may have to be made) Make sure that 'Fit Blend Shader to this' is checked. A seamless tile pattern of craters scaled correctly with maybe five tiles should work. The x and z mirror should also be checked. Power fractals can be added to break up the regular pattern which occurs.

Let me get back to this, I want to try something...
Title: Re: Just a few steps ... to procedural craters ...
Post by: Henry Blewer on November 02, 2009, 05:17:52 PM
This is a quick and dirty way to do this. I made a tgd (terrain file) so you could see what I did easily. You'll have to supply an image, something with high contrast would work best.
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on November 02, 2009, 05:51:51 PM
Hello,

indeed - I am very busy these days - doing some software development - acquiring B to C and B to B ... which is time consumpting but the base for some few free weeks with TG again ... maybe end of the year I guess.

Anyway, I try to give you some insight to craters to the end of the week.

Regards,
Volker
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on November 02, 2009, 05:53:05 PM
@njeneb ... thanks for jumpin in ;) ;D
Title: Re: Just a few steps ... to procedural craters ...
Post by: acolyte on November 02, 2009, 07:15:09 PM
Thanks so much guys, I really appreciate it! :)
Title: Re: Just a few steps ... to procedural craters ...
Post by: acolyte on November 02, 2009, 08:09:36 PM
Hey, what did the image map look like that you plugged into your sample file? Did you set it up to just render the craters from the current camera position or do I need to do some tweaking? When I render I keep getting sharp jaggies all over the terrain. I'm just using a small 256x256 gradated circle on a mid-gray background. Got any ideas?
Title: Re: Just a few steps ... to procedural craters ...
Post by: acolyte on November 02, 2009, 10:39:50 PM
Ok, i started messing with the file you gave me and after figuring out I couldn't project with a camera and still render using that camera I came up with this. (Check included image). It's really uniform, how can I get it to look really random and sporadic? Do I just make the image bigger? I also don't want the same shapes exactly just tiled all over the place because it will look like its repeated. Thanks for the file though, it definitely helped me understand a little more about what's going on.
Title: Re: Just a few steps ... to procedural craters ...
Post by: Henry Blewer on November 02, 2009, 11:12:27 PM
Now you add power fractals. Some with large displacements along the normal, and one or two with lateral displacements. Input a compute normal to the power fractals with the lateral displacements.
Also a mask for just the crater rims will alllow more precise placements.
Title: Re: Just a few steps ... to procedural craters ...
Post by: Kadri on November 02, 2009, 11:23:00 PM
Njeneb , you know it better i think , there are maybe dem (?) files for The Moon and such...for Mars there are i know.
http://forums.planetside.co.uk/index.php?topic=6217.0  Acolyte you could alter such files with grey maps  power f. and so...

Kadri.
Title: Re: Just a few steps ... to procedural craters ...
Post by: acolyte on November 03, 2009, 01:23:52 AM
@Njeneb
I think I understand what you're saying about the setup, but I don't think i'm getting it right. Do you think you could show me how you would set it up in your example file?

@Kadri
I appreciate the idea. I actually went through about a 2 week span at the beginning of the project where I was conversing with some of the guys at the Clementine project for mapping the moon trying to get height maps since they seem to be pretty hard to get a hold of. I would really like to try and go the procedural route until i'm forced not to because my project requires that I render a lot of different sections on the surface which need to look complex and different. In the end I think it would be a lot less work setting up a complex node structure than having to paint a ridiculously detailed height map for all the craters I need. Plus I don't think I would be able to render it because I would run out of memory.

Thanks for your help guys. Njeneb, I know i'm taxing your time, but any sort of visuals you can provide to help with this would help me get my head around how this stuff works. Hopefully Volker will be able to explain some more and if he ends up posting a preset on NWDA for sale, I will be more than happy to be his first customer. :)
Title: Re: Just a few steps ... to procedural craters ...
Post by: Kadri on November 03, 2009, 01:39:41 AM
Acolyte , excuse me if you said it here anywhere but what are you trying to do? From wide angle to near distant animation?
You seem to know what you want. In the end  i think you can make this with TG2.
But maybe if we/me know it more precise we could help you better on your project.

Edit : http://forums.planetside.co.uk/index.php?topic=7882.0

Kadri.
Title: Re: Just a few steps ... to procedural craters ...
Post by: acolyte on November 03, 2009, 02:38:42 AM
@Kadri
Yeah, I have a pretty good idea of what I want. I started my own thread before I was directed to this one here http://forums.planetside.co.uk/index.php?topic=7902.0 (http://forums.planetside.co.uk/index.php?topic=7902.0). If you look at my first post it has a link to a zip with my terragen file so far (before I started messing with these craters) and a sample render of what it looks like. I'm basically going for as photo-real as possible both from a few hundred kilometers up from the surface down to the inch on the lunar surface. Now, i'm by no means trying to create an exact replica in 3d of the actual surface of the moon, but it needs to look convincing enough to pass for the real thing to the average joe. Shouldn't be too hard, I have complete confidence in Terragen...but I'm still trying to wrap my head around these node setups. I'm only really used to material nodes in 3d, not procedural mathematical nodes, so its a bit convoluted right now. But the end goal, as you can see in that link, is to create a 3d moon in Terragen which will allow me to basically go as far out or as close in as I need to as I place my own imported 3d objects on the terrain for my project. That's why I think it's a better idea to stay almost 100% procedural because it will free me up from having to paint another displacement map any time I want to move to a new area, or make it look like i'm moving to a new area. Anyways, I hope all this is clear... :) I tend to ramble on and on. Thanks for your help again guys!
Title: Re: Just a few steps ... to procedural craters ...
Post by: Oshyan on November 03, 2009, 02:48:24 AM
Actually it's probably best if you continue the discussion in the original thread as this one had more to do with Volker's procedural solution. ;)

Thanks,

Oshyan
Title: Re: Just a few steps ... to procedural craters ...
Post by: DJ on November 05, 2009, 04:07:00 PM
I found a way to produce simple craters similar to these.
Maybe it's useful for someone...

[attachthumb=#]
[attachurl=#]

DJ
Title: Re: Just a few steps ... to procedural craters ...
Post by: Volker Harun on November 05, 2009, 05:51:03 PM
Hey DJ!  ;D

Very fine use of the smooth step scalar here ... in fact this is the base of my voronoi craters, too.  :D

Attached is a work in progress.
Title: Re: Just a few steps ... to procedural craters ...
Post by: Gannaingh on November 05, 2009, 05:54:48 PM
Wow, thank you very much for sharing with us :)
Title: Re: Just a few steps ... to procedural craters ...
Post by: littlecannon on November 06, 2009, 03:39:23 AM
Thanks Volker and DJ....
Title: Re: Just a few steps ... to procedural craters ...
Post by: acolyte on November 06, 2009, 03:37:30 PM
Thanks a lot guys. Haven't got a chance to try them out yet, but i'm very excited about this!!!  ;D ;D ;D
Title: Re: Just a few steps ... to procedural craters ...
Post by: DJ on November 11, 2009, 02:46:03 AM
a moon image with procedural craters....

DJ


[attachthumb=#]
Title: Re: Just a few steps ... to procedural craters ...
Post by: inkydigit on November 11, 2009, 04:08:43 AM
this looks sweet!
Title: Re: Just a few steps ... to procedural craters ...
Post by: MF_Erwan on November 11, 2009, 04:46:10 AM
Nice, but only big craters (>10 km) have a central peak... ;)

Erwan
Title: Re: Just a few steps ... to procedural craters ...
Post by: TheBlackHole on November 11, 2009, 07:59:26 PM
Quote from: DJ on November 11, 2009, 02:46:03 AM
a moon image with procedural craters....

DJ


[attachthumb=#]
Wow.  :o 8) Those are the BEST procedural craters I've EVER seen!!!!!!!
/
| (O)
\                      __
            ==<    |__|
/                     
| (O)           
\


*pure astonishment*
Title: Re: Just a few steps ... to procedural craters ...
Post by: FrankB on November 12, 2009, 09:07:50 AM
they're also the first, I reckon ;D
Title: Re: Just a few steps ... to procedural craters ...
Post by: TheBlackHole on November 12, 2009, 02:33:36 PM
The only way these could be improved would be to add several scales (giant ones filled with dark lava, large ones with rays, medium ones without rays, and then smaller ones like those) that could cover a whole planet about the size of the moon...
Title: Re: Just a few steps ... to procedural craters ...
Post by: DJ on November 12, 2009, 05:30:35 PM
Thx for the comments ragarding the moon image.

Here is an asteroid based on the same technique:

[attachthumb=#]

DJ
Title: Re: Just a few steps ... to procedural craters ...
Post by: Henry Blewer on November 12, 2009, 05:34:38 PM
That looks pretty good. I have never seen one, so I can't really give too much advise. Maybe some smaller craters?
Title: Re: Just a few steps ... to procedural craters ...
Post by: Kadri on November 12, 2009, 06:00:30 PM
Quote from: DJ on November 12, 2009, 05:30:35 PM
Thx for the comments ragarding the moon image.

Here is an asteroid based on the same technique:


Google  "Near-Earth Asteroids" or such ...  I think your way is very good.

Kadri.
Title: Re: Just a few steps ... to procedural craters ...
Post by: DJ on November 13, 2009, 03:05:55 AM
Craters on asteroids can be quite large (in relation to the asteroids size).
Look at this:

http://www.solarviews.com/browse/eros/eros24.jpg

DJ
Title: Re: Just a few steps ... to procedural craters ...
Post by: Dune on November 13, 2009, 03:18:43 AM
But you'll notice that there's no rim on such small asteroids. Without a proper atmosphere and gravitation the debris will be thrown into outer space... leaving only the crater.

---Dune
Title: Re: Just a few steps ... to procedural craters ...
Post by: DJ on November 13, 2009, 05:09:13 AM
Some asteroid craters have rims, even if they are not very explicit formed.
I think it's more a deformation of the rock than the debris, it depends on the material.
BTW craters with rims are simply more attracive   :)

http://www.ioncmaste.ca/homepage/resources/web_resources/CSA_Astro9/files/images/unit5/asteroid_ida.jpg

DJ
Title: Re: Just a few steps ... to procedural craters ...
Post by: domdib on November 13, 2009, 05:47:28 AM
Very impressive asteroid - I would have taken that for a photo.
Title: Re: Just a few steps ... to procedural craters ...
Post by: DJ on November 13, 2009, 05:54:59 AM
Thank you domdib!
Normally I take photos, but my spaceship has a damage, so I had to use terragen instead  :D

DJ
Title: Re: Just a few steps ... to procedural craters ...
Post by: DJ on November 13, 2009, 04:28:50 PM
One more suggestion for making procedural craters:

If you combine two voronoi noises, the resulting craters will be more random, both in size and distribution.
This comes closer to reality.

[attachthumb=#]
[attachurl=#]

DJ
Title: Re: Just a few steps ... to procedural craters ...
Post by: DJ on November 13, 2009, 04:57:29 PM

Now the same asteroid with the improved model for the small craters.
I think this looks more realistic....

[attachthumb=#]

DJ
Title: Re: Just a few steps ... to procedural craters ...
Post by: rcallicotte on November 23, 2009, 10:26:45 AM
I agree DJ.  This looks better.  With some slight color variance across the surface, this would be exceptional.
Title: Re: Just a few steps ... to procedural craters ...
Post by: rpleak on July 17, 2018, 01:11:07 AM
This is a great addition to Terragen. Is there anyway to randomize the diameter, number, and scattering of craters?

Rob P
Title: Re: Just a few steps ... to procedural craters ...
Post by: luvsmuzik on July 17, 2018, 07:53:27 AM
Quote from: rpleak on July 17, 2018, 01:11:07 AM
This is a great addition to Terragen. Is there anyway to randomize the diameter, number, and scattering of craters?

Rob P
Just guessing Rob P, but inside the 2craters tgc, are the variables ......try changing the seed for scattering. You should already have two constant scalar on the voronoi noise blue nodes which should control the number. I am sure there is a detailed explanation, but that is where I would start experimenting making small changes in those numbers rather than extreme.
Title: Re: Just a few steps ... to procedural craters ...
Post by: rpleak on July 17, 2018, 08:53:29 AM
Thanks, I appreciate the help! I'm just now getting in to using nodes, but I can see how powerful they can be...if you know how...

Rob P
Title: Re: Just a few steps ... to procedural craters ...
Post by: WAS on July 17, 2018, 11:31:05 AM
This is only really good for craters at a severe distance. They only have one scale controller without breaking it, so you'll have to mask out the function to thin them out to add others, but that will create broken cut off craters. Adding multiple crater shaders gets too dense for a natural look without masking. And the base functions can't get any thinner. Additionally the crater edges will always be a hard edge.
Title: Re: Just a few steps ... to procedural craters ...
Post by: bobbystahr on July 18, 2018, 07:19:21 AM
new life on a 9 yr old thread...good thing as well as I'd forgotten this.