[Oblivion] NLA enbeffect.fx Port

share shaders here
  • Author
  • Message
Offline
User avatar
*sensei*
Posts: 316
Joined: 12 Aug 2013, 18:55
Location: Scotland

Re: [Oblivion] NLA enbeffect.fx Port

So it seems that the tempF variables are bugged; assigning variables in enbeffect.fx to them causes the shader to not run properly. No error is thrown, but the game's original post processing is used (toggling ENB does nothing). Changing the variables also doesn't affect the visuals in any way.

Here's the enbeffect.fx file, the tempF vars are used after the APPLYGAMECOLORCORRECTION block, rest of it is the same as the Pastebin in the OP: https://pastebin.com/RWBDsaYB
_________________
Intel i7 6700k | AMD Vega 56 8GB | 2x16GB DDR4 @ 3000mhz | Windows 7 64bit | Creative Soundblaster X-Fi Titanium Fatal1ty Pro | Asus z170 Pro Gaming

Offline
User avatar
*blah-blah-blah maniac*
Posts: 530
Joined: 30 Jan 2012, 13:18

Re: [Oblivion] NLA enbeffect.fx Port

I'm not sure if you can change globally declared variables inside the pixel shader. Most likely you broke the shader but the enb for oblivion doesn't output compiler errors as it does on SSE for example.

Offline
*blah-blah-blah maniac*
Posts: 565
Joined: 05 Apr 2014, 10:29
Location: Taiwan

Re: [Oblivion] NLA enbeffect.fx Port

you can use local var,

Code: Select all

//inside shader
	float GammaDay = tempF1.x; //local variable prioritize before global var
	//other stuffs...
	float fGamma = lerp(lerp(GammaNight, GammaDay, ENightDayFactor), GammaInterior, EInteriorFactor);
or use static global

Code: Select all

//move enbparams at the start of file
//+++++++++++++++++++++++++++++
//external parameters, do not modify
//+++++++++++++++++++++++++++++
//...
//
 	//begin NLA Color
static float	GammaDay = tempF1.x; //line 53 in pastbin

//then the shaders...
u can also do this as global var,

Code: Select all

	static float Gamma = lerp(lerp(GammaNight, GammaDay, ENightDayFactor), GammaInterior, EInteriorFactor);
mostly they're just eye candy for easy access, but it is quite useful for quick test on params.

and again, I would recommend using fxc.exe to debug if you're doing intensive coding.
_________________
Intel Xeon L5639 6C12T @3.96GHz | Gigabyte ga-x58a-ud3r | MSI GTX680 4G | 48G RAM | Intel 760p Nvme w clover bootloader
Flickr
YouTube

Offline
User avatar
*sensei*
Posts: 316
Joined: 12 Aug 2013, 18:55
Location: Scotland

Re: [Oblivion] NLA enbeffect.fx Port

I'd like to have realtime var editing, like in the newer ENBs, but uh, I've no idea how to get that rigged up in NVidia's FXComposer. Google didn't give any meaningful results. Same gig with RenderMonkey.

I'd have to somehow take a screenshot without any of the added post processing, and chuck that in as a texture on a plane, then rotate the camera so the plane takes up the whole screen.

Good tip about the global vars, didn't know they were static in older ENBs. I'll see if local vars change anything.
_________________
Intel i7 6700k | AMD Vega 56 8GB | 2x16GB DDR4 @ 3000mhz | Windows 7 64bit | Creative Soundblaster X-Fi Titanium Fatal1ty Pro | Asus z170 Pro Gaming

Offline
User avatar
*sensei*
Posts: 316
Joined: 12 Aug 2013, 18:55
Location: Scotland

Re: [Oblivion] NLA enbeffect.fx Port

Slowly getting there :D

Image

Edit: Made some more changes, fixed image link. It's looking pretty solid now.
_________________
Intel i7 6700k | AMD Vega 56 8GB | 2x16GB DDR4 @ 3000mhz | Windows 7 64bit | Creative Soundblaster X-Fi Titanium Fatal1ty Pro | Asus z170 Pro Gaming

Offline
User avatar
*sensei*
Posts: 316
Joined: 12 Aug 2013, 18:55
Location: Scotland

Re: [Oblivion] NLA enbeffect.fx Port

Got the interior and night variables looking pretty damn good. Updated the OP with the Pastebin for enbeffect.fx

Image
_________________
Intel i7 6700k | AMD Vega 56 8GB | 2x16GB DDR4 @ 3000mhz | Windows 7 64bit | Creative Soundblaster X-Fi Titanium Fatal1ty Pro | Asus z170 Pro Gaming

Offline
User avatar
*blah-blah-blah maniac*
Posts: 530
Joined: 30 Jan 2012, 13:18

Re: [Oblivion] NLA enbeffect.fx Port

Your color ranges are totally off, no color ever reaches 255. Try doing color *= something greater than 1 after the tonemap to restore a bit dynamic range if the tonemap itself can't be configured to not kill the ranges.

Offline
User avatar
*sensei*
Posts: 316
Joined: 12 Aug 2013, 18:55
Location: Scotland

Re: [Oblivion] NLA enbeffect.fx Port

Marty McFly wrote:Your color ranges are totally off, no color ever reaches 255. Try doing color *= something greater than 1 after the tonemap to restore a bit dynamic range if the tonemap itself can't be configured to not kill the ranges.
Yeah, I don't know diddly squat about modifying colours. I don't even know how something is supposed to look "good", just winged it and came up with something that looks cool.

I'll give that a go, see what I can come up with.
_________________
Intel i7 6700k | AMD Vega 56 8GB | 2x16GB DDR4 @ 3000mhz | Windows 7 64bit | Creative Soundblaster X-Fi Titanium Fatal1ty Pro | Asus z170 Pro Gaming
Post Reply