Skip to content

Instantly share code, notes, and snippets.

Richard Copperwaite DashW

  • United Kingdom
Block or report user

Report or block DashW

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
DashW / RecenterResetter.cs
Last active Dec 10, 2019
Unity Behaviour to counteract 're-centering' on the Oculus Quest and keep the camera centered relative to the Guardian Boundaries
View RecenterResetter.cs
using UnityEngine;
// This behaviour disables 're-centering' on the Oculus Quest,
// instead forcing the camera origin to remain centered and
// facing the same direction within the Guardian boundaries,
// even between app restarts.
public class RecenterResetter : MonoBehaviour
public OVRCameraRig CameraRig = null;
DashW / PlayableVideoAsset.cs
Created Oct 24, 2018
Scrubbable Video Player Track for Unity Timeline
View PlayableVideoAsset.cs
using UnityEngine;
using UnityEngine.Playables;
using UnityEngine.Video;
public class PlayableVideoAsset : PlayableAsset
public ExposedReference<VideoClip> Clip = new ExposedReference<VideoClip>();
public float Offset;
private double _duration;
DashW / TriplanarNormal.shader
Created Oct 19, 2016
Unity Normal-Mapped Triplanar Texturing Shader
View TriplanarNormal.shader
Shader "Tri-Planar World Normal" {
_Color("Main Color", Color) = (1,1,1,1)
_Side("Side", 2D) = "gray" {}
_Top("Top", 2D) = "gray" {}
_Bottom("Bottom", 2D) = "gray" {}
_SideScale("Side Scale", Float) = 2
_TopScale("Top Scale", Float) = 2
_BottomScale("Bottom Scale", Float) = 2
_BumpMapSide("Side Normal Map", 2D) = "bump" {}
DashW / ScreenRecorder.cs
Last active May 22, 2020
ScreenRecorder - High Performance Unity Video Capture Script
View ScreenRecorder.cs
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)
You can’t perform that action at this time.