sublambda / arkit-web

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ARKit Web

An experimental iOS app for rapidly prototyping ARKit experiences with WebGL.

Shadows demo Anchors demo

Features

  • Metal rendering for Camera feed
  • WebGL library free - use whatever graphics library you prefer
  • Rapid prototyping using ngrok and Safari web inspector tools
  • Simple JavaScript API for configuring ARKit and subscribing to events

Example

import ARKit from './arkit/arkit';
import ARConfig from './arkit/config';

/* Turn on features */
ARConfig.imageFrame = true;
ARConfig.pointCloud = true;

/* Get latest frame data */
ARKit.on('frame', data => {});

Requirements

  • iOS11 (currently in beta and can be installed from here)
  • A device which has A9 and A10 processors

We recommend any of the following devices: iPad (2017), iPad Pro, iPhone 7 and 7 Plus.

Implemented

Getting started

This project is comprised of two parts:

  1. A native iOS app that configures ARKit and exposes the frame data to a WKWebView layer.
  2. A series of demos showing the features of ARKit and how to utilise the data with threejs.

Installation

  1. Open your terminal and navigate to the arkit-web/Demos directory
  2. If you don't have yarn globally run npm i yarn --global
  3. Install the project dependencies by running yarn

Tasks

  • yarn start - Start the dev server.
  • yarn tunnel - Start an ngrok connection for live development

Check Demos/package.json for the other available tasks.

Demos

Each demo contains instructions for setting up and running.

Debugging

Use the Safari Technology Preview web inspector tools.

Resources

License

MIT

About

License:MIT License


Languages

Language:Swift 81.3%Language:Metal 14.0%Language:C 4.1%Language:Objective-C 0.6%