Skip to content

Instantly share code, notes, and snippets.

View colinmcardell's full-sized avatar

Colin McArdell colinmcardell

View GitHub Profile
@colinmcardell
colinmcardell / gist:9145656
Created February 21, 2014 23:17
Youtube Stereoscopic on iOS
<!DOCTYPE html>
<html>
<body>
<!-- 1. The <iframe> (and video player) will replace this <div> tag. -->
<div id="player"></div>
<script>
// 2. This code loads the IFrame Player API code asynchronously.
var tag = document.createElement('script');
@colinmcardell
colinmcardell / NSLog replacement (DLog, ALog, ULog).
Created March 7, 2013 21:08
Replacement for NSLog similar to http://www.cimgf.com/2010/05/02/my-current-prefix-pch-file/ This is plenty available elsewhere with a number of variations...
// DLog will output like NSLog only when the DEBUG variable is set
#ifdef DEBUG
#define DLog(fmt, ...) NSLog((@"%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__);
#else
#define DLog(...)
#endif
// ALog will always output like NSLog
#define ALog(fmt, ...) NSLog((@"%s [Line %d] " fmt), __PRETTY_FUNCTION__, __LINE__, ##__VA_ARGS__);