PixelArtPreset

ceramic.PixelArtPreset (Class)

A complete set of PixelArt settings, as data: every property of the filter, with the defaults of the filter itself. Apply one with PixelArt.applyPreset(), read the current settings back with PixelArt.toPreset(), and paste the result of toHaxe() in code to keep a look that was tuned at runtime.

Built-in presets: sharp, clean, crtTv, crtMonitor, gba, lite (see byName()).

Static Members

Names of the built-in presets accepted by byName()


The original PixelArt look: SHARP mode with its defaults

Returns
PixelArtPreset

CRT mode with no effect at all: the reference to compare the CRT shader against sharp

Returns
PixelArtPreset

A consumer television: soft beam, marked scanlines, TV shadow mask, halo, slight curvature, rounded corners, vignette and a little grain

Returns
PixelArtPreset

crtMonitor(): PixelArtPreset

A computer monitor: sharper beam, thin scanlines, aperture grille, faint halo, flat screen

Returns
PixelArtPreset

Game Boy Advance LCD: sharp pixels, RGB subpixels and grid, and the gba-color (Pokefan531, hunterk) gamma, luminance and color matrix

Returns
PixelArtPreset

crtTv for weak GPUs: lite quality, no halo, no grain

Returns
PixelArtPreset

byName(name: String): PixelArtPreset

A built-in preset by name (see NAMES), or null

Name Type
name String
Returns
PixelArtPreset

Instance Members


sharpness: Float

chromaticAberration: Float

gridThickness: Float

gridColor: Color

gridAlpha: Float

scanlineCount: Float

scanlineIntensity: Float

scanlineShape: Float

verticalMaskCount: Float

verticalMaskIntensity: Float

glowStrength: Float

glowThresholdMin: Float

glowThresholdMax: Float

beamAmount: Float

hardPix: Float

sharpBand: Float

hardScan: Float

beamMin: Float

beamMax: Float

scanlineStrength: Float

maskType: PixelArtMask

maskDark: Float

maskLight: Float

maskScale: Float

lcdGridStrength: Float

lcdSubpixelLow: Float

bloomAmount: Float

bloomSize: Float

warpX: Float

warpY: Float

cornerRadius: Float

cornerSmooth: Float

vignetteStrength: Float

gamma: Float

brightness: Float

colorMatrix: Array<Float>

3 x 3 color matrix, row by row: the first three values give the output red from the input red, green and blue, and so on.


luminance: Float

noiseStrength: Float

flickerStrength: Float


toHaxe(): String

This preset as a Haxe struct literal, ready to paste in code

Returns
String

new(?mode: Null<PixelArtMode>, ?sharpness: Null<Float>, ?chromaticAberration: Null<Float>, ?gridThickness: Null<Float>, ?gridColor: Null<Color>, ?gridAlpha: Null<Float>, ?scanlineCount: Null<Float>, ?scanlineIntensity: Null<Float>, ?scanlineShape: Null<Float>, ?verticalMaskCount: Null<Float>, ?verticalMaskIntensity: Null<Float>, ?glowStrength: Null<Float>, ?glowThresholdMin: Null<Float>, ?glowThresholdMax: Null<Float>, ?beamAmount: Null<Float>, ?hardPix: Null<Float>, ?sharpBand: Null<Float>, ?hardScan: Null<Float>, ?beamMin: Null<Float>, ?beamMax: Null<Float>, ?scanlineStrength: Null<Float>, ?maskType: Null<PixelArtMask>, ?maskDark: Null<Float>, ?maskLight: Null<Float>, ?maskScale: Null<Float>, ?lcdGridStrength: Null<Float>, ?lcdSubpixelLow: Null<Float>, ?bloomAmount: Null<Float>, ?bloomSize: Null<Float>, ?warpX: Null<Float>, ?warpY: Null<Float>, ?cornerRadius: Null<Float>, ?cornerSmooth: Null<Float>, ?vignetteStrength: Null<Float>, ?gamma: Null<Float>, ?brightness: Null<Float>, ?colorMatrix: Null<Array<Float>>, ?luminance: Null<Float>, ?noiseStrength: Null<Float>, ?flickerStrength: Null<Float>, ?quality: Null<PixelArtQuality>): Void
Name Type Default Description
mode Null<PixelArtMode> (optional)
sharpness Null<Float> (optional)
chromaticAberration Null<Float> (optional)
gridThickness Null<Float> (optional)
gridColor Null<Color> (optional)
gridAlpha Null<Float> (optional)
scanlineCount Null<Float> (optional)
scanlineIntensity Null<Float> (optional)
scanlineShape Null<Float> (optional)
verticalMaskCount Null<Float> (optional)
verticalMaskIntensity Null<Float> (optional)
glowStrength Null<Float> (optional)
glowThresholdMin Null<Float> (optional)
glowThresholdMax Null<Float> (optional)
beamAmount Null<Float> (optional)
hardPix Null<Float> (optional)
sharpBand Null<Float> (optional)
hardScan Null<Float> (optional)
beamMin Null<Float> (optional)
beamMax Null<Float> (optional)
scanlineStrength Null<Float> (optional)
maskType Null<PixelArtMask> (optional)
maskDark Null<Float> (optional)
maskLight Null<Float> (optional)
maskScale Null<Float> (optional)
lcdGridStrength Null<Float> (optional)
lcdSubpixelLow Null<Float> (optional)
bloomAmount Null<Float> (optional)
bloomSize Null<Float> (optional)
warpX Null<Float> (optional)
warpY Null<Float> (optional)
cornerRadius Null<Float> (optional)
cornerSmooth Null<Float> (optional)
vignetteStrength Null<Float> (optional)
gamma Null<Float> (optional)
brightness Null<Float> (optional)
colorMatrix Null<Array<Float>> (optional) * 3 x 3 color matrix, row by row: the first three values give the output red from the input red, green and blue, and so on.
luminance Null<Float> (optional)
noiseStrength Null<Float> (optional)
flickerStrength Null<Float> (optional)
quality Null<PixelArtQuality> (optional)

Private Members

sameMatrix(a: Array<Float>, b: Array<Float>): Bool
Name Type
a Array<Float>
b Array<Float>
Returns
Bool

Metadata

Name Parameters
:structInit -