ffmpeg.js
ffmpeg.js copied to clipboard
Streaming
would it be possible to get input from a remote source and push output to a remote destination? The use case would be with nodejs publishing services (e.g. through express), not a webapp shown in a browser
Thanks and BR
Hi there!
Also interest in similar case. I want to use remote source (say a file in Amazon S3) as stdin, pass it through ffmpeg.js and play in player on a page or save to file system.
Is it possible?
(all done in browser)
Thanks!
If you want to get an input from a remote source just feed ffmpeg.js with a Blob that you've retrieved using XHR. If you want to push it to a remote server in one request you need to be able to create a big blob which depends on #54 as your browser crashes randomly due to the very limited amount of blob elements (sometimes crashes with files < 70MB using ffmpeg.js). If you don't need to push it to a remote server in one request, you can write a server application that does the handling of the file chunks and create a new Emscripten FS using the synchronous XHR API to handle the chunks. With that the input/output file size should be unlimited and you could even create/consume streams.
Thanks @CodeFetch, I think that's correct. See also https://github.com/Kagami/ffmpeg.js/issues/11#issuecomment-564360336