Measured film-emulation looks add a stock color grade, halation, and optional gate weave.
Also known as: FilmStockfilm emulationfilm look
Moves in browsers that support WebGPU
This device could not render the demo — showing a still
Code reflects the control values
React
// Renders only in browsers with WebGPU.
// /samples/… are this site’s sample files — point them at your own image or video.
import { Shader, FilmStock, ImageTexture } from 'shaders/react'
export default function ShaderEffect() {
return (
<Shader style={{ width: '100%', height: 320 }} disableTelemetry>
<ImageTexture
objectFit="cover"
url="/samples/photo.jpg" />
<FilmStock />
</Shader>
)
}
Vue
<!-- Renders only in browsers with WebGPU. -->
<!-- /samples/… are this site’s sample files — point them at your own image or video. -->
<script setup lang="ts">
import { Shader, FilmStock, ImageTexture } from 'shaders/vue'
</script>
<template>
<Shader style="width: 100%; height: 320px" :disable-telemetry="true">
<ImageTexture
object-fit="cover"
url="/samples/photo.jpg"/>
<FilmStock/>
</Shader>
</template>
Svelte
<!-- Renders only in browsers with WebGPU. -->
<!-- /samples/… are this site’s sample files — point them at your own image or video. -->
<script>
import { Shader, FilmStock, ImageTexture } from 'shaders/svelte'
</script>
<Shader style="width: 100%; height: 320px" disableTelemetry>
<ImageTexture
objectFit="cover"
url="/samples/photo.jpg" />
<FilmStock />
</Shader>
Solid
// Renders only in browsers with WebGPU.
// /samples/… are this site’s sample files — point them at your own image or video.
import { Shader, FilmStock, ImageTexture } from 'shaders/solid'
export default function ShaderEffect() {
return (
<Shader style={{ width: '100%', height: '320px' }} disableTelemetry>
<ImageTexture
objectFit="cover"
url="/samples/photo.jpg" />
<FilmStock />
</Shader>
)
}
JavaScript
// Renders only in browsers with WebGPU.
// /samples/… are this site’s sample files — point them at your own image or video.
// expects <canvas id="canvas" style="width:100%;height:320px"></canvas> on the page
import { createShader } from 'shaders/js'
const shader = await createShader(document.getElementById("canvas"), {
components: [
{
type: 'ImageTexture',
props: {
objectFit: 'cover',
url: '/samples/photo.jpg',
},
},
{
type: 'FilmStock',
}
]
}, { disableTelemetry: true })
Props · FilmStock
Changes apply to the demo above and to the code tabs. Descriptions come from the library registry (MIT).
It applies the color character of a measured film stock and adds a red glow around bright areas. Enabling subtle frame movement can suggest a projected film print.
`stock` defaults to portrait400 and selects the film look. `strength` defaults to 1 and ranges from 0 to 1 for the grade amount. `halation` defaults to 0.4 and ranges from 0 to 1 for the red-orange glow; `halationRadius` defaults to 28 and ranges from 0 to 100 for its spread. `weave` defaults to 0 and ranges from 0 to 1 for projector-like frame movement.
Apply it over a photo or video input. Bright highlights and colorful scenes make the treatment easier to see, while motion-sensitive UI is usually better without weave. The film data includes LUTs with a separate license notice, so check the site's license information when using it in a product.
When to use
Use it to give photos or video a film grade, add analog glow to highlights, or suggest projection on a short clip. Avoid it on motion-sensitive UI or product screens that need exact brand colors.