fix ly shine inverted font colors

Make AtomFont use the same vertex color format as LyShine.
This commit is contained in:
rgba16f
2021-05-26 13:38:03 -05:00
committed by GitHub
parent 50085d0487
commit 6b2028c756
2 changed files with 3 additions and 3 deletions
@@ -864,7 +864,7 @@ int AZ::FFont::CreateQuadsForText(const RHI::Viewport& viewport, float x, float
if (drawFrame)
{
ColorB tempColor(255, 255, 255, 255);
uint32_t frameColor = tempColor.pack_abgr8888(); //note: this ends up in r,g,b,a order on little-endian machines
uint32_t frameColor = tempColor.pack_argb8888(); //note: this ends up in r,g,b,a order on little-endian machines
Vec2 textSize = GetTextSizeUInternal(viewport, str, asciiMultiLine, ctx);
@@ -1122,7 +1122,7 @@ int AZ::FFont::CreateQuadsForText(const RHI::Viewport& viewport, float x, float
{
ColorB tempColor = color;
tempColor.a = ((uint32_t) tempColor.a * alphaBlend) >> 8;
packedColor = tempColor.pack_abgr8888(); //note: this ends up in r,g,b,a order on little-endian machines
packedColor = tempColor.pack_argb8888(); //note: this ends up in r,g,b,a order on little-endian machines
}
if (ctx.m_drawTextFlags & eDrawText_UseTransform)