Vignette strength
This commit is contained in:
Binary file not shown.
@@ -13,8 +13,6 @@
|
||||
#include "../std/denoise.glsl"
|
||||
#endif
|
||||
|
||||
const float compoVignetteStrength = 0.4;
|
||||
|
||||
uniform sampler2D tex;
|
||||
#ifdef _CDepth
|
||||
uniform sampler2D gbufferD;
|
||||
@@ -32,6 +30,10 @@ uniform sampler2D lutTexture;
|
||||
uniform sampler2D histogram;
|
||||
#endif
|
||||
|
||||
#ifdef _CVignette
|
||||
uniform float vignetteStrength;
|
||||
#endif
|
||||
|
||||
// #ifdef _CPos
|
||||
// uniform vec3 eye;
|
||||
// uniform vec3 eyeLook;
|
||||
@@ -119,7 +121,7 @@ vec4 LUTlookup(in vec4 textureColor, in sampler2D lookupTable) {
|
||||
|
||||
#ifdef _CVignette
|
||||
float vignette() {
|
||||
return (1.0 - compoVignetteStrength) + compoVignetteStrength * pow(16.0 * texCoord.x * texCoord.y * (1.0 - texCoord.x) * (1.0 - texCoord.y), 0.2);
|
||||
return (1.0 - vignetteStrength) + vignetteStrength * pow(16.0 * texCoord.x * texCoord.y * (1.0 - texCoord.x) * (1.0 - texCoord.y), 0.2);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -74,6 +74,9 @@ class Uniforms {
|
||||
#end
|
||||
}
|
||||
#end
|
||||
if (link == "_vignetteStrength") {
|
||||
return UITrait.inst.vignetteStrength;
|
||||
}
|
||||
if (link == "_coneOffset") {
|
||||
return UITrait.inst.vxaoOffset;
|
||||
}
|
||||
|
||||
@@ -186,6 +186,10 @@ class BoxPreferences {
|
||||
ui.check(UITrait.inst.hssr, "SSR");
|
||||
if (UITrait.inst.hssr.changed) Config.applyConfig();
|
||||
|
||||
var h = Id.handle({value: UITrait.inst.vignetteStrength});
|
||||
UITrait.inst.vignetteStrength = ui.slider(h, "Vignette", 0.0, 1.0, true);
|
||||
if (h.changed) Context.ddirty = 2;
|
||||
|
||||
#if arm_creator
|
||||
var h = Id.handle({value: UITrait.inst.vxaoExt});
|
||||
UITrait.inst.vxaoExt = ui.slider(h, "VXAO Ext", 1.0, 10.0);
|
||||
|
||||
@@ -245,6 +245,7 @@ class UITrait {
|
||||
#end
|
||||
public var vxaoOffset = 1.5;
|
||||
public var vxaoAperture = 1.2;
|
||||
public var vignetteStrength = 0.4;
|
||||
public var textureExport = false;
|
||||
public var textureExportPath = "";
|
||||
public var projectExport = false;
|
||||
|
||||
Reference in New Issue
Block a user