1
General discussions / Low frame rate for about 10 instances
« on: February 09, 2017, 02:51:26 pm »
HI
I am using SFML for a game, and I have developed it for months, now I have everything ready to put things on the scene, but when there are about 10 instances on the scene, the game almost freezes. for fewer instances everything is fine, and I get a very smooth 60 FPS. My approach to the problem was to use a profiling program called very sleepy, which gives me how much each function uses the CPU. so after running the game alongside very sleepy I noticed, the most Consuming functions are
these two functions use 80 percent of the total CPU the program uses, and I haven't written them, they are not part of SFML too.
my most consuming function only uses about 0.02%.
I should mention that my laptop has 16 GB of RAM, and my CPU and GPU handle most advanced games, so hardware should not be a problem...
What should I do?
I am using SFML for a game, and I have developed it for months, now I have everything ready to put things on the scene, but when there are about 10 instances on the scene, the game almost freezes. for fewer instances everything is fine, and I get a very smooth 60 FPS. My approach to the problem was to use a profiling program called very sleepy, which gives me how much each function uses the CPU. so after running the game alongside very sleepy I noticed, the most Consuming functions are
- RtlSubscribeWnfStateChangeNotification : 72%
- DwmFlush 8%
these two functions use 80 percent of the total CPU the program uses, and I haven't written them, they are not part of SFML too.
my most consuming function only uses about 0.02%.
I should mention that my laptop has 16 GB of RAM, and my CPU and GPU handle most advanced games, so hardware should not be a problem...
What should I do?