People often ask (this article only discusses the Android platform):
“What on earth is the frame rate tested using PerfDog? Whose frame rate does it test?”
“How to test the frame rate of mini-games?”
“How to test the frame rate of mini-programs?”
“How to test the frame rate of traditional APPs?”
“How to test the frame rate of web?”
“Also, how to test the frame rate of games?”
These questions are really difficult to answer in one word. We need to first make clear what the Android window is. I will brief it below. If you still do not understand some details, please Baidu the SurfaceFliger.
From the viewpoint of main categories, usually for an Android main window Activity and its corresponding View, there is a special View such as SurfaceView. It can use a dedicated Surface and will not share Surface with the main window. The independent rendering is very efficient and supports OpenglES rendering. That is to say, two types of window FPS may occur. One is the frame rate of Activity window and the other is that of SurfaceView window.
Under what conditions may both types of windows occur? Usually both types of windows may occur for the types of Apps such as games, live broadcasting, video streaming and mini-games. In particular cases, multiple Activities and multiple SurfaceViews may occur, which cause great difficulties to perform the statistics of frame rate. Thus, it needs a strategy to acquire the frame rate.
For the types of Apps such as games, live broadcasting, video and mini-games, the PerfDog acquires the FPS of SurfaceView by default. For the other traditional or Web Apps, it will acquire the frame rate of Activity.
Meanwhile, the high-order functions of PerfDog supports the user to select the frame rate of window type by the user itself. Especially for the mini-programs and mini-games, etc., it can more precisely test the frame rate of target window as shown in below figure (WeChat Mini Game – Fight the Landlord):
For the types of Apps such as mini-games, live broadcasting, video and games, please select the SurfaceView.