|
76 | 76 | <SettingInput v-if="storage_cifs && config.STORAGE_CIFS_REMOVE === 'on'" title="保存日数" :titleOffset="2" :span="3" tooltip="指定日数後に削除します" type="number" v-model="config.STORAGE_CIFS_REMOVE_DAYS" :min="1" />
|
77 | 77 |
|
78 | 78 | <h3>ストリーミング</h3>
|
79 |
| - <SettingSwitch title="RTSP" tooltip="RTSPサーバーを起動します" v-model="config.RTSPSERVER" /> |
80 |
| - <SettingSwitch v-if="config.RTSPSERVER === 'on'" title="音声" :titleOffset="2" tooltip="RTSPの音声を設定します" v-model="config.RTSP_AUDIO" /> |
81 |
| - <SettingSwitch v-if="config.RTSPSERVER === 'on'" title="RTSP over HTTP" :titleOffset="2" tooltip="RTSPをHTTP経由で配信します" v-model="config.RTSP_OVER_HTTP" /> |
82 |
| - <SettingInput v-if="config.RTSPSERVER === 'on'" title="RTSP URL" :titleOffset="2" :span="10" tooltip="VLC playerなどにURLをcopy&pasteしてください" type="readonly" v-model="RtspUrl" :min="1" /> |
| 79 | + <SettingSwitch title="RTSP Main" tooltip="RTSP Main(1080p AVC)を開始します" v-model="config.RTSP_VIDEO0" /> |
| 80 | + <SettingSwitch v-if="config.RTSP_VIDEO0 === 'on'" title="音声" :titleOffset="2" tooltip="RTSP Mainの音声を設定します" v-model="config.RTSP_AUDIO0" /> |
| 81 | + <SettingInput v-if="config.RTSP_VIDEO0 === 'on'" title="URL" :titleOffset="2" :span="10" tooltip="VLC playerなどにURLをcopy&pasteしてください" type="readonly" v-model="RtspUrl0" :min="1" /> |
| 82 | + <SettingSwitch title="RTSP Sub" tooltip="RTSP Sub(360p HEVC)を開始します" v-model="config.RTSP_VIDEO1" /> |
| 83 | + <SettingSwitch v-if="config.RTSP_VIDEO1 === 'on'" title="音声" :titleOffset="2" tooltip="RTSP Subの音声を設定します" v-model="config.RTSP_AUDIO1" /> |
| 84 | + <SettingInput v-if="config.RTSP_VIDEO1 === 'on'" title="URL" :titleOffset="2" :span="10" tooltip="VLC playerなどにURLをcopy&pasteしてください" type="readonly" v-model="RtspUrl1" :min="1" /> |
| 85 | + <SettingSwitch v-if="(config.RTSP_VIDEO0 === 'on') || (config.RTSP_VIDEO1 === 'on')" title="RTSP over HTTP" :titleOffset="2" tooltip="RTSPをHTTP経由で配信します" v-model="config.RTSP_OVER_HTTP" /> |
83 | 86 |
|
84 | 87 | <h3>イベント通知</h3>
|
85 | 88 | <SettingSwitch title="WebHook" tooltip="WebHookを設定します" v-model="config.WEBHOOK" />
|
|
179 | 182 | REBOOT_SCHEDULE: '0 2 * * 7', // -> /var/spool/crontabs/root
|
180 | 183 | RECORDING_LOCAL_SCHEDULE: 'off',
|
181 | 184 | RECORDING_LOCAL_SCHEDULE_LIST: '', // -> /media/mmc/local_schedule
|
182 |
| - RTSPSERVER: 'off', |
| 185 | + RTSP_VIDEO0: 'off', |
| 186 | + RTSP_AUDIO0: 'off', |
| 187 | + RTSP_VIDEO1: 'off', |
| 188 | + RTSP_AUDIO1: 'off', |
183 | 189 | RTSP_OVER_HTTP: 'off',
|
184 |
| - RTSP_AUDIO: 'off', |
185 | 190 | STORAGE_SDCARD: 'on', // on(alarm & record), alarm, record, off
|
186 | 191 | STORAGE_SDCARD_PUBLISH: 'off',
|
187 | 192 | STORAGE_SDCARD_PATH: '%Y%m%d/%H%M%S',
|
|
275 | 280 | isSwing() {
|
276 | 281 | return !this.rebooting && this.posValid && (this.config.PRODUCT_MODEL === 'ATOM_CAKP1JZJP');
|
277 | 282 | },
|
278 |
| - RtspUrl() { |
| 283 | + RtspUrl0() { |
279 | 284 | const port = (this.config.RTSP_OVER_HTTP === 'on') ? 8080 : 8554;
|
280 |
| - return `rtsp://${window.location.host}:${port}/unicast`; |
| 285 | + return `rtsp://${window.location.host}:${port}/video0_unicast`; |
| 286 | + }, |
| 287 | + RtspUrl1() { |
| 288 | + const port = (this.config.RTSP_OVER_HTTP === 'on') ? 8080 : 8554; |
| 289 | + return `rtsp://${window.location.host}:${port}/video1_unicast`; |
281 | 290 | },
|
282 | 291 | },
|
283 | 292 | async mounted() {
|
|
619 | 628 | this.rebootStart = new Date();
|
620 | 629 | this.rebootStart.setSeconds(this.rebootStart.getSeconds() + 30);
|
621 | 630 | } else {
|
622 |
| - if((this.config.RTSPSERVER !== this.oldConfig.RTSPSERVER) && (this.config.RTSPSERVER === "off")) { |
623 |
| - execCmds.push(`rtspserver ${this.config.RTSPSERVER}`); |
| 631 | + if(((this.config.RTSP_VIDEO0 !== this.oldConfig.RTSP_VIDEO0) || |
| 632 | + (this.config.RTSP_VIDEO1 !== this.oldConfig.RTSP_VIDEO1)) && |
| 633 | + (this.config.RTSP_VIDEO0 === "off") && (this.config.RTSP_VIDEO1 === "off")) { |
| 634 | + execCmds.push('rtspserver off'); |
624 | 635 | }
|
625 | 636 | if(this.config.STORAGE_SDCARD_PUBLISH !== this.oldConfig.STORAGE_SDCARD_PUBLISH) {
|
626 | 637 | execCmds.push(`samba ${this.config.STORAGE_SDCARD_PUBLISH}`);
|
627 | 638 | }
|
628 |
| - if(((this.config.RTSPSERVER !== this.oldConfig.RTSPSERVER) || |
629 |
| - (this.config.RTSP_AUDIO !== this.oldConfig.RTSP_AUDIO) || |
630 |
| - (this.config.RTSP_OVER_HTTP !== this.oldConfig.RTSP_OVER_HTTP)) && |
631 |
| - (this.config.RTSPSERVER === "on")) { |
| 639 | + if((this.config.RTSP_VIDEO0 === "on") || (this.config.RTSP_VIDEO1 === "on")) { |
632 | 640 | if(this.config.RTSP_OVER_HTTP !== this.oldConfig.RTSP_OVER_HTTP) {
|
633 | 641 | execCmds.push('rtspserver restart');
|
634 |
| - } else { |
| 642 | + } else if((this.config.RTSP_VIDEO0 !== this.oldConfig.RTSP_VIDEO0) || |
| 643 | + (this.config.RTSP_VIDEO1 !== this.oldConfig.RTSP_VIDEO1) || |
| 644 | + (this.config.RTSP_AUDIO0 !== this.oldConfig.RTSP_AUDIO0) || |
| 645 | + (this.config.RTSP_AUDIO1 !== this.oldConfig.RTSP_AUDIO1)) { |
635 | 646 | execCmds.push('rtspserver on');
|
636 | 647 | }
|
637 | 648 | }
|
|
0 commit comments