C Specification
The XrFaceExpressionWeights2FB structure is defined as:
// Provided by XR_FB_face_tracking2
typedef struct XrFaceExpressionWeights2FB {
XrStructureType type;
void* next;
uint32_t weightCount;
float* weights;
uint32_t confidenceCount;
float* confidences;
XrBool32 isValid;
XrBool32 isEyeFollowingBlendshapesValid;
XrFaceTrackingDataSource2FB dataSource;
XrTime time;
} XrFaceExpressionWeights2FB;
Members
Description
XrFaceExpressionWeights2FB structure returns the facial expression.
The runtime must return XR_ERROR_VALIDATION_FAILURE
if
weightCount
is not equal to the number of blend shapes defined by the
XrFaceExpressionSet2FB used to create the XrFaceTracker2FB.
The runtime must return XR_ERROR_VALIDATION_FAILURE
if
confidenceCount
is not equal to the number of confidence areas defined
by the XrFaceExpressionSet2FB used to create the
XrFaceTracker2FB.
The runtime must return weights
representing the weights of blend
shapes of current facial expression.
The runtime must update the weights
array ordered so that the
application can index elements using the corresponding facial expression
enum (e.g. XrFaceExpression2FB) as described by
XrFaceExpressionSet2FB when creating the XrFaceTracker2FB.
For example, when the XrFaceTracker2FB is created with
XR_FACE_EXPRESSION_SET2_DEFAULT_FB
, the application sets the
weightCount
to XR_FACE_EXPRESSION2_COUNT_FB
, and the runtime
must fill the weights
array ordered so that it can be indexed by the
XrFaceExpression2FB enum.
The runtime must update the confidences
array ordered so that the
application can index elements using the corresponding confidence area enum
(e.g. XrFaceConfidence2FB) as described by
XrFaceExpressionSet2FB when creating the XrFaceTracker2FB.
For example, when the XrFaceTracker2FB is created with
XR_FACE_EXPRESSION_SET2_DEFAULT_FB
, the application sets the
confidenceCount
to XR_FACE_CONFIDENCE2_COUNT_FB
, and the runtime
must fill the confidences
array ordered so that it can be indexed by
the XrFaceConfidence2FB enum.
The runtime must set isValid
to XR_FALSE
and it must also set
all elements of weights
to zero, if one of the following is true:
-
the face tracker failed to track or lost track of the face
-
the application lost focus
-
the consent for face tracking was denied
-
the runtime is unable to estimate facial expression from the data sources specified when xrCreateFaceTracker2FB function was called
If the returned isValid
is XR_TRUE
, the runtime must return all
weights (or all weights except eyes related weights, see
isEyeFollowingBlendshapesValid
).
The runtime must set isEyeFollowingBlendshapesValid
to XR_FALSE
and it must also set 8 expression weights with prefix
XR_FACE_EXPRESSION2_EYES_LOOK_*
to zero, if one of the following is true:
-
the eye tracking driving blendshapes with prefix
XR_FACE_EXPRESSION2_EYES_LOOK_*
lost track -
the consent for eye tracking was denied
See Also
Document Notes
For more information, see the OpenXR Specification
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright 2014-2024, The Khronos Group Inc.
This work is licensed under a Creative Commons Attribution 4.0 International License.