mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-12-04 03:33:44 +01:00
Add some paranoid checks guided by stack traces from Google Play
This commit is contained in:
1 parent
d7770307f3
commit
b730d187e8
5 files changed
+28
-14
No files matched your search
+11
-6
@@ -856,13 +856,16 @@ public:
|
||||
|
||||
// PIC1 is the loading image, so let's only draw if it's available.
|
||||
if (ginfo && ginfo->pic1.texture) {
|
||||
dc.GetDrawContext()->BindTexture(0, ginfo->pic1.texture->GetTexture());
|
||||
Draw::Texture *texture = ginfo->pic1.texture->GetTexture();
|
||||
if (texture) {
|
||||
dc.GetDrawContext()->BindTexture(0, texture);
|
||||
|
||||
double loadTime = ginfo->pic1.timeLoaded;
|
||||
uint32_t color = alphaMul(color_, ease((time_now_d() - loadTime) * 3));
|
||||
dc.Draw()->DrawTexRect(dc.GetBounds(), 0, 0, 1, 1, color);
|
||||
dc.Flush();
|
||||
dc.RebindTexture();
|
||||
double loadTime = ginfo->pic1.timeLoaded;
|
||||
uint32_t color = alphaMul(color_, ease((time_now_d() - loadTime) * 3));
|
||||
dc.Draw()->DrawTexRect(dc.GetBounds(), 0, 0, 1, 1, color);
|
||||
dc.Flush();
|
||||
dc.RebindTexture();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1154,6 +1157,8 @@ void EmuScreen::render() {
|
||||
using namespace Draw;
|
||||
|
||||
DrawContext *thin3d = screenManager()->getDrawContext();
|
||||
if (!thin3d)
|
||||
return; // shouldn't really happen but I've seen a suspicious stack trace..
|
||||
|
||||
if (invalid_) {
|
||||
// Loading, or after shutdown?
|
||||
|
||||
Reference in new issue
Block a user