Skip to content

Instantly share code, notes, and snippets.

View smukkejohan's full-sized avatar

Johan Bichel Lindegaard smukkejohan

View GitHub Profile
@kylemcdonald
kylemcdonald / index.html
Last active August 7, 2022 18:14
Google Cloud Vision API testing from Frontend
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>vision-test</title>
<script src="libraries/p5.js" type="text/javascript"></script>
<script src="libraries/p5.dom.js" type="text/javascript"></script>
<script src="libraries/p5.sound.js" type="text/javascript"></script>
@kylemcdonald
kylemcdonald / SeeneViewer.cpp
Last active October 11, 2017 18:20
Seene Viewer with C++ in openFrameworks.
// Based on https://github.com/detunized/seene-viewer
#include "ofMain.h"
inline bool ends_with(std::string const & value, std::string const & ending)
{
if (ending.size() > value.size()) return false;
return std::equal(ending.rbegin(), ending.rend(), value.rbegin());
}
@ramontayag
ramontayag / gist:6308461
Last active June 10, 2016 10:51
Raspberry Pi setup with BitTorrent Sync

First boot

  • Expand storage
  • Start desktop
  • Reboot

Continue by plugging the LAN cable, then in the router admin panel, find the IP address of the pi. Connect:

ssh pi@ipaddress
/*
* Modified from WiFlyHQ Example httpclient.ino
*
* This sketch implements a simple Web client that connects to a
* web server, sends a GET, and then sends the result to the
* Serial monitor.
*
* This sketch is released to the public domain.
*
*/
@SquidLord
SquidLord / turtleLib.lua
Last active February 6, 2016 18:16
turtleLib: A core set of tool libraries for ComputerCraft turtles
-- turtleLib: A core set of tool libraries for ComputerCraft turtles
-- by Alexander "SquidLord" Williams (SaladinVrai)
-- Gist: https://gist.github.com/SquidLord/4755840
-- Put in turtle startup file with:
-- os.loadAPI("squid/turtleLib")
-- The MIT License (MIT)
@companje
companje / QuadWarp.cpp
Created November 18, 2012 13:57
QuadWarping with openFrameworks
#include "ofMain.h"
#include "ofAppGlutWindow.h"
class testApp : public ofBaseApp {
public:
ofImage img;
ofPoint corners[4];
int selectedCorner;
@adamgit
adamgit / .gitignore
Last active August 20, 2024 10:33
.gitignore file for Xcode4 / OS X Source projects
#########################
# .gitignore file for Xcode4 and Xcode5 Source projects
#
# Apple bugs, waiting for Apple to fix/respond:
#
# 15564624 - what does the xccheckout file in Xcode5 do? Where's the documentation?
#
# Version 2.6
# For latest version, see: http://stackoverflow.com/questions/49478/git-ignore-file-for-xcode-projects
#
@OlliV
OlliV / disable_OS_X_NotificationCenter.txt
Created July 26, 2012 19:56
Disable that annoying NotificationCenter on OS X Mountain Lion
launchctl unload /System/Library/LaunchAgents/com.apple.notificationcenterui.plist
sudo mv /System/Library/LaunchAgents/com.apple.notificationcenterui.plist /System/Library/LaunchAgents/com.apple.notificationcenterui.bak
@gereon
gereon / gist:3150445
Created July 20, 2012 12:20
Mac OSX Spotlight Enhancement

Mac OSX Spotlight Enhancement

Add this to Info.plist in /System/Library/Spotlight/RichText.mdimporter/Contents/ and Spotlight will search for source code files.

<string>public.c-header</string>
<string>public.c-plus-plus-header</string>
<string>public.c-source</string>
<string>public.objective-c-source</string>
public.c-plus-plus-source
@tacoe
tacoe / gist:2900840
Created June 9, 2012 12:38
::open behavior sketch
// ...
SoftwareSerial wifiSerial(8,9);
WiFly wifly;
// ...
void setupWifi() {
wifiSerial.begin(9600);