First stab at webGL, in 1k between two nappy changes. It's glitchy and tiny but I quite like this puppy. It ranked #3 at DemoJS.
This entry is a bit of a proof of concept: I was sure it was possible to make something decent in 1k with webGL but wondered how much effort this could take and how small the setup code would be.
It turns out it's not that complex and the setup code ( including vertex shader and a minimal fragment shader ) is under 500 bytes uncompressed which leaves a lot of space for a shiny fragment shader.
Initially this little intro was made for DemoJS and took 1024 bytes of JS. If you add the HTML/CSS/JS shim, it weighed around 2.5Kb. Soon after I wrote a standalone version in 961 bytes. Today, the standalone version clocks at 842 bytes with the following breakdown:
- 87 bytes of HTML + CSS
- 441 bytes of GLSL ( 44 and 397 for the vertex and fragment shader respectively )
Comments and other karma retribution
Make sure to leave comments, piggies and thumbs up or down for GL1K Cotton Candy on Pouet.net.
To be continued...
Expect more gl1k productions in the future. Making this intro was fun and there is no doubt this intro can be optimized further and the setup code improved.
Other recent projects
There are many experiments and projects like COTTON CANDY to discover other here.
- MUSIC FOR TINY AIRPORTS 2/1 🛫 Celebrating the 40 years anniversay of Brian Eno's "Ambient 1: Music for Airports" with an homage written in 256 bytes with the Web Audio API.
- THEY COME AT DUSK 👺 A survival horror game for JS1k 2018, where you run away from dead miners as you hear your heart beat. Turn around using the arrow keys until all you hear is beeeeeeeep.
- FRONTFEST MOSCOW It was an honour to be invited to Fronfest Moscow 2017 with the little family to give my first workshop; implementing a Twin-stick shooter using ES6 and Canvas, and to continue my CODE🎙ART series of talks + live coding aiming to inspire new web developer artists.
- SUDOKU SOLVER Solves a Sudoku grid using magic, recursion, and 140bytes of brute force.
- WOLF1K The idea of this entry for the JS1K contest was to do the impossible: a 1K remake of the famous WOLF5K that rocked the final edition of the5K. It does not feature guns, evil grins and violence for in WOLF1K there is no room for guns or any form of violence.
- FIRE Warming up with a 32 bytes fire effect for MSDOS after a few years break from the demoscene for studies and work.
- 256B.HTM ROUND 2 The second edition of the 256B.HTM contest allowed 3 entries per author. Mine ranked 1st, 2nd and 4th out of 43. Only a few points shy of a total take over!
Don't be shy; get in touch by mail, twitter, github, linkedin or pouet if you have any questions, feedback, speaking, workshop or performance opportunity.