WebAPI 支持摄像头启停控制、码流切换、审计日志的提供

This commit is contained in:
2025-12-26 12:15:10 +08:00
parent e9f5975a79
commit adcdc56c7a
12 changed files with 1176 additions and 357 deletions

View File

@@ -110,11 +110,12 @@ namespace SHH.CameraSdk
{
Id = 101,
Brand = DeviceBrand.HikVision,
// IpAddress = "172.16.41.206",
IpAddress = "192.168.5.9",
IpAddress = "172.16.41.206",
//IpAddress = "192.168.5.9",
Port = 8000,
Username = "admin",
Password = "RRYFOA",
Password = "abcd1234",
//Password = "RRYFOA",
StreamType = 0 // 主码流
};
manager.AddDevice(config);
@@ -152,25 +153,25 @@ namespace SHH.CameraSdk
// 投递到渲染线程 (FrameConsumer)
renderer.Enqueue(frame);
Console.WriteLine("Frame Enqueued");
//Console.WriteLine("Frame Enqueued");
});
// [消费者 B] - 绝对只会收到 8fps
GlobalStreamDispatcher.Subscribe("Process_B_Local", (deviceId, frame) =>
{
if (deviceId == 101)
{
Console.WriteLine($"[Process B] 本地渲染一帧 (8fps节奏)");
}
//if (deviceId == 101)
//{
// Console.WriteLine($"[Process B] 本地渲染一帧 (8fps节奏)");
//}
});
// [消费者 AI]
GlobalStreamDispatcher.Subscribe("AI_Engine_Core", (deviceId, frame) =>
{
if (deviceId == 101)
{
Console.WriteLine($" >>> [AI] 分析一帧...");
}
//if (deviceId == 101)
//{
// Console.WriteLine($" >>> [AI] 分析一帧...");
//}
});
}
}