|
@@ -140,6 +140,7 @@ struct Window::Internal |
|
|
std::map<std::string, std::shared_ptr<Image>> imageCache; |
|
|
std::map<std::string, std::shared_ptr<Image>> imageCache; |
|
|
|
|
|
|
|
|
bool fbDirtyOnSubpixelChange = true; |
|
|
bool fbDirtyOnSubpixelChange = true; |
|
|
|
|
|
int fbCount = 0; |
|
|
|
|
|
|
|
|
#ifdef WITH_MESA |
|
|
#ifdef WITH_MESA |
|
|
void run() override { |
|
|
void run() override { |
|
@@ -359,6 +360,7 @@ void Window::step() { |
|
|
double lastFrameTime = internal->frameTime; |
|
|
double lastFrameTime = internal->frameTime; |
|
|
internal->frameTime = frameTime; |
|
|
internal->frameTime = frameTime; |
|
|
internal->lastFrameDuration = frameTime - lastFrameTime; |
|
|
internal->lastFrameDuration = frameTime - lastFrameTime; |
|
|
|
|
|
internal->fbCount = 0; |
|
|
// DEBUG("%.2lf Hz", 1.0 / internal->lastFrameDuration); |
|
|
// DEBUG("%.2lf Hz", 1.0 / internal->lastFrameDuration); |
|
|
|
|
|
|
|
|
// Make event handlers and step() have a clean NanoVG context |
|
|
// Make event handlers and step() have a clean NanoVG context |
|
@@ -507,6 +509,11 @@ bool& Window::fbDirtyOnSubpixelChange() { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
int& Window::fbCount() { |
|
|
|
|
|
return internal->fbCount; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} // namespace window |
|
|
} // namespace window |
|
|
} // namespace rack |
|
|
} // namespace rack |
|
|
|
|
|
|
|
|