Populating Bitmaps?

Started by pokoy, August 27, 2019, 05:31:47 am

Previous topic - Next topic

pokoy

So I finally came to the conclusion that it's way more effective for my needs to use textures rather than building terrain shaders with crazy numbers of noise nodes and masks.
Since I mostly need spherical environments for aviation imagery, the camera's high up in the air overlooking huge areas.

My idea was that I could populate bitmaps on a terrain with random placement, rotation, size - basically what the Populator does with geometry - ideally with a border blend to make tiling less obvious.

Is there any way to achieve this with TG's current toolset? If not, I'm pretty sure it would be a very useful and effective addition.

Dune

Not possible, afaik. You'd have to project the bitmaps somehow (Y), and that can only be achieved by importing texture image maps and merging them together by PF or altitudes, that sort of thing. But repetition is imminent if you don't have (large) enough image maps.
I'm sure procedural would be far better, and even with a few nodes nice terrain effects can be achieved. No need for hundreds of nodes.

pokoy

Yeah, thought so... I hoped someone has figured out a way to do this in the past maybe.

Doing it with nodes may be possible for noise-like structures but in this special case - a mix of rural and village landscape types - I'm way better off by using satellite images, creating masks for noise nodes and 'scattering' them, that's way more efficient... and it would render much faster I guess. In this case, the kind of noise voronoi provides isn't really cutting it.

Thinking further it might be useful for so many different situations, think of it more like using scanned objects versus having to model and creating a texture first. I think it would open up many useful possibilities and make a nice shortcut to believable textures without the hassle of noise nodes. Combined with tri-planar mapping it would be quite a nice thing to have in TG in general.

Dune

I agree. Maybe, one day.......

Oshyan

This is definitely an idea we've discussed at Planetside before and I agree it's an interesting one. Technically I think you can already implement a basic version of this by simply using populated cards or an imported rectangle with your image mapped to it. You'd need multiple populations to handle multiple images, and overlaps wouldn't be smoothed in any way, so it's a limited method, but it may be worth trying, especially if you add alpha maps to the edges of your loaded images/cards which would allow them to blend a bit.

Not sure how hard it is to implement something more sophisticated and specific to scattering images, but it's in the feature request tracker at any rate. :)

Ultimately the kind of improvements to populating that we have planned would I think also help with techniques like this...

- Oshyan

cyphyr

Using cards works well on smaller images, leaves and general debris for example but for larger images that have to blend in with the terrain, it's basically unfeasible.
Glad it's on the tracker, look forward to seeing it :)
www.richardfraser.co.uk
https://www.facebook.com/RichardFraserVFX/
/|\

Ryzen 9 3900X @3.79Ghz, 64Gb (TG4 benchmark 6:20)
i7 5930K @3.5Ghz, 32Gb (TG4 benchmark 13.44)

Tangled-Universe

How about populating cards with the texture applied, so you have rotation/size variation and use force displacement mode on the object driven by the terrain displacement? Critical in this idea is that the "sit on" shader is not the terrain, but the undisplaced planet/plane.

Dune

I think it's hardly possible without strange artifacts. If you populate cards with an image projected on it (world space), you get a lot of overlapping cards (edges) and thus shadows from one card onto another. Unless I misunderstand the way you guys think.

Tangled-Universe

August 28, 2019, 07:54:50 am #8 Last Edit: August 28, 2019, 08:02:49 am by Tangled-Universe
The way I see it is that the cards may overlap on a flat surface, due to size/scale variation, but taken as a whole they are essentially 1 plane.
Displacing the population as a whole will deform the cards as if it is 1 plane so should generate similar results as if displacing the plane to get a terrain.
Or from another angle: can we displace 1 big card object in force displacement node using the terrain displacement and have it look similar as the terrain?
I don't see why not.
Question is then: will the plane object subdivide sufficiently when using force displacement mode or do we need a higher poly card object as texture holder?

Dune

You could be right. Interesting challenge anyway.

N-drju

Quote from: Tangled-Universe on August 28, 2019, 07:54:50 amQuestion is then: will the plane object subdivide sufficiently when using force displacement mode or do we need a higher poly card object as texture holder?

I don't think the native card object has any limitations regarding the subdivision / point numbers. You could apply any displacement to any card with any scale conceivable and it will just heed to this fractal / displacement / etc.

I remember I used a card as a water surface with the actual water shader on it. With all the ripples and waves it has to offer. It was indistinguishable from a default, circular lake object. Would have been much different if card had any set subdiv amount.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

Tangled-Universe

Well, that's good to know then... Never tested that myself. So theoretically it should work...but will it?

N-drju

September 02, 2019, 08:05:37 am #12 Last Edit: September 02, 2019, 08:09:34 am by N-drju
Quote from: Tangled-Universe on September 02, 2019, 06:53:46 amWell, that's good to know then... Never tested that myself. So theoretically it should work...but will it?

Guess it's pokoy's turn to discover. ;)

Why not? If one knows how to bend a card parallel to a planet's curvature plus apply a displacement following the surface normal, then they are good to go.

The only limitation is the knowledge. I can't see any technical (or, to be more precise, "polygonal") obstacle whatsoever.

EDIT: Whoa, wait, wait, wait... do you mean "plane" or do you mean "card"...? Because I notice you use these terms interchangeably. These are different things. Even if slightly.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"

pokoy

My original request was neither of both, not planes, not cards - instead, simply scatter textures, without having to deal with the surface displacement or other objects. It's often available in other packages and renderers: load a few texture files, randomize positions/scale/rotation, set border blend values, maybe randomize hue and saturation.

I thought about placing cards but you'd probably have no border blending and I guess it takes some additional rendertime to displace the cards according to the underlying surface. All of this sound rather cumbersome... and even if possible it's above my head.

I'm recreating the landscape as good as I can with noise nodes and a few surface layers... it works but I'd rather used satellite textures for more realism.

Anyways, I hope it's going to be added, there seems to be interest :D

N-drju

Quote from: pokoy on September 02, 2019, 08:30:59 amI'd rather used satellite textures for more realism.
If this is what you need, then it's doable. There are guys out here who use satellite imagery inputs (DEMs, MOLAs, whatever it is called). I never need it, but I think someone could aid you.
"This year - a factory of semiconductors. Next year - a factory of whole conductors!"