Files
cocos4/cocos/rendering/post-process/components/bloom.ts
T
PP 509d73b27d merge branch v3.8.0-aot (#15421)
* PR1: add explicit function return type (#15311)

* PR4: add explicit function return type (#15314)

* [ci skip][AUTO]: Automated code generating update: 8843bfe54cd3f8e6f84432948716c8d130ecb233  (#15314) (#15357)

Co-authored-by: cocos-robot <cocos-robot@cocos.com>

* add function return type

* fix version checking

* fix return type

---------

Co-authored-by: Cocos Robot <48829427+cocos-robot@users.noreply.github.com>
Co-authored-by: cocos-robot <cocos-robot@cocos.com>
2023-06-13 18:08:45 +08:00

45 lines
1.1 KiB
TypeScript

import { ccclass, disallowMultiple, executeInEditMode, menu, range, rangeMin, serializable, slide, tooltip, type } from '../../../core/data/decorators';
import { CCFloat, CCInteger } from '../../../core/data/utils/attribute';
import { PostProcessSetting } from './post-process-setting';
@ccclass('cc.Bloom')
@menu('PostProcess/Bloom')
@disallowMultiple
@executeInEditMode
export class Bloom extends PostProcessSetting {
@serializable
protected _threshold = 0.8;
@serializable
protected _iterations = 3;
@serializable
protected _intensity = 2.3;
@rangeMin(0)
@type(CCFloat)
set threshold (value: number) {
this._threshold = value;
}
get threshold (): number {
return this._threshold;
}
@slide
@range([1, 6, 1])
@type(CCInteger)
set iterations (value: number) {
this._iterations = value;
}
get iterations (): number {
return this._iterations;
}
@rangeMin(0)
@type(CCFloat)
set intensity (value: number) {
this._intensity = value;
}
get intensity (): number {
return this._intensity;
}
}