Pablo Ceballos | ce796e7 | 2016-02-04 19:10:51 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2016 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 | |
| 17 | #ifndef ANDROID_GUI_FRAMETIMESTAMPS_H |
| 18 | #define ANDROID_GUI_FRAMETIMESTAMPS_H |
| 19 | |
| 20 | #include <utils/Timers.h> |
| 21 | #include <utils/Flattenable.h> |
| 22 | |
| 23 | namespace android { |
| 24 | |
Brian Anderson | 069b365 | 2016-07-22 10:32:47 -0700 | [diff] [blame^] | 25 | enum class SupportableFrameTimestamps { |
| 26 | REQUESTED_PRESENT, |
| 27 | ACQUIRE, |
| 28 | REFRESH_START, |
| 29 | GL_COMPOSITION_DONE_TIME, |
| 30 | DISPLAY_PRESENT_TIME, |
| 31 | DISPLAY_RETIRE_TIME, |
| 32 | RELEASE_TIME, |
| 33 | }; |
Pablo Ceballos | ce796e7 | 2016-02-04 19:10:51 -0800 | [diff] [blame] | 34 | |
Brian Anderson | 069b365 | 2016-07-22 10:32:47 -0700 | [diff] [blame^] | 35 | struct FrameTimestamps : public LightFlattenablePod<FrameTimestamps> { |
| 36 | uint64_t frameNumber{0}; |
| 37 | nsecs_t requestedPresentTime{0}; |
| 38 | nsecs_t acquireTime{0}; |
| 39 | nsecs_t refreshStartTime{0}; |
| 40 | nsecs_t glCompositionDoneTime{0}; |
| 41 | nsecs_t displayPresentTime{0}; |
| 42 | nsecs_t displayRetireTime{0}; |
| 43 | nsecs_t releaseTime{0}; |
Pablo Ceballos | ce796e7 | 2016-02-04 19:10:51 -0800 | [diff] [blame] | 44 | }; |
| 45 | |
| 46 | } // namespace android |
| 47 | #endif |