nickadamson / messonry

Messy Meets Masonry Grid
https://nickadamson.github.io/messonry/?path=/story/example-messonry--default
MIT License
4 stars 0 forks source link

investigate ffmpeg/ffmpeg-probe/vercel compatability #15

Open nickadamson opened 1 year ago

nickadamson commented 1 year ago

as mentioned in #14, I need to investigate how to get video dimensions/resolution server side from a url.

due to the varied nature of video codecs, this pretty much requires the use of ffmpeg. there is a nodejs wrapper for it: https://github.com/fluent-ffmpeg/node-fluent-ffmpeg

the use of ffmpeg is likely going to involve some extra setup for server deployments, but this might help: https://www.npmjs.com/package/@ffprobe-installer/ffprobe

depending on how difficult installation is for users of this library and vercel deployment limits, this might actually be cause for creating 2 separate libraries, one that only supports images, and one that supports images+videos.

nickadamson commented 1 year ago

https://betterprogramming.pub/how-to-process-video-with-ffmpeg-and-nodejs-940a8e510791 useful article