oops.js

Logo

Only One-pass Shader

View the Project on GitHub boytchev/oops.js

Effects Gallery

This page is a showcase of individual effects. They can be used to pick a desired effect and to play with its parameters.

A ACESFilmicToneMapping · AfterimagePass B Basic · BleachBypass · Blend · Bokeh · Bokeh2 · BrightnessContrast C ColorCorrection · Colorify · ColorifyX · Convolution · Copy D DepthLimitedBlur · DigitalGlitch · DOFMipMap · DotScreen · DotScreenX E Exposure · ExposureX F Film · FilmX · Focus · FreiChen · FXAA G GammaCorrection · GodRays H Halftone · HorizontalBlur · HorizontalBlurX · HorizontalTiltShift · HorizontalTiltShiftX · HueSaturation K Kaleido · KaleidoX L LuminosityHighPass · Luminosity M Mirror · MMDToon · MotionBlurPassX N NormalMap O Output R RGBShift S SAO · Sepia · SMAA · SobelOperator · SSAO · SSR · SubsurfaceScattering T Technicolor · TechnicolorX · Toon · TriangleBlur U UnpackDepthRGBA V Velocity · VerticalBlur · VerticalBlurX · VerticalTiltShift · VerticalTiltShiftX · Vignette · VignetteX · Volume W WaterRefraction

ACESFilmicToneMapping

This effect applies filmic tonemap to the frame as defined by the Academy Color Encoding System.

Example: ACESFilmicToneMapping.html

Afterimage

This effect applies the frame onto cumulative image of older versions of the frame, thus building an after image effect. The effect is similar to MotionBlurX.

Example: Afterimage.html

Basic

This effect fills the frame with red color with 50% opacity. It is intended as a template for more complex effects.

Example: Basic.html

BleachBypass

This effects implements the bleach bypass effect in photography.

Example: BleachBypass.html

Bokeh

This effects implements the out-of-focus bokeh effect in photography. Objects at focal distance appear sharp, while closer objects or objects further away are blurred with a circuler pattern. The size of the focused area, known as depth of field (DOF) depends on the lens aperture. Higher aperture shrinks DOF, so a tiny slice of the space is on focus.

Example: Bokeh.html

BrightnessContrast

This effect changes the brightness and the contract of a frame.

Example: BrightnessContrast.html

ColorCorrection

This effect transforms the colors in a frame by m×(color + a)p. Each color component is transformed by its own factors m, a and p.

Example: ColorCorrection.html

Colorify

This effect converts the colors of the frame into specific color. For an alternative version of this effect see ColorifyX.

Example: Colorify.html

ColorifyX

This effect converts the colors of the frame into specific color. It extends the Colorify by adding opacity.

Example: ColorifyX.html

Convolution

This effect applies 1D convolution to the colors of the frame. Convolution is used to implement blur, sharpen, edge detection and other filters, based on a kernel. The kernel is an array of 25 floats.

Example: Convolution.html

Copy

This effect just copies the frame multiplying each color with opacity factor.

Example: Copy.html

DotScreen

This effect converts the frame into regularly spread dots. For an alternative version of this effect see DotScreenX.

Example: DotScreen.html

DotScreenX

This effect converts the frame into regularly spread dots. It extends the DotScreen by assuming ascending orientation of scale and adding opacity.

Example: DotScreenX.html

Exposure

This effect changes the exposure of a frame by myltiplying colors by factor f. Exposure factor f<1 makes the colors darker, while exposure f>1 makes them brighter. Exposure is multiplicative, i.e. the black color does not change the frame and the ‘opposite’ of f=2 is f=1/2. For an alternative version of this effect see ExposureX.

Example: Exposure.html

ExposureX

This effect changes the exposure of a frame by myltiplying colors by factor ef, where e&approx;2.718 is the Euler’s number. Exposure factor f<0 makes the colors darker, while exposure f>0 makes them brighter. Exposure is linear, i.e. the ‘opposite’ of f=2 is f=-2. This effect is an alternative to Exposure.

Example: ExposureX.html

Film

This effect adds graininess to the frame. For an alternative version see FilmX.

Example: Film.html

FilmX

This effect adds stronger graininess to the frame. It is an alternative to Film.

Example: FilmX.html

Focus

This effect blurs the frame by keeping the center more focused.

Example: Focus.html

FreiChen

This effect marks the edges of shapes based on the Frei-Chen edge detection algorithm.

Example: FreiChen.html

FXAA

This effect implements a variation of the FXAA (Fast approximate anti-aliasing) screen-space anti-aliasing.

Example: FXAA.html

GammaCorrection

This effect applies sRGB electro-optical transfer function (EOTF), which is approximation of γ=2.2.

Example: GammaCorrection.html

Halftone

This effect converts the colors in the frame into overlapping single-color patterns of shapes.

Example: Halftone.html

HorizontalBlur

This effect blurs the frame horizontally with a fixed Gaussian blur filter. For a variable filter see HorizontalBlurX.

Example: HorizontalBlur.html

HorizontalBlurX

This effect blurs the frame horizontally with a variable Gaussian blur filter by using the same number of samplings, but at different span. For a fixed filter at amount=1 see HorizontalBlur.

Example: HorizontalBlurX.html

HorizontalTiltShift

This effect makes the horizontal blur of a tilt-shift effect similar to the miniature faking in tilt-shift photography. Both horizontal blur and vertical blur (see VerticalTiltShift) are required for a full tilt-shift effect. For an alternative implementation of the horizontal blur effect with different parameters see HorizontalTiltShiftX.

Example: HorizontalTiltShift.html

HorizontalTiltShiftX

This effect makes the horizontal blur of a tilt-shift effect similar to the miniature faking in tilt-shift photography. Both horizontal blur and vertical blur (see VerticalTiltShiftX) are required for a full tilt-shift effect. For an alternative implementation of the horizontal blur effect with different parameters see HorizontalTiltShift.

Example: HorizontalTiltShiftX.html

HueSaturation

This effect changes the hue (the colorness of colors, like red, green or yellow) and the saturation (the colorfulness or strength of colors, line gray or colorful) of a frame.

Example: HueSaturation.html

Kaleido

This effect mirrors a pie fragment of the frame into a kaleidoscopic image. For an aspect-friendly alternative of this effect see KaleidoX.

Example: Kaleido.html

KaleidoX

This effect mirrors a pie fragment of the frame into a kaleidoscopic image. For a non-aspect alternative of this effect see Kaleido.

Example: KaleidoX.html

LuminosityHighPass

This effect changes a frame by blending colors based on their luminocity. In contrast to the Luminosity, this effect calculates the luminocity as &approx;30% (red), &approx;59% (green) and &approx;11%(blue).

Example: LuminosityHighPass.html

Luminosity

This effect converts colors of a frame to grayscale based on luminocity, i.e. color components contribute with their different factors: &approx;21% (red), &approx;72% (green) and &approx;7%(blue). A more advanced lunimosity effect is LuminosityHighPass.

Example: Luminosity.html

Mirror

This effect mirrors half of the frame onto the other half.

Example: Mirror.html

MotionBlurX

This effect applies the frame onto cumulative image of older versions of the frame, thus building a motion blur. The effect is similar to Afterimage.

Example: MotionBlurX.html

RGBShift

This effect splits the RGB color components of the frame and shifts them apart.

Example: RGBShift.html

Sepia

This effect recolors the frame into sepia color.

Example: Sepia.html

SobelOperator

This effect applies a Sobel operator on a frame and detects the edges of shapes based on the red color component.

Example: SobelOperator.html

Technicolor

This effect converts the colors of the frame into Technicolor cyan-red hues. For an altenative version see TechnicolorX.

Example: Technicolor.html

TechnicolorX

This effect converts the colors of the frame into Technicolor cyan-red. It extends the Technicolor by adding amount.

Example: TechnicolorX.html

TriangleBlur

This effect blurs the frame using randomized weighted samples. The blur is biased along a direction.

To use this effect for a non-biased blur, it must be applied twice: a horizontal blur (e.g. amount=(0.1,0)) and a vertical blur (e.g. amount=(0,0.1)).

Example: TriangleBlur.html

UnpackDepthRGBA

This effect assumes the frame contains RGBA encoded depth data and unpacks it into grayscale colors.

Example: UnpackDepthRGBA.html

VerticalBlur

This effect blurs the frame vertically with a fixed Gaussian blur filter. For a variable filter see VerticalBlurX.

Example: VerticalBlur.html

VerticalBlurX

This effect blurs the frame vertically with a variable Gaussian blur filter by using the same number of samplings, but at different span. For a fixed filter at amount=1 see VerticalBlur.

Example: VerticalBlurX.html

VerticalTiltShift

This effect makes the vertical blur of a tilt-shift effect similar to the miniature faking in tilt-shift photography. Both horizontal blur (see HorizontalTiltShift) and vertical blur are required for a full tilt-shift effect. For an alternative implementation of the vertical blur effect with different parameters see VerticalTiltShiftX.

Example: VerticalTiltShift.html

VerticalTiltShiftX

This effect makes the vertical blur of a tilt-shift effect similar to the miniature faking in tilt-shift photography. Both horizontal blur (see HrizontalTiltShiftX) and vertical blur are required for a full tilt-shift effect. For an alternative implementation of the horizontal blur with different parameters see VerticalTiltShift.

Example: VerticalTiltShiftX.html

Vignette

This effect adds a vignette effect on the frame. For an alternative implementation with different parameters see VignetteX.

Example: Vignette.html

VignetteX

This effect adds a vignette effect on the frame. For an alternative implementation with different parameters see Vignette.

Example: VignetteX.html