Interface XRFrame
interface XRFrame {
createAnchor?: (
pose: XRRigidTransform,
space: XRSpace,
) => Promise<XRAnchor>;
detectedMeshes?: XRMeshSet;
detectedPlanes?: XRPlaneSet;
getJointPose?: (joint: XRJointSpace, baseSpace: XRSpace) => XRJointPose;
predictedDisplayTime: number;
session: XRSession;
trackedAnchors?: XRAnchorSet;
getDepthInformation(view: XRView): XRCPUDepthInformation;
getHitTestResults(hitTestSource: XRHitTestSource): XRHitTestResult[];
getHitTestResultsForTransientInput(
hitTestSource: XRTransientInputHitTestSource,
): XRTransientInputHitTestResult[];
getPose(space: XRSpace, baseSpace: XRSpace): XRPose;
getViewerPose(referenceSpace: XRReferenceSpace): XRViewerPose;
}
createAnchor?: (
pose: XRRigidTransform,
space: XRSpace,
) => Promise<XRAnchor>;
detectedMeshes?: XRMeshSet;
detectedPlanes?: XRPlaneSet;
getJointPose?: (joint: XRJointSpace, baseSpace: XRSpace) => XRJointPose;
predictedDisplayTime: number;
session: XRSession;
trackedAnchors?: XRAnchorSet;
getDepthInformation(view: XRView): XRCPUDepthInformation;
getHitTestResults(hitTestSource: XRHitTestSource): XRHitTestResult[];
getHitTestResultsForTransientInput(
hitTestSource: XRTransientInputHitTestSource,
): XRTransientInputHitTestResult[];
getPose(space: XRSpace, baseSpace: XRSpace): XRPose;
getViewerPose(referenceSpace: XRReferenceSpace): XRViewerPose;
}
 Properties
OptionalcreateAnchor 
Optional ReadonlydetectedMeshes 
Optional ReadonlydetectedPlanes 
XRFrame is extended to contain detectedPlanes attribute which contains all planes that are still tracked in the frame.
The set is initially empty and will be populated by the update planes algorithm. If this attribute is accessed when the frame is not active, the user agent MUST throw InvalidStateError.
OptionalgetJointPose  
ReadonlypredictedDisplayTime  
predictedDisplayTime: number
Readonlysession
OptionaltrackedAnchors 
 Methods
getDepthInformation  
- getDepthInformation(view: XRView): XRCPUDepthInformation
- Parameters- view: XRView
 - Returns XRCPUDepthInformation
getHitTestResults   
- getHitTestResults(hitTestSource: XRHitTestSource): XRHitTestResult[]
- Parameters- hitTestSource: XRHitTestSource
 - Returns XRHitTestResult[]
getHitTestResultsForTransientInput      
- getHitTestResultsForTransientInput(
 hitTestSource: XRTransientInputHitTestSource,
 ): XRTransientInputHitTestResult[]
- Parameters- hitTestSource: XRTransientInputHitTestSource
 - Returns XRTransientInputHitTestResult[]
getPose 
getViewerPose  
- getViewerPose(referenceSpace: XRReferenceSpace): XRViewerPose
- Provides the pose of the viewer relative to referenceSpace as an XRViewerPose, at the XRFrame's time. - Parameters- referenceSpace: XRReferenceSpace
 - Returns XRViewerPose
XRFrame is extended to contain detectedMeshes attribute which contains all meshes that are still tracked in the frame.
The set is initially empty and will be populated by the update meshes algorithm. If this attribute is accessed when the frame is not active, the user agent MUST throw InvalidStateError.