Skip to content

v3.0.0

Choose a tag to compare

@Pulpyyyy Pulpyyyy released this 15 Mar 16:37
· 4 commits to main since this release
5a9bb43

MeteoCSS Card v3.0.0

Shadow layer

The main addition in this release is a real-time shadow engine driven by a depth map image.
A WebGL shader reads a greyscale depth map and computes per-pixel shadow opacity based on the current sun/moon position, producing dynamic, physically coherent shadows that move as the day progresses.

shadow

Configuration

Add shadow to your layer stack and provide a depth map image:

layers:
  - shadow
  - moon
  - sun
  - foreground
shadow:
  depthmap: /local/shadow/my_depthmap.png
  ambient:   0.2   # minimum light level (0 = pitch black, 1 = no shadow)
  intensity: 0.7   # shadow strength multiplier
  blur:      3     # softness in pixels (0 = hard edge)
  bias:      0.003 # depth bias to avoid self-shadowing artefacts
  step:      0.002 # ray-march step size

Depth map format

  • Greyscale PNG (white = close to camera, black = far)
  • Any resolution — the shader samples it in UV space
  • depthmap is required, the layer is skipped with a warning if absent
  • WebGL is required; the layer is silently skipped on unsupported browsers

Tuning guide

Goal ambient intensity
Soft, subtle 0.4–0.5 0.7
Balanced 0.3 0.8–0.85
Marked shadows 0.2 0.9
Keep v2 behaviour 0.5 1.0

Other changes

  • HACS compatibilityzip_release: true in hacs.json, card file moved to dist/, getStubConfig() added for the card picker UI
  • Mobile rendering fix — sun and moon position now driven by transform: translate() instead of left/top, eliminating layout thrashing; contain: paint added to the layer container to prevent GPU layer bleed on mobile
  • CI — release pipeline refactored as an orchestrator (pipeline.yml) calling auto-tag and release as reusable workflow_call components

Full Changelog: v2.0.3...v3.0.0