public final class VideoFrameReleaseTimeHelper
extends java.lang.Object
| Constructor and Description |
|---|
VideoFrameReleaseTimeHelper()
Constructs an instance that smooths frame release timestamps but does not align them with
the default display's vsync signal.
|
VideoFrameReleaseTimeHelper(android.content.Context context)
Constructs an instance that smooths frame release timestamps and aligns them with the default
display's vsync signal.
|
| Modifier and Type | Method and Description |
|---|---|
long |
adjustReleaseTime(long framePresentationTimeUs,
long unadjustedReleaseTimeNs)
Adjusts a frame release timestamp.
|
void |
disable()
Disables the helper.
|
void |
enable()
Enables the helper.
|
public VideoFrameReleaseTimeHelper()
public VideoFrameReleaseTimeHelper(@Nullable
android.content.Context context)
context - A context from which information about the default display can be retrieved.public void enable()
public void disable()
public long adjustReleaseTime(long framePresentationTimeUs,
long unadjustedReleaseTimeNs)
framePresentationTimeUs - The frame's presentation time, in microseconds.unadjustedReleaseTimeNs - The frame's unadjusted release time, in nanoseconds and in
the same time base as System.nanoTime().System.nanoTime().