Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add feature to remux signed rtmp stream #486

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/node_fission_session.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ class NodeFissionSession extends EventEmitter {
}

run() {
let inPath = 'rtmp://127.0.0.1:' + this.conf.rtmpPort + this.conf.streamPath;
let inPath = 'rtmp://127.0.0.1:' + this.conf.rtmpPort + this.conf.streamPath + ((this.conf.args.sign)? `?sign=${this.conf.args.sign}`: '');
let argv = ['-i', inPath];
for (let m of this.conf.model) {
let x264 = ['-c:v', 'libx264', '-preset', 'veryfast', '-tune', 'zerolatency', '-maxrate', m.vb, '-bufsize', m.vb, '-g', parseInt(m.vf) * 2, '-r', m.vf, '-s', m.vs];
Expand Down Expand Up @@ -51,4 +51,4 @@ class NodeFissionSession extends EventEmitter {
}
}

module.exports = NodeFissionSession;
module.exports = NodeFissionSession;
4 changes: 2 additions & 2 deletions src/node_trans_session.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class NodeTransSession extends EventEmitter {
run() {
let vc = this.conf.vc || 'copy';
let ac = this.conf.ac || 'copy';
let inPath = 'rtmp://127.0.0.1:' + this.conf.rtmpPort + this.conf.streamPath;
let inPath = 'rtmp://127.0.0.1:' + this.conf.rtmpPort + this.conf.streamPath + ((this.conf.args.sign)? `?sign=${this.conf.args.sign}`: '');
let ouPath = `${this.conf.mediaroot}/${this.conf.streamApp}/${this.conf.streamName}`;
let mapStr = '';

Expand Down Expand Up @@ -99,4 +99,4 @@ class NodeTransSession extends EventEmitter {
}
}

module.exports = NodeTransSession;
module.exports = NodeTransSession;