From 89a6c2fbcdbff7272bb7bbd35ce2e7116313fe76 Mon Sep 17 00:00:00 2001 From: BlueRose <378100977@qq.com> Date: Sun, 29 Sep 2024 18:56:14 +0800 Subject: [PATCH] vault backup: 2024-09-29 18:56:14 --- 02-Note/DAWA/ASoul/流程笔记/MultiView逻辑.md | 31 +++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/02-Note/DAWA/ASoul/流程笔记/MultiView逻辑.md b/02-Note/DAWA/ASoul/流程笔记/MultiView逻辑.md index 9569218..405ee1a 100644 --- a/02-Note/DAWA/ASoul/流程笔记/MultiView逻辑.md +++ b/02-Note/DAWA/ASoul/流程笔记/MultiView逻辑.md @@ -85,4 +85,33 @@ bool UMediaCapture::ValidateMediaOutput() const } return true; } -``` \ No newline at end of file +``` + +```c++ +bool UDeckLinkMediaCapture::InitBlackmagic(int _Width, int _Height) +{ + if (DeckLinkDiscovery == nullptr) + { + return false; + } + Width = _Width; + Height = _Height; + check(Height > 0 && Width > 0) + BMDDisplayMode displayMode = GetDisplayMode(Width, Height); + m_DeckLinkOutputDevice = DeckLinkDiscovery->GetDeviceByName(m_DeviceName); + if (m_DeckLinkOutputDevice.Get() == nullptr) + { + return false; + } + if (!m_DeckLinkOutputDevice->EnableOutput(displayMode, bmdFormat8BitYUV)) + { + m_DeckLinkOutputDevice.Reset(); + return false; + } + + + return true; +} +``` + +***DeckLinkDiscovery->GetDeviceByName(m_DeviceName);*** \ No newline at end of file