Forum Replies Created

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • in reply to: Movie Conversion #1366
    glenn
    Participant

    I don’t know what a “filmstrip BMP” is. Googling for it brings me back here, it looks like you mean a sprite sheet. I didn’t think of trying that–all of the examples on the SD card were one file per frame.

    The main difference is that I used the exact format of the backing store, with the pixel order and zigzag pixel output order baked into the file. This means the loop of reading a row at a time goes away, since I can just do read(strip.getPixels(), 768); strip.show(). The frame delay is embedded per-frame (though I doubt I’ll use anything but a constant value). I have a simple Python script to convert from an image sequence to this format.

    Sprite sheets would probably have done the job, but I like the result (INI files go away, and each video is a single file in the top directory), and it only took a few hours to do. (I spent more time getting Arduino to work than actually implementing anything, actually…)

    in reply to: Movie Conversion #1364
    glenn
    Participant

    Do you not have issues with framerate with large videos like this?

    When I tried playing video-framerate data, I found that it couldn’t manage the framerate. It’d start around 15-20 FPS (didn’t measure it), which was too low to keep up with movies, then progressively slow down as it rendered frames. It got down to around 4-5 FPS before I stopped it (don’t recall how long the video was, probably a few hundred frames). It looked like two problems: the frame rendering speed (too much conversion, etc. happening), and I think the SDFAT code is re-scanning the directory to find each file, so as it went further into the directory it’d take longer and longer to find the next frame.

    I ended up editing the firmware to make a movie player. It uses a custom pre-swizzled file format, which lets me read each frame directly into the backing store (reducing read-and-flip to a few lines of code), and which puts the whole video in a single file, so it never has to switch files mid-video. It manages around 50 FPS. 60 would be nice, but I was only looking to break 24, so I can export full-framerate animations from AFX. (I haven’t done anything with it or cleaned it up, or I’d send a PR as an alternate firmware.)

Viewing 2 posts - 1 through 2 (of 2 total)