Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
hrydgard
GitHub Repository: hrydgard/ppsspp
Path: blob/master/Core/FrameTiming.h
5654 views
1
#pragma once
2
3
#include "Common/GPU/thin3d.h"
4
5
// See big comment in the CPP file.
6
7
namespace Draw {
8
class DrawContext;
9
}
10
11
class FrameTiming {
12
public:
13
void DeferWaitUntil(double until, double *curTimePtr);
14
void PostSubmit();
15
void ComputePresentMode(Draw::DrawContext *draw, bool fastForward);
16
17
bool FastForwardNeedsSkipFlip() const {
18
return fastForwardSkipFlip_;
19
}
20
Draw::PresentMode PresentMode() const {
21
return presentMode_;
22
}
23
24
private:
25
// For use on the next Present. These two are set by ComputePresentMode.
26
Draw::PresentMode presentMode_;
27
bool fastForwardSkipFlip_;
28
29
double waitUntil_;
30
double *curTimePtr_;
31
};
32
33
extern FrameTiming g_frameTiming;
34
35
36
void WaitUntil(double now, double timestamp, const char *reason);
37
38