Downsample when blurring bloom
This commit is contained in:
@@ -3,10 +3,12 @@ in vec2 vTexPos;
|
||||
out vec4 fColor;
|
||||
const vec2 winSize = vec2 (300,300);
|
||||
// note that the above opening bracket should be the first in this file
|
||||
// this is so that the window size can be extracted and the shader recompiled on
|
||||
// the fly
|
||||
uniform sampler2D screenTexture;
|
||||
|
||||
const float hOff = 4.0 / winSize.x;
|
||||
const float vOff = 4.0 / winSize.y;
|
||||
const float hOff = 3.0 / winSize.x;
|
||||
const float vOff = 3.0 / winSize.y;
|
||||
const float frac = 1.0 / 9;
|
||||
const vec2 off[9] = vec2[]
|
||||
( vec2( vOff,hOff )
|
||||
|
||||
Reference in New Issue
Block a user