feature: add ip cam to webcams
Signed-off-by: Stefan Dej <meteyou@gmail.com>
This commit is contained in:
parent
fcbdd18d04
commit
cae2bfd2cb
@ -159,6 +159,7 @@
|
||||
<div class="subtitle-1 mt-2">{{ $t('Settings.WebcamPanel.UrlNotAvailable') }}</div>
|
||||
</template>
|
||||
</vue-load-image>
|
||||
<video v-if="['ipstream'].includes(dialog.service)" :src="dialog.url" autoplay :style="webcamStyle" />
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row class="mt-3">
|
||||
@ -230,6 +231,7 @@ export default {
|
||||
serviceItems: [
|
||||
{ value: "mjpegstreamer", text: this.$t("Settings.WebcamPanel.Mjpegstreamer")},
|
||||
{ value: "mjpegstreamer-adaptive", text: this.$t("Settings.WebcamPanel.MjpegstreamerAdaptive") },
|
||||
{ value: "ipstream", text: this.$t("Settings.WebcamPanel.Ipstream") },
|
||||
],
|
||||
};
|
||||
},
|
||||
|
@ -16,7 +16,11 @@
|
||||
<v-item-group v-if="this.webcams.length > 1">
|
||||
<v-menu :offset-y="true" title="Webcam">
|
||||
<template v-slot:activator="{ on, attrs }">
|
||||
<v-btn small class="px-2 minwidth-0" color="primary" v-bind="attrs" v-on="on">{{ 'name' in currentCam ? currentCam.name : "unknown" }} <v-icon small>mdi-menu-down</v-icon></v-btn>
|
||||
<v-btn small class="px-2 minwidth-0" color="primary" v-bind="attrs" v-on="on">
|
||||
<v-icon small v-if="'icon' in currentCam" class="mr-2">{{ currentCam.icon }}</v-icon>
|
||||
{{ 'name' in currentCam ? currentCam.name : "unknown" }}
|
||||
<v-icon small>mdi-menu-down</v-icon>
|
||||
</v-btn>
|
||||
</template>
|
||||
<v-list dense class="py-0">
|
||||
<v-list-item v-for="webcam of this.webcams" v-bind:key="webcam.index" link @click="currentCamName = webcam.name">
|
||||
@ -57,6 +61,9 @@
|
||||
border-top-left-radius: 5px;
|
||||
">{{ $t('Panels.WebcamPanel.FPS')}}: {{ currentFPS }}</span>
|
||||
</template>
|
||||
<template v-else-if="'service' in this.currentCam && this.currentCam.service === 'ipstream'">
|
||||
<video :src="url" autoplay :style="webcamStyle" />
|
||||
</template>
|
||||
<template v-else>
|
||||
<img slot="image" :src="url" alt="Preview" :style="webcamStyle" class="webcamImage" @load="onLoad" />
|
||||
</template>
|
||||
|
@ -421,6 +421,7 @@ export default {
|
||||
|
||||
Mjpegstreamer: "MJPEG-Streamer",
|
||||
MjpegstreamerAdaptive: "Adaptive MJPEG-Streamer (experimental)",
|
||||
Ipstream: "IP Camera",
|
||||
|
||||
Required: "required",
|
||||
NameAlreadyExists: "Name already exists",
|
||||
|
Loading…
x
Reference in New Issue
Block a user