简体   繁体   中英

LWJGL Framerate Locked with Nvidia GPU


So all I did was copy the code from LWJGL website's Get Started page, and add small code to count the fps. On doing so I realized that with Intel GPU the frame rate is not capped and I get around 500 FPS.

But when I change the GPU to Nvidia, the frame rate gets capped to 30 FPS.....

I did some research and most articles said that it might be due to V-Sync(weird because I have 240Hz monitor), which I turned off and it is still is capped to 30.

How can I prevent it from capping? Please help.

The information I got on the console is :

Nvidia GPU :

Hello LWJGL 3.2.3 build 13!
----------------------------
OpenGL Version : 4.6.0 NVIDIA 441.20
OpenGL Vendor : NVIDIA Corporation
OpenGL Renderer : GeForce RTX 2070 with Max-Q Design/PCIe/SSE2
----------------------------
FPS : 32
FPS : 30
FPS : 30

Intel GPU:

Hello LWJGL 3.2.3 build 13!
----------------------------
OpenGL Version : 4.5.0 - Build 25.20.100.6519
OpenGL Vendor : Intel
OpenGL Renderer : Intel(R) UHD Graphics 630
----------------------------
FPS : 385
FPS : 455
FPS : 572
FPS : 570

Thanks for taking the time. :)

Turns out, there was nothing wrong in the code. Nvidia caps frame rate to 30 by itself to preserve battery.

To prevent this you can remove the cap from Nvidia GForce Experience.

Credit: https://youtu.be/TP_tvuUb_NA

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM