[idd] transport: add frame sink boundary

This commit is contained in:
Geoffrey McRae
2026-08-12 16:45:01 +10:00
parent 801a1e58f8
commit bd4d31f0bd
21 changed files with 634 additions and 81 deletions

View File

@@ -717,13 +717,13 @@ bool CLGMPFrameTransport::RetryPendingDelivery(uint64_t now, bool& retry)
return result == SHARED_FRAME_POSTED;
}
PreparedFrameBuffer CLGMPFrameTransport::PrepareFrameBuffer(
SinkTarget CLGMPFrameTransport::PrepareFrameBuffer(
unsigned pitch, const D12FrameFormat& srcFormat,
const D12FrameFormat& dstFormat, const RECT * dirtyRects,
unsigned nbDirtyRects, const CFrameScheduler::Schedule& schedule,
bool allowReadyReplacement)
{
PreparedFrameBuffer result = {};
SinkTarget result = {};
const unsigned dataWidth = dstFormat.dataWidth ?
dstFormat.dataWidth : (unsigned)dstFormat.desc.Width;
@@ -913,7 +913,7 @@ PreparedFrameBuffer CLGMPFrameTransport::PrepareFrameBuffer(
LGMPBuffer * fb = m_frameBuffer[frameIndex];
fb->wp = 0;
result.frameIndex = frameIndex;
result.slot = frameIndex;
result.mem = fb->data;
result.heapOffset = reinterpret_cast<uintptr_t>(fb->data) -
reinterpret_cast<uintptr_t>(m_ivshmem.GetMem());

View File

@@ -34,14 +34,14 @@ extern "C" {
#include "capture/CFrameScheduler.h"
#include "capture/FramePipeline.h"
#include "transport/FrameMemoryLimits.h"
#include "transport/IFrameTransport.h"
#include "transport/IFrameSink.h"
class CIVSHMEM;
class CLGMPHost;
class CLGMPTransport;
struct LGMPBuffer;
class CLGMPFrameTransport final : public IFrameTransport
class CLGMPFrameTransport final : public IFrameSink
{
private:
friend class CLGMPTransport;
@@ -172,7 +172,7 @@ public:
bool GetPendingDeliveryTarget(
uint64_t now, uint64_t& target) override;
bool RetryPendingDelivery(uint64_t now, bool& retry) override;
PreparedFrameBuffer PrepareFrameBuffer(unsigned pitch,
SinkTarget PrepareFrameBuffer(unsigned pitch,
const D12FrameFormat& srcFormat, const D12FrameFormat& dstFormat,
const RECT * dirtyRects, unsigned nbDirtyRects,
const CFrameScheduler::Schedule& schedule,

View File

@@ -63,7 +63,7 @@ public:
FrameMemoryLimits GetMemoryLimits() const override;
DirectFrameBufferMemory GetDirectMemory() const override;
IFrameTransport& Frames() override { return m_frames; }
IFrameSink& FrameSink() override { return m_frames; }
IControlTransport& Control() override { return m_control; }
IInputTransport * Input() override { return &m_input; }
};