[idd] select linear RGB24 packing automatically

Replace the texture-shaped RGB24 output with a linear raw buffer and
keep its packing, damage translation, and buffer copies inside the
RGB24 effect.

Benchmark full-frame native and packed processing and retain the faster
path for each source format. Preserve logical damage rectangles for
client updates and alternating framebuffer repair.

Return compute outputs to COMMON for COPY queue handoff and refresh
cached framebuffer sizes when switching packed and native layouts.
This commit is contained in:
Geoffrey McRae
2026-08-03 20:35:49 +10:00
parent fa2769b332
commit 6109501eed
16 changed files with 987 additions and 232 deletions

View File

@@ -33,25 +33,24 @@ using namespace Microsoft::WRL;
class CFrameBufferResource
{
private:
bool m_valid = false;
unsigned m_frameIndex = 0;
uint8_t * m_base = nullptr;
size_t m_size = 0;
size_t m_frameSize = 0;
uint64_t m_captureTime = 0;
uint64_t m_postProcessStart = 0;
uint64_t m_copyStart = 0;
unsigned m_frameIndex = 0;
uint8_t * m_base = nullptr;
size_t m_size = 0;
size_t m_frameSize = 0;
uint64_t m_captureTime = 0;
uint64_t m_postProcessStart = 0;
uint64_t m_copyStart = 0;
unsigned m_timingEffectIndex = 0;
uint64_t m_timingToken = 0;
bool m_fullCopy = false;
ComPtr<ID3D12Resource> m_res;
void * m_map = nullptr;
void * m_map = nullptr;
public:
bool Init(CSwapChainProcessor * swapChain, unsigned frameIndex, uint8_t * base, size_t size);
void Reset();
bool IsValid() { return m_valid; }
unsigned GetFrameIndex() { return m_frameIndex; }
uint8_t * GetBase() { return m_base; }
size_t GetSize() { return m_size; }
size_t GetFrameSize() { return m_frameSize; }
void * GetMap() { return m_map; }
@@ -66,5 +65,16 @@ class CFrameBufferResource
uint64_t GetPostProcessStart() const { return m_postProcessStart; }
uint64_t GetCopyStart () const { return m_copyStart; }
void SetPostProcessSample(
unsigned effectIndex, uint64_t token, bool fullCopy)
{
m_timingEffectIndex = effectIndex;
m_timingToken = token;
m_fullCopy = fullCopy;
}
unsigned GetTimingEffectIndex() const { return m_timingEffectIndex; }
uint64_t GetTimingToken () const { return m_timingToken; }
bool IsFullCopy () const { return m_fullCopy; }
ComPtr<ID3D12Resource> Get() { return m_res; }
};