Class OVRPerfStatsPerCompositorFrame
- All Implemented Interfaces:
org.lwjgl.system.Pointer
All of the int fields can be reset via the ResetPerfStats call.
Layout
struct ovrPerfStatsPerCompositorFrame {
int HmdVsyncIndex();
int AppFrameIndex();
int AppDroppedFrameCount();
float AppMotionToPhotonLatency();
float AppQueueAheadTime();
float AppCpuElapsedTime();
float AppGpuElapsedTime();
int CompositorFrameIndex();
int CompositorDroppedFrameCount();
float CompositorLatency();
float CompositorCpuElapsedTime();
float CompositorGpuElapsedTime();
float CompositorCpuStartToGpuEndElapsedTime();
float CompositorGpuEndToVsyncElapsedTime();
ovrBool AswIsActive();
int AswActivatedToggleCount();
int AswPresentedFrameCount();
int AswFailedFrameCount();
}-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classAn array ofOVRPerfStatsPerCompositorFramestructs.Nested classes/interfaces inherited from class org.lwjgl.system.Struct
org.lwjgl.system.Struct.StructValidationNested classes/interfaces inherited from interface org.lwjgl.system.Pointer
org.lwjgl.system.Pointer.Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe struct alignment in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionOVRPerfStatsPerCompositorFrame(ByteBuffer container) Creates aOVRPerfStatsPerCompositorFrameinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionfloatamount of time in seconds spent on the CPU by the app's render-thread that callsSubmitFrame.intif the app fails to callSubmitFrameon time, then expect this value to increment with each missed frameintindex that increments with each successiveSubmitFramecallfloatamount of time in seconds spent on the GPU by the app.floatmotion-to-photon latency for the applicationfloatamount of queue-ahead in seconds provided to the app based on performance and overlap of CPU and GPU utilization.intIncrements each time ASW it activated where the app was forced in and out of half-rate rendering.intAccumulates the number of frames that the compositor tried to present when ASW is active but failedbooleanWill be true if ASW is active for the given frame such that the application is being forced into half the frame-rate while the compositor continues to run at full frame-rate.intAccumulates the number of frames presented by the compositor which had extrapolated ASW frames presentedfloatthe amount of time in seconds spent on the CPU by the SDK compositor.floatthe amount of time in seconds spent from the point the CPU kicks off the compositor to the point in time the compositor completes the distortion & timewarp on the GPU.intincrements each time the SDK compositor fails to complete in time.intindex that increments each time the SDK compositor completes a distortion and timewarp pass.floatthe amount of time in seconds spent on the GPU by the SDK compositor.floatthe amount of time in seconds left after the compositor is done on the GPU to the associated V-Sync time.floatmotion-to-photon latency of the SDK compositor in seconds.create(long address) Returns a newOVRPerfStatsPerCompositorFrameinstance for the specified memory address.create(long address, int capacity) Create aOVRPerfStatsPerCompositorFrame.Bufferinstance at the specified memory.static @Nullable OVRPerfStatsPerCompositorFramecreateSafe(long address) static @Nullable OVRPerfStatsPerCompositorFrame.BuffercreateSafe(long address, int capacity) intVsync Frame Index - increments with each HMD vertical synchronization signal (i.e.static floatnAppCpuElapsedTime(long struct) Unsafe version ofAppCpuElapsedTime().static intnAppDroppedFrameCount(long struct) Unsafe version ofAppDroppedFrameCount().static intnAppFrameIndex(long struct) Unsafe version ofAppFrameIndex().static floatnAppGpuElapsedTime(long struct) Unsafe version ofAppGpuElapsedTime().static floatnAppMotionToPhotonLatency(long struct) Unsafe version ofAppMotionToPhotonLatency().static floatnAppQueueAheadTime(long struct) Unsafe version ofAppQueueAheadTime().static intnAswActivatedToggleCount(long struct) Unsafe version ofAswActivatedToggleCount().static intnAswFailedFrameCount(long struct) Unsafe version ofAswFailedFrameCount().static booleannAswIsActive(long struct) Unsafe version ofAswIsActive().static intnAswPresentedFrameCount(long struct) Unsafe version ofAswPresentedFrameCount().static floatnCompositorCpuElapsedTime(long struct) Unsafe version ofCompositorCpuElapsedTime().static floatnCompositorCpuStartToGpuEndElapsedTime(long struct) Unsafe version ofCompositorCpuStartToGpuEndElapsedTime().static intnCompositorDroppedFrameCount(long struct) Unsafe version ofCompositorDroppedFrameCount().static intnCompositorFrameIndex(long struct) Unsafe version ofCompositorFrameIndex().static floatnCompositorGpuElapsedTime(long struct) Unsafe version ofCompositorGpuElapsedTime().static floatnCompositorGpuEndToVsyncElapsedTime(long struct) Unsafe version ofCompositorGpuEndToVsyncElapsedTime().static floatnCompositorLatency(long struct) Unsafe version ofCompositorLatency().static intnHmdVsyncIndex(long struct) Unsafe version ofHmdVsyncIndex().intsizeof()Methods inherited from class org.lwjgl.system.Struct
clear, free, isNull, validate, validateMethods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
HMDVSYNCINDEX
public static final int HMDVSYNCINDEXThe struct member offsets. -
APPFRAMEINDEX
public static final int APPFRAMEINDEXThe struct member offsets. -
APPDROPPEDFRAMECOUNT
public static final int APPDROPPEDFRAMECOUNTThe struct member offsets. -
APPMOTIONTOPHOTONLATENCY
public static final int APPMOTIONTOPHOTONLATENCYThe struct member offsets. -
APPQUEUEAHEADTIME
public static final int APPQUEUEAHEADTIMEThe struct member offsets. -
APPCPUELAPSEDTIME
public static final int APPCPUELAPSEDTIMEThe struct member offsets. -
APPGPUELAPSEDTIME
public static final int APPGPUELAPSEDTIMEThe struct member offsets. -
COMPOSITORFRAMEINDEX
public static final int COMPOSITORFRAMEINDEXThe struct member offsets. -
COMPOSITORDROPPEDFRAMECOUNT
public static final int COMPOSITORDROPPEDFRAMECOUNTThe struct member offsets. -
COMPOSITORLATENCY
public static final int COMPOSITORLATENCYThe struct member offsets. -
COMPOSITORCPUELAPSEDTIME
public static final int COMPOSITORCPUELAPSEDTIMEThe struct member offsets. -
COMPOSITORGPUELAPSEDTIME
public static final int COMPOSITORGPUELAPSEDTIMEThe struct member offsets. -
COMPOSITORCPUSTARTTOGPUENDELAPSEDTIME
public static final int COMPOSITORCPUSTARTTOGPUENDELAPSEDTIMEThe struct member offsets. -
COMPOSITORGPUENDTOVSYNCELAPSEDTIME
public static final int COMPOSITORGPUENDTOVSYNCELAPSEDTIMEThe struct member offsets. -
ASWISACTIVE
public static final int ASWISACTIVEThe struct member offsets. -
ASWACTIVATEDTOGGLECOUNT
public static final int ASWACTIVATEDTOGGLECOUNTThe struct member offsets. -
ASWPRESENTEDFRAMECOUNT
public static final int ASWPRESENTEDFRAMECOUNTThe struct member offsets. -
ASWFAILEDFRAMECOUNT
public static final int ASWFAILEDFRAMECOUNTThe struct member offsets.
-
-
Constructor Details
-
OVRPerfStatsPerCompositorFrame
Creates aOVRPerfStatsPerCompositorFrameinstance at the current position of the specifiedByteBuffercontainer. Changes to the buffer's content will be visible to the struct instance and vice versa.The created instance holds a strong reference to the container object.
-
-
Method Details
-
sizeof
public int sizeof()- Specified by:
sizeofin classorg.lwjgl.system.Struct<OVRPerfStatsPerCompositorFrame>
-
HmdVsyncIndex
public int HmdVsyncIndex()Vsync Frame Index - increments with each HMD vertical synchronization signal (i.e. vsync or refresh rate).If the compositor drops a frame, expect this value to increment more than 1 at a time.
-
AppFrameIndex
public int AppFrameIndex()index that increments with each successiveSubmitFramecall -
AppDroppedFrameCount
public int AppDroppedFrameCount()if the app fails to callSubmitFrameon time, then expect this value to increment with each missed frame -
AppMotionToPhotonLatency
public float AppMotionToPhotonLatency()motion-to-photon latency for the applicationThis value is calculated by either using the
SensorSampleTimeprovided for theOVRLayerEyeFovor if that is not available, then the call toGetTrackingStatewhich haslatencyMarkerset toTrue. -
AppQueueAheadTime
public float AppQueueAheadTime()amount of queue-ahead in seconds provided to the app based on performance and overlap of CPU and GPU utilization.A value of 0.0 would mean the CPU & GPU workload is being completed in 1 frame's worth of time, while 11 ms (on the CV1) of queue ahead would indicate that the app's CPU workload for the next frame is overlapping the app's GPU workload for the current frame.
-
AppCpuElapsedTime
public float AppCpuElapsedTime()amount of time in seconds spent on the CPU by the app's render-thread that callsSubmitFrame.Measured as elapsed time between from when app regains control from
SubmitFrameto the next time the app callsSubmitFrame. -
AppGpuElapsedTime
public float AppGpuElapsedTime()amount of time in seconds spent on the GPU by the app.Measured as elapsed time between each
SubmitFramecall using GPU timing queries. -
CompositorFrameIndex
public int CompositorFrameIndex()index that increments each time the SDK compositor completes a distortion and timewarp pass.Since the compositor operates asynchronously, even if the app calls
SubmitFrametoo late, the compositor will kick off for each vsync. -
CompositorDroppedFrameCount
public int CompositorDroppedFrameCount()increments each time the SDK compositor fails to complete in time.This is not tied to the app's performance, but failure to complete can be related to other factors such as OS capabilities, overall available hardware cycles to execute the compositor in time and other factors outside of the app's control.
-
CompositorLatency
public float CompositorLatency()motion-to-photon latency of the SDK compositor in seconds.This is the latency of timewarp which corrects the higher app latency as well as dropped app frames.
-
CompositorCpuElapsedTime
public float CompositorCpuElapsedTime()the amount of time in seconds spent on the CPU by the SDK compositor.Unless the VR app is utilizing all of the CPU cores at their peak performance, there is a good chance the compositor CPU times will not affect the app's CPU performance in a major way.
-
CompositorGpuElapsedTime
public float CompositorGpuElapsedTime()the amount of time in seconds spent on the GPU by the SDK compositor. Any time spent on the compositor will eat away from the available GPU time for the app. -
CompositorCpuStartToGpuEndElapsedTime
public float CompositorCpuStartToGpuEndElapsedTime()the amount of time in seconds spent from the point the CPU kicks off the compositor to the point in time the compositor completes the distortion & timewarp on the GPU.In the event the GPU time is not available, expect this value to be -1.0f.
-
CompositorGpuEndToVsyncElapsedTime
public float CompositorGpuEndToVsyncElapsedTime()the amount of time in seconds left after the compositor is done on the GPU to the associated V-Sync time.In the event the GPU time is not available, expect this value to be -1.0f.
-
AswIsActive
public boolean AswIsActive()Will be true if ASW is active for the given frame such that the application is being forced into half the frame-rate while the compositor continues to run at full frame-rate. -
AswActivatedToggleCount
public int AswActivatedToggleCount()Increments each time ASW it activated where the app was forced in and out of half-rate rendering. -
AswPresentedFrameCount
public int AswPresentedFrameCount()Accumulates the number of frames presented by the compositor which had extrapolated ASW frames presented -
AswFailedFrameCount
public int AswFailedFrameCount()Accumulates the number of frames that the compositor tried to present when ASW is active but failed -
create
Returns a newOVRPerfStatsPerCompositorFrameinstance for the specified memory address. -
createSafe
-
create
Create aOVRPerfStatsPerCompositorFrame.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
public static @Nullable OVRPerfStatsPerCompositorFrame.Buffer createSafe(long address, int capacity) -
nHmdVsyncIndex
public static int nHmdVsyncIndex(long struct) Unsafe version ofHmdVsyncIndex(). -
nAppFrameIndex
public static int nAppFrameIndex(long struct) Unsafe version ofAppFrameIndex(). -
nAppDroppedFrameCount
public static int nAppDroppedFrameCount(long struct) Unsafe version ofAppDroppedFrameCount(). -
nAppMotionToPhotonLatency
public static float nAppMotionToPhotonLatency(long struct) Unsafe version ofAppMotionToPhotonLatency(). -
nAppQueueAheadTime
public static float nAppQueueAheadTime(long struct) Unsafe version ofAppQueueAheadTime(). -
nAppCpuElapsedTime
public static float nAppCpuElapsedTime(long struct) Unsafe version ofAppCpuElapsedTime(). -
nAppGpuElapsedTime
public static float nAppGpuElapsedTime(long struct) Unsafe version ofAppGpuElapsedTime(). -
nCompositorFrameIndex
public static int nCompositorFrameIndex(long struct) Unsafe version ofCompositorFrameIndex(). -
nCompositorDroppedFrameCount
public static int nCompositorDroppedFrameCount(long struct) Unsafe version ofCompositorDroppedFrameCount(). -
nCompositorLatency
public static float nCompositorLatency(long struct) Unsafe version ofCompositorLatency(). -
nCompositorCpuElapsedTime
public static float nCompositorCpuElapsedTime(long struct) Unsafe version ofCompositorCpuElapsedTime(). -
nCompositorGpuElapsedTime
public static float nCompositorGpuElapsedTime(long struct) Unsafe version ofCompositorGpuElapsedTime(). -
nCompositorCpuStartToGpuEndElapsedTime
public static float nCompositorCpuStartToGpuEndElapsedTime(long struct) Unsafe version ofCompositorCpuStartToGpuEndElapsedTime(). -
nCompositorGpuEndToVsyncElapsedTime
public static float nCompositorGpuEndToVsyncElapsedTime(long struct) Unsafe version ofCompositorGpuEndToVsyncElapsedTime(). -
nAswIsActive
public static boolean nAswIsActive(long struct) Unsafe version ofAswIsActive(). -
nAswActivatedToggleCount
public static int nAswActivatedToggleCount(long struct) Unsafe version ofAswActivatedToggleCount(). -
nAswPresentedFrameCount
public static int nAswPresentedFrameCount(long struct) Unsafe version ofAswPresentedFrameCount(). -
nAswFailedFrameCount
public static int nAswFailedFrameCount(long struct) Unsafe version ofAswFailedFrameCount().
-