Hi guys, I have a scene where I’m using the FilterManager as a way to chain FBOs to do some shader tricks. I originally thought the FBOs were the reason for some slowdown as I was doing per-pixel shader work. However, I checked PStats and found something interesting. Right now, I get a significant spike in Wait:Flip:End only when I maximize my window–what is this exactly? When searching through the forums I found things such as v-sync being the cause, but I have that disabled.
I’m guessing here, but does your windowing system animate the transition to full-screen? If so, perhaps the program–or at least rendering–is suspended while that animation happens.
Yes. Also, I should’ve definitely clarified in my original post that there is also a noticeable slowdown going forward from when the window is made fullscreen.
You should enable pstats-gpu-timing to find out.
Time spent here means that the CPU is waiting for the GPU. If this occurs especially when enlarging the window, it suggests that pixel fill is your bottleneck: more pixels are being rendered, your fragment shader is now getting run more often and now the CPU is submitting work faster than the GPU is able to render it, and therefore it has to wait on the GPU so that it doesn’t keep piling on more and more work.
The CPU charts are a poor way of measuring actual GPU activity, which happens asynchronously from the submission of the commands on the CPU end. Therefore, you should enable pstats-gpu-timing 1
in Config.prc and see if you can learn more from the GPU timing charts.
Using a development build of Panda may help, since the PStats profiling has improved significantly on the master branch.
Thank you both for your help