Hi,
In recent OC settlement rounds, I was reminded of a problem which always annoyed me. It's the possibility of material ending up behind an object, which cannot be seen by the player. It's especial fatal with small lava puddles behind a vehicle or a building.
Minor annoyance is solid material for example earth landing behind a building from an earthquake - or through a loam bridge which got build. There is also snow of course. But the major threat comes from liquids.
-------------- Finding a solution
--
I talked with Sven about this some weeks ago.
My first suggestion was making liquids semi-transparent and creating it in front of objects. (This would also have been nice for showing the background material behind the water, would probably look awesome), however Sven said that this doubles the landscape calculation and is not a valid option.
--
So my second idea was to make the objects, which are covered, semi transparent. Now, this would work nice for a building under water - but it get's tricky for objects only partly covered in material. Now we'd have transparent buildings shining around, only because of small pixels of earth or water somewhere on the object, also not great.
---
This is where my thoughts are stuck.
So, does anybody have an idea how to solve this problem :)?
In recent OC settlement rounds, I was reminded of a problem which always annoyed me. It's the possibility of material ending up behind an object, which cannot be seen by the player. It's especial fatal with small lava puddles behind a vehicle or a building.
Minor annoyance is solid material for example earth landing behind a building from an earthquake - or through a loam bridge which got build. There is also snow of course. But the major threat comes from liquids.
-------------- Finding a solution
--
I talked with Sven about this some weeks ago.
My first suggestion was making liquids semi-transparent and creating it in front of objects. (This would also have been nice for showing the background material behind the water, would probably look awesome), however Sven said that this doubles the landscape calculation and is not a valid option.
--
So my second idea was to make the objects, which are covered, semi transparent. Now, this would work nice for a building under water - but it get's tricky for objects only partly covered in material. Now we'd have transparent buildings shining around, only because of small pixels of earth or water somewhere on the object, also not great.
---
This is where my thoughts are stuck.
So, does anybody have an idea how to solve this problem :)?
Do we have any benchmark information on how harmful doubling or quadrupling landscape calculation would be?
Why not just create most buildings behind the landscape? It's not just liquids after all, but sometimes solid pixels are annoying as well. This wouldn't require any engine work, but just a different default plane for buildings.
It would require two landscape drawing passes (or some kind of z buffering); not two calculation passes.
> however Sven said that this doubles the landscape calculation and is not a valid option.
It would require two landscape drawing passes (or some kind of z buffering); not two calculation passes.
>Why not just create most buildings behind the landscape?
Because they would need to be in front of tunnel but behind earth.
Is there a plane that does this? I thought it can be either behind the landscape (also behind tunnel) or in front of everything.
> It would require two landscape drawing passes (or some kind of z buffering); not two calculation passes.
Now, how harmful is that?
>Why not just create most buildings behind the landscape?
Well would buildings not just simply disappear in a lake? (but for earthquakes it would make sense to see your building literally buried).
You can display your semi transparent building and the building which is above the water at the same time. It would only require some lines in CreateConstructionSite to create the same graphic (without being in the background) again. Corrent me if I'm wrong but a 50% transparent layer of a in front of the same building is non-visible as long as there is no lava,water etc.? The only problem I see here is that all building graphics lag like the double amount of construction graphics.
Actually materials (or at least the material pixels) could have a Plane like objects, that would mean if I empty my barrel that some pixels could be created with a Plane in front of the clonk and some with a Plane behind the clonk. And the clonk would appear to be in the middle of the water.
I think you always have the problem that the material is either behind or in front of the object.
I think you always have the problem that the material is either behind or in front of the object.
>Second idea
You could draw objects behind water, and as soon as there's one pixel of water in front of it, draw a second, semi-transparent image over object in front of the water.
No, anything that is bound to a condition ("if there is water") would not work - it would simply be way too slow to do the checks.
It's either always or never!
It's either always or never!
>No, anything that is bound to a condition ("if there is water") would not work - it would simply be way too slow to do the checks.
If I recall this correctly, a "water check" is done anyway. (for swim action stuff or for objects floating up in water).
But if at all, it is probably only done for the center of the object or something. Not for the complete shape
If a big object is submerged halfway, we'd run into problems anyway. Modulating it with water color would look silly for the part that is still outside.
A very cool solution would be a pixel shader that post-processes the drawn landscape+objects according to material. For water, it would modulate and blur the objects. Lava could add bloom.
A very cool solution would be a pixel shader that post-processes the drawn landscape+objects according to material. For water, it would modulate and blur the objects. Lava could add bloom.
As stupid as it sounds - can't you just draw certain Object categories (C4D_BehindLiquid) behind the liquid, which you could then see if the liquid material was translucent? Then it would also only apply to the submerged parts of the object.
That still requires more than one landscape drawing pass, as Sven described above:
1. Draw material
2. Draw objects
3. Draw liquids
1. Draw material
2. Draw objects
3. Draw liquids
My idea would be that materials create colored waves and bubbles etc. in the shape of little particles all the time or only when in front of buildings. Imagine a hut which is half in the sea, so you can see some small, blue or white lines passing by. And light yellow bubbles even show the exact surface of lava seas.
Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill