mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-03-07 02:18:07 +01:00
Miscellaneous fixes (#20875)
* Improve stream fetching logic * Reduce need to revalidate stream info * fix frigate+ frame submission * add UI setting to configure jsmpeg fallback timeout * hide settings dropdown when fullscreen * Fix arcface running on OpenVINO --------- Co-authored-by: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com>
This commit is contained in:
@@ -343,6 +343,10 @@ export function TrackingDetails({
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
}, [displayedRecordTime]);
|
||||
|
||||
const onUploadFrameToPlus = useCallback(() => {
|
||||
return axios.post(`/${event.camera}/plus/${currentTime}`);
|
||||
}, [event.camera, currentTime]);
|
||||
|
||||
if (!config) {
|
||||
return <ActivityIndicator />;
|
||||
}
|
||||
@@ -388,6 +392,7 @@ export function TrackingDetails({
|
||||
frigateControls={true}
|
||||
onTimeUpdate={handleTimeUpdate}
|
||||
onSeekToTime={handleSeekToTime}
|
||||
onUploadFrame={onUploadFrameToPlus}
|
||||
isDetailMode={true}
|
||||
camera={event.camera}
|
||||
currentTimeOverride={currentTime}
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import { baseUrl } from "@/api/baseUrl";
|
||||
import { usePersistence } from "@/hooks/use-persistence";
|
||||
import {
|
||||
LivePlayerError,
|
||||
PlayerStatsType,
|
||||
@@ -71,6 +72,8 @@ function MSEPlayer({
|
||||
const [errorCount, setErrorCount] = useState<number>(0);
|
||||
const totalBytesLoaded = useRef(0);
|
||||
|
||||
const [fallbackTimeout] = usePersistence<number>("liveFallbackTimeout", 3);
|
||||
|
||||
const videoRef = useRef<HTMLVideoElement>(null);
|
||||
const wsRef = useRef<WebSocket | null>(null);
|
||||
const reconnectTIDRef = useRef<number | null>(null);
|
||||
@@ -475,7 +478,10 @@ function MSEPlayer({
|
||||
setBufferTimeout(undefined);
|
||||
}
|
||||
|
||||
const timeoutDuration = bufferTime == 0 ? 5000 : 3000;
|
||||
const timeoutDuration =
|
||||
bufferTime == 0
|
||||
? (fallbackTimeout ?? 3) * 2 * 1000
|
||||
: (fallbackTimeout ?? 3) * 1000;
|
||||
setBufferTimeout(
|
||||
setTimeout(() => {
|
||||
if (
|
||||
@@ -500,6 +506,7 @@ function MSEPlayer({
|
||||
onError,
|
||||
onPlaying,
|
||||
playbackEnabled,
|
||||
fallbackTimeout,
|
||||
]);
|
||||
|
||||
useEffect(() => {
|
||||
|
||||
Reference in New Issue
Block a user