vincent15000's avatar

How to add Augmented Reality in an application ?

How is it possible to add AR in an application ?

I have heard about the WebXR API from Google. Has somebody already used it ? Are there other possibilities ?

Thanks for your answer.

V

0 likes
8 replies
martinbean's avatar

@vincent15000 This is quite a vague question. It’s like asking “Is it possible to add animation in an application?” Well, sure, if you write the code to do so.

1 like
vincent15000's avatar

@martinbean Hmmm ... ok ... It's for an application for treasure hunts.

The treasure hunt owner can take a photo of a place and add a virtual object on it.

When the treasure hunter points his smartphone to the right place, the virtual object appears on the screen.

martinbean's avatar

@vincent15000 This is going to very client-side heavy. You’d probably be better off creating a native app, and using dedicated libraries (i.e. ARKit on iOS) as you’re going to need request permissions for the user’s device camera etc. The only thing a web application is going to be responsible for here is maybe exposing an API that say what objects are at what real world coordinates.

1 like
vincent15000's avatar

@martinbean @jlrdw Thank you both.

I never worked with AR, but I thought that there would probably be more efficient with a native app.

Hum ... well ... ok, I will have a look at all this (native app vs API).

martinbean's avatar

I will have a look at all this (native app vs API).

@vincent15000 It’s not one or the other. You’re not going to create an augmented reality app using an API only. Augmented reality is very much a client-side thing. As I mentioned before, the only thing an API would be used for is to tell the client side where objects are in relation to the real world.

jdc1898's avatar

Maybe a little late to this but NativePHP for iOS and Android may be what you’re looking for! It allows you to use Laravel and interact with the native features like the camera. I don’t KNOW that it will work but it may be a good use case for trying it out. Let us know if you do.

1 like

Please or to participate in this conversation.