build-lens-raindrops
Add camera-space water drops, rain on glass and windshield beads that bend the live scene. Use for a rain-soaked driving camera, a wet intro lens, speed-responsive runoff or a performant WebGL refraction pass.
Install / Use
npx skills add MengTo/Skills --skill build-lens-raindropsInstalls into whichever agent you are using.
SKILL.md
Installable skill definition
Quality Score
Category
MarketingSupported Platforms
Tags
Our assessment of build-lens-raindrops
build-lens-raindrops scores 88/100 on our quality scale, 286th of 647 Marketing skills we index (top 45%).
Its SKILL.md is 4.1 KB long, split into 4 sections with 1 code example: a solid amount of guidance for an agent.
With 6,252 GitHub stars, it is one of the more widely adopted skills in the catalogue.
Maintenance, license and trust
- The repository was last updated about 2 months ago, so build-lens-raindrops is actively maintained.
- It is released under the MIT license, a permissive license that allows use, modification and commercial use with attribution.
- Its trust signals score 100/100, with no cautions. These come from repository metadata, not a code audit — read the skill file before letting an agent act on it.
build-lens-raindrops compared with similar skills
All 4 of these similar skills score higher than build-lens-raindrops; compare them before choosing.
| Skill | Score | Stars | Updated | Format |
|---|---|---|---|---|
| build-lens-raindrops (this skill)by MengTo | 88 | 6.3k | 2mo ago | SKILL.md |
| algorithmic-artby anthropics | 100 | 177.9k | 2mo ago | SKILL.md |
| pptxby anthropics | 100 | 177.9k | 2mo ago | SKILL.md |
| prospectingby coreyhaines31 | 100 | 62.2k | 6d ago | SKILL.md |
| ad-creativeby coreyhaines31 | 100 | 62.2k | 6d ago | SKILL.md |
Frequently asked questions
- How do I install build-lens-raindrops?
- Run
npx skills add MengTo/Skills --skill build-lens-raindrops. The install tabs above show the steps for each supported agent. - Which AI agents does build-lens-raindrops work with?
- It is written for Universal, as a SKILL.md file. Other agents that read the same format can often use it too.
- Is build-lens-raindrops safe to use?
- It is MIT-licensed and scores 100/100 on trust signals. Skills are instructions an agent will follow, so read the file before installing it and do not approve commands you do not understand.
- Is build-lens-raindrops still maintained?
- The repository was last updated about 2 months ago, so build-lens-raindrops is actively maintained.
Skill content
View source on GitHubname: build-lens-raindrops description: Add camera-space water drops, rain on glass and windshield beads that bend the live scene. Use for a rain-soaked driving camera, a wet intro lens, speed-responsive runoff or a performant WebGL refraction pass.
Build lens raindrops
Start with a moving scene containing one strong contrast edge, such as a lit sign against a dark wall. A convincing bead bends that edge inside its silhouette. To judge the motion, look at a stationary bead and a runner side by side.
Watch the lens comparison or inspect the taillight detail. Both sides use the same recorded game frame. The right side runs the two bundled shaders over it. The lower pair magnifies the same region in each render.
Wire the two passes
- Finish rendering the 3D scene, including the lights you want refracted, to a sampleable color target. Give it clamp-to-edge sampling. Keep the HUD in a later pass or DOM layer so speed, messages and buttons stay readable.
- Draw drop-field.frag on a fullscreen triangle into a separate, linearly filtered RGBA8 target at half the scene's width and height. The red and green channels store biased signed slopes. Blue carries droplet height. Treat this field as linear data, with blending, tone mapping, color conversion and mipmaps off.
- Draw refract.frag to a different target using the scene color and field. Feed both passes a bottom-left-origin
vUvin [0,1]. GiveuAspectthe scene's width divided by height. In the field pass, setuFieldSizeto the actual field target size in pixels. Resize targets when viewport or render scale changes. Apply the output color transform once in the host pipeline. - Feed
uIntensity(0–1) anduPhase(accumulated animation time) to the field. FeeduAmount(0–1) anduBendto the composite. Try 0.005 foruBendin viewport-height units. Both shaders use WebGL 2. In a node-material pipeline the same stages are a data render target followed by a displaced scene-color lookup.
The sample combines fine pinned beads with larger runners. Per-column timing breaks up parallel movement. Each moving bead has a round head and thinner tail extending upward. Taking differences of the scalar field produces a slope which bends the underlying image. Reversing the UV origin reverses the apparent fall; correct the coordinate convention at the pass boundary.
Drive it from weather and speed
The game's driving lens used a half-resolution field, a speed ramp between 30 and 240 km/h, and separate wetting and drying rates. Its intro glass had a separate treatment. Adapt those thresholds to the game's actual cruising speed. A slow market drive may need visible drizzle even at idle.
// dt is elapsed simulation time in seconds. Clamp long resume gaps in the host clock.
const speedMix = Math.min(1, Math.max(0, (Math.abs(kmh) - minKmh) / (fullKmh - minKmh)));
const target = exposed ? rainIntensity * (idleWetness + (1 - idleWetness) * speedMix) : 0;
const rate = target > wetness ? 1.2 : 0.35;
wetness += (target - wetness) * -Math.expm1(-rate * dt);
if (target === 0 && wetness < 0.002) wetness = 0;
phase += dt * (0.9 + 2.4 * wetness);
Choose fullKmh > minKmh; keep rain intensity and idle wetness in [0,1]. Use wetness for intensity and Math.min(1, wetness * 5) for amount as a starting point. Resume with the current phase when rain returns. At zero, bypass both passes and use the unmodified scene. On a wet menu or stationary window, drive the same inputs from rainfall and elapsed time. For reduced motion, hold the phase or fade out the pass according to the host's preference setting.
Test the glass
Move a bright line behind a drop. The line should bend locally and remain sharp on the dry glass. Pan the camera; the field should stay attached to the screen. Compare idle, acceleration and shelter, then check the same bead at wide and portrait aspect ratios. Inspect the HUD at peak wetness. On low-end hardware, reduce the field target first and measure GPU frame time. Render a dry frame against the same unprocessed scene and compare their pixels.
Related Skills
algorithmic-art
177.9kCreating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems.
pptx
177.9kUse this skill any time a .pptx or .potx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or presentations; reading, parsing, or extracting text from any .pptx or .potx file (even if the extracted content will be used elsewhere, like in an em…
prospecting
62.2kWhen the user wants to find and qualify prospects for outbound, or asks who to target first, which signal to prioritize, or where to spot buyers with the problem: buying signals, enrichment, verification, account research.
ad-creative
62.2kWhen the user wants to write or judge ad creative, or asks which ad, hook, or angle to run or kill: headlines, primary text, and variations for Google, Meta, LinkedIn, and TikTok, fresh angles when creative fatigues. Test hypotheses name the metric, comparison, and expected direction.
Languages
Trust signals
From repository metadata: license, adoption, age and documentation. Not a code audit — see the Safety scan above for what the skill file itself contains.
