Speed up device snapshot cadence for a near-live thumbnail
Lower the default and minimum snapshot interval (10s/2s -> 2s/1s) and refresh the selected device's thumbnail on its own 1s timer instead of waiting for the 5s device-list poll, so the preview updates fast enough to feel close to live video without building an actual streaming pipeline. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5
parent
e5df068778
commit
03ec3f0c68
+4
-4
@@ -1114,8 +1114,8 @@ def communication(data):
|
||||
except (TypeError, ValueError):
|
||||
sendMessage(toSidDevice, fromSidDevice, 'warning', 'Invalid snapshot interval', 0)
|
||||
else:
|
||||
if interval_seconds < 2:
|
||||
sendMessage(toSidDevice, fromSidDevice, 'warning', 'Snapshot interval must be at least 2 seconds', 0)
|
||||
if interval_seconds < 1:
|
||||
sendMessage(toSidDevice, fromSidDevice, 'warning', 'Snapshot interval must be at least 1 second', 0)
|
||||
else:
|
||||
SNAPSHOT_INTERVAL_SECONDS = interval_seconds
|
||||
sendMessage(
|
||||
@@ -1302,7 +1302,7 @@ def initIPTV():
|
||||
|
||||
# ----------------------------------------------------------------
|
||||
# ----------------------------------------------------------------
|
||||
num_version='5.0.6'
|
||||
num_version='5.0.7'
|
||||
# ----------------------------------------------------------------
|
||||
# ----------------------------------------------------------------
|
||||
|
||||
@@ -1328,7 +1328,7 @@ mediaRunning = ''
|
||||
status_vpn = 'disconnected'
|
||||
data_running = {}
|
||||
auto_snapshot_enabled = True
|
||||
SNAPSHOT_INTERVAL_SECONDS = 10
|
||||
SNAPSHOT_INTERVAL_SECONDS = 2
|
||||
POLLING_INTERVAL_SECONDS = 10
|
||||
SOCKET_CONNECT_TIMEOUT = 10
|
||||
SOCKET_RETRY_MIN_INTERVAL = 3
|
||||
|
||||
Reference in New Issue
Block a user