diff --git a/main.go b/main.go index 0100c45..93f577b 100644 --- a/main.go +++ b/main.go @@ -55,6 +55,7 @@ var api *API var SSRC uint32 var SSRCMap = make(map[string]uint32) var ssrcLock sync.Mutex +var playWaitList sync.Map func init() { m.RegisterCodec(NewRTPH264Codec(DefaultPayloadTypeH264, 90000)) @@ -72,162 +73,125 @@ type WebRTC struct { RTP *PeerConnection RemoteAddr string + videoTrack *Track } func (rtc *WebRTC) Play(streamPath string) bool { - peerConnection, err := api.NewPeerConnection(Configuration{ - ICEServers: []ICEServer{ - { - URLs: config.ICEServers, - }, - }, - }) - if _, err = peerConnection.AddTransceiverFromKind(RTPCodecTypeVideo); err != nil { - if err != nil { - Println(err) - return false - } - } - if err != nil { - return false - } - - rtc.PeerConnection = peerConnection - // Create a video track, using the same SSRC as the incoming RTP Packet - ssrcLock.Lock() - ssrc, ok := SSRCMap[streamPath] - if !ok { - SSRC++ - ssrc = SSRC - SSRCMap[streamPath] = SSRC - } - ssrcLock.Unlock() - videoTrack, err := peerConnection.NewTrack(DefaultPayloadTypeH264, ssrc, "video", "monibuca") - if err != nil { - Println(err) - return false - } - if _, err = peerConnection.AddTrack(videoTrack); err != nil { - Println(err) - return false - } - var sequence uint16 - var sub Subscriber - var sps []byte - var pps []byte - sub.ID = rtc.RemoteAddr - sub.Type = "WebRTC" - nextHeader := func(ts uint32, marker bool) rtp.Header { - sequence++ - return rtp.Header{ - Version: 2, - SSRC: ssrc, - PayloadType: DefaultPayloadTypeH264, - SequenceNumber: sequence, - Timestamp: ts, - Marker: marker, - } - } - stapA := func(naul ...[]byte) []byte { - var buffer bytes.Buffer - buffer.WriteByte(24) - for _, n := range naul { - l := len(n) - buffer.WriteByte(byte(l >> 8)) - buffer.WriteByte(byte(l)) - buffer.Write(n) - } - return buffer.Bytes() - } - - // aud := []byte{0x09, 0x30} - sub.OnData = func(packet *avformat.SendPacket) error { - if packet.Type == avformat.FLV_TAG_TYPE_AUDIO { - return nil - } - if packet.IsSequence { - payload := packet.Payload[11:] - spsLen := int(payload[0])<<8 + int(payload[1]) - sps = payload[2:spsLen] - payload = payload[3+spsLen:] - ppsLen := int(payload[0])<<8 + int(payload[1]) - pps = payload[2:ppsLen] - } else { - if packet.IsKeyFrame { - if err := videoTrack.WriteRTP(&rtp.Packet{ - Header: nextHeader(0, true), - Payload: stapA(sps, pps), - }); err != nil { - return err + rtc.OnICEConnectionStateChange(func(connectionState ICEConnectionState) { + Printf("%s Connection State has changed %s ", streamPath, connectionState.String()) + switch connectionState { + case ICEConnectionStateDisconnected: + if rtc.Stream != nil { + rtc.Stream.Close() + } + case ICEConnectionStateConnected: + var sequence uint16 + var sub Subscriber + var sps []byte + var pps []byte + sub.ID = rtc.RemoteAddr + sub.Type = "WebRTC" + nextHeader := func(ts uint32, marker bool) rtp.Header { + sequence++ + return rtp.Header{ + Version: 2, + SSRC: SSRC, + PayloadType: DefaultPayloadTypeH264, + SequenceNumber: sequence, + Timestamp: ts, + Marker: marker, } } - payload := packet.Payload[5:] - for { - var naulLen = int(util.BigEndian.Uint32(payload)) - payload = payload[4:] - _payload := payload[:naulLen] - if naulLen > 1000 { - part := _payload[:1000] - indicator := ((part[0] >> 5) << 5) | 28 - nalutype := part[0] & 31 - header := 128 | nalutype - part = part[1:] - marker := false - for { - if err := videoTrack.WriteRTP(&rtp.Packet{ - Header: nextHeader(packet.Timestamp*90, marker), - Payload: append([]byte{indicator, header}, part...), + stapA := func(naul ...[]byte) []byte { + var buffer bytes.Buffer + buffer.WriteByte(24) + for _, n := range naul { + l := len(n) + buffer.WriteByte(byte(l >> 8)) + buffer.WriteByte(byte(l)) + buffer.Write(n) + } + return buffer.Bytes() + } + + // aud := []byte{0x09, 0x30} + sub.OnData = func(packet *avformat.SendPacket) error { + if packet.Type == avformat.FLV_TAG_TYPE_AUDIO { + return nil + } + if packet.IsSequence { + payload := packet.Payload[11:] + spsLen := int(payload[0])<<8 + int(payload[1]) + sps = payload[2:spsLen] + payload = payload[3+spsLen:] + ppsLen := int(payload[0])<<8 + int(payload[1]) + pps = payload[2:ppsLen] + } else { + if packet.IsKeyFrame { + if err := rtc.videoTrack.WriteRTP(&rtp.Packet{ + Header: nextHeader(packet.Timestamp*90, true), + Payload: stapA(sps, pps), }); err != nil { return err } - if _payload == nil { - break - } - if len(_payload[1000:]) <= 1000 { - header = 64 | nalutype - part = _payload[1000:] - _payload = nil - marker = true + } + payload := packet.Payload[5:] + for { + var naulLen = int(util.BigEndian.Uint32(payload)) + payload = payload[4:] + _payload := payload[:naulLen] + if naulLen > 1000 { + indicator := (_payload[0] & 224) | 28 + nalutype := _payload[0] & 31 + header := 128 | nalutype + part := _payload[1:1000] + marker := false + for { + if err := rtc.videoTrack.WriteRTP(&rtp.Packet{ + Header: nextHeader(packet.Timestamp*90, marker), + Payload: append([]byte{indicator, header}, part...), + }); err != nil { + return err + } + if _payload == nil { + break + } + _payload = _payload[1000:] + if len(_payload) <= 1000 { + header = 64 | nalutype + part = _payload + _payload = nil + marker = true + } else { + header = nalutype + part = _payload[:1000] + } + } } else { - header = nalutype - part = _payload[1000:] - _payload = part + if err := rtc.videoTrack.WriteRTP(&rtp.Packet{ + Header: nextHeader(packet.Timestamp*90, true), + Payload: _payload, + }); err != nil { + return err + } } + if len(payload) < naulLen+4 { + break + } + payload = payload[naulLen:] } - } else { - if err := videoTrack.WriteRTP(&rtp.Packet{ - Header: nextHeader(packet.Timestamp*90, true), - Payload: _payload, - }); err != nil { - return err - } + // if err := videoTrack.WriteRTP(&rtp.Packet{ + // Header: nextHeader(packet.Timestamp * 90), + // Payload: aud, + // }); err != nil { + // return err + // } } - if len(payload) < naulLen+4 { - break - } - payload = payload[naulLen:] + return nil } - // if err := videoTrack.WriteRTP(&rtp.Packet{ - // Header: nextHeader(packet.Timestamp * 90), - // Payload: aud, - // }); err != nil { - // return err - // } + go sub.Subscribe(streamPath) } - return nil - } - go sub.Subscribe(streamPath) - // peerConnection.OnICEConnectionStateChange(func(connectionState ICEConnectionState) { - // Printf("%s Connection State has changed %s ", streamPath, connectionState.String()) - // switch connectionState { - // case ICEConnectionStateDisconnected: - // if rtc.Stream != nil { - // rtc.Stream.Close() - // } - // case ICEConnectionStateConnected: - - // } - // }) + }) return true } func (rtc *WebRTC) Publish(streamPath string) bool { @@ -310,30 +274,79 @@ func (rtc *WebRTC) GetAnswer(localSdp SessionDescription) ([]byte, error) { func run() { http.HandleFunc("/webrtc/play", func(w http.ResponseWriter, r *http.Request) { streamPath := r.URL.Query().Get("streamPath") - // offer := SessionDescription{} - // bytes, err := ioutil.ReadAll(r.Body) - // err = json.Unmarshal(bytes, &offer) - // if err != nil { - // Println(err) - // return - // } - rtc := new(WebRTC) - rtc.RemoteAddr = r.RemoteAddr - if rtc.Play(streamPath) { - offer, err := rtc.CreateOffer(nil) - if err != nil { + offer := SessionDescription{} + bytes, err := ioutil.ReadAll(r.Body) + err = json.Unmarshal(bytes, &offer) + if err != nil { + Println(err) + return + } + if value, ok := playWaitList.Load(streamPath); ok { + rtc := value.(*WebRTC) + if err := rtc.SetRemoteDescription(offer); err != nil { Println(err) return } - if bytes, err := rtc.GetAnswer(offer); err == nil { - w.Write(bytes) + if rtc.Play(streamPath) { + w.Write([]byte(`success`)) } else { + w.Write([]byte(`{"errmsg":"bad name"}`)) + } + } else { + w.Write([]byte(`{"errmsg":"bad name"}`)) + } + }) + http.HandleFunc("/webrtc/preparePlay", func(w http.ResponseWriter, r *http.Request) { + streamPath := r.URL.Query().Get("streamPath") + rtc := new(WebRTC) + peerConnection, err := api.NewPeerConnection(Configuration{ + ICEServers: []ICEServer{ + { + URLs: config.ICEServers, + }, + }, + }) + if _, err = peerConnection.AddTransceiverFromKind(RTPCodecTypeVideo); err != nil { + if err != nil { Println(err) - w.Write([]byte(err.Error())) return } + } + if err != nil { + return + } + + rtc.PeerConnection = peerConnection + // Create a video track, using the same SSRC as the incoming RTP Packet + ssrcLock.Lock() + if _, ok := SSRCMap[streamPath]; !ok { + SSRC++ + SSRCMap[streamPath] = SSRC + } + ssrcLock.Unlock() + videoTrack, err := rtc.NewTrack(DefaultPayloadTypeH264, SSRC, "video", "monibuca") + if err != nil { + Println(err) + return + } + if _, err = rtc.AddTrack(videoTrack); err != nil { + Println(err) + return + } + rtc.videoTrack = videoTrack + playWaitList.Store(streamPath, rtc) + rtc.RemoteAddr = r.RemoteAddr + offer, err := rtc.CreateOffer(nil) + if err != nil { + Println(err) + return + } + if bytes, err := rtc.GetAnswer(offer); err == nil { + w.Write(bytes) } else { - w.Write([]byte(`{"errmsg":"bad name"}`)) + Println(err) + w.Write([]byte(err.Error())) + return } }) http.HandleFunc("/webrtc/publish", func(w http.ResponseWriter, r *http.Request) { @@ -364,6 +377,7 @@ func run() { w.Write([]byte(err.Error())) return } + w.Write([]byte(`success`)) } else { w.Write([]byte(`{"errmsg":"bad name"}`)) } diff --git a/ui/dist/plugin-webrtc.common.js b/ui/dist/plugin-webrtc.common.js index f644909..61aea88 100644 --- a/ui/dist/plugin-webrtc.common.js +++ b/ui/dist/plugin-webrtc.common.js @@ -87,6 +87,24 @@ module.exports = /************************************************************************/ /******/ ({ +/***/ "11a1": +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_09aaef78_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("30b5"); +/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_09aaef78_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_09aaef78_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__); +/* unused harmony reexport * */ + /* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_09aaef78_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a); + +/***/ }), + +/***/ "30b5": +/***/ (function(module, exports, __webpack_require__) { + +// extracted by mini-css-extract-plugin + +/***/ }), + /***/ "8875": /***/ (function(module, exports, __webpack_require__) { @@ -163,24 +181,6 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_ })); -/***/ }), - -/***/ "8e55": -/***/ (function(module, exports, __webpack_require__) { - -// extracted by mini-css-extract-plugin - -/***/ }), - -/***/ "e91a": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_03ea1df8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("8e55"); -/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_03ea1df8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_03ea1df8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__); -/* unused harmony reexport * */ - /* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_03ea1df8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a); - /***/ }), /***/ "fb15": @@ -214,12 +214,12 @@ if (typeof window !== 'undefined') { // Indicate to webpack that this file can be concatenated /* harmony default export */ var setPublicPath = (null); -// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"7d106341-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/App.vue?vue&type=template&id=03ea1df8&scoped=true& +// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"7d106341-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/App.vue?vue&type=template&id=09aaef78&scoped=true& var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[(_vm.$parent.titleTabActive == 1)?_c('pre',[_vm._v(_vm._s(_vm.localSDP))]):(_vm.$parent.titleTabActive == 2)?_c('pre',[_vm._v(_vm._s(_vm.remoteSDP))]):_c('div',[_c('mu-text-field',{attrs:{"label":"streamPath"},model:{value:(_vm.streamPath),callback:function ($$v) {_vm.streamPath=$$v},expression:"streamPath"}}),(!_vm.localSDP || _vm.ask)?_c('span',{staticClass:"blink"},[_vm._v("Connecting")]):_vm._e(),[_c('m-button',{on:{"click":function($event){return _vm.startSession('publish')}}},[_vm._v("Publish")]),_c('m-button',{on:{"click":function($event){return _vm.startSession('play')}}},[_vm._v("Play")])],_c('m-button',{on:{"click":_vm.stopSession}},[_vm._v("Stop")]),_c('br'),_c('video',{ref:"video1",attrs:{"width":"640","height":"480","autoplay":"","muted":""},domProps:{"srcObject":_vm.stream,"muted":true}})],2)])} var staticRenderFns = [] -// CONCATENATED MODULE: ./src/App.vue?vue&type=template&id=03ea1df8&scoped=true& +// CONCATENATED MODULE: ./src/App.vue?vue&type=template&id=09aaef78&scoped=true& // CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/App.vue?vue&type=script&lang=js& // @@ -287,6 +287,33 @@ var streamPath = "live/rtc"; async startSession(type) { this.type = type; this.ask = true; + if (type == "play") { + const result = await this.ajax({ + url: "/webrtc/preparePlay?streamPath=" + this.streamPath, + dataType: "json" + }); + if (result.errmsg) { + this.$toast.error(result.errmsg); + return; + } else { + streamPath = this.streamPath; + this.remoteSDP = result.sdp; + } + pc.ontrack = event => { + console.log(event) + if (event.streams[0].id == "monibuca") + this.stream = stream = event.streams[0]; + }; + await pc.setRemoteDescription( + new RTCSessionDescription(result) + ); + await pc.setLocalDescription(await pc.createAnswer()); + this.localSDP = pc.localDescription.sdp; + } else { + pc.addStream(stream); + await pc.setLocalDescription(await pc.createOffer()); + this.localSDP = pc.localDescription.sdp; + } const result = await this.ajax({ type: "POST", processData: false, @@ -295,24 +322,17 @@ var streamPath = "live/rtc"; dataType: "json" }); this.ask = false; - if (result.errmsg) { - this.$toast.error(result.errmsg); + if (result!="success") { + this.$toast.error(result.errmsg||result); + return; } else { streamPath = this.streamPath; - this.remoteSDP = result.sdp; - this.$parent.titleTabs = ["摄像头", "localSDP", "remoteSDP"]; - pc.setRemoteDescription(new RTCSessionDescription(result)); } - if (type == "publish") { - pc.addStream(stream); - this.localSDP = ( - await pc.setLocalDescription(await pc.createOffer()) - ).sdp; + if (type == "play") { + } else { - pc.ontrack = event => { - if(event.streams[0].id=="monibuca") - this.stream = stream = event.streams[0]; - }; + this.remoteSDP = result.sdp; + pc.setRemoteDescription(new RTCSessionDescription(result)); } }, stopSession() { @@ -332,33 +352,23 @@ var streamPath = "live/rtc"; this.$toast.info(pc.iceConnectionState); this.iceConnectionState = pc.iceConnectionState; }; - pc.onicecandidate = event => { - if (event.candidate === null) { - this.$parent.titleTabs = ["摄像头", "localSDP"]; - } - }; - if (this.localSDP) { - let tabs = ["摄像头"]; - if (this.localSDP) tabs.push("localSDP"); - if (this.remoteSDP) tabs.push("remoteSDP"); - this.$parent.titleTabs = tabs; - } else { - try { - if (!this.stream) - this.stream = stream = await navigator.mediaDevices.getUserMedia( - { video: true, audio: true } - ); - } catch (err) { - this.$toast.error(err.message); - } + pc.onicecandidate = event => {}; + this.$parent.titleTabs = ["摄像头", "localSDP", "remoteSDP"]; + try { + if (!this.stream) + this.stream = stream = await navigator.mediaDevices.getUserMedia( + { video: true, audio: true } + ); + } catch (err) { + this.$toast.error(err.message); } } }); // CONCATENATED MODULE: ./src/App.vue?vue&type=script&lang=js& /* harmony default export */ var src_Appvue_type_script_lang_js_ = (Appvue_type_script_lang_js_); -// EXTERNAL MODULE: ./src/App.vue?vue&type=style&index=0&id=03ea1df8&scoped=true&lang=css& -var Appvue_type_style_index_0_id_03ea1df8_scoped_true_lang_css_ = __webpack_require__("e91a"); +// EXTERNAL MODULE: ./src/App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css& +var Appvue_type_style_index_0_id_09aaef78_scoped_true_lang_css_ = __webpack_require__("11a1"); // CONCATENATED MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js /* globals __VUE_SSR_CONTEXT__ */ @@ -475,7 +485,7 @@ var component = normalizeComponent( staticRenderFns, false, null, - "03ea1df8", + "09aaef78", null ) diff --git a/ui/dist/plugin-webrtc.common.js.map b/ui/dist/plugin-webrtc.common.js.map index 3f0b539..1eeac2c 100644 --- a/ui/dist/plugin-webrtc.common.js.map +++ b/ui/dist/plugin-webrtc.common.js.map @@ -1 +1 @@ -{"version":3,"sources":["webpack://plugin-webrtc/webpack/bootstrap","webpack://plugin-webrtc/./node_modules/@soda/get-current-script/index.js","webpack://plugin-webrtc/./src/App.vue?8531","webpack://plugin-webrtc/./src/App.vue?b994","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js","webpack://plugin-webrtc/./src/App.vue?8171","webpack://plugin-webrtc/src/App.vue","webpack://plugin-webrtc/./src/App.vue?8b47","webpack://plugin-webrtc/./node_modules/vue-loader/lib/runtime/componentNormalizer.js","webpack://plugin-webrtc/./src/App.vue","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js"],"names":[],"mappings":";;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;AClFA;AACA;AACA;;AAEA;;AAEA;AACA,MAAM,IAA0C;AAChD,IAAI,iCAAO,EAAE,oCAAE,OAAO;AAAA;AAAA;AAAA,oGAAC;AACvB,GAAG,MAAM,EAIN;AACH,CAAC;AACD;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0DAA0D;;AAE1D;AACA;AACA,+DAA+D,qBAAqB;AACpF;AACA;;AAEA,qBAAqB,oBAAoB;AACzC;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,CAAC;;;;;;;;ACvED,uC;;;;;;;;ACAA;AAAA;AAAA;AAAgc,CAAgB,ggBAAG,EAAC,C;;;;;;;;;;;;ACApd;;AAEA;AACA;AACA,MAAM,IAAuC;AAC7C,2BAA2B,mBAAO,CAAC,MAA0B;AAC7D;;AAEA;AACA;AACA,wDAAwD,wBAAwB;AAChF;AACA;;AAEA;AACA;AACA,IAAI,qBAAuB;AAC3B;AACA;;AAEA;AACe,sDAAI;;;ACrBnB,0BAA0B,aAAa,0BAA0B,wBAAwB,sMAAsM,OAAO,qBAAqB,QAAQ,gDAAgD,mBAAmB,0BAA0B,wCAAwC,oBAAoB,kDAAkD,IAAI,yBAAyB,qCAAqC,qCAAqC,IAAI,yBAAyB,kCAAkC,mCAAmC,IAAI,yBAAyB,wCAAwC,oBAAoB,sDAAsD,WAAW,qCAAqC;AACt5B;;;;;;;;;;;;;;;;;;;;;;;;;ACkBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,EAAC;;;ACnIoK,CAAgB,+FAAG,EAAC,C;;;;;ACA1L;;AAEA;AACA;AACA;;AAEe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,yBAAyB;AACzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;;ACjG8F;AACvC;AACL;AACqC;;;AAGvF;AACuF;AACvF,gBAAgB,kBAAU;AAC1B,EAAE,+BAAM;AACR,EAAE,MAAM;AACR,EAAE,eAAe;AACjB;AACA;AACA;AACA;;AAEA;;AAEe,yD;;ACnBS;AACA;AACT,kFAAG;AACI","file":"plugin-webrtc.common.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"fb15\");\n","// addapted from the document.currentScript polyfill by Adam Miller\n// MIT license\n// source: https://github.com/amiller-gh/currentScript-polyfill\n\n// added support for Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1620505\n\n(function (root, factory) {\n if (typeof define === 'function' && define.amd) {\n define([], factory);\n } else if (typeof module === 'object' && module.exports) {\n module.exports = factory();\n } else {\n root.getCurrentScript = factory();\n }\n}(typeof self !== 'undefined' ? self : this, function () {\n function getCurrentScript () {\n if (document.currentScript) {\n return document.currentScript\n }\n \n // IE 8-10 support script readyState\n // IE 11+ & Firefox support stack trace\n try {\n throw new Error();\n }\n catch (err) {\n // Find the second match for the \"at\" string to get file src url from stack.\n var ieStackRegExp = /.*at [^(]*\\((.*):(.+):(.+)\\)$/ig,\n ffStackRegExp = /@([^@]*):(\\d+):(\\d+)\\s*$/ig,\n stackDetails = ieStackRegExp.exec(err.stack) || ffStackRegExp.exec(err.stack),\n scriptLocation = (stackDetails && stackDetails[1]) || false,\n line = (stackDetails && stackDetails[2]) || false,\n currentLocation = document.location.href.replace(document.location.hash, ''),\n pageSource,\n inlineScriptSourceRegExp,\n inlineScriptSource,\n scripts = document.getElementsByTagName('script'); // Live NodeList collection\n \n if (scriptLocation === currentLocation) {\n pageSource = document.documentElement.outerHTML;\n inlineScriptSourceRegExp = new RegExp('(?:[^\\\\n]+?\\\\n){0,' + (line - 2) + '}[^<]*\r\n\r\n","import mod from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"","/* globals __VUE_SSR_CONTEXT__ */\n\n// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).\n// This module is a runtime utility for cleaner component module output and will\n// be included in the final webpack user bundle.\n\nexport default function normalizeComponent (\n scriptExports,\n render,\n staticRenderFns,\n functionalTemplate,\n injectStyles,\n scopeId,\n moduleIdentifier, /* server only */\n shadowMode /* vue-cli only */\n) {\n // Vue.extend constructor export interop\n var options = typeof scriptExports === 'function'\n ? scriptExports.options\n : scriptExports\n\n // render functions\n if (render) {\n options.render = render\n options.staticRenderFns = staticRenderFns\n options._compiled = true\n }\n\n // functional template\n if (functionalTemplate) {\n options.functional = true\n }\n\n // scopedId\n if (scopeId) {\n options._scopeId = 'data-v-' + scopeId\n }\n\n var hook\n if (moduleIdentifier) { // server build\n hook = function (context) {\n // 2.3 injection\n context =\n context || // cached call\n (this.$vnode && this.$vnode.ssrContext) || // stateful\n (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional\n // 2.2 with runInNewContext: true\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__\n }\n // inject component styles\n if (injectStyles) {\n injectStyles.call(this, context)\n }\n // register component module identifier for async chunk inferrence\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier)\n }\n }\n // used by ssr in case component is cached and beforeCreate\n // never gets called\n options._ssrRegister = hook\n } else if (injectStyles) {\n hook = shadowMode\n ? function () {\n injectStyles.call(\n this,\n (options.functional ? this.parent : this).$root.$options.shadowRoot\n )\n }\n : injectStyles\n }\n\n if (hook) {\n if (options.functional) {\n // for template-only hot-reload because in that case the render fn doesn't\n // go through the normalizer\n options._injectStyles = hook\n // register for functional component in vue file\n var originalRender = options.render\n options.render = function renderWithStyleInjection (h, context) {\n hook.call(context)\n return originalRender(h, context)\n }\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate\n options.beforeCreate = existing\n ? [].concat(existing, hook)\n : [hook]\n }\n }\n\n return {\n exports: scriptExports,\n options: options\n }\n}\n","import { render, staticRenderFns } from \"./App.vue?vue&type=template&id=03ea1df8&scoped=true&\"\nimport script from \"./App.vue?vue&type=script&lang=js&\"\nexport * from \"./App.vue?vue&type=script&lang=js&\"\nimport style0 from \"./App.vue?vue&type=style&index=0&id=03ea1df8&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"03ea1df8\",\n null\n \n)\n\nexport default component.exports","import './setPublicPath'\nimport mod from '~entry'\nexport default mod\nexport * from '~entry'\n"],"sourceRoot":""} \ No newline at end of file +{"version":3,"sources":["webpack://plugin-webrtc/webpack/bootstrap","webpack://plugin-webrtc/./src/App.vue?250a","webpack://plugin-webrtc/./src/App.vue?8e13","webpack://plugin-webrtc/./node_modules/@soda/get-current-script/index.js","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js","webpack://plugin-webrtc/./src/App.vue?493d","webpack://plugin-webrtc/src/App.vue","webpack://plugin-webrtc/./src/App.vue?8b47","webpack://plugin-webrtc/./node_modules/vue-loader/lib/runtime/componentNormalizer.js","webpack://plugin-webrtc/./src/App.vue","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js"],"names":[],"mappings":";;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;;AClFA;AAAA;AAAA;AAAgc,CAAgB,ggBAAG,EAAC,C;;;;;;;ACApd,uC;;;;;;;ACAA;AACA;AACA;;AAEA;;AAEA;AACA,MAAM,IAA0C;AAChD,IAAI,iCAAO,EAAE,oCAAE,OAAO;AAAA;AAAA;AAAA,oGAAC;AACvB,GAAG,MAAM,EAIN;AACH,CAAC;AACD;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0DAA0D;;AAE1D;AACA;AACA,+DAA+D,qBAAqB;AACpF;AACA;;AAEA,qBAAqB,oBAAoB;AACzC;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,CAAC;;;;;;;;;;;;;ACvED;;AAEA;AACA;AACA,MAAM,IAAuC;AAC7C,2BAA2B,mBAAO,CAAC,MAA0B;AAC7D;;AAEA;AACA;AACA,wDAAwD,wBAAwB;AAChF;AACA;;AAEA;AACA;AACA,IAAI,qBAAuB;AAC3B;AACA;;AAEA;AACe,sDAAI;;;ACrBnB,0BAA0B,aAAa,0BAA0B,wBAAwB,sMAAsM,OAAO,qBAAqB,QAAQ,gDAAgD,mBAAmB,0BAA0B,wCAAwC,oBAAoB,kDAAkD,IAAI,yBAAyB,qCAAqC,qCAAqC,IAAI,yBAAyB,kCAAkC,mCAAmC,IAAI,yBAAyB,wCAAwC,oBAAoB,sDAAsD,WAAW,qCAAqC;AACt5B;;;;;;;;;;;;;;;;;;;;;;;;;ACkBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,EAAC;;;AC7IoK,CAAgB,+FAAG,EAAC,C;;;;;ACA1L;;AAEA;AACA;AACA;;AAEe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,yBAAyB;AACzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;;ACjG8F;AACvC;AACL;AACqC;;;AAGvF;AACuF;AACvF,gBAAgB,kBAAU;AAC1B,EAAE,+BAAM;AACR,EAAE,MAAM;AACR,EAAE,eAAe;AACjB;AACA;AACA;AACA;;AAEA;;AAEe,yD;;ACnBS;AACA;AACT,kFAAG;AACI","file":"plugin-webrtc.common.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"fb15\");\n","import mod from \"-!../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../node_modules/css-loader/dist/cjs.js??ref--6-oneOf-1-1!../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css&\"; export default mod; export * from \"-!../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../node_modules/css-loader/dist/cjs.js??ref--6-oneOf-1-1!../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css&\"","// extracted by mini-css-extract-plugin","// addapted from the document.currentScript polyfill by Adam Miller\n// MIT license\n// source: https://github.com/amiller-gh/currentScript-polyfill\n\n// added support for Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1620505\n\n(function (root, factory) {\n if (typeof define === 'function' && define.amd) {\n define([], factory);\n } else if (typeof module === 'object' && module.exports) {\n module.exports = factory();\n } else {\n root.getCurrentScript = factory();\n }\n}(typeof self !== 'undefined' ? self : this, function () {\n function getCurrentScript () {\n if (document.currentScript) {\n return document.currentScript\n }\n \n // IE 8-10 support script readyState\n // IE 11+ & Firefox support stack trace\n try {\n throw new Error();\n }\n catch (err) {\n // Find the second match for the \"at\" string to get file src url from stack.\n var ieStackRegExp = /.*at [^(]*\\((.*):(.+):(.+)\\)$/ig,\n ffStackRegExp = /@([^@]*):(\\d+):(\\d+)\\s*$/ig,\n stackDetails = ieStackRegExp.exec(err.stack) || ffStackRegExp.exec(err.stack),\n scriptLocation = (stackDetails && stackDetails[1]) || false,\n line = (stackDetails && stackDetails[2]) || false,\n currentLocation = document.location.href.replace(document.location.hash, ''),\n pageSource,\n inlineScriptSourceRegExp,\n inlineScriptSource,\n scripts = document.getElementsByTagName('script'); // Live NodeList collection\n \n if (scriptLocation === currentLocation) {\n pageSource = document.documentElement.outerHTML;\n inlineScriptSourceRegExp = new RegExp('(?:[^\\\\n]+?\\\\n){0,' + (line - 2) + '}[^<]*\r\n\r\n","import mod from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"","/* globals __VUE_SSR_CONTEXT__ */\n\n// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).\n// This module is a runtime utility for cleaner component module output and will\n// be included in the final webpack user bundle.\n\nexport default function normalizeComponent (\n scriptExports,\n render,\n staticRenderFns,\n functionalTemplate,\n injectStyles,\n scopeId,\n moduleIdentifier, /* server only */\n shadowMode /* vue-cli only */\n) {\n // Vue.extend constructor export interop\n var options = typeof scriptExports === 'function'\n ? scriptExports.options\n : scriptExports\n\n // render functions\n if (render) {\n options.render = render\n options.staticRenderFns = staticRenderFns\n options._compiled = true\n }\n\n // functional template\n if (functionalTemplate) {\n options.functional = true\n }\n\n // scopedId\n if (scopeId) {\n options._scopeId = 'data-v-' + scopeId\n }\n\n var hook\n if (moduleIdentifier) { // server build\n hook = function (context) {\n // 2.3 injection\n context =\n context || // cached call\n (this.$vnode && this.$vnode.ssrContext) || // stateful\n (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional\n // 2.2 with runInNewContext: true\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__\n }\n // inject component styles\n if (injectStyles) {\n injectStyles.call(this, context)\n }\n // register component module identifier for async chunk inferrence\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier)\n }\n }\n // used by ssr in case component is cached and beforeCreate\n // never gets called\n options._ssrRegister = hook\n } else if (injectStyles) {\n hook = shadowMode\n ? function () {\n injectStyles.call(\n this,\n (options.functional ? this.parent : this).$root.$options.shadowRoot\n )\n }\n : injectStyles\n }\n\n if (hook) {\n if (options.functional) {\n // for template-only hot-reload because in that case the render fn doesn't\n // go through the normalizer\n options._injectStyles = hook\n // register for functional component in vue file\n var originalRender = options.render\n options.render = function renderWithStyleInjection (h, context) {\n hook.call(context)\n return originalRender(h, context)\n }\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate\n options.beforeCreate = existing\n ? [].concat(existing, hook)\n : [hook]\n }\n }\n\n return {\n exports: scriptExports,\n options: options\n }\n}\n","import { render, staticRenderFns } from \"./App.vue?vue&type=template&id=09aaef78&scoped=true&\"\nimport script from \"./App.vue?vue&type=script&lang=js&\"\nexport * from \"./App.vue?vue&type=script&lang=js&\"\nimport style0 from \"./App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"09aaef78\",\n null\n \n)\n\nexport default component.exports","import './setPublicPath'\nimport mod from '~entry'\nexport default mod\nexport * from '~entry'\n"],"sourceRoot":""} \ No newline at end of file diff --git a/ui/dist/plugin-webrtc.css b/ui/dist/plugin-webrtc.css index 569bee6..180dae5 100644 --- a/ui/dist/plugin-webrtc.css +++ b/ui/dist/plugin-webrtc.css @@ -1 +1 @@ -@-webkit-keyframes blink-data-v-03ea1df8{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}@keyframes blink-data-v-03ea1df8{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}.blink[data-v-03ea1df8]{-webkit-animation:blink-data-v-03ea1df8 1s infinite;animation:blink-data-v-03ea1df8 1s infinite} \ No newline at end of file +@-webkit-keyframes blink-data-v-09aaef78{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}@keyframes blink-data-v-09aaef78{0%{opacity:.2}50%{opacity:1}to{opacity:.2}}.blink[data-v-09aaef78]{-webkit-animation:blink-data-v-09aaef78 1s infinite;animation:blink-data-v-09aaef78 1s infinite} \ No newline at end of file diff --git a/ui/dist/plugin-webrtc.umd.js b/ui/dist/plugin-webrtc.umd.js index 73034f6..ffa7051 100644 --- a/ui/dist/plugin-webrtc.umd.js +++ b/ui/dist/plugin-webrtc.umd.js @@ -96,6 +96,24 @@ return /******/ (function(modules) { // webpackBootstrap /************************************************************************/ /******/ ({ +/***/ "11a1": +/***/ (function(module, __webpack_exports__, __webpack_require__) { + +"use strict"; +/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_09aaef78_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("30b5"); +/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_09aaef78_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_09aaef78_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__); +/* unused harmony reexport * */ + /* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_09aaef78_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a); + +/***/ }), + +/***/ "30b5": +/***/ (function(module, exports, __webpack_require__) { + +// extracted by mini-css-extract-plugin + +/***/ }), + /***/ "8875": /***/ (function(module, exports, __webpack_require__) { @@ -172,24 +190,6 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_ })); -/***/ }), - -/***/ "8e55": -/***/ (function(module, exports, __webpack_require__) { - -// extracted by mini-css-extract-plugin - -/***/ }), - -/***/ "e91a": -/***/ (function(module, __webpack_exports__, __webpack_require__) { - -"use strict"; -/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_03ea1df8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("8e55"); -/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_03ea1df8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_03ea1df8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__); -/* unused harmony reexport * */ - /* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_App_vue_vue_type_style_index_0_id_03ea1df8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a); - /***/ }), /***/ "fb15": @@ -223,12 +223,12 @@ if (typeof window !== 'undefined') { // Indicate to webpack that this file can be concatenated /* harmony default export */ var setPublicPath = (null); -// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"7d106341-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/App.vue?vue&type=template&id=03ea1df8&scoped=true& +// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"7d106341-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/App.vue?vue&type=template&id=09aaef78&scoped=true& var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[(_vm.$parent.titleTabActive == 1)?_c('pre',[_vm._v(_vm._s(_vm.localSDP))]):(_vm.$parent.titleTabActive == 2)?_c('pre',[_vm._v(_vm._s(_vm.remoteSDP))]):_c('div',[_c('mu-text-field',{attrs:{"label":"streamPath"},model:{value:(_vm.streamPath),callback:function ($$v) {_vm.streamPath=$$v},expression:"streamPath"}}),(!_vm.localSDP || _vm.ask)?_c('span',{staticClass:"blink"},[_vm._v("Connecting")]):_vm._e(),[_c('m-button',{on:{"click":function($event){return _vm.startSession('publish')}}},[_vm._v("Publish")]),_c('m-button',{on:{"click":function($event){return _vm.startSession('play')}}},[_vm._v("Play")])],_c('m-button',{on:{"click":_vm.stopSession}},[_vm._v("Stop")]),_c('br'),_c('video',{ref:"video1",attrs:{"width":"640","height":"480","autoplay":"","muted":""},domProps:{"srcObject":_vm.stream,"muted":true}})],2)])} var staticRenderFns = [] -// CONCATENATED MODULE: ./src/App.vue?vue&type=template&id=03ea1df8&scoped=true& +// CONCATENATED MODULE: ./src/App.vue?vue&type=template&id=09aaef78&scoped=true& // CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/App.vue?vue&type=script&lang=js& // @@ -296,6 +296,33 @@ var streamPath = "live/rtc"; async startSession(type) { this.type = type; this.ask = true; + if (type == "play") { + const result = await this.ajax({ + url: "/webrtc/preparePlay?streamPath=" + this.streamPath, + dataType: "json" + }); + if (result.errmsg) { + this.$toast.error(result.errmsg); + return; + } else { + streamPath = this.streamPath; + this.remoteSDP = result.sdp; + } + pc.ontrack = event => { + console.log(event) + if (event.streams[0].id == "monibuca") + this.stream = stream = event.streams[0]; + }; + await pc.setRemoteDescription( + new RTCSessionDescription(result) + ); + await pc.setLocalDescription(await pc.createAnswer()); + this.localSDP = pc.localDescription.sdp; + } else { + pc.addStream(stream); + await pc.setLocalDescription(await pc.createOffer()); + this.localSDP = pc.localDescription.sdp; + } const result = await this.ajax({ type: "POST", processData: false, @@ -304,24 +331,17 @@ var streamPath = "live/rtc"; dataType: "json" }); this.ask = false; - if (result.errmsg) { - this.$toast.error(result.errmsg); + if (result!="success") { + this.$toast.error(result.errmsg||result); + return; } else { streamPath = this.streamPath; - this.remoteSDP = result.sdp; - this.$parent.titleTabs = ["摄像头", "localSDP", "remoteSDP"]; - pc.setRemoteDescription(new RTCSessionDescription(result)); } - if (type == "publish") { - pc.addStream(stream); - this.localSDP = ( - await pc.setLocalDescription(await pc.createOffer()) - ).sdp; + if (type == "play") { + } else { - pc.ontrack = event => { - if(event.streams[0].id=="monibuca") - this.stream = stream = event.streams[0]; - }; + this.remoteSDP = result.sdp; + pc.setRemoteDescription(new RTCSessionDescription(result)); } }, stopSession() { @@ -341,33 +361,23 @@ var streamPath = "live/rtc"; this.$toast.info(pc.iceConnectionState); this.iceConnectionState = pc.iceConnectionState; }; - pc.onicecandidate = event => { - if (event.candidate === null) { - this.$parent.titleTabs = ["摄像头", "localSDP"]; - } - }; - if (this.localSDP) { - let tabs = ["摄像头"]; - if (this.localSDP) tabs.push("localSDP"); - if (this.remoteSDP) tabs.push("remoteSDP"); - this.$parent.titleTabs = tabs; - } else { - try { - if (!this.stream) - this.stream = stream = await navigator.mediaDevices.getUserMedia( - { video: true, audio: true } - ); - } catch (err) { - this.$toast.error(err.message); - } + pc.onicecandidate = event => {}; + this.$parent.titleTabs = ["摄像头", "localSDP", "remoteSDP"]; + try { + if (!this.stream) + this.stream = stream = await navigator.mediaDevices.getUserMedia( + { video: true, audio: true } + ); + } catch (err) { + this.$toast.error(err.message); } } }); // CONCATENATED MODULE: ./src/App.vue?vue&type=script&lang=js& /* harmony default export */ var src_Appvue_type_script_lang_js_ = (Appvue_type_script_lang_js_); -// EXTERNAL MODULE: ./src/App.vue?vue&type=style&index=0&id=03ea1df8&scoped=true&lang=css& -var Appvue_type_style_index_0_id_03ea1df8_scoped_true_lang_css_ = __webpack_require__("e91a"); +// EXTERNAL MODULE: ./src/App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css& +var Appvue_type_style_index_0_id_09aaef78_scoped_true_lang_css_ = __webpack_require__("11a1"); // CONCATENATED MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js /* globals __VUE_SSR_CONTEXT__ */ @@ -484,7 +494,7 @@ var component = normalizeComponent( staticRenderFns, false, null, - "03ea1df8", + "09aaef78", null ) diff --git a/ui/dist/plugin-webrtc.umd.js.map b/ui/dist/plugin-webrtc.umd.js.map index dcb5d7c..ce3d425 100644 --- a/ui/dist/plugin-webrtc.umd.js.map +++ b/ui/dist/plugin-webrtc.umd.js.map @@ -1 +1 @@ -{"version":3,"sources":["webpack://plugin-webrtc/webpack/universalModuleDefinition","webpack://plugin-webrtc/webpack/bootstrap","webpack://plugin-webrtc/./node_modules/@soda/get-current-script/index.js","webpack://plugin-webrtc/./src/App.vue?8531","webpack://plugin-webrtc/./src/App.vue?b994","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js","webpack://plugin-webrtc/./src/App.vue?8171","webpack://plugin-webrtc/src/App.vue","webpack://plugin-webrtc/./src/App.vue?8b47","webpack://plugin-webrtc/./node_modules/vue-loader/lib/runtime/componentNormalizer.js","webpack://plugin-webrtc/./src/App.vue","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,O;QCVA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;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AkD,IAAI,yBAAyB,qCAAqC,qCAAqC,IAAI,yBAAyB,kCAAkC,mCAAmC,IAAI,yBAAyB,wCAAwC,oBAAoB,sDAAsD,WAAW,qCAAqC;AACt5B;;;;;;;;;;;;;;;;;;;;;;;;;ACkBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,EAAC;;;ACnIoK,CAAgB,+FAAG,EAAC,C;;;;;ACA1L;;AAEA;AACA;AACA;;AAEe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,yBAAyB;AACzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;;ACjG8F;AACvC;AACL;AACqC;;;AAGvF;AACuF;AACvF,gBAAgB,kBAAU;AAC1B,EAAE,+BAAM;AACR,EAAE,MAAM;AACR,EAAE,eAAe;AACjB;AACA;AACA;AACA;;AAEA;;AAEe,yD;;ACnBS;AACA;AACT,kFAAG;AACI","file":"plugin-webrtc.umd.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"plugin-webrtc\"] = factory();\n\telse\n\t\troot[\"plugin-webrtc\"] = factory();\n})((typeof self !== 'undefined' ? self : this), function() {\nreturn "," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"fb15\");\n","// addapted from the document.currentScript polyfill by Adam Miller\n// MIT license\n// source: https://github.com/amiller-gh/currentScript-polyfill\n\n// added support for Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1620505\n\n(function (root, factory) {\n if (typeof define === 'function' && define.amd) {\n define([], factory);\n } else if (typeof module === 'object' && module.exports) {\n module.exports = factory();\n } else {\n root.getCurrentScript = factory();\n }\n}(typeof self !== 'undefined' ? self : this, function () {\n function getCurrentScript () {\n if (document.currentScript) {\n return document.currentScript\n }\n \n // IE 8-10 support script readyState\n // IE 11+ & Firefox support stack trace\n try {\n throw new Error();\n }\n catch (err) {\n // Find the second match for the \"at\" string to get file src url from stack.\n var ieStackRegExp = /.*at [^(]*\\((.*):(.+):(.+)\\)$/ig,\n ffStackRegExp = /@([^@]*):(\\d+):(\\d+)\\s*$/ig,\n stackDetails = ieStackRegExp.exec(err.stack) || ffStackRegExp.exec(err.stack),\n scriptLocation = (stackDetails && stackDetails[1]) || false,\n line = (stackDetails && stackDetails[2]) || false,\n currentLocation = document.location.href.replace(document.location.hash, ''),\n pageSource,\n inlineScriptSourceRegExp,\n inlineScriptSource,\n scripts = document.getElementsByTagName('script'); // Live NodeList collection\n \n if (scriptLocation === currentLocation) {\n pageSource = document.documentElement.outerHTML;\n inlineScriptSourceRegExp = new RegExp('(?:[^\\\\n]+?\\\\n){0,' + (line - 2) + '}[^<]*\r\n\r\n","import mod from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"","/* globals __VUE_SSR_CONTEXT__ */\n\n// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).\n// This module is a runtime utility for cleaner component module output and will\n// be included in the final webpack user bundle.\n\nexport default function normalizeComponent (\n scriptExports,\n render,\n staticRenderFns,\n functionalTemplate,\n injectStyles,\n scopeId,\n moduleIdentifier, /* server only */\n shadowMode /* vue-cli only */\n) {\n // Vue.extend constructor export interop\n var options = typeof scriptExports === 'function'\n ? scriptExports.options\n : scriptExports\n\n // render functions\n if (render) {\n options.render = render\n options.staticRenderFns = staticRenderFns\n options._compiled = true\n }\n\n // functional template\n if (functionalTemplate) {\n options.functional = true\n }\n\n // scopedId\n if (scopeId) {\n options._scopeId = 'data-v-' + scopeId\n }\n\n var hook\n if (moduleIdentifier) { // server build\n hook = function (context) {\n // 2.3 injection\n context =\n context || // cached call\n (this.$vnode && this.$vnode.ssrContext) || // stateful\n (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional\n // 2.2 with runInNewContext: true\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__\n }\n // inject component styles\n if (injectStyles) {\n injectStyles.call(this, context)\n }\n // register component module identifier for async chunk inferrence\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier)\n }\n }\n // used by ssr in case component is cached and beforeCreate\n // never gets called\n options._ssrRegister = hook\n } else if (injectStyles) {\n hook = shadowMode\n ? function () {\n injectStyles.call(\n this,\n (options.functional ? this.parent : this).$root.$options.shadowRoot\n )\n }\n : injectStyles\n }\n\n if (hook) {\n if (options.functional) {\n // for template-only hot-reload because in that case the render fn doesn't\n // go through the normalizer\n options._injectStyles = hook\n // register for functional component in vue file\n var originalRender = options.render\n options.render = function renderWithStyleInjection (h, context) {\n hook.call(context)\n return originalRender(h, context)\n }\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate\n options.beforeCreate = existing\n ? [].concat(existing, hook)\n : [hook]\n }\n }\n\n return {\n exports: scriptExports,\n options: options\n }\n}\n","import { render, staticRenderFns } from \"./App.vue?vue&type=template&id=03ea1df8&scoped=true&\"\nimport script from \"./App.vue?vue&type=script&lang=js&\"\nexport * from \"./App.vue?vue&type=script&lang=js&\"\nimport style0 from \"./App.vue?vue&type=style&index=0&id=03ea1df8&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"03ea1df8\",\n null\n \n)\n\nexport default component.exports","import './setPublicPath'\nimport mod from '~entry'\nexport default mod\nexport * from '~entry'\n"],"sourceRoot":""} \ No newline at end of file +{"version":3,"sources":["webpack://plugin-webrtc/webpack/universalModuleDefinition","webpack://plugin-webrtc/webpack/bootstrap","webpack://plugin-webrtc/./src/App.vue?250a","webpack://plugin-webrtc/./src/App.vue?8e13","webpack://plugin-webrtc/./node_modules/@soda/get-current-script/index.js","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js","webpack://plugin-webrtc/./src/App.vue?493d","webpack://plugin-webrtc/src/App.vue","webpack://plugin-webrtc/./src/App.vue?8b47","webpack://plugin-webrtc/./node_modules/vue-loader/lib/runtime/componentNormalizer.js","webpack://plugin-webrtc/./src/App.vue","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD,O;QCVA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;;AClFA;AAAA;AAAA;AAAgc,CAAgB,ggBAAG,EAAC,C;;;;;;;ACApd,uC;;;;;;;ACAA;AACA;AACA;;AAEA;;AAEA;AACA,MAAM,IAA0C;AAChD,IAAI,iCAAO,EAAE,oCAAE,OAAO;AAAA;AAAA;AAAA,oGAAC;AACvB,GAAG,MAAM,EAIN;AACH,CAAC;AACD;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0DAA0D;;AAE1D;AACA;AACA,+DAA+D,qBAAqB;AACpF;AACA;;AAEA,qBAAqB,oBAAoB;AACzC;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,CAAC;;;;;;;;;;;;;ACvED;;AAEA;AACA;AACA,MAAM,IAAuC;AAC7C,2BAA2B,mBAAO,CAAC,MAA0B;AAC7D;;AAEA;AACA;AACA,wDAAwD,wBAAwB;AAChF;AACA;;AAEA;AACA;AACA,IAAI,qBAAuB;AAC3B;AACA;;AAEA;AACe,sDAAI;;;ACrBnB,0BAA0B,aAAa,0BAA0B,wBAAwB,sMAAsM,OAAO,qBAAqB,QAAQ,gDAAgD,mBAAmB,0BAA0B,wCAAwC,oBAAoB,kDAAkD,IAAI,yBAAyB,qCAAqC,qCAAqC,IAAI,yBAAyB,kCAAkC,mCAAmC,IAAI,yBAAyB,wCAAwC,oBAAoB,sDAAsD,WAAW,qCAAqC;AACt5B;;;;;;;;;;;;;;;;;;;;;;;;;ACkBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,EAAC;;;AC7IoK,CAAgB,+FAAG,EAAC,C;;;;;ACA1L;;AAEA;AACA;AACA;;AAEe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA,yBAAyB;AACzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;;ACjG8F;AACvC;AACL;AACqC;;;AAGvF;AACuF;AACvF,gBAAgB,kBAAU;AAC1B,EAAE,+BAAM;AACR,EAAE,MAAM;AACR,EAAE,eAAe;AACjB;AACA;AACA;AACA;;AAEA;;AAEe,yD;;ACnBS;AACA;AACT,kFAAG;AACI","file":"plugin-webrtc.umd.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"plugin-webrtc\"] = factory();\n\telse\n\t\troot[\"plugin-webrtc\"] = factory();\n})((typeof self !== 'undefined' ? self : this), function() {\nreturn "," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"fb15\");\n","import mod from \"-!../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../node_modules/css-loader/dist/cjs.js??ref--6-oneOf-1-1!../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css&\"; export default mod; export * from \"-!../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../node_modules/css-loader/dist/cjs.js??ref--6-oneOf-1-1!../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css&\"","// extracted by mini-css-extract-plugin","// addapted from the document.currentScript polyfill by Adam Miller\n// MIT license\n// source: https://github.com/amiller-gh/currentScript-polyfill\n\n// added support for Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1620505\n\n(function (root, factory) {\n if (typeof define === 'function' && define.amd) {\n define([], factory);\n } else if (typeof module === 'object' && module.exports) {\n module.exports = factory();\n } else {\n root.getCurrentScript = factory();\n }\n}(typeof self !== 'undefined' ? self : this, function () {\n function getCurrentScript () {\n if (document.currentScript) {\n return document.currentScript\n }\n \n // IE 8-10 support script readyState\n // IE 11+ & Firefox support stack trace\n try {\n throw new Error();\n }\n catch (err) {\n // Find the second match for the \"at\" string to get file src url from stack.\n var ieStackRegExp = /.*at [^(]*\\((.*):(.+):(.+)\\)$/ig,\n ffStackRegExp = /@([^@]*):(\\d+):(\\d+)\\s*$/ig,\n stackDetails = ieStackRegExp.exec(err.stack) || ffStackRegExp.exec(err.stack),\n scriptLocation = (stackDetails && stackDetails[1]) || false,\n line = (stackDetails && stackDetails[2]) || false,\n currentLocation = document.location.href.replace(document.location.hash, ''),\n pageSource,\n inlineScriptSourceRegExp,\n inlineScriptSource,\n scripts = document.getElementsByTagName('script'); // Live NodeList collection\n \n if (scriptLocation === currentLocation) {\n pageSource = document.documentElement.outerHTML;\n inlineScriptSourceRegExp = new RegExp('(?:[^\\\\n]+?\\\\n){0,' + (line - 2) + '}[^<]*\r\n\r\n","import mod from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"","/* globals __VUE_SSR_CONTEXT__ */\n\n// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).\n// This module is a runtime utility for cleaner component module output and will\n// be included in the final webpack user bundle.\n\nexport default function normalizeComponent (\n scriptExports,\n render,\n staticRenderFns,\n functionalTemplate,\n injectStyles,\n scopeId,\n moduleIdentifier, /* server only */\n shadowMode /* vue-cli only */\n) {\n // Vue.extend constructor export interop\n var options = typeof scriptExports === 'function'\n ? scriptExports.options\n : scriptExports\n\n // render functions\n if (render) {\n options.render = render\n options.staticRenderFns = staticRenderFns\n options._compiled = true\n }\n\n // functional template\n if (functionalTemplate) {\n options.functional = true\n }\n\n // scopedId\n if (scopeId) {\n options._scopeId = 'data-v-' + scopeId\n }\n\n var hook\n if (moduleIdentifier) { // server build\n hook = function (context) {\n // 2.3 injection\n context =\n context || // cached call\n (this.$vnode && this.$vnode.ssrContext) || // stateful\n (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional\n // 2.2 with runInNewContext: true\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__\n }\n // inject component styles\n if (injectStyles) {\n injectStyles.call(this, context)\n }\n // register component module identifier for async chunk inferrence\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier)\n }\n }\n // used by ssr in case component is cached and beforeCreate\n // never gets called\n options._ssrRegister = hook\n } else if (injectStyles) {\n hook = shadowMode\n ? function () {\n injectStyles.call(\n this,\n (options.functional ? this.parent : this).$root.$options.shadowRoot\n )\n }\n : injectStyles\n }\n\n if (hook) {\n if (options.functional) {\n // for template-only hot-reload because in that case the render fn doesn't\n // go through the normalizer\n options._injectStyles = hook\n // register for functional component in vue file\n var originalRender = options.render\n options.render = function renderWithStyleInjection (h, context) {\n hook.call(context)\n return originalRender(h, context)\n }\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate\n options.beforeCreate = existing\n ? [].concat(existing, hook)\n : [hook]\n }\n }\n\n return {\n exports: scriptExports,\n options: options\n }\n}\n","import { render, staticRenderFns } from \"./App.vue?vue&type=template&id=09aaef78&scoped=true&\"\nimport script from \"./App.vue?vue&type=script&lang=js&\"\nexport * from \"./App.vue?vue&type=script&lang=js&\"\nimport style0 from \"./App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"09aaef78\",\n null\n \n)\n\nexport default component.exports","import './setPublicPath'\nimport mod from '~entry'\nexport default mod\nexport * from '~entry'\n"],"sourceRoot":""} \ No newline at end of file diff --git a/ui/dist/plugin-webrtc.umd.min.js b/ui/dist/plugin-webrtc.umd.min.js index ca245ca..25930c3 100644 --- a/ui/dist/plugin-webrtc.umd.min.js +++ b/ui/dist/plugin-webrtc.umd.min.js @@ -1,2 +1,2 @@ -(function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e():"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["plugin-webrtc"]=e():t["plugin-webrtc"]=e()})("undefined"!==typeof self?self:this,(function(){return function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t["default"]}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s="fb15")}({8875:function(t,e,n){var r,o,i;(function(n,a){o=[],r=a,i="function"===typeof r?r.apply(e,o):r,void 0===i||(t.exports=i)})("undefined"!==typeof self&&self,(function(){function t(){if(document.currentScript)return document.currentScript;try{throw new Error}catch(d){var t,e,n,r=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,o=/@([^@]*):(\d+):(\d+)\s*$/gi,i=r.exec(d.stack)||o.exec(d.stack),a=i&&i[1]||!1,s=i&&i[2]||!1,c=document.location.href.replace(document.location.hash,""),l=document.getElementsByTagName("script");a===c&&(t=document.documentElement.outerHTML,e=new RegExp("(?:[^\\n]+?\\n){0,"+(s-2)+"}[^<]*\r\n\r\n","import mod from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"","/* globals __VUE_SSR_CONTEXT__ */\n\n// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).\n// This module is a runtime utility for cleaner component module output and will\n// be included in the final webpack user bundle.\n\nexport default function normalizeComponent (\n scriptExports,\n render,\n staticRenderFns,\n functionalTemplate,\n injectStyles,\n scopeId,\n moduleIdentifier, /* server only */\n shadowMode /* vue-cli only */\n) {\n // Vue.extend constructor export interop\n var options = typeof scriptExports === 'function'\n ? scriptExports.options\n : scriptExports\n\n // render functions\n if (render) {\n options.render = render\n options.staticRenderFns = staticRenderFns\n options._compiled = true\n }\n\n // functional template\n if (functionalTemplate) {\n options.functional = true\n }\n\n // scopedId\n if (scopeId) {\n options._scopeId = 'data-v-' + scopeId\n }\n\n var hook\n if (moduleIdentifier) { // server build\n hook = function (context) {\n // 2.3 injection\n context =\n context || // cached call\n (this.$vnode && this.$vnode.ssrContext) || // stateful\n (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional\n // 2.2 with runInNewContext: true\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__\n }\n // inject component styles\n if (injectStyles) {\n injectStyles.call(this, context)\n }\n // register component module identifier for async chunk inferrence\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier)\n }\n }\n // used by ssr in case component is cached and beforeCreate\n // never gets called\n options._ssrRegister = hook\n } else if (injectStyles) {\n hook = shadowMode\n ? function () {\n injectStyles.call(\n this,\n (options.functional ? this.parent : this).$root.$options.shadowRoot\n )\n }\n : injectStyles\n }\n\n if (hook) {\n if (options.functional) {\n // for template-only hot-reload because in that case the render fn doesn't\n // go through the normalizer\n options._injectStyles = hook\n // register for functional component in vue file\n var originalRender = options.render\n options.render = function renderWithStyleInjection (h, context) {\n hook.call(context)\n return originalRender(h, context)\n }\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate\n options.beforeCreate = existing\n ? [].concat(existing, hook)\n : [hook]\n }\n }\n\n return {\n exports: scriptExports,\n options: options\n }\n}\n","import { render, staticRenderFns } from \"./App.vue?vue&type=template&id=03ea1df8&scoped=true&\"\nimport script from \"./App.vue?vue&type=script&lang=js&\"\nexport * from \"./App.vue?vue&type=script&lang=js&\"\nimport style0 from \"./App.vue?vue&type=style&index=0&id=03ea1df8&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"03ea1df8\",\n null\n \n)\n\nexport default component.exports","import './setPublicPath'\nimport mod from '~entry'\nexport default mod\nexport * from '~entry'\n"],"sourceRoot":""} \ No newline at end of file +{"version":3,"sources":["webpack://plugin-webrtc/webpack/universalModuleDefinition","webpack://plugin-webrtc/webpack/bootstrap","webpack://plugin-webrtc/./src/App.vue?250a","webpack://plugin-webrtc/./node_modules/@soda/get-current-script/index.js","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/setPublicPath.js","webpack://plugin-webrtc/./src/App.vue?493d","webpack://plugin-webrtc/src/App.vue","webpack://plugin-webrtc/./src/App.vue?8b47","webpack://plugin-webrtc/./node_modules/vue-loader/lib/runtime/componentNormalizer.js","webpack://plugin-webrtc/./src/App.vue","webpack://plugin-webrtc/./node_modules/@vue/cli-service/lib/commands/build/entry-lib.js"],"names":["root","factory","exports","module","define","amd","self","this","installedModules","__webpack_require__","moduleId","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","prototype","hasOwnProperty","p","s","getCurrentScript","document","currentScript","Error","err","pageSource","inlineScriptSourceRegExp","inlineScriptSource","ieStackRegExp","ffStackRegExp","stackDetails","exec","stack","scriptLocation","line","currentLocation","location","href","replace","hash","scripts","getElementsByTagName","documentElement","outerHTML","RegExp","trim","length","readyState","src","innerHTML","window","match","render","_vm","_h","$createElement","_c","_self","$parent","titleTabActive","_v","_s","localSDP","remoteSDP","attrs","model","callback","$$v","streamPath","expression","ask","staticClass","_e","on","$event","startSession","stopSession","ref","domProps","stream","staticRenderFns","config","iceServers","pc","RTCPeerConnection","localDescription","sdp","remoteDescription","iceConnectionState","type","methods","result","ajax","url","dataType","errmsg","$toast","error","ontrack","event","console","log","streams","id","setRemoteDescription","RTCSessionDescription","setLocalDescription","createAnswer","addStream","createOffer","processData","data","JSON","stringify","close","onsignalingstatechange","e","oniceconnectionstatechange","info","onicecandidate","titleTabs","navigator","mediaDevices","getUserMedia","video","audio","message","normalizeComponent","scriptExports","functionalTemplate","injectStyles","scopeId","moduleIdentifier","shadowMode","hook","options","_compiled","functional","_scopeId","context","$vnode","ssrContext","parent","__VUE_SSR_CONTEXT__","_registeredComponents","add","_ssrRegister","$root","$options","shadowRoot","_injectStyles","originalRender","h","existing","beforeCreate","concat","component"],"mappings":"CAAA,SAA2CA,EAAMC,GAC1B,kBAAZC,SAA0C,kBAAXC,OACxCA,OAAOD,QAAUD,IACQ,oBAAXG,QAAyBA,OAAOC,IAC9CD,OAAO,GAAIH,GACe,kBAAZC,QACdA,QAAQ,iBAAmBD,IAE3BD,EAAK,iBAAmBC,KAR1B,CASoB,qBAATK,KAAuBA,KAAOC,MAAO,WAChD,O,YCTE,IAAIC,EAAmB,GAGvB,SAASC,EAAoBC,GAG5B,GAAGF,EAAiBE,GACnB,OAAOF,EAAiBE,GAAUR,QAGnC,IAAIC,EAASK,EAAiBE,GAAY,CACzCC,EAAGD,EACHE,GAAG,EACHV,QAAS,IAUV,OANAW,EAAQH,GAAUI,KAAKX,EAAOD,QAASC,EAAQA,EAAOD,QAASO,GAG/DN,EAAOS,GAAI,EAGJT,EAAOD,QA0Df,OArDAO,EAAoBM,EAAIF,EAGxBJ,EAAoBO,EAAIR,EAGxBC,EAAoBQ,EAAI,SAASf,EAASgB,EAAMC,GAC3CV,EAAoBW,EAAElB,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EAAUnB,GACpB,CAACA,GAIT,MAAO,CACL3J,QAASqJ,EACTO,QAASA,GCvFb,IAAIqB,EAAY,EACd,EACAxG,EACA4B,GACA,EACA,KACA,WACA,MAIa,EAAA4E,E,QCjBA,kB","file":"plugin-webrtc.umd.min.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory();\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine([], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"plugin-webrtc\"] = factory();\n\telse\n\t\troot[\"plugin-webrtc\"] = factory();\n})((typeof self !== 'undefined' ? self : this), function() {\nreturn "," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"fb15\");\n","import mod from \"-!../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../node_modules/css-loader/dist/cjs.js??ref--6-oneOf-1-1!../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css&\"; export default mod; export * from \"-!../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../node_modules/css-loader/dist/cjs.js??ref--6-oneOf-1-1!../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css&\"","// addapted from the document.currentScript polyfill by Adam Miller\n// MIT license\n// source: https://github.com/amiller-gh/currentScript-polyfill\n\n// added support for Firefox https://bugzilla.mozilla.org/show_bug.cgi?id=1620505\n\n(function (root, factory) {\n if (typeof define === 'function' && define.amd) {\n define([], factory);\n } else if (typeof module === 'object' && module.exports) {\n module.exports = factory();\n } else {\n root.getCurrentScript = factory();\n }\n}(typeof self !== 'undefined' ? self : this, function () {\n function getCurrentScript () {\n if (document.currentScript) {\n return document.currentScript\n }\n \n // IE 8-10 support script readyState\n // IE 11+ & Firefox support stack trace\n try {\n throw new Error();\n }\n catch (err) {\n // Find the second match for the \"at\" string to get file src url from stack.\n var ieStackRegExp = /.*at [^(]*\\((.*):(.+):(.+)\\)$/ig,\n ffStackRegExp = /@([^@]*):(\\d+):(\\d+)\\s*$/ig,\n stackDetails = ieStackRegExp.exec(err.stack) || ffStackRegExp.exec(err.stack),\n scriptLocation = (stackDetails && stackDetails[1]) || false,\n line = (stackDetails && stackDetails[2]) || false,\n currentLocation = document.location.href.replace(document.location.hash, ''),\n pageSource,\n inlineScriptSourceRegExp,\n inlineScriptSource,\n scripts = document.getElementsByTagName('script'); // Live NodeList collection\n \n if (scriptLocation === currentLocation) {\n pageSource = document.documentElement.outerHTML;\n inlineScriptSourceRegExp = new RegExp('(?:[^\\\\n]+?\\\\n){0,' + (line - 2) + '}[^<]*\r\n\r\n","import mod from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../node_modules/cache-loader/dist/cjs.js??ref--0-0!../node_modules/vue-loader/lib/index.js??vue-loader-options!./App.vue?vue&type=script&lang=js&\"","/* globals __VUE_SSR_CONTEXT__ */\n\n// IMPORTANT: Do NOT use ES2015 features in this file (except for modules).\n// This module is a runtime utility for cleaner component module output and will\n// be included in the final webpack user bundle.\n\nexport default function normalizeComponent (\n scriptExports,\n render,\n staticRenderFns,\n functionalTemplate,\n injectStyles,\n scopeId,\n moduleIdentifier, /* server only */\n shadowMode /* vue-cli only */\n) {\n // Vue.extend constructor export interop\n var options = typeof scriptExports === 'function'\n ? scriptExports.options\n : scriptExports\n\n // render functions\n if (render) {\n options.render = render\n options.staticRenderFns = staticRenderFns\n options._compiled = true\n }\n\n // functional template\n if (functionalTemplate) {\n options.functional = true\n }\n\n // scopedId\n if (scopeId) {\n options._scopeId = 'data-v-' + scopeId\n }\n\n var hook\n if (moduleIdentifier) { // server build\n hook = function (context) {\n // 2.3 injection\n context =\n context || // cached call\n (this.$vnode && this.$vnode.ssrContext) || // stateful\n (this.parent && this.parent.$vnode && this.parent.$vnode.ssrContext) // functional\n // 2.2 with runInNewContext: true\n if (!context && typeof __VUE_SSR_CONTEXT__ !== 'undefined') {\n context = __VUE_SSR_CONTEXT__\n }\n // inject component styles\n if (injectStyles) {\n injectStyles.call(this, context)\n }\n // register component module identifier for async chunk inferrence\n if (context && context._registeredComponents) {\n context._registeredComponents.add(moduleIdentifier)\n }\n }\n // used by ssr in case component is cached and beforeCreate\n // never gets called\n options._ssrRegister = hook\n } else if (injectStyles) {\n hook = shadowMode\n ? function () {\n injectStyles.call(\n this,\n (options.functional ? this.parent : this).$root.$options.shadowRoot\n )\n }\n : injectStyles\n }\n\n if (hook) {\n if (options.functional) {\n // for template-only hot-reload because in that case the render fn doesn't\n // go through the normalizer\n options._injectStyles = hook\n // register for functional component in vue file\n var originalRender = options.render\n options.render = function renderWithStyleInjection (h, context) {\n hook.call(context)\n return originalRender(h, context)\n }\n } else {\n // inject component registration as beforeCreate hook\n var existing = options.beforeCreate\n options.beforeCreate = existing\n ? [].concat(existing, hook)\n : [hook]\n }\n }\n\n return {\n exports: scriptExports,\n options: options\n }\n}\n","import { render, staticRenderFns } from \"./App.vue?vue&type=template&id=09aaef78&scoped=true&\"\nimport script from \"./App.vue?vue&type=script&lang=js&\"\nexport * from \"./App.vue?vue&type=script&lang=js&\"\nimport style0 from \"./App.vue?vue&type=style&index=0&id=09aaef78&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"09aaef78\",\n null\n \n)\n\nexport default component.exports","import './setPublicPath'\nimport mod from '~entry'\nexport default mod\nexport * from '~entry'\n"],"sourceRoot":""} \ No newline at end of file diff --git a/ui/src/App.vue b/ui/src/App.vue index 0f4715e..ed104aa 100644 --- a/ui/src/App.vue +++ b/ui/src/App.vue @@ -63,6 +63,33 @@ export default { async startSession(type) { this.type = type; this.ask = true; + if (type == "play") { + const result = await this.ajax({ + url: "/webrtc/preparePlay?streamPath=" + this.streamPath, + dataType: "json" + }); + if (result.errmsg) { + this.$toast.error(result.errmsg); + return; + } else { + streamPath = this.streamPath; + this.remoteSDP = result.sdp; + } + pc.ontrack = event => { + console.log(event) + if (event.streams[0].id == "monibuca") + this.stream = stream = event.streams[0]; + }; + await pc.setRemoteDescription( + new RTCSessionDescription(result) + ); + await pc.setLocalDescription(await pc.createAnswer()); + this.localSDP = pc.localDescription.sdp; + } else { + pc.addStream(stream); + await pc.setLocalDescription(await pc.createOffer()); + this.localSDP = pc.localDescription.sdp; + } const result = await this.ajax({ type: "POST", processData: false, @@ -71,24 +98,17 @@ export default { dataType: "json" }); this.ask = false; - if (result.errmsg) { - this.$toast.error(result.errmsg); + if (result!="success") { + this.$toast.error(result.errmsg||result); + return; } else { streamPath = this.streamPath; - this.remoteSDP = result.sdp; - this.$parent.titleTabs = ["摄像头", "localSDP", "remoteSDP"]; - pc.setRemoteDescription(new RTCSessionDescription(result)); } - if (type == "publish") { - pc.addStream(stream); - this.localSDP = ( - await pc.setLocalDescription(await pc.createOffer()) - ).sdp; + if (type == "play") { + } else { - pc.ontrack = event => { - if(event.streams[0].id=="monibuca") - this.stream = stream = event.streams[0]; - }; + this.remoteSDP = result.sdp; + pc.setRemoteDescription(new RTCSessionDescription(result)); } }, stopSession() { @@ -108,25 +128,15 @@ export default { this.$toast.info(pc.iceConnectionState); this.iceConnectionState = pc.iceConnectionState; }; - pc.onicecandidate = event => { - if (event.candidate === null) { - this.$parent.titleTabs = ["摄像头", "localSDP"]; - } - }; - if (this.localSDP) { - let tabs = ["摄像头"]; - if (this.localSDP) tabs.push("localSDP"); - if (this.remoteSDP) tabs.push("remoteSDP"); - this.$parent.titleTabs = tabs; - } else { - try { - if (!this.stream) - this.stream = stream = await navigator.mediaDevices.getUserMedia( - { video: true, audio: true } - ); - } catch (err) { - this.$toast.error(err.message); - } + pc.onicecandidate = event => {}; + this.$parent.titleTabs = ["摄像头", "localSDP", "remoteSDP"]; + try { + if (!this.stream) + this.stream = stream = await navigator.mediaDevices.getUserMedia( + { video: true, audio: true } + ); + } catch (err) { + this.$toast.error(err.message); } } };