mirror of
https://github.com/Dispatcharr/Dispatcharr.git
synced 2026-08-01 14:30:16 +00:00
Add stream type to stats page.
This commit is contained in:
parent
f869daa37c
commit
1f6f15ed73
2 changed files with 16 additions and 5 deletions
|
|
@ -317,6 +317,9 @@ class ChannelStatus:
|
|||
ffmpeg_bitrate = metadata.get(ChannelMetadataField.FFMPEG_BITRATE.encode('utf-8'))
|
||||
if ffmpeg_bitrate:
|
||||
info['ffmpeg_bitrate'] = float(ffmpeg_bitrate.decode('utf-8'))
|
||||
stream_type = metadata.get(ChannelMetadataField.STREAM_TYPE.encode('utf-8'))
|
||||
if stream_type:
|
||||
info['stream_type'] = stream_type.decode('utf-8')
|
||||
|
||||
return info
|
||||
|
||||
|
|
@ -497,6 +500,9 @@ class ChannelStatus:
|
|||
audio_channels = metadata.get(ChannelMetadataField.AUDIO_CHANNELS.encode('utf-8'))
|
||||
if audio_channels:
|
||||
info['audio_channels'] = audio_channels.decode('utf-8')
|
||||
stream_type = metadata.get(ChannelMetadataField.STREAM_TYPE.encode('utf-8'))
|
||||
if stream_type:
|
||||
info['stream_type'] = stream_type.decode('utf-8')
|
||||
|
||||
return info
|
||||
except Exception as e:
|
||||
|
|
|
|||
|
|
@ -477,11 +477,6 @@ const ChannelCard = ({ channel, clients, stopClient, stopChannel, logos, channel
|
|||
|
||||
{/* Add stream information badges */}
|
||||
<Group gap="xs" mt="xs">
|
||||
{channel.video_codec && (
|
||||
<Badge size="sm" variant="light" color="blue">
|
||||
{channel.video_codec.toUpperCase()}
|
||||
</Badge>
|
||||
)}
|
||||
{channel.resolution && (
|
||||
<Badge size="sm" variant="light" color="green">
|
||||
{channel.resolution}
|
||||
|
|
@ -492,6 +487,16 @@ const ChannelCard = ({ channel, clients, stopClient, stopChannel, logos, channel
|
|||
{channel.source_fps} FPS
|
||||
</Badge>
|
||||
)}
|
||||
{channel.video_codec && (
|
||||
<Badge size="sm" variant="light" color="blue">
|
||||
{channel.video_codec.toUpperCase()}
|
||||
</Badge>
|
||||
)}
|
||||
{channel.stream_type && (
|
||||
<Badge size="sm" variant="light" color="blue">
|
||||
{channel.stream_type.toUpperCase()}
|
||||
</Badge>
|
||||
)}
|
||||
{channel.audio_codec && (
|
||||
<Badge size="sm" variant="light" color="purple">
|
||||
{channel.audio_codec.toUpperCase()}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue