/illuminate-xr

A framework for creating and self-hosting networked VR and AR experiences using Laravel and A-Frame.

Primary LanguageBladeMIT LicenseMIT

This is an alpha-stage project. Please do not use it, yet.

Illuminate XR

Software License Travis Total Downloads

Build your next app UI with WebVR/WebXR using A-Frame, and self-host "multiplayer" networked experiences using Laravel WebSockets. This Laravel package aims to provide:

  • Patterns for creating reactive VR UI, powered by Vue and A-Frame
  • Laravel WebSockets pre-configured for self-hosting fast, scalable networked experiences
  • Familiar and comfortable networked experiences including Lobbies and Rooms
  • Use Cashier to charge credit cards and manage paid subscriptions
  • Use Socialite to allow visitors to login using their social media accounts and many other providers
  • Add an API to your project using Passport, and allow your users to have and manage profiles
  • Catalog and preview scene assets using Twill as your CMS

While the focus of this project is currently on building experiences for VR, the goal is to eventually expand that scope to support AR solutions as well, hence the X in Illuminate XR.

Why VR, and why now?

Dramatically increased by the Coronavirus pandemic of 2020, the demand for remote collaboration calls on creatives to give birth to novel ways of fostering connection across distances. There is ample space in that greenfield project for immersive experiences that connect people with each other and interact with new and old ideas on an emotional, even visceral level—a level of connection that cannot be achieved just by talking to a grid of faces displayed on a monitor.

Why Laravel?

Laravel is a popular web application framework written in PHP. It's also a community, comprised of many thousands of developers all around the world. My experiences using Laravel to build enterprise software inspired me to provide similarly "opinionated" patterns and packaged solutions for deploying XR, to enable the consumption of content—not just VR content, but all kinds of content, services, and even products, delivered through VR—and for fostering more and better collaboration online.

When setting out to build an XR experience, a developer shouldn't have to consume such a large breadth of information just to be able to get started. Great projects like A-Frame gave a web geek like me the ability to start rapidly iterating in VR, even building experiences I could explore using my Oculus headset.

Illuminate XR should allow you to easily trace those really difficult first steps I took, and be able to create robust, collaborative, VR experiences almost as quickly as you can imagine them. My goal is for this project to help keep the creative space in VR democratic and open. After all, that's the way the web should be.

Install

Because it's a Laravel package, you need to create a local Laravel app to install Illuminate XR into. The best place to learn about setting up Laravel is the manual.

Note that while Laravel includes a built-in webserver for developing locally, if you plan to use the networking features of this package, you'll need to use Valet, Homestead, or some other proper webserver.

You can install XR into any Laravel 6.0+ application:

composer require illuminate/xr

Then, publish the package's config into your own project. If you've never worked with Laravel before, note that the artisan command is how you use Laravel's CLI.

php artisan vendor:publish --provider="Illuminate\Xr\XrServiceProvider" --tag="config" 

Usage

The best way to learn how to use the features of this package is to explore the examples, but before you do, make sure you enable the examples in your copy of config/xr.php:

<?php

return [
  
  'examples' => true, // Set to true to enable example experiences
  
];

If you can't find your copy of config/xr.php in your project it's because you skipped the asset publishing step above.

Once you've enabled the examples, just visit the URL /xr/examples in your app. Happy creating!

Contributing

Please see CONTRIBUTING for details.

Security

If you discover any security-related issues, please email aaron@collegeman.net instead of using the issue tracker.

License

The MIT License (MIT). Please see License File for more information.