Pixel UI/Scenes/Sunset lake

Sunset lake

A flat-colour sunset over a lake, with a boat drifting across.

<piix-scene>WebGL
Colours
Sky
Fade

Vector-poster style: a huge sun, two layers of soft green hills and a lake that mirrors all of it through gentle ripples. A tiny rower crosses the water. Move the pointer up and down and the sun rises and sets with you.

Installation

<!-- once, anywhere on the page: every component -->
<script src="https://cdn.jsdelivr.net/npm/piixpal@0.6/piixpal.min.js"></script>

Usage

<piix-scene kind="lake" height="460px"></piix-scene>

Examples

As a hero

Give Hero a scene and your content sits on top of it.

Now open

Somewhere new

A whole place, drawn in pixels, behind your words.

Explore

On a normal page

sky="none" cuts the sky out, so your page shows through. Add fade to dissolve an edge.

Repainted

Give it a palette and the whole scene is redrawn in those colours.

Fewer colours

levels sets how many shades each colour channel gets. 2 or 3 is very retro.

API reference

AttributeWhat it doesDefault
kindsakura alps lake galaxy rays vortex train poppies castle vistasakura
skynone makes the sky see-through–
fadetop bottom both: dissolve that edge in dithered pixels–
paletterepaint it in a palette instead of its own colours–
levelsshades per colour channel, 2 to 166
pixelsize of one pixel, in px4
dither0 for flat colour, 1 for full dither1
speed1 is normal, 0 holds still1
heightwhen not filling: px or any CSS length480px
fillsit behind the content of the parent element–

Accessibility