Skip to content

Instantly share code, notes, and snippets.

@rcolinray
rcolinray / gl_ffmpeg.cpp
Created November 19, 2013 20:54
OpenGL-FFMpeg integration
// Use OpenGL 3.0+, but don't use GLU
#define GLFW_INCLUDE_GL3
#define GLFW_NO_GLU
#include <GL/glfw.h>
#include <glm/glm.hpp>
#include <glm/gtc/matrix_transform.hpp>
#include <glm/gtc/type_ptr.hpp>
extern "C" {
@jvcleave
jvcleave / distccd-rpi.plist
Last active April 30, 2024 06:27
mac distcc install instructions
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>distccd-rpi</string>
<key>Program</key>
<string>/Users/YOUR_USER_NAME/Scripts/launchd-distccd.sh</string>
<key>RunAtLoad</key>
<true/>
@tealtan
tealtan / instructions.md
Last active December 30, 2016 15:07
Custom Twitter stylesheet

Custom Twitter Stylesheet

Craig Mod does a bigger overhaul with Twitter for Minimalists, but this will only do the following:

  • Hides promoted tweets and trends
  • Hides the useless “Expand” link that appears under every tweet
  • Tones down the blue conversation line to a barely-visible gray
  • Hides all numbers

You can add this CSS in Safari with this extension. The URL to target is twitter.com/*.

@danomatika
danomatika / Makefile.iphone
Created July 2, 2013 17:15
FreeImage Makefile for iOS updated for newer version of XCode, tested with OSX 10.8 & XCode 4.6
# Configuration for iPhone OS, builds static libs for iOS and the iOSSimulator
#
# You can make a fat lib (iOS + iOSSimulator) using lipo:
# lipo -c libfreeimage-simulator.a libfreeimage-armv7.a -o libfreeimage.a
#
# Example: build & link fat lib for armv6, armv7, armv7s, & simulator
#
# make -f Makefile.iphone
# sed -i tmp "s|ARCH_PHONE =.*|ARCH_PHONE = armv7s|" Makefile.iphone
# make -f Makefile.iphone
@danomatika
danomatika / Makefile.osx
Created July 2, 2013 17:13
FreeImage Makefile for Mac OSX updated to build 32/64 bit fat libs, tested with OSX 10.8 & XCode 4.6
# Configuration for Max OSX, builds fat 32/64 bit static & dynamic libs
include Makefile.srcs
# Update this based on your installed SDKs
MACOSX_SDK = 10.8
MACOSX_MIN_SDK = 10.6
# Find SDK path via xcode-select, backwards compatible with Xcode vers < 4.5
MACOSX_SYSROOT = $(shell xcode-select -print-path)/Platforms/MacOSX.platform/Developer/SDKs/MacOSX$(MACOSX_SDK).sdk
@jkosoy
jkosoy / gist:5379904
Last active September 6, 2024 08:51
Raspberry Pi setup

Raspberry Pi setup

Just wanted a quick start guide for myself so that I wouldn't have to keep rooting through Google to remember all this stuff. Hopefully it helps other people.

If you had other ideas or suggestions please leave a comment.

Useful things to own before you buy a Pi

The first time I bought a Pi I was enormously frustrated with myself because I didn't own all of this stuff. Kept having to order things off of Amazon and wait to get started... very irritating. This is all good stuff to have laying around anyway:

@jkosoy
jkosoy / .bash_profile
Last active October 13, 2015 02:38
Bash Profile Settings.
alias ls='ls -GFh'
export CLICOLOR=1
# From Andrzej Szelachowski's ~/.bash_profile:
# Note that a variable may require special treatment
#+ if it will be exported.
DARKGRAY='\[\e[1;30m\]'
@ofZach
ofZach / gitignore OF
Created September 12, 2012 14:41
good gitignore for OF
# Some general ignore patterns
build/
obj/
*.o
Debug*/
Release*/
*.mode*
*.app/
*.pyc
.svn/
@companje
companje / subdivide-tetrahedron.cpp
Created August 4, 2012 16:21
Subdivide a tetrahedron to a sphere with ofMesh in openFrameworks
#include "ofMain.h"
#include "ofAppGlutWindow.h"
class ofApp : public ofBaseApp {
public:
ofMesh mesh;
ofEasyCam cam;
void setup() {
@companje
companje / cloud-alpha-shader.cpp
Created July 19, 2012 18:26
Earth with Clouds AlphaBlending Shader
//testApp.cpp
#include "ofMain.h"
class testApp : public ofBaseApp {
public:
ofShader shader;
ofImage earth,clouds;
ofEasyCam cam;
GLUquadricObj *quadric; //for gluSphere