在 AiVideo 中能看到图像

增加了在线状态同步逻辑
This commit is contained in:
2026-01-09 12:30:36 +08:00
parent 3d47c8f009
commit 3351ae739e
31 changed files with 1090 additions and 477 deletions

View File

@@ -0,0 +1,20 @@
using MessagePack;
using SHH.CameraDashboard;
using SHH.CameraDashboard.Services;
using SHH.Contracts;
public class RegisterProcessor : IProtocolProcessor
{
public string ProtocolType => ProtocolHeaders.ServerRegister;
private readonly CommandBusClient _bus;
public RegisterProcessor(CommandBusClient bus) => _bus = bus;
public void Process(byte[] identity, byte[] payloadBytes)
{
var p = MessagePackSerializer.Deserialize<RegisterPayload>(payloadBytes);
_bus.UpdateSession(p.InstanceId, identity);
_bus.RaiseServerRegistered(p);
}
}