reactjs – What is the recommended method to get metadata from files uploaded with ffmpeg.wasm? HELP BEGINNER
I’m developing an app using vite react.js and ffmpeg.wasm and I’m having trouble to find out how to get the duration time of a file. I need to writeFile to the FS, read the metadata, get the time duration, store it in a variable so I can use it to encode other things.
I’ve tried to get it through log and process calls, but the time in log always shows different results, and the time in progress shows me how long the process it’s taking to finish, not the file duration time. I’ve tried to readFile in countless ways as well. I guess I could maybe do that by local directory reading methods, but I wish to do that only with ffmpeg.wasm. I’m currently running ffmpeg/core from its API, in the latest 12.4.0 version, and the ffmpeg/ffmpeg in its latest 12.7.0. I’m a beginner, so maybe the answer it’s right in my face, but I spent a good amount of time trying and can’t see to find a solution. Please help!!!!
Read more here: Source link
