Jump to content

Blending mode for terrain materials....


Mitovo
 Share

Recommended Posts

Some more tests on another map:


Old:

http://duion.com/files/temp/bugs/screenshot_Paintball%20-%20Gummigrube-1_023-0000.png


With fix:

http://duion.com/files/temp/bugs/screenshot_Paintball%20-%20Gummigrube-1_024-0000.png


With fix and more texture strength on the cliffs:

http://duion.com/files/temp/bugs/screenshot_Paintball%20-%20Gummigrube-1_025-0000.png


So as you can see that in the first image (the current method) the texture on the cliffs is already close to black at some spots, especially in the shadow, so if you were to increase the texture strength there it would fade into total black and look ugly.

But in the second image everything is more bright and washed out, but this is not so much of a problem, since it allows you to add more texture strength as I have shown in image three on the cliffs. So I now have much more texture in the detail as well as macro texture and it is still not as close to black as in the first image.

A little downside is that the new method washes out the colors, but that is not that bad, but less color makes it look more realistic and if you really wanted you could just add more color in the textures to make off for it.

Link to comment
Share on other sites

  • Replies 93
  • Created
  • Last Reply

Top Posters In This Topic

Some more tests on another map:


Old:

http://duion.com/files/temp/bugs/screenshot_Paintball%20-%20Gummigrube-1_023-0000.png


With fix:

http://duion.com/files/temp/bugs/screenshot_Paintball%20-%20Gummigrube-1_024-0000.png


With fix and more texture strength on the cliffs:

http://duion.com/files/temp/bugs/screenshot_Paintball%20-%20Gummigrube-1_025-0000.png


So as you can see that in the first image (the current method) the texture on the cliffs is already close to black at some spots, especially in the shadow, so if you were to increase the texture strength there it would fade into total black and look ugly.

But in the second image everything is more bright and washed out, but this is not so much of a problem, since it allows you to add more texture strength as I have shown in image three on the cliffs. So I now have much more texture in the detail as well as macro texture and it is still not as close to black as in the first image.

A little downside is that the new method washes out the colors, but that is not that bad, but less color makes it look more realistic and if you really wanted you could just add more color in the textures to make off for it.

 

Thanks for all the examples. If anyone else wants to test it but doesn't like dealing with git, just pm or something and i'll chuck up a binary for testing with these changes, i can supply a windows, linux or mac binary.

Link to comment
Share on other sites

Some more tests on another map:

Thanks for all the examples. If anyone else wants to test it but doesn't like dealing with git, just pm or something and i'll chuck up a binary for testing with these changes, i can supply a windows, linux or mac binary.

sorry, up images is default blending

Link to comment
Share on other sites

i don't understand what this happen )), but this my screenshots before and after

befor

 

I'm not 100% sure what versions of t3d we are talking about here. If that sand texture is the stock sand texture from t3d, than i'm guessing picture 1 is from a version of T3D before the change to linear space and picture 2 is a version of T3D that now uses linear space. If you could give a bit more info, i'll be able to give you a better explanation.


For example: What i think is the original texture(do correct me if im wrong) is in the middle, notice how the pic on the left, the sand color is wrong, on the right it is correct. Im guessing if you compared the other original textures like the one on the bricks for example, the picture on the right would be correct.


http://i64.tinypic.com/o85ruo.png

Link to comment
Share on other sites

My question was about how he was able to get it to change the prop models texture blending as well, since not just the terrain textures are different in those comparison shots, so there is more going on than just terrain blending, but only some prop models have changed.


My guess is that the changed prop models are made with the sketch tool, so somehow the new algorithm changes the blending on the sketch shapes as well?!

Link to comment
Share on other sites

My question was about how he was able to get it to change the prop models texture blending as well, since not just the terrain textures are different in those comparison shots, so there is more going on than just terrain blending, but only some prop models have changed.


My guess is that the changed prop models are made with the sketch tool, so somehow the new algorithm changes the blending on the sketch shapes as well?!

 

Yeah i mentioned the brick texture too in my post, i just used the sand texture because i have that one handy, i'm guessing this is a pic of T3D 3.8 (or earlier) vs either 3.10 or even the latest development branch. That would perfectly explain the color change with both mesh and terrain. @damik will have to confirm exactly which versions.

Link to comment
Share on other sites

@damik

Then why are you posting that here? We are trying to compare different blending algorithms on the same scenes with same settings.

 

Some more tests on another map:

Thanks for all the examples. If anyone else wants to test it but doesn't like dealing with git, just pm or something and i'll chuck up a binary for testing with these changes, i can supply a windows, linux or mac binary.

sorry, up images is default blending

Link to comment
Share on other sites

I'm totally confused, i'm not sure i am following what you are saying @damik. First thing if you are using version 3.8, than you don't need this blend fix and definitely shouldn't apply that PR to your code, it is only for 3.10 or people using the development branch.


Back to your before and after pictures, im really confused by you saying this "I just changed in GIMP diffuse textures in terrain", so i'm really not 100% sure what it is exactly that im looking at in those before/after shots.


@Duion yep you are totally correct, i had the blinkers on trying to justify the change in color from all the other stuff i completely missed the most obvious aspect, the trees don't change color.

Link to comment
Share on other sites

  • 3 weeks later...

So, reading through this thread, while I don't understand the technicalities of what was being discussed, I got the idea that something had been changed between previous versions of T3D, and version 10 that changed the way terrain textures are blended? That clicked with me, as I had been able to get terrain materials to look fine in previous versions, but then suddenly couldn't with 3.10 (and maybe 3.9? I don't recall).


I've always known that T3D can produce great looking terrains, and I've been playing Life is Feudal, which I'm sure uses a previous version of T3D, and that game's terrains look awesome.


So I went ahead and tried 3.8 to see if it would make a difference and, lo and behold, everything looks fine. I'm using the same textures/layers that I tried unsuccessfully to get to look acceptable in 3.10.


Here's a shot I took of my "tests" in 3.8 with a few texture layers, and a nifty decal road. The textures are nothing to scream about; was more concerned about getting them to look "right" more so than "good".

http://i.imgur.com/GQLECpZ.pnghttp://i.imgur.com/GQLECpZ.png


So yeah... seems fine there.


Something else did arise, though. I noticed that if I go over 3 terrain layers, that 4th layer will have a kind of "halo" around the texture, instead of blending smoothly into the layer(s) beneath it. Is this a known thing, or is there some good way of getting around that?


Anyway, I still don't think it would be a *bad* idea to introduce another option for terrain texturing and let people decide which they prefer to work with (similarly to how you allow them to choose Physics versions, etc), as per my previous posts... I think maybe reverting the "math" to how it was in 3.8 could be fine as well?



Thanks :)

Link to comment
Share on other sites

Life is Feudal does not have that good terrains, they are kind of mediocre and the textures as well. The thing with Life is Feudal is, that the Terrain can be modified ingame as well as all the other stuff, therefore you cannot enhance it artistically by hand. If you use baked basetextures for the whole terrain and high res textures you can even achieve much better results than Life is Feudal. Look at BeamNG they have much nicer terrains, but it all depends on scene.


Regarding the "halo" around the textures, yes I noticed that as well with the terrain, I don't know why that is, but it may have to do something with that the blending algorithms change if you blend more than 3 textures. Maybe someone else can explain why that is, but at least I noticed that as well.

Link to comment
Share on other sites

Life is Feudal does not have that good terrains, they are kind of mediocre and the textures as well. The thing with Life is Feudal is, that the Terrain can be modified ingame as well as all the other stuff, therefore you cannot enhance it artistically by hand. If you use baked basetextures for the whole terrain and high res textures you can even achieve much better results than Life is Feudal. Look at BeamNG they have much nicer terrains, but it all depends on scene.

 

Let no opinion go unchallenged, eh Duion? lol I wasn't claiming they were the "best ever". I didn't say they were better or worse than anything else. I was just saying "I think the terrain materials in LiF look great, so I know that kind of result is possible", relative to the trouble I was having with it in 3.10.


As for the halo thing around texture layers.. yeah it's kinda unsightly. Hopefully that can be somehow addressed.


In the meantime, I think you can do quite a bit with 3 texture layers. Just have to be more "creative" with it.

Link to comment
Share on other sites

I was just saying that LiF terrains are just average, anyone can do that with T3D, the rest is just other settings and graphical features like ambience light, postFX, shaders etc.


The "halo" thing is not that bad, I easily use around 5-10 layers per map, it is hardly noticeable, so by far not a reason to not use more layers.

Link to comment
Share on other sites

  • 5 weeks later...

For the record, yes the blending was broken with more than 3 textures, this has been an issue throughout the lifetime of T3D. It has to do with the blending between different passes over each terrain block.


I've tried to fix it numerous times, but there is always a new issue showing up.


My latest attempt to fix this issue is this PR: https://github.com/GarageGames/Torque3D/pull/2049 but it doesn't work in OpenGL. It should be fixed if I figure out how to get the constNum of textures, as I'm doing some hackery around that, which is unstable.



The reason the colours are off, is due to the change to working with colours in "linear space". CryEngine encountered the same issue, they fixed it by moving the terrain color back into whatever space it was before ( I'm not fully versed in these things :P ). With that change the terrain colours would give you the same results as before linear space. Giving you less "correct" colours, but an easier pipeline. An example of that can be seen in this issue: https://github.com/GarageGames/Torque3D/issues/2050


This is the reason why no one minded the terrain textures in 3.8, but are having difficulties working with them in 3.9/3.10.

Link to comment
Share on other sites

  • 9 months later...

So, sorry to resurrect an old thread, but I figured it would be better in context, as it's related to the same subject.


As of now, what are the plans with the terrain blending method? I know there were some changes that were tried out, but I don't know what's happened since then. So, will the terrain material blending go back to how it was pre-3.10? Will it continue as it is now?


Just wondering if I should go back to a previous version, or forge ahead with 3.10 and forward.


Thanks!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share


×
×
  • Create New...