-
Notifications
You must be signed in to change notification settings - Fork 104
Window keeps repainting when idle #45
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
Comments
Hi mackrol, I'm glad you like tev. Thank you very much for the feedback! Currently, With your hack, I suspect if you open secondary instances of tev (e.g. by double-clicking an EXR file while an instance of tev is already open) nothing will happen until you manually re-focus the original instance. Could you confirm this? I fully agree, that this situation is not optimal. Ideally, tev would request repaints only when such events occur, but I am not aware of a mechanism in nanogui that allows both
in a cross-platform manner. In-fact, I already tried getting this to work at some point using |
Indeed, there is a problem when opening an image with a second instance of TEV with hack applied. New image is shown once I hover mouse over the window (new messages in the queue). I'm investigating this because I'm looking for a viable GUI library for small desktop applications like Yours. I use Qt professionally, but it's an overkill for hobby projects. All small GUI libraries that I know, fail my desktop citizenship test, that's the price of simplicity I guess. |
Uh oh!
There was an error while loading. Please reload this page.
Thank You for such a great tool. This is currently my favorite exr viewer.
Crossposted in wjakob/nanogui#337
On Win10 tev window keeps constantly repainting itself eating GPU cycles. Task manager shows 1% GPU utilization on GTX 780 even when out of focus. To be a good desktop citizen, application should repaint its windows only when required. A quick investigation showed that repaint is configured in the main.cpp:
nanogui::mainloop(250)
I disabled continous refresh rate with:
nonogui::mainloop(0)
GPU utilization dropped to 0.5%, but surprisingly didn't disable repaints completely. Digging further I noticed that glfwWaitEvents in nanogui::mainloop keeps returning every second. This is caused by the constant stream of WM_GETICON messages (verified with Spy++). I couldn't resist to hack glfwWaitEvents to ignore this message:
GPU utilization dropped to 0% after this hack. This is obviously more of a problem of nanogui rather than TEV itself. I'm reporting this just to keep You noted.
The text was updated successfully, but these errors were encountered: