Search e01
One query across the encyclopedia, books, dictionary, papers, Wikidata and the developer library. Every hit carries its source.
6 results across 6 corpora for XRHitTestResult.
Developer library 6
XRAnchor
nchor: ${error}`); }, ); ``` ## Specifications ## Browser compatibility ## See also - XRAnchorSet - XRFrame.createAnchor() - XRFrame.trackedAnchors - XRHitTestResult.createAnchor()
XRHitTestResult
WebXR Device API The **`XRHitTestResult`** interface of the [WebXR Device API](/docs/Web/API/WebXR_Device_API) contains a single result of a hit test. You can get an array of `XRHitTestResult` objects for a frame by calling XRFrame.getHitTestResults(). ## Instance properties None. ## Instance methods - XRHitTestResult.createAnchor() - : Returns a Promise that resolves with an XRAnchor created from the hit tes
XRHitTestResult: getPose() method
WebXR Device API The **`getPose()`** method of the XRHitTestResult interface returns the XRPose of the hit test result relative to the given base space. ## Syntax ```js-nolint getPose(baseSpace) ``` ### Parameters - `baseSpace` - : An XRSpace to use as the base or origin for computing the relative position and orientation of hit test results. ### Return value Returns an XRPose object. ## Examples ### Getti
XRHitTestResult: createAnchor() method
WebXR Device API The **`createAnchor()`** method of the XRHitTestResult interface creates an XRAnchor from a hit test result that is attached to a real-world object. ## Syntax ```js-nolint createAnchor() ``` ### Parameters None. ### Return value A Promise resolving with an XRAnchor object. ## Examples ### Creating an anchor from a hit test result The following example starts with an XRHitTestResult retrieve
XRFrame
thInformation() - : Returns an XRCPUDepthInformation object containing CPU depth information for the frame. - getHitTestResults() - : Returns an array of XRHitTestResult objects containing hit test results for a given XRHitTestSource. - getHitTestResultsForTransientInput() - : Returns an array of XRTransientInputHitTestResult objects containing hit test results for a given XRTransientInputHitTestSource. - ge
XRFrame: getHitTestResults() method
WebXR Device API The **`getHitTestResults()`** method of the XRFrame interface returns an array of XRHitTestResult objects containing hit test results for a given XRHitTestSource. ## Syntax ```js-nolint getHitTestResults(hitTestSource) ``` ### Parameters - `hitTestSource` - : An XRHitTestSource object that contains hit test subscriptions. ### Return value An array of XRHitTestResult objects. ## Examples ##