diff options
Diffstat (limited to 'services/surfaceflinger/DispSync.h')
-rw-r--r-- | services/surfaceflinger/DispSync.h | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/services/surfaceflinger/DispSync.h b/services/surfaceflinger/DispSync.h index 67142b6..61d891b 100644 --- a/services/surfaceflinger/DispSync.h +++ b/services/surfaceflinger/DispSync.h @@ -26,11 +26,8 @@ namespace android { // Ignore present (retire) fences if the device doesn't have support for the -// sync framework, or if all phase offsets are zero. The latter is useful -// because it allows us to avoid resync bursts on devices that don't need -// phase-offset VSYNC events. -#if defined(RUNNING_WITHOUT_SYNC_FRAMEWORK) || \ - (VSYNC_EVENT_PHASE_OFFSET_NS == 0 && SF_VSYNC_EVENT_PHASE_OFFSET_NS == 0) +// sync framework. +#if defined(RUNNING_WITHOUT_SYNC_FRAMEWORK) static const bool kIgnorePresentFences = true; #else static const bool kIgnorePresentFences = false; @@ -149,11 +146,18 @@ private: // number of nanoseconds from time 0 to the first vsync event. nsecs_t mPhase; + // mReferenceTime is the reference time of the modeled vsync events. + // It is the nanosecond timestamp of the first vsync event after a resync. + nsecs_t mReferenceTime; + // mError is the computed model error. It is based on the difference // between the estimated vsync event times and those observed in the // mPresentTimes array. nsecs_t mError; + // Whether we have updated the vsync event model since the last resync. + bool mModelUpdated; + // These member variables are the state used during the resynchronization // process to store information about the hardware vsync event times used // to compute the model. |