Streampunk / beamcoder

Node.js native bindings to FFmpeg.
GNU General Public License v3.0
397 stars 76 forks source link

How to set movflags? #63

Closed felicemarra closed 3 years ago

felicemarra commented 3 years ago

Hi.. I'm trying to stream via rtmp to social networks. Everything works with facebook and node-media-stream but I have troubles with youtube and twitch.

I tested with classic ffmpeg and I saw that if I put -movflags faststart works well. If I miss movflags parameter doesn't work.

So I tried to set movflags with this function await muxer.initOutput({ movflags: "faststart" })

but I'm not shure if the syntax is correct. Nothing changes about youtube streaming and I don't know how can I check if this flag is actually setted

Anyone can help me?

Rock-N-Troll commented 3 years ago

If you do a search in this repo, I think you will come across where I found something like the following (mostly untested on my end)

https://github.com/Streampunk/beamcoder/search?q=movflags&type=issues

await mux.initOutput({ movflags: 'frag_keyframe+empty_moov+default_base_moof'});