diff --git a/Source/Common/AvfCtlWrapper.h b/Source/Common/AvfCtlWrapper.h index 7ca4d4ac..9b076ef0 100644 --- a/Source/Common/AvfCtlWrapper.h +++ b/Source/Common/AvfCtlWrapper.h @@ -39,6 +39,7 @@ class AVFCtlWrapper : public BaseWrapper { bool WaitForSessionEnd(uint64_t Timeout); private: + static std::string Interface; void* Ctl; ControllerBaseWrapper* ExtCtl; }; diff --git a/Source/Common/AvfCtlWrapper.mm b/Source/Common/AvfCtlWrapper.mm index 3723fe36..57489981 100644 --- a/Source/Common/AvfCtlWrapper.mm +++ b/Source/Common/AvfCtlWrapper.mm @@ -125,6 +125,8 @@ - (AVCaptureDeviceTransportControlsSpeed) getSpeed } @end +string AVFCtlWrapper::Interface = "DV"; + AVFCtlWrapper::AVFCtlWrapper(size_t DeviceIndex, ControllerBaseWrapper* ExtCtl) : ExtCtl(ExtCtl) { AVFCtlExternalController* ExternalController = nil; @@ -164,7 +166,7 @@ - (AVCaptureDeviceTransportControlsSpeed) getSpeed if (DeviceIndex < 0) return string(); - return string([[AVFCtl getDeviceName:DeviceIndex] UTF8String]); + return string([[AVFCtl getDeviceName:DeviceIndex] UTF8String]) + " [" + Interface + "]"; } string AVFCtlWrapper::GetDeviceID(size_t DeviceIndex) diff --git a/Source/Common/DecklinkWrapper.cpp b/Source/Common/DecklinkWrapper.cpp index 4dc3f8ac..1e889b77 100644 --- a/Source/Common/DecklinkWrapper.cpp +++ b/Source/Common/DecklinkWrapper.cpp @@ -181,6 +181,9 @@ HRESULT DecklinkWrapper::StatusDelegate::DeckControlStatusChanged(BMDDeckControl return S_OK; } +//--------------------------------------------------------------------------- +string DecklinkWrapper::Interface = "DeckLink"; + //--------------------------------------------------------------------------- void DecklinkWrapper::Init() { @@ -404,7 +407,7 @@ string DecklinkWrapper::GetDeviceName(size_t DeviceIndex) if (DeviceIndex >= Devices.size()) return ""; - return Devices[DeviceIndex].Name; + return Devices[DeviceIndex].Name + " [" + Interface + "]"; } //--------------------------------------------------------------------------- diff --git a/Source/Common/DecklinkWrapper.h b/Source/Common/DecklinkWrapper.h index a36049c5..60f0c69f 100644 --- a/Source/Common/DecklinkWrapper.h +++ b/Source/Common/DecklinkWrapper.h @@ -141,6 +141,7 @@ class DecklinkWrapper : public BaseWrapper { private: playback_mode PlaybackMode = Playback_Mode_NotPlaying; bool Capture = false; + static std::string Interface; //DeckLink IDeckLink* DeckLinkDevice = nullptr; diff --git a/Source/Common/LinuxWrapper.cpp b/Source/Common/LinuxWrapper.cpp index 027a5dcf..c11b49b0 100644 --- a/Source/Common/LinuxWrapper.cpp +++ b/Source/Common/LinuxWrapper.cpp @@ -57,6 +57,8 @@ static int ReceiveFrame(unsigned char* Data, int Lenght, int, void *UserData) return 0; } +//--------------------------------------------------------------------------- +string LinuxWrapper::Interface = "DV"; //--------------------------------------------------------------------------- void LinuxWrapper::Init() @@ -220,7 +222,7 @@ string LinuxWrapper::GetDeviceName(const string& DeviceID) for (size_t Pos = 0; Pos < Devices.size(); Pos++) { if (Devices[Pos].UUID == ID) - return Devices[Pos].Vendor + " " + Devices[Pos].Model; + return Devices[Pos].Vendor + " " + Devices[Pos].Model + " [" + Interface + "]"; } return ""; diff --git a/Source/Common/LinuxWrapper.h b/Source/Common/LinuxWrapper.h index e1c27fe2..afc735bf 100644 --- a/Source/Common/LinuxWrapper.h +++ b/Source/Common/LinuxWrapper.h @@ -69,6 +69,8 @@ class LinuxWrapper : public BaseWrapper { bool WaitForSessionEnd(uint64_t Timeout); private: + static std::string Interface; + // global int Port = -1; nodeid_t Node = (nodeid_t)-1; diff --git a/Source/Common/SimulatorWrapper.cpp b/Source/Common/SimulatorWrapper.cpp index 6cf4bae0..b001591e 100644 --- a/Source/Common/SimulatorWrapper.cpp +++ b/Source/Common/SimulatorWrapper.cpp @@ -139,6 +139,9 @@ static ZtringListList ReadFileNames() return List; } +//--------------------------------------------------------------------------- +string SimulatorWrapper::Interface = "Simulator"; + //--------------------------------------------------------------------------- SimulatorWrapper::SimulatorWrapper(std::size_t DeviceIndex) { @@ -188,7 +191,7 @@ std::string SimulatorWrapper::GetDeviceName(std::size_t DeviceIndex) auto List = ReadFileNames(); if (DeviceIndex >= List.size() || List[DeviceIndex].empty()) return {}; - return List[DeviceIndex][0].To_UTF8() + " (Simulator)"; + return List[DeviceIndex][0].To_UTF8() + " [" + Interface + "]"; } //--------------------------------------------------------------------------- diff --git a/Source/Common/SimulatorWrapper.h b/Source/Common/SimulatorWrapper.h index 70aa625e..be9c4448 100644 --- a/Source/Common/SimulatorWrapper.h +++ b/Source/Common/SimulatorWrapper.h @@ -35,5 +35,6 @@ class SimulatorWrapper : public BaseWrapper { bool WaitForSessionEnd(uint64_t Timeout); private: + static std::string Interface; void* Ctl; };