Simplifyimprove #118

Merged
Swordfish90 merged 12 commits from simplifyimprove into master 2014-09-14 15:35:54 +02:00
2 changed files with 6 additions and 2 deletions
Showing only changes of commit 53897f8186 - Show all commits

View File

@ -278,6 +278,8 @@ Item{
hideSource: true hideSource: true
smooth: false smooth: false
wrapMode: ShaderEffectSource.ClampToEdge wrapMode: ShaderEffectSource.ClampToEdge
//sourceRect is needed because FastBlur expands slightly outside the rectangle
sourceRect: Qt.rect(-1, -1, sourceItem.width + 2, sourceItem.height + 2)
} }
} }

View File

@ -224,12 +224,14 @@ ShaderEffect {
"finalColor *= texture2D(rasterizationSource, coords).a;" + "finalColor *= texture2D(rasterizationSource, coords).a;" +
(bloom_strength !== 0 ? (bloom_strength !== 0 ?
"vec3 bloomColor = texture2D(bloomSource, coords).rgb;" + "vec4 bloomFullColor = texture2D(bloomSource, coords);
vec3 bloomColor = bloomFullColor.rgb;
float bloomAlpha = bloomFullColor.a;" +
(chroma_color !== 0 ? (chroma_color !== 0 ?
"bloomColor = font_color.rgb * mix(vec3(rgb2grey(bloomColor)), bloomColor, chroma_color);" "bloomColor = font_color.rgb * mix(vec3(rgb2grey(bloomColor)), bloomColor, chroma_color);"
: :
"bloomColor = font_color.rgb * rgb2grey(bloomColor);") + "bloomColor = font_color.rgb * rgb2grey(bloomColor);") +
"finalColor += bloomColor * bloom_strength;" "finalColor += bloomColor * bloom_strength * bloomAlpha;"
: "") + : "") +
(brightness_flickering !== 0 ? " (brightness_flickering !== 0 ? "