big stream progress

- stream manager (with bare bones ui)
- debug video tap
- toxav progress
- toxav debug ui
- some default devices
This commit is contained in:
2024-09-15 11:39:23 +02:00
parent a100eaae82
commit 964f6de656
19 changed files with 989 additions and 69 deletions

39
src/stream_manager_ui.cpp Normal file
View File

@ -0,0 +1,39 @@
#include "./stream_manager_ui.hpp"
#include <solanaceae/object_store/object_store.hpp>
#include <imgui/imgui.h>
StreamManagerUI::StreamManagerUI(ObjectStore2& os, StreamManager& sm) : _os(os), _sm(sm) {
}
void StreamManagerUI::render(void) {
if (ImGui::Begin("StreamManagerUI")) {
// TODO: node canvas?
// by fametype ??
ImGui::SeparatorText("Sources");
// list sources
for (const auto& [oc, ss] : _os.registry().view<Components::StreamSource>().each()) {
ImGui::Text("src %d (%s)[%s]", entt::to_integral(oc), ss.name.c_str(), ss.frame_type_name.c_str());
}
ImGui::SeparatorText("Sinks");
// list sinks
for (const auto& [oc, ss] : _os.registry().view<Components::StreamSink>().each()) {
ImGui::Text("sink %d (%s)[%s]", entt::to_integral(oc), ss.name.c_str(), ss.frame_type_name.c_str());
}
ImGui::SeparatorText("Connections");
// list connections
for (const auto& con : _sm._connections) {
ImGui::Text("con %d->%d", entt::to_integral(con->src.entity()), entt::to_integral(con->sink.entity()));
}
}
ImGui::End();
}