webxr | Repository for the WebXR Device API Specification | Augmented Reality library

 by   immersive-web JavaScript Version: CRS-20220331 License: Non-SPDX

kandi X-RAY | webxr Summary

kandi X-RAY | webxr Summary

webxr is a JavaScript library typically used in Virtual Reality, Augmented Reality applications. webxr has no bugs, it has no vulnerabilities and it has medium support. However webxr has a Non-SPDX License. You can download it from GitHub.

The WebXR device API is for accessing virtual reality (VR) and augmented reality (AR) devices, including sensors and head-mounted displays on the Web. The WebXR Device API Specification is the repository of the Immersive Web Working Group.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              webxr has a medium active ecosystem.
              It has 2454 star(s) with 346 fork(s). There are 302 watchers for this library.
              OutlinedDot
              It had no major release in the last 12 months.
              There are 51 open issues and 625 have been closed. On average issues are closed in 48 days. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of webxr is CRS-20220331

            kandi-Quality Quality

              webxr has 0 bugs and 0 code smells.

            kandi-Security Security

              webxr has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              webxr code analysis shows 0 unresolved vulnerabilities.
              There are 0 security hotspots that need review.

            kandi-License License

              webxr has a Non-SPDX License.
              Non-SPDX licenses can be open source with a non SPDX compliant license, or non open source licenses, and you need to review them closely before use.

            kandi-Reuse Reuse

              webxr releases are available to install and integrate.
              Installation instructions are not available. Examples and code snippets are available.

            Top functions reviewed by kandi - BETA

            kandi has reviewed webxr and discovered the below as its top functions. This is intended to give you an instant insight into webxr implemented functionality, and help decide if they suit your requirements.
            • Write output to the temporary directory .
            • Check error and process errors
            Get all kandi verified functions for this library.

            webxr Key Features

            No Key Features are available at this moment for webxr.

            webxr Examples and Code Snippets

            No Code Snippets are available at this moment for webxr.

            Community Discussions

            QUESTION

            Integrating Google's with React/Reagent
            Asked 2022-Mar-17 at 14:59

            Google's provides all the key features I need without having write a custom solution via something like react-three-fiber or directly in three.js.

            I am struggling with how to properly integrate it into a Reagent (and React for that matter) structure.

            In order to make it easy to use with vanilla JS, is built as a web component and is largely controlled via the attributes on its html element. Normally that wouldn't be much of a problem, but with the overhead of 3D and loading large models re-rendering this is expensive and in many cases functionality-breaking.

            I've tried to naively use it inside a component and trying to eliminate the possibility of re-rendering. Using a ref to mutate it directly.

            I have also tried setting it up as a manually created html element from the Reagent/React controlled application and reference it in various events via its dom element.

            Both of these options introduced a lot of hacks and were not ideal in a single page application.

            I am wondering if anyone has any tips on how to best wrap this in a React/Reagent shell, while still having access to the core element to use their underlying JS api.

            Answers don't have to be in ClojureScript.

            Here is the example of its usage from their page:

            ...

            ANSWER

            Answered 2022-Mar-17 at 14:59
            1. Include it in your index.html as a module type script.

            Source https://stackoverflow.com/questions/71512752

            QUESTION

            Is it possible to build an AR App, with a VR display wrapper, for mobile devices, using Javascript?
            Asked 2022-Mar-11 at 00:28

            thanks kindly for your time and attention. I recognise this is a long shot but I'm hoping someone might be generous enough to relay some advice or guidance. I am in the beginning phases of researching how I might build an app for a mobile device, using javascript and related tools, libraries and packages. The concept for the app is that it will access the device camera, recognise faces, and overlay animated AR assets onto the device display. However, I want users to couple their phone with a wearable headset, and use the app through a split screen VR style display. I assume I'll need some sort of VR wrapper for the core AR application. At the moment, I am focussed primarily on the graphical display and UI aspects, so that I can build a proof-of-concept to test whether the idea is even viable. I recognise I may be misguided to attempt this in javascript rather than native mobile languages - if this is the case, I would welcome any opinions on the matter. I'm asking about javascript because that's what I know, basically.

            Thus far, I've been reading about various libraries such as WebXR, Three.js and others. I assume I'll need to use React Native, though it's not easy to get a clear sense of whether I should even be trying to achieve what I want using javascript. I have no code to show as yet.

            Additionally, I recognise there are similar questions already posted to the forum - for example, this one: VR+AR on mobile phone. I haven't found any recent threads that address this specific set of requirements so I do apologise if I've missed something. If there is info on the forum, grateful if someone could point me to the relevant thread. At the very least, thanks for reading. Cheers, all.

            ...

            ANSWER

            Answered 2022-Mar-11 at 00:28

            I found Snap's Lens Studio extremely intuitive and powerful. It provides templates for feature recognition, tracking, and physics. It also provides advanced controls for custom creative. I would also expect it to receive future feature development support. It can be monetized.

            ...or do you want to expose yourself to more computer vision terminology and patterns? Try searching CodePen or CodeSandbox for features such as: MediaPipe, OpenCV, face detection webcam. But the overhead of a VR/AR app is probably best described in an O'Reilly book or John Carmack keynote speech. Topics like pupil distance, foot tracking, and predictive tracking.

            Source https://stackoverflow.com/questions/71420441

            QUESTION

            How to share WebXR Anchors over the network?
            Asked 2022-Mar-10 at 10:32

            I'm trying to share anchors from WebXR over the network with other clients. However, they only have one property, anchorSpace, which itself doesn't have any properties:

            ...

            ANSWER

            Answered 2022-Mar-10 at 10:32

            Anchors are currently explicitly not-persistent or sharable. - @AdaRoseCannon (Feb 9, 2022) in https://github.com/immersive-web/anchors/issues/71#issuecomment-1033705978

            Source https://stackoverflow.com/questions/70010943

            QUESTION

            GL_OUT_OF_MEMORY using A-frame to display stereoscopic images
            Asked 2022-Jan-19 at 23:49

            I've created a proof-of-concept SPA (source code / demo) which loads stereoscopic images from a web server and renders them in stereoscopic 3D using the aframe-stereo-component for A-frame.

            Testing this on a Quest 2 in the Oculus Browser and Firefox Reality, this works fine: each image appears in 3D when viewed in immersive VR mode via WebXR.

            However, after scrolling through a number of images (usually 8 to 12), the slideshow stops working. In Firefox Reality, this manifests by the app just freezing and becoming unresponsive.

            In Oculus Browser, the image description is displayed but the image area remains black. Connecting the Quest 2 to a PC with adb and inspecting the page using Chrome DevTools, I can see the following output when this occurs:

            ...

            ANSWER

            Answered 2021-Oct-04 at 09:18

            The asset management system (a-assets) is intended to help with preloading assets, not throwing them in and out at runtime.

            Removing the element from the assets won't dispose the texture (which is cached within the material system).

            You can access and clear the cache, but I'd try managing the images 'manually',

            • loading the image via new THREE.Texture(src) like the material system does

            • apply the material with

            Source https://stackoverflow.com/questions/69432820

            QUESTION

            I keep seeing 'XRWebGLLayer' is not defined no-undef' when using three.js in react.js to create WebXR app
            Asked 2021-Oct-11 at 06:42

            I'm trying to use WebXR using Three.js in React but I keep seeing this error:

            'XRWebGLLayer' is not defined no-undef

            for baseLayer: new XRWebGLLayer(session, gl)

            I tried this same code in vanilla.js and had no errors at all but when I try it with react.js it doesn't compile.

            The tutorials I'm referring to are: https://developers.google.com/ar/develop/webxr/hello-webxr and https://www.devbridge.com/articles/ar-app-development-tutorial/

            I'm using version 0.133 of three.js and I imported it into my react app using: import * as THREE from 'three';

            I'm relatively new to react and three.js. Can anyone please help point me in the right direction? I'd really appreciate it!!

            ...

            ANSWER

            Answered 2021-Oct-11 at 06:42

            XRWebGLLayer is available in the window object.

            Also refer:
            https://stackoverflow.com/a/62264777/4290781

            Source https://stackoverflow.com/questions/69518179

            QUESTION

            Google Chrome version 91 causing legacy JSP with Struts to lose data and formatting
            Asked 2021-Jun-11 at 18:03

            UPDATE IN ANSWER BELOW

            Is anyone else experiencing the newest couple versions of chrome causing issues with legacy Java applications? Just yesterday I needed to get the company's policy manager to allow downloading files from an internal unsecured server by adding our URLs to a whitelist - you can see the details of the process on the chromium blog here. That issue was present in v90 as well.

            What I'm currently experiencing due to the v91 update is as follows: My boss was trying to use a page in one of our Java 6 legacy applications and he noticed that the page wouldn't return the data in any format - we checked and he was already v91. I was on v90 and the page worked fine. After updating Chrome to v91, I'm getting the same broken page as my boss.

            I was thinking it might be something related to the CSS but I don't have time to poke at it and redeploy the legacy app every time to test the changes. Though, I have taken a peek at this chromium blog post for version 91. Though I don't see much relating to what may have caused the removal of all non-label fields and the formatting of the label fields are all wonky and out of place.

            I'm going to look into investigating the struts tile that holds the code JSP code; if I find something I'll post it here for reference.

            The first image below is what one row should look like with the header above it. As you see in the second picture, all there is the header with improper formatting and the grid is gone.

            ...

            ANSWER

            Answered 2021-Jun-10 at 21:45

            I have determined the problem to be the

            here tag. In the newest version (v91) of Chrome, the table rendering engine has been rewritten. the notes are here and if you want the in-depth documentation, is the link to the Google Doc that the developers wrote. Basically, the old way of rendering tables has become obsolete and the

            Workaround: Disable the chrome flag named Enable TableNG and restart your browser.

            Addition: I found chromestatus, a website that shows new features being added, deprecations, etc.

            tag is now defunct.

            Source https://stackoverflow.com/questions/67829181

            QUESTION

            How to mirror/clone a WebXR 'immersive-xr' HMD view to the browser
            Asked 2021-May-11 at 12:46

            How would one go about mirroring or cloning the WebXR 'immersive-xr' view from a HMD like the VIVE or Oculus in the browser using the same WebGL canvas?

            There is much discussion about copying the pixels to a texture2D, then applying that as a render texture, or completely re-drawing the entire scene with an adjusted viewTransform. These work well if you are rendering a different view, such as a remote camera or 3rd person spectator view, however both are a waste of resources if one only wants to mirror the current HMD view on the desktop.

            Self answered below as there was no solid answer when I ran into this and I'd like to save future devs the time. (Especially if they're not all to savvy with WebGl2 and WebXR)

            Note, that I'm not using any existing frameworks for this project for 'reasons'. It shouldn't change much if you are, you'd just need to perform the steps at the appropriate place in your library's render pipeline.

            ...

            ANSWER

            Answered 2021-May-11 at 12:46

            The answer is delightfully simple as it turns out, and barely hits my fps.

            1. Attach the canvas to the DOM and set it to your desired size. (Mine was fluid, so had a CSS width of 100% of it's parent container with a height of auto)
            2. When you initialize your glContext, be sure to specify that antialiasing is false. This is important if your spectator and HMD views are to be different resolutions.{xrCompatible: true, webgl2: true, antialias: false}
            3. create a frameBuffer that will be used to store your rendered HMD view. spectateBuffer
            4. Draw your immersive-xr layer as usual in your xrSession.requestAnimationFrame(OnXRFrame); callback
            5. Just prior to exiting your OnXRFrame method, implement a call to draw the spectator view. I personally used a bool showCanvas to allow me to toggle the spectator mirror on and off as desired:

            Source https://stackoverflow.com/questions/67487066

            QUESTION

            How to solve "addEventListener" TypeError of null in ReactJS?
            Asked 2021-Apr-16 at 07:38

            I am trying to use Google's model viewer to load 3D models. It has a button. But I want that button to be visible after the model is completely loaded. So, I used to use this Vanilla JavaScript code

            ...

            ANSWER

            Answered 2021-Apr-15 at 22:57

            You need to control element within a React wrapper. See react-model-viewer, this is is their wrapper

            Source https://stackoverflow.com/questions/67107461

            QUESTION

            How to use a collada model with aframe-v1.1.0.min
            Asked 2021-Feb-17 at 22:51

            I have been using a-frame since 2018 to show my scenographies to the directors I work for. I used the colladas files for my objects and everything was working great and my textures were as I wanted. But since the webxr (aframe-v1.1.0.min) appeared it is no longer possible to use collada I have tried the Gltf files but it is too heavy and not satisfactory. So I wanted to know how to put collada back into the a-frame scipts. I tried: "collada-model-legacy.js" with "ColladaLoader.js" in another folder but it doesn't work. Do you have a solution? Thank you

            ...

            ANSWER

            Answered 2021-Feb-17 at 22:51

            You can use any of the loaders from the three.js repository - also the ColladaLoader.

            You could create a wrapper component, which will use threejs loader and add the model to the scene:

            Source https://stackoverflow.com/questions/66196396

            QUESTION

            A-Frame: parent's raycaster-intersected-cleared triggered if no intersection with children
            Asked 2021-Feb-15 at 02:53

            I'm implementing a feature to get coordinate of an a-sky while moving the VR controller.

            ...

            ANSWER

            Answered 2021-Feb-15 at 02:53

            It turns out that raycaster-intersected-cleared event from parent element is fired but it does not mean that it is not intersected anymore. To confirm if it has been still intersected I have to check if getIntersection result is NULL.

            Source https://stackoverflow.com/questions/66100319

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install webxr

            You can download it from GitHub.

            Support

            AnchorsComputer VisionGeo AlignmentLighting EstimationNavigationPerformance ImprovementsReal World GeometrySpatial FaviconsDepth SensingWebXR WebGPU Binding
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/immersive-web/webxr.git

          • CLI

            gh repo clone immersive-web/webxr

          • sshUrl

            git@github.com:immersive-web/webxr.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular Augmented Reality Libraries

            AR.js

            by jeromeetienne

            ar-cutpaste

            by cyrildiagne

            aframe

            by aframevr

            engine

            by playcanvas

            Awesome-ARKit

            by olucurious

            Try Top Libraries by immersive-web

            webvr-polyfill

            by immersive-webJavaScript

            webxr-samples

            by immersive-webHTML

            webxr-polyfill

            by immersive-webJavaScript

            webxr-input-profiles

            by immersive-webJavaScript

            webvrrocks

            by immersive-webHTML