Skip to content

Instantly share code, notes, and snippets.

View xwipeoutx's full-sized avatar

Steve Leigh xwipeoutx

View GitHub Profile
xwipeoutx / generate-icons.js
Last active December 14, 2020 22:19
Generates all the UWP icons with sensible naming, based of a couple initial files.
let imageConversion = require("image-conversion");
var fs = require("fs");
let jimp = require("jimp");
let ImageJs = require("image-js");
let output = "public/images/icon";
const scales = [100, 125, 150, 200, 240, 400];
const iconTargetSizes = [16,24,32,48,256];
const iconTargetDecorations = ['unplated_targetsize', 'targetsize'];
using System.IO;
using System.Linq;
using System.Text;
using System.Xml;
using UnityEditor;
using UnityEditor.Build;
using UnityEditor.Build.Reporting;
using UnityEngine;
namespace Project.Scripts.Editor
xwipeoutx / ar-hello-world-astronaut.html
Last active August 8, 2020 11:40
Hello, World of WebXR - an astronaut in your living room.
<title>Model Viewer Example</title>
<script type="module" src=""></script>
<script nomodule src=""></script>
<model-viewer src=""
ar ar-modes="webxr scene-viewer quick-look" ar-scale="auto" camera-controls
alt="A 3D model of an astronaut"
export async function getParcel(coords: {lat: number, lng: number}): Promise<Feature> {
let url = `${coords.lng}%2C${}&geometryType=esriGeometryPoint&inSR=4326&spatialRel=esriSpatialRelIntersects&outFields=*&returnGeometry=true&outSR=4326&f=geojson`
let response = await fetch(url);
let collection = await response.json();
return (collection && collection.features[0]) || null;
xwipeoutx /
Last active May 8, 2024 14:31
XR Tech Interview Questions

XR specific tech interview

AR / VR / MR / XR

  • Explain what is AR / VR / XR / MR, how are they connected? Why would you choose one over another?
  • Your client is saying "I want a HoloLens app that can do X".  How do you qualify if they're wasting their money?
  • Tell me about some logistical implications of this tech in the enterprise?
  • How does developing an XR app differ from a traditional 2D or 3D game / app?
  • Specifically, what are some downsides to translucent displays (HoloLens, Magic Leap), and how do you accommodate for them?
xwipeoutx /
Last active December 21, 2018 01:52
Setting up for mixed reality

If you want to prepare your PC beforehand, I would

  • Install Unity Hub. This handled multiple Unity versions on the same PC and is a life saver
  • Install the latest Unity from (whatever it happens to be - there won't be any major releases soon AFAIK). Include all the UWP/Windows store things and the IL2CPP scripting engine support
    • If you're more interested in doing AR for the tablet or phone, then install those SDKs too - it's really up to you what you want to get out of it
    • Careful with the installer and it telling you to install VS 2018. There's a checklist here - but I wouldn't worry about the emulator. It sucks.
  • Do a quick "Hello, world"
  • -or- do my old "Hello, world!" tutorial (I will

Git Extensions

Path to mergetool:

C:/Program Files/SourceGear/Common/DiffMerge/sgdm.exe

Mergetool command:

"C:/Program Files/SourceGear/Common/DiffMerge/sgdm.exe" /m /r="$MERGED" "$LOCAL" "$BASE" "$REMOTE"
xwipeoutx / validate-accessibility.js
Created October 21, 2016 00:34
(function() {
var invalidElementFinders = {
"Lists should have titles": () => Array.from(document.querySelectorAll("ul,li")).filter(el => !el.title),
"Articles should be aria-labelledby": () => Array.from(document.querySelectorAll("article")).filter(el => !el.getAttribute("aria-labelledby")),
var validateAccessibility = function () {
Array.from(document.querySelectorAll("*")).forEach(el => {
if (el.problems) delete el.problems
xwipeoutx / Car.cs
Created June 6, 2016 13:01
Simple, clean, fast IQueryable filter with expression chaining in C#
using System;
namespace ExpressionChainDemo
public class Car
public DateTime RegistrationDate { get; set; }
public DateTime PurchaseDate { get; set; }