makepad/apps/vj/resources/effects/233_star_prism.splash
Admin cb49b032df vjfx: 104 presets, engine hooks + hold stage, the videomesh engine, the audio picture, livecodable effects, and mp4 thumbnail sheets
Squashed from work; the fine-grained history is under tag archive/work-2026-08-26:
- vjfx: 104 new presets — the transition lane fills out and the screen family goes wide
- vjfx: three lanes land — engine hooks + hold stage, the videomesh engine, and the audio picture
- vj: the thumbnail pipeline becomes one honest machine, and effects go livecodable
- vj: thumbnails become mp4 — hardware-coded sheets at measured-4K cells, and the bake stops racing the GPU
- store: the ceremony dies — batch publish, one transaction, and the engine stops re-reading its own log
- store: the ceremony dies — batch publish, one transaction, and the engine stops re-reading its own log
- vj: the console grows real transports, and the deck stops lying about reverse
- vj: reverse earns a memory, and the effects stop aging
- fab: a 3D creation shell and the viewer built on it
2026-08-26 08:49:48 +02:00

56 lines
1.8 KiB
Text

// STAR PRISM — a five-pointed star slab tumbling in space: both star faces
// play the clip through a flat planar projection while the prism's side
// band runs as beat-pumped neon, so every turn alternates picture and
// light. Pattern taught here: face-id routing in fx_color — the star_prism
// stream marks front 0 / back 1 / sides 2, and the look branches on it.
{
name: "Star Prism"
engine: "videomesh"
shape: "star_prism"
seed: 9
points: 5
size: 2.8
aspect: 1.4
fly: 0.8
beat_pulse: 0.5
input0: "test"
color_bg: #x08040e
color_a: #xffd040
color_b: #xf04fb0
color_c: #xfff2cc
fog: 0.0
glow: 1.0
stages: [
{kind: "bloom", threshold: 0.62, strength: 1.0, levels: 3}
]
// THE LOOK LIVES HERE — faces vs side band, routed on attr.y.
shader: draw.DrawVjFxVideomesh {
fx_axis: fn(id: float, hash: float) -> vec3 {
return vec3(0.25, 1.0, 0.2)
}
fx_place: fn(id: float, hash: float, t: float) -> vec4 {
return vec4(0.0, 0.0, 0.0,
t * 0.55 * (1.0 + clamp(self.user.x, 0.0, 4.0)) + 0.4 * sin(t * 0.27))
}
fx_color: fn(t: float, attr: vec4, content: vec4, cmix: float) -> vec4 {
let mut out = vec3(0.0, 0.0, 0.0)
if attr.y > 1.5 {
// The side band: the clip seen through a neon gel, pumping
// on the beat — never a flat card even edge-on.
out = (self.col_b.xyz * 0.35 + content.xyz * self.col_b.xyz * 1.4)
* (0.5 + self.time_beat.w * 1.0 + clamp(self.user.z, 0.0, 4.0))
* (0.4 + 0.6 * t)
} else {
out = content.xyz * t
+ self.col_c.xyz * (1.0 - attr.z) * 0.25
}
return vec4(out * self.fog.y, 1.0)
}
}
}