fix(decklink-bridge): use GetFrameInternalBufferBytes instead of GetBytes

This commit is contained in:
Wild Dragon Dev 2026-06-04 00:28:19 +00:00
parent a5aed86349
commit 74055e79f8

View file

@ -271,7 +271,9 @@ public:
/* Some SDK versions require casting to the base IDeckLinkVideoFrame
* to access GetBytes() from an IDeckLinkVideoInputFrame. */
IDeckLinkVideoFrame *baseFrame = static_cast<IDeckLinkVideoFrame *>(videoFrame);
baseFrame->GetBytes(&bytes);
// SDK has changed: GetBytes() is no longer directly on IDeckLinkVideoFrame.
// Use GetFrameInternalBufferBytes() which is more robust.
videoFrame->GetFrameInternalBufferBytes(&bytes);
uint32_t sz = (uint32_t)(videoFrame->GetRowBytes() * videoFrame->GetHeight());
uint32_t frame_bytes_expected = (uint32_t)m_ds->width * (uint32_t)m_ds->height * 2;