1/*
2 * Copyright (C) 2020 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 *      http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17syntax = "proto2";
18
19package perfetto.protos;
20
21message AndroidDisplayMetrics {
22  // Stat that reports the number of duplicate frames submitted
23  // to the display for rendering. That is frames that have the same
24  // pixels values but where still submitted. It is tracked based on
25  // comparing the MISR of the current frame vs previous frame.
26  optional uint32 total_duplicate_frames = 1;
27
28  // Stat reports whether there is any duplicate_frames tracked
29  optional uint32 duplicate_frames_logged = 2;
30
31  // Stat that reports the number of dpu underrrun occurs count.
32  optional uint32 total_dpu_underrun_count = 3;
33
34
35  message RefreshRateStat {
36    // The refresh rate value (the number of frames per second)
37    optional uint32 refresh_rate_fps = 1;
38
39    // Calculate the number of refresh rate switches to this fps
40    optional uint32 count = 2;
41
42    // Calculate the total duration of refresh rate stays at this fps
43    optional double total_dur_ms = 3;
44
45    // Calculate the average duration of refresh rate stays at this fps
46    optional double avg_dur_ms = 4;
47  }
48
49  // Calculate the total number of refresh rate changes
50  optional uint32 refresh_rate_switches = 4;
51
52  // The statistics for each refresh rate value
53  repeated RefreshRateStat refresh_rate_stats = 5;
54}
55