I'll have to try some more stuff out with video elements too. I haven't dug that rabbit hole deep enough yet 😄
Posts by jessep
Mainly I wanted to try the sprite technique😄 This gives creative control tweaking the animation in post with CSS. Changing FPS, rescaling the pixel-art with `image-rendering: pixelated;` keeps it crispy looking. I also have user interaction ideas for the sprite, I imagine extend nicely with sprites.
The shader material based on this:
www.youtube.com/watch?v=sHwd...
CSS Code snippet for a single spritesheet animation where the animation frames have been wrapped on multiple rows. Utilizing two custom properties and keyframe animations for spritesheet frames X and Y coordinates.
I got it working on Chrome by doing 2 animations on the position values of the custom properties for the X and Y values.
Sadly I had to switch last minute to a better supported method of `overflow: hidden` + `translate` as I noticed that Firefox did not like my way of animating the variables 😵
I initially used the technique from the article. To animate the `object-position` which I liked a lot, and since my animation was so long I had to wrap it to multiple rows so as to not exceed WEBP maximum width, which required me to move the sprite's X and Y frame position at separate intervals.
Was inspired by this article to try a spritesheet animation:
@joshwcomeau.com
www.joshwcomeau.com/animation/sp...
Made this 3D animated puppy that I rendered into a 2D 1-bit style spritesheet CSS animation for my website. Weekend project went a bit overtime, but had to get it done before I'm off travelling 😪
Really beautiful work 🙌
This website is a definitive hype builder 😆🙌