Skip to content

Instantly share code, notes, and snippets.

@ryankee
ryankee / CMakeLists.txt
Created November 14, 2016 18:19
Cinder CMake
cmake_minimum_required(VERSION 3.0)
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
include("Cinder.cmake")
project( Calibrator )
include_directories(${CMAKE_SOURCE_DIR}/src)
@ryankee
ryankee / cinder.rb
Created July 20, 2015 16:57
Cinder Homebrew
class Cinder < Formula
desc "Example formula" # shows up in `brew info`, and can be searched with `brew search --desc`.
homepage "http://libcinder.org" # used by `brew home example-formula`.
# The URL of the archive. Prefer https (security and proxy issues):
url "http://libcinder.org/releases/cinder_0.8.6_mac.zip"
url "[email protected]:cinder/Cinder.git", :using => :git, :tag => "v0.8.6"
# version is seldom needed, because it's usually autodetected from the URL/tag.
version "0.8.6"
@ryankee
ryankee / libfreenect2.rb
Last active August 29, 2015 14:25
LibFreenect2
require "formula"
class Libfreenect2 < Formula
desc "Drivers/Example for Kinect V2"
homepage "https://github.com/OpenKinect/libfreenect2"
head "https://github.com/OpenKinect/libfreenect2.git"
url "https://github.com/OpenKinect/libfreenect2/archive/master.zip"
sha256 "29cc2002eaed822de73fee904f064f2f61438e946192b0e39e272ee713250d78"
version "0.0.1"
@ryankee
ryankee / thrift_serializer.py
Created November 5, 2014 17:25
Thrift python serializer
import json
class ThriftDictSerializer:
@staticmethod
def serialize(instance):
specs = instance.thrift_spec
obj = {}
for spec in specs:
_grabkey() {
curl -s -S "https://api.github.com/users/$1/keys" | grep 'key' | awk '{c=$3; gsub(/\"/,"",c); print c}'
}
alias grabkey=_grabkey
class BuenaVista extends LandBlock
constructor: (containerElement)->
super containerElement
@name = 'buena_vista'
@background = new BuenaVistaBackground("#buena_vista_background")
@title = new BuenaVistaTitle("#buena_vista_description")
@buildings = new BuenaVistaBuildings("#buena_vista_buildings")
@trees = new BuenaVistaTrees("#buena_vista_trees")
@bg_details = new BuenaVistaBgDetails("#buena_vista_bg_details")
@trolley = new BuenaVistaTrolley("#buena_vista_trolley")
set guioptions-=e
set guioptions-=e
set showtabline=0