Skip to content

Commit

Permalink
add more opt
Browse files Browse the repository at this point in the history
  • Loading branch information
GhostChild authored and datagutt committed Jul 16, 2019
1 parent c039c37 commit 613d524
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion node_relay_session.js
Expand Up @@ -18,7 +18,8 @@ class NodeRelaySession extends EventEmitter {

run() {
let format = this.conf.ouPath.startsWith('rtsp://') ? 'rtsp' : 'flv';
let argv = ['-fflags', 'nobuffer', '-i', this.conf.inPath, '-c', 'copy', '-f', format, this.conf.ouPath];
let argv = ['-fflags', 'nobuffer', '-i', this.conf.inPath, '-c', 'copy', '-f', format, this.conf.ouPath,
'-stimeout', '10000000 ','-reconnect', '1', '-reconnect_at_eof', '1', '-reconnect_streamed', '1', '-reconnect_delay_max', '2']
if (this.conf.inPath[0] === '/' || this.conf.inPath[1] === ':') {
argv.unshift('-1');
argv.unshift('-stream_loop');
Expand Down

0 comments on commit 613d524

Please sign in to comment.