Skip to content

Instantly share code, notes, and snippets.

- (void) applicationDidFinishLaunching:(UIApplication*)application
{
// create our rendering timer
[self performSelectorOnMainThread:@selector(mainGameLoop) withObject:nil waitUntilDone:NO];
}
- (void) mainGameLoop
{
while (gameRunning)
{
#pragma mark -
#pragma mark DisplayLinkDirector
// Allows building DisplayLinkDirector for pre-3.1 SDKS
// without getting compiler warnings.
@interface NSObject(CADisplayLink)
+ (id) displayLinkWithTarget:(id)arg1 selector:(SEL)arg2;
- (void) addToRunLoop:(id)arg1 forMode:(id)arg2;
- (void) setFrameInterval:(int)interval;
/*
File: Reachability.h
Abstract: SystemConfiguration framework wrapper.
Version: 1.5
Disclaimer: IMPORTANT: This Apple software is supplied to you by Apple Inc.
("Apple") in consideration of your agreement to the following terms, and your
use, installation, modification or redistribution of this Apple software
/* Copyright (c) 2010 Robert Blackwood
*
* Based upon Box2d's b2PulleyJoint equations:
* Copyright (c) 2007 Erin Catto http://www.gphysics.com
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
@reklis
reklis / fetch.htm
Created October 7, 2010 00:07
broken bmp decoding
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>fetch</title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" type="text/javascript"></script>
<!-- http://code.google.com/p/explorercanvas/ -->
<!--[if IE]><script src="excanvas.compiled.js" type="text/javascript"></script><![endif]-->
<script src="texture2d.js" type="text/javascript"></script>
@reklis
reklis / fetch.htm
Created October 8, 2010 01:56
working bmp decoding
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>fetch</title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js" type="text/javascript"></script>
<script src="jquery.base64.min.js" type="text/javascript"></script>
<!--[if IE]><script src="excanvas.compiled.js" type="text/javascript"></script><![endif]-->
<script src="texture2d.js" type="text/javascript"></script>
<script type="text/javascript">
@reklis
reklis / edit-map.diff
Created September 22, 2011 13:50
SVG map changes
diff --git a/ElectionMeterDemo/Images/Map.svg b/ElectionMeterDemo/Images/Map.svg
index 46ccbd3..4b73095 100644
--- a/ElectionMeterDemo/Images/Map.svg
+++ b/ElectionMeterDemo/Images/Map.svg
@@ -11,9 +11,10 @@
height="593"
id="svg2"
sodipodi:version="0.32"
- inkscape:version="0.46"
- sodipodi:docname="United States WIP.svg"
@reklis
reklis / build.sh
Created September 30, 2011 15:42
Archive post-action
#in older versions of Xcode4 you may need to set PRODUCT_NAME manually
DIST_LIST=<TestFlight Distribution List name here>
API_TOKEN=<TestFlight API token here>
TEAM_TOKEN=<TestFlight team token here>
SIGNING_IDENTITY="iPhone Distribution: Development Seed"
PROVISIONING_PROFILE="${HOME}/Library/MobileDevice/Provisioning Profiles/MapBox Ad Hoc.mobileprovision"
LOG="/tmp/testflight.log"
DATE=$( /bin/date +"%Y-%m-%d" )
@reklis
reklis / svgtextelement.patch
Created November 4, 2011 14:29
SVG Text Element parsing
diff --git a/Core/SVGParser.m b/Core/SVGParser.m
index a2a3106..7726901 100644
--- a/Core/SVGParser.m
+++ b/Core/SVGParser.m
@@ -23,6 +23,7 @@
#import "SVGPolylineElement.h"
#import "SVGRectElement.h"
#import "SVGTitleElement.h"
+#import "SVGTextElement.h"
@reklis
reklis / osx-10.7-Xcode-4.2.1.diff
Created February 13, 2012 15:38
Cinder full build on osx 10.7 Xcode 4.2.1
diff --git a/xcode/cinder.xcodeproj/project.pbxproj b/xcode/cinder.xcodeproj/project.pbxproj
index fad0215..e66892c 100644
--- a/xcode/cinder.xcodeproj/project.pbxproj
+++ b/xcode/cinder.xcodeproj/project.pbxproj
@@ -3,7 +3,7 @@
archiveVersion = 1;
classes = {
};
- objectVersion = 45;
+ objectVersion = 46;