ok so there's a contraption for importing and playing back a gif https://itch.io/post/7502270 and if I can get this running at a consistent enough speed and maybe change things around so it's triggered by a button click, and then I could trigger an audio file to play at the same time and like hopefully it syncs up vaguely?
so far my experiment has been that I can import a gif in using the contraption above that I've converted from a video, and it does show up all nice and dithered and 1-bit, but at least at the size I used (320x240) it's not running at full speed. This may be a case of needing a smaller size, and if I can create the gifs with a 1-bit palette that may help too since then it's not like two layers of downsampling. And I'll need to do a bit of coding to get it playing on demand but like I reckon I could definitely do it, sort of. The real question is performance, like whether it'll fall out of sync and such.
I want to make it work though! Or at least see if I can try!
I don't quite have a proof of concept I want to share yet, but I'll try and get something to show on the weekend
So, first step is I use ffmpeg to convert my video into a gif and a wave file
Then, using a pretty similar method to the gif playback contraption, I import the gif in and stash it in a richtext field - this is basically what the gif contraption does, at this stage I'm just doing it by bunging some code right into the listener
then I just iterate through the frames stored in the richtext field, and display each one and then wait for however many frames are necessary considering my video's framerate. If you start the audio playing at the start of this then... hopefully it synchs up.
Right now I have two main things I wanna fix before sticking a demo up
- converting the video, in theory I wanna do the conversion to a 1-bit palette in ffmpeg, and I assume this should be possible, I'll just need to poke around a bit, I'm not super familiar wtih ffmpeg. Right now I've just stuck a roughly-converted colour gif in which Decker converts to its own secret 16-colour palette. The resulting filesize is way too big, so for a sharable version I'll use 1-bit colour and probably a smaller video size.
- it doesn't QUITE synch up at the moment, because the test video is something I shot on my phone that did it some sort of godawful variable framerate low light mode when what I need is a nice locked 30fps. I'll try and make something nice for a test. Perfect sync may or may not be achievable, we shall see.
but yeah, stay tuned for a decker deck that has a video embedded in it. it will not look impressive at all except to people who've played around with decker and are familiar with its capabilities and limitations. but assuming I can get it to a point where I'm happy enough to share then I am definitely doing this in my next zine!
