Objective: Enable avatars and objects to move between virtual worlds.
Ranking implementations on a sliding scale of interoperability.
// sensor via https://wiki.postmarketos.org/wiki/PINE64_PinePhone_(pine64-pinephone)#Sensors | |
const x_path = "/sys/bus/iio/devices/iio:device3/in_accel_x_raw" | |
const y_path = "/sys/bus/iio/devices/iio:device3/in_accel_y_raw" | |
const z_path = "/sys/bus/iio/devices/iio:device3/in_accel_z_raw" | |
var fs = require("fs"); | |
var express = require('express'); | |
var app = express(); | |
// could be WSS but fast enough on LAN as-is |
AFRAME.registerComponent('outline-geometry', { | |
schema : { | |
margin : { default : 1.025 }, | |
color: { default : 'red' }, | |
}, | |
init : function () { | |
var p = this.el; | |
var p_prime = p.cloneNode(true); | |
p_prime.removeAttribute('outline-geometry') | |
p_prime.setAttribute('material', 'color', this.data.color) |
#ifndef UNITY_STANDARD_BRDF_INCLUDED | |
#define UNITY_STANDARD_BRDF_INCLUDED | |
#include "UnityCG.cginc" | |
#include "UnityStandardConfig.cginc" | |
#include "UnityLightingCommon.cginc" | |
//------------------------------------------------------------------------------------- | |
// Legacy, to keep backwards compatibility for (pre Unity 5.3) custom user shaders: | |
#define unity_LightGammaCorrectionConsts_PIDiv4 (IsGammaSpace()? (UNITY_PI/4)*(UNITY_PI/4): (UNITY_PI/4)) |
using UnityEngine; | |
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Threading; | |
class BitmapEncoder | |
{ | |
public static void WriteBitmap(Stream stream, int width, int height, byte[] imageData) |
--# Main | |
-- Component System by Utsira. uses runtime mix-ins to add component's methods to entities (ie not a pure entity - component - system model). | |
-- TO USE: | |
-- Entity is a superclass that adds the method :add, for adding (including) components to game objects(entities). | |
-- Components are tables, but use : to name their methods. | |
-- If component has an iterator table then it is a system. Iterate will run through every entity that is part of that system | |
-- If component has an :init function, this will not be added to the entity, but will instead be run when the component is added | |
-- Use this function to perform your initial setup | |
function setup() |
/* | |
Delta Compression by Glenn Fiedler. | |
This source code is placed in the public domain. | |
http://gafferongames.com/2015/03/14/the-networked-physics-data-compression-challenge/ | |
*/ | |
#include <stdint.h> | |
#include <stdio.h> | |
#include <assert.h> | |
#include <string.h> |
Patch for Myo Unity package for SDK Windows 0.8.0 to access EMG raw data. |
// Copyright Lee Grey, 2014 | |
// License: MIT | |
module lg.tileSystem { | |
import Vector2D = lg.math.geometry.Vector2D; | |
export class FieldInfo { | |
distanceFromTarget: number = -1; |