mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-02-03 01:35:22 +03:00
Make sure jsmpeg works as expected
This commit is contained in:
parent
7ff2dae9d5
commit
6c95e78366
@ -94,20 +94,26 @@ export default function Camera({ camera }) {
|
||||
|
||||
let player;
|
||||
if (viewMode === 'live') {
|
||||
if (cameraConfig.restream.enabled) {
|
||||
<VideoPlayer
|
||||
options={{
|
||||
preload: 'auto',
|
||||
autoplay: true,
|
||||
sources: [
|
||||
{
|
||||
src: `${apiHost}/restream/${camera}`,
|
||||
type: 'video/mp4',
|
||||
},
|
||||
],
|
||||
}}
|
||||
onReady={() => {}}
|
||||
/>
|
||||
if (cameraConfig.live.source == 'restream') {
|
||||
player = (
|
||||
<Fragment>
|
||||
<div>
|
||||
<VideoPlayer
|
||||
options={{
|
||||
preload: 'auto',
|
||||
autoplay: true,
|
||||
sources: [
|
||||
{
|
||||
src: `${apiHost}/restream/${camera}`,
|
||||
type: 'video/mp4',
|
||||
},
|
||||
],
|
||||
}}
|
||||
onReady={() => {}}
|
||||
/>
|
||||
</div>
|
||||
</Fragment>
|
||||
);
|
||||
} else {
|
||||
player = (
|
||||
<Fragment>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user