Skip to content

Instantly share code, notes, and snippets.

View lux's full-sized avatar

John Luxford lux

View GitHub Profile
@lux
lux / gif-to-mp4.sh
Created January 9, 2018 15:59
Quick script ot convert a folder of gifs to mp4 with web-optimal settings (note: requires ffmpeg)
#!/bin/bash
for i in *.gif; do
ffmpeg -i "$i" -movflags faststart -pix_fmt yuv420p -vf "scale=trunc(iw/2)*2:trunc(ih/2)*2" "${i%.*}.mp4";
done
@lux
lux / SketchSystems.spec
Last active February 28, 2019 20:35
Camera System
Camera System
POV*
Cut to Camera N -> Camera N
Move to Camera N -> Camera N
Camera N
Cut to POV -> POV
Move to POV -> POV
Cut to Camera N -> Camera N
Move to Camera N -> Camera N
// <auto-generated>
// automatically generated by the FlatBuffers compiler, do not modify
// </auto-generated>
namespace Data
{
using global::System;
using global::FlatBuffers;
@lux
lux / QuaternionCompression.cs
Created November 12, 2019 22:50 — forked from StagPoint/QuaternionCompression.cs
C# - Use "smallest three" compression for transmitting Quaternion rotations in Unity's UNET networking, from 16 bytes to 7 bytes.
// Copyright (c) 2016 StagPoint Software
namespace StagPoint.Networking
{
using System;
using UnityEngine;
using UnityEngine.Networking;
/// <summary>
/// Provides some commonly-used functions for transferring compressed data over the network using