-
Notifications
You must be signed in to change notification settings - Fork 124
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TTF_RenderUTF8_Blended very very slow in Android #193
Comments
First, this is the emulator. so times are maybe wrong ? otherwise: first fime: it will render each glyph. then cache them. then render the string. more issue: |
Thank you for your help. I'm run this app on huawei p40. I don't understand your solution, can you give me more information? |
Help |
dont render the font every frame. Render the font when the text changes only on a texture. And render the texture every frame. |
I render different texts that it cost more 5 seconds on HUAWEI p40... |
Store |
I encountered a problem that it was run this function(TTF_RenderUTF8_Blended) cost more than 0.5 seconds to render one char(chinese) on HUAWEI p40 or virtual machine.I uploaded the test code,help~ |
安卓的apk,zip是压缩的ttf,你应该把整个ttf读到内存,或者先从assets复制到 SDL_GetPrefPath |
It takes more than 1 second to run this function...
SDL_Color oColor = {0xFF, 0xFF, 0xFF};
for (auto s : oMsgVec)
{
auto nStart = SDL_GetTicks64();
}
The text was updated successfully, but these errors were encountered: