public class MockTimingSource extends java.lang.Object implements TimingSource, ChoreographerCompat
ChoreographerCompat.FrameCallback| Modifier and Type | Field and Description |
|---|---|
static int |
FRAME_TIME_MS |
| Constructor and Description |
|---|
MockTimingSource() |
| Modifier and Type | Method and Description |
|---|---|
void |
postFrameCallback(ChoreographerCompat.FrameCallback callbackWrapper) |
void |
postFrameCallbackDelayed(ChoreographerCompat.FrameCallback callbackWrapper,
long delayMillis) |
void |
removeFrameCallback(ChoreographerCompat.FrameCallback callbackWrapper) |
void |
setDataFlowGraph(DataFlowGraph dataFlowGraph) |
void |
start()
Registers the
DataFlowGraph to receive frame callbacks until it calls TimingSource.stop(). |
void |
step(int numFrames) |
void |
stop()
Stops the
DataFlowGraph from receiving frame callbacks. |
public void setDataFlowGraph(DataFlowGraph dataFlowGraph)
setDataFlowGraph in interface TimingSourcepublic void start()
TimingSourceDataFlowGraph to receive frame callbacks until it calls TimingSource.stop().start in interface TimingSourcepublic void stop()
TimingSourceDataFlowGraph from receiving frame callbacks.stop in interface TimingSourcepublic void step(int numFrames)
public void postFrameCallback(ChoreographerCompat.FrameCallback callbackWrapper)
postFrameCallback in interface ChoreographerCompatpublic void postFrameCallbackDelayed(ChoreographerCompat.FrameCallback callbackWrapper, long delayMillis)
postFrameCallbackDelayed in interface ChoreographerCompatpublic void removeFrameCallback(ChoreographerCompat.FrameCallback callbackWrapper)
removeFrameCallback in interface ChoreographerCompat