Fix to align HAlign to 128bytes for Linear Packed YUV format
diff --git a/Source/GmmLib/Texture/GmmTexture.h b/Source/GmmLib/Texture/GmmTexture.h
index 88ce4be..fed1b52 100644
--- a/Source/GmmLib/Texture/GmmTexture.h
+++ b/Source/GmmLib/Texture/GmmTexture.h
@@ -230,7 +230,15 @@
UnitAlignHeight = pPlatform->TexAlign.YUV422.Height;
// For packed 8/16-bit formats alignment factor of 4 will give us < 16B so expand to 32B
- SET_ALIGN_FACTOR(Width, 32);
+
+ if (pTexInfo->Flags.Info.Linear)
+ {
+ SET_ALIGN_FACTOR(Width, 128);
+ }
+ else
+ {
+ SET_ALIGN_FACTOR(Width, 32);
+ }
}
else if(GmmIsCompressed(pGmmLibContext, pTexInfo->Format)) /////////////////////////////
{