diff --git a/source/gegl/bloom.ts b/source/gegl/bloom.ts new file mode 100644 index 0000000..c05ae58 --- /dev/null +++ b/source/gegl/bloom.ts @@ -0,0 +1,30 @@ +import {BaseOperation} from './base.js'; + +export interface BloomParameters { + limitExposure: boolean; + radius: number; + softness: number; + strength: number; + threshold: number; +} + +export class Bloom extends BaseOperation { + public static default: BloomParameters = { + limitExposure: false, + radius: 10, + softness: 25, + strength: 50, + threshold: 50, + }; + + public get default() { + return Bloom.default; + } + + public appendCrop = false; + public name = 'gegl:bloom'; + + constructor(parameters?: Partial) { + super({...Bloom.default, ...parameters}); + } +} diff --git a/source/gegl/exports.ts b/source/gegl/exports.ts index dd8eb90..600f791 100644 --- a/source/gegl/exports.ts +++ b/source/gegl/exports.ts @@ -1,4 +1,5 @@ export * from './base.js'; +export * from './bloom.js'; export * from './cartoon.js'; export * from './cell-noise.js'; export * from './crop.js';