https://github.com/danielesteban/vermeer
https://github.com/danielesteban/vermeer
Last synced: over 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/danielesteban/vermeer
- Owner: danielesteban
- License: mit
- Created: 2023-06-29T16:38:37.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2023-06-29T23:24:21.000Z (about 3 years ago)
- Last Synced: 2025-02-13T05:34:23.213Z (over 1 year ago)
- Language: TypeScript
- Homepage: https://vermeer.gatunes.com/
- Size: 2.05 MB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
[vermeer](https://github.com/danielesteban/vermeer)
==
[](https://vermeer.gatunes.com)
#### Setup pass (Runs once)
* Load a texture
* Render it with the [Velocity](src/shaders/velocity.ts) shader to get a velocity map
* The velocity map stores the difference in lightness for every pixel
* Setup two ping-pong rendertargets
* [Populate](src/shaders/populate.ts) the first render target with the initial position and velocity for every dot
* Generate a color map with a random color for every dot
#### Compute pass (Runs every frame)
* Render the current rendertarget texture with the [Compute](src/shaders/compute.ts) shader to get the next simulation state
* This shader uses the velocity map to slow down the points near the bright pixels of the input image
* Swap the rendertargets
#### Render pass (Runs every frame)
* Render a instanced plane for every dot with the [Dots](src/shaders/dots.ts) shader
* This shader uses the last computed simulation state and the color map to position and color the dots.