White boxes when using Fonts from External Flash
This is a project that I just updated from TouchGFX 4.5 to 4.19.
I've been working to update a project to use external flash fonts instead of internal which was the reason from upgrading from 4.5 to 4.19.
I'm stuck at a point where the font gets loaded. It appears that the glyphNode buffer is getting filled correctly as the width, height, left, kerning, etc from the datareader->copydata
But it appears that the font itself might not be getting loaded as getBitsPerPixel is returning unexpected values like 0x79, when I know that my font has a BPP of 2. Which makes me think that the actual bitmap of the glyph might not be getting loaded.
All the other image graphics and drawings we use are working fine.
Code from TouchGFX/UnmappedDataFont.cpp
const GlyphNode* UnmappedDataFont::getGlyph(Unicode::UnicodeChar unicode, const uint8_t*& pixelData, uint8_t& bitsPerPixel) const
{
int index = lookupUnicode(unicode);
if (index != -1)
{
// Read glyphNode from unmapped flash
touchgfx::FlashDataReader* const flashReader = ApplicationFontProvider::getFlashReader();
flashReader->copyData(glyphList + index, &glyphNodeBuffer, sizeof(GlyphNode));
pixelData = getPixelData(const_cast<const GlyphNode*>(&glyphNodeBuffer));
bitsPerPixel = getBitsPerPixel();
return &glyphNodeBuffer;
}
return 0;
}Example:
Internal --> External
Any ideas