Use a separate texture for rendering to avoid blending in the alignment padding

Fixes #885
This commit is contained in:
Cameron Gutman
2022-10-26 21:48:55 -05:00
parent 3dcab90752
commit a6fccf93d1
2 changed files with 70 additions and 62 deletions
@@ -30,7 +30,7 @@ private:
static void unlockContext(void* lock_ctx);
bool setupRenderingResources();
bool setupTexturePoolViews(AVD3D11VAFramesContext* frameContext);
bool setupVideoTexture();
void renderOverlay(Overlay::OverlayType type);
void bindColorConversion(AVFrame* frame);
void renderVideo(AVFrame* frame);
@@ -60,8 +60,8 @@ private:
ID3D11PixelShader* m_VideoBt2020LimPixelShader;
ID3D11Buffer* m_VideoVertexBuffer;
#define DECODER_BUFFER_POOL_SIZE 17
ID3D11ShaderResourceView* m_VideoTextureResourceViews[DECODER_BUFFER_POOL_SIZE][2];
ID3D11Texture2D* m_VideoTexture;
ID3D11ShaderResourceView* m_VideoTextureResourceViews[2];
SDL_SpinLock m_OverlayLock;
ID3D11Buffer* m_OverlayVertexBuffers[Overlay::OverlayMax];