mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2026-01-29 00:51:53 +08:00
native tracks list for janus 1.x
This commit is contained in:
@@ -235,8 +235,17 @@ export function JanusStreamer(__setActive, __setInactive, __setInfo, __orient, _
|
|||||||
|
|
||||||
if (jsep) {
|
if (jsep) {
|
||||||
__logInfo("Handling SDP:", jsep);
|
__logInfo("Handling SDP:", jsep);
|
||||||
|
let tracks = [{"type": "video", "capture": false, "recv": true, "add": true}];
|
||||||
|
if (__allow_audio) {
|
||||||
|
tracks.push({"type": "audio", "capture": false, "recv": true, "add": true});
|
||||||
|
}
|
||||||
__handle.createAnswer({
|
__handle.createAnswer({
|
||||||
"jsep": jsep,
|
"jsep": jsep,
|
||||||
|
|
||||||
|
// Janus 1.x
|
||||||
|
"tracks": tracks,
|
||||||
|
|
||||||
|
// Janus 0.x
|
||||||
"media": {"audioSend": false, "videoSend": false, "data": false},
|
"media": {"audioSend": false, "videoSend": false, "data": false},
|
||||||
|
|
||||||
"success": function(jsep) {
|
"success": function(jsep) {
|
||||||
|
|||||||
Reference in New Issue
Block a user