Jump to content

source - HDR impact on normal maps


EviLTaxi
 Share

Recommended Posts

Hey

it's been like 2 years that I've posted on mapcore but now I've got a problem I can't seem to fix.

I'm working on a map for the pvkii mod. 2 weeks ago I decided to do a full compile and see what it looks like with HDR.

So I did a full compile and the result was quite pleasing but I felt something was wrong, it all looked way more flat than before.

when I turned off HDR to build cubemaps I noticed that my normal maps are way more intensive with HDR turned off. have a look at the gif

of course I want the map to look as much a possible the same with and without HDR but Im not able to do that if the 2 versions differ so much.

I first thought that maybe because the bloom effect overlays the materials the contrast of the materials is lowered thus making the normal maps less intensive but the 2 versions look so much different even in places without bloom effect (with HDR on) that it seems unlikely.

Any idea how to fix this?

p.s.: I have a GeForce 7900GT

pvk_haven_HDR.gif

Link to comment
Share on other sites

It looks like your HDR settings use a different ambiant than LDR, and that's what's creating that difference. HDR should bring higher contrasts, but the end result here is quite the opposite. What are your light_environment settings?

Link to comment
Share on other sites

hehe yes, it really is the opposite of what you expect to get when you use HDR!

I've set the HDR and LDR ambient light settings of my light_environment to the same value.

I did mess around with the brightness values for HDR & LDR to see how it affects the lighting. do you by any chance refer to the brightness value instead of the ambient value? ..because it's the brightness value which is mainly responsible for the bloom effect.

anyway, I think the first time I did a full compile I hadn't changed anything about the lighting ...and this problem occurred. (the values for HDR & LDR are the same by default)

I might be wrong so I'll do another compile and post about the result tomorrow.

thank you for your help

Link to comment
Share on other sites

well, the blue channel does have a very light version of a height map.

I've put some stronger heightmaps in there and as you said, contrast goes up but uglyness goes along.

unfortunately, it does also not change anything about the difference between LDR & HDR.

I did another full compile with LDR and HDR values using the same values and nothing as changed

I've just read in the SDK Docs that HDR values should be slightly less intense than LDR values. I'll try that out aswell although I don't expect too much of it.

Link to comment
Share on other sites

although I appreciate that you've thought of the solution that HDR "is fucking up the effectiveness of the normal map", I would also appreciate if you would read my post entirely:

I first thought that maybe because the bloom effect overlays the materials the contrast of the materials is lowered thus making the normal maps less intensive but the 2 versions look so much different even in places without bloom effect (with HDR on) that it seems unlikely.

meanwhile, I did another test. turning off the bloom effect only (with "mat_hdr_level 0") while HDR was still on, I saw that the bloom effect itself does not alternate the normal maps in any way. they still look very weak as in the gif.

of course, the bloom effect does overlay materials and if it is strong enough it even overlays materials completely but with HDR, all normal maps are getting very weak, no matter if their face is hit by direct light or not, no matter if they have a bloom effect or not.

here another gif to emphasize what I mean

pvk_haven_HDR2.gif

see how the normal maps are stonger only if HDR is completely off

Link to comment
Share on other sites

although I appreciate that you've thought of the solution that HDR "is fucking up the effectiveness of the normal map", I would also appreciate if you would read my post entirely:

I first thought that maybe because the bloom effect overlays the materials the contrast of the materials is lowered thus making the normal maps less intensive but the 2 versions look so much different even in places without bloom effect (with HDR on) that it seems unlikely.

meanwhile, I did another test. turning off the bloom effect only (with "mat_hdr_level 0") while HDR was still on, I saw that the bloom effect itself does not alternate the normal maps in any way. they still look very weak as in the gif.

of course, the bloom effect does overlay materials and if it is strong enough it even overlays materials completely but with HDR, all normal maps are getting very weak, no matter if their face is hit by direct light or not, no matter if they have a bloom effect or not.

No, I read your whole post and I stand by my answer. HDR as it's implemented in Source is mostly just an overbrightening effect. Even if bloom is off the HDR effect will still wash out the map a little bit. The effect isn't limited to areas with strong light sources alone.

Link to comment
Share on other sites

you can scale the bump effect and there is a special option where you can put specific properties for specific graphic modes. for example to lower the intensity of reflections while running in hdr mode.

"LightmappedGeneric"

{

	"$basetexture" "wood01"

	"$bumpmap" "wood01_normal"

	"$envmap" "env_cubemap"

	"$normalmapalphaenvmapmask" 1

	"$envmapcontrast" .2

	"$envmapsaturation" .7

	"$envmaptint" "[ .72 .72 .72 ]"

	"$fresnelreflection" "1.3"

 		"lightmappedgeneric_HDR_dx9"

 		{

  			"$envmaptint" "[.15 .15 .15]"

		}

}

check out the valve developer wiki: http://developer.valvesoftware.com/wiki ... Parameters
"$bumpscale" 

didnt do that my self yet, but it is supposed to work.

Link to comment
Share on other sites

No, I read your whole post and I stand by my answer. HDR as it's implemented in Source is mostly just an overbrightening effect. Even if bloom is off the HDR effect will still wash out the map a little bit. The effect isn't limited to areas with strong light sources alone.

yes, that's true. my point was just that I already wrote about your thesis and that this thesis turned out to be wrong because it doesn't matter where the normal map is, they overall get weaker with HDR turned on.

anyway, thank you for your help

this seems to be the solution! thank you hessi. I already knew that you can set fallback shaders for materials but I didn't know that you can even set the intensitiy for the normal map when HDR is on! thanks

I will try this out and post about the result

Link to comment
Share on other sites

 Share

  • MapCore on Discord

  • Our picks

    • Post in Yanzl's Source Emporium
      Two new asset releases!

      First up is Basalt. Sadly I can't release all of the assets as some of the nature stuff is from Megascans and can't be redistributed. Also only includes the assets I've made.


      https://www.dropbox.com/s/e86kdqwpvhhs5x6/Basalt.zip?dl=0

      Second one is assets I've made for Pitstop. A small release that includes some road and concrete trim textures, a bunch of sponsors and some skybox buildings that might be useful.


      https://www.dropbox.com/s/x6tn3b6nfo2u77d/Pitstop.zip?dl=0

      As always, free for non-commercial use with attribution. 
×
×
  • Create New...