Page 20 of 39

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 10:45
by --JawZ--
Yeah I did a typo there, totally missed the float4 inclusion there.

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 16:11
by tapioks
Thanks guys, will try again.

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 21:28
by tapioks
Unfortunately I am still getting a CTD when loading any save game. I have added the following near the other GUI parameters in my enbeffect.fx file:

Code: Select all

bool SWITCH_BLOOM <
    string UIName = "Switch Bloom";
> = {false};

float4 xcolorbloom=0;
if (SWITCH_BLOOM == true)
{
xcolorbloom = tex2D(_s3, _v0.xy); // ENB bloom
}
else if ( (SWITCH_BLOOM == false)
{
xcolorbloom = tex2D(_s1, _v0.xy); // Vanilla bloom
}

Any ideas...?

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 21:35
by mindflux
At least you have one extra bracket after 'else if' statement, should be:

Code: Select all

else if (SWITCH_BLOOM == false)
Also make sure xcolorbloom is not declared again further down in the code.

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 21:37
by tapioks
@Mindflux

Thanks, I actually spotted that after making my previous post and removed the first '(' ... but still no luck :/

To be clear, I now have:

Code: Select all

bool SWITCH_BLOOM <
    string UIName = "Switch Bloom";
> = {false};

float4 xcolorbloom=0;
if (SWITCH_BLOOM == true)
{
xcolorbloom = tex2D(_s3, _v0.xy); // ENB bloom
}
else if (SWITCH_BLOOM == false)
{
xcolorbloom = tex2D(_s1, _v0.xy); // Vanilla bloom
}

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 21:47
by mindflux
A second thought, I don't think it can work that way because the sampler _s3 and float4 _v0 are declared later down in the code. If you want to use GUI, you should probably make a helper switch there and then perform the actual switch later in the code.

A quick cig, and then as follows... put this part in the GUI section:

Code: Select all

bool SWITCH_BLOOM <    string UIName = "ENB Bloom";> = {false};
Then find the xcolorbloom declaration in the code, comment it out and paste this snippet after it:

Code: Select all

float4 xcolorbloom=0;
if (SWITCH_BLOOM == true)
{
xcolorbloom = tex2D(_s3, _v0.xy); // ENB bloom
}
else
{
xcolorbloom = tex2D(_s1, _v0.xy); // Vanilla bloom
}
Then get ready to rock'n roll :D

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 22:14
by tapioks
Hallelujah, that worked! Thanks a billion.

Looks like I'll have to use a different ENB config for my bloom demo video, as NLA's weather .esp sends vanilla bloom through the STRATOSPHERE :D

Image

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 22:26
by mindflux
Great to hear! Haha yeah that happens I figure with pretty much every config, you can't revert to vanilla bloom by simply using it as a texture, so many different variables at play...

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 22:30
by --JawZ--
Use a multiplying variable then.

Code: Select all

    float fBloomMult <
      string UIName="Bloom Intensity";  string UIWidget="Spinner";  float UIMin=0.0;  float UIMax=10.0;
    > = {1.0};

----

xcolorbloom = tex2D(_s1, _v0.xy);
color.rgb += xcolorbloom.xyz * fBloomMult;

Re: TES Skyrim 0.265

Posted: 24 Jan 2015, 22:34
by mindflux
ENB controls in enbseries.ini and in the weather specific files will also work.