新增 Mjpegplayer 用来播放 Web 流

This commit is contained in:
2026-01-21 19:03:59 +08:00
parent f79cb6e74d
commit c438edfa0d
71 changed files with 4538 additions and 452 deletions

View File

@@ -163,10 +163,9 @@ public class ServiceConfig
string ip = parts[0].Trim();
string portStr = parts[1].Trim();
string type = parts[2].Trim().ToLower();
// ★★★ 提取第四个字段作为备注 ★★★
string desc = parts.Length >= 4 ? parts[3].Trim() : "未命名终端";
string desc = parts.Length >= 4 ? parts[2].Trim() : "未命名终端";
if (int.TryParse(portStr, out int port))
{
@@ -180,16 +179,10 @@ public class ServiceConfig
};
// 添加前检查 Uri 是否重复 (备注不参与排重)
if (type == "video")
{
if (!config.VideoEndpoints.Any(e => e.Uri == zmqUri))
config.VideoEndpoints.Add(endpoint);
}
else if (type == "command" || type == "text")
{
if (!config.CommandEndpoints.Any(e => e.Uri == zmqUri))
config.CommandEndpoints.Add(endpoint);
}
if (!config.VideoEndpoints.Any(e => e.Uri == zmqUri))
config.VideoEndpoints.Add(endpoint);
if (!config.CommandEndpoints.Any(e => e.Uri == zmqUri))
config.CommandEndpoints.Add(endpoint);
}
}
}