Skip to content

Commit 7a2b15b

Browse files
committed
Added brightness adjustment for kwase bloom algorithm
1 parent 1d92dfa commit 7a2b15b

File tree

3 files changed

+2
-5
lines changed

3 files changed

+2
-5
lines changed

editor/assets/default_renderpipeline/builtin-pipeline-settings.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -283,9 +283,6 @@ export class BuiltinPipelineSettings extends Component {
283283
@property({
284284
group: { id: 'Bloom', name: 'Bloom (PostProcessing)', style: 'section' },
285285
})
286-
@visible(function(this: BuiltinPipelineSettings) {
287-
return this.bloomType === BloomType.MipmapFilter;
288-
})
289286
set bloomIntensity(value: number) {
290287
this._settings.bloom.intensity = value;
291288
if (EDITOR) {

editor/assets/default_renderpipeline/builtin-pipeline.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1276,7 +1276,7 @@ export class BuiltinBloomPassBuilder implements rendering.PipelinePassBuilder {
12761276
[{ name: 'bloomTexSize', value: this._bloomTexSize }],
12771277
);
12781278
}
1279-
1279+
this._bloomParams.w = settings.bloom.intensity;
12801280
// Combine pass
12811281
const combinePass = buildScreenQuadPass(
12821282
width,

editor/assets/effects/pipeline/post-process/bloom-kawase-dual.effect

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ uniform sampler2D bloomTexture;
203203
layout(location = 0)out vec4 fragColor;
204204

205205
void main() {
206-
vec3 bloomColor = texture(bloomTexture, v_uv).rgb;
206+
vec3 bloomColor = texture(bloomTexture, v_uv).rgb * bloomParams.w;
207207
fragColor = vec4(bloomColor, 0);
208208
}
209209
}%

0 commit comments

Comments
 (0)