Skip to content

Instantly share code, notes, and snippets.

View fjenett's full-sized avatar
💤
(offline)

Florian Jenett fjenett

💤
(offline)
View GitHub Profile
@fjenett
fjenett / get_3d_positions_event.pde
Last active August 29, 2015 11:29
Find "3D Positions" event for a video
/**
* fjenett - 2015
*/
import org.piecemaker2.api.*;
import org.piecemaker2.models.*;
import java.util.Properties;
import java.util.Date;
@fjenett
fjenett / get_api_key.pde
Last active August 28, 2015 17:38
Get Piecemaker2 API Key
/**
* Piecemaker basics:
* logging in and how to retrieve the API KEY
*
* fjenett 2015
*/
import org.piecemaker2.api.*;
import org.piecemaker2.models.*;
import java.util.Properties;
@fjenett
fjenett / apiservice.js
Created April 12, 2015 11:20
Using Piecemeta API node.js client
var PMApi = require('piecemeta-apiclient');
var ls_apiKey, ls_access_token;
var authService = (function(){
var auth = {
api_key : null,
access_token : null,
getCredentials : function () {
@fjenett
fjenett / .gitignore
Last active August 29, 2015 14:18
Piecemeta API with Processing
.DS_Store
@fjenett
fjenett / pm2_api_example_dhay_data.pde
Last active August 29, 2015 14:18
Example showing how to load 3D path from Piecemaker2
/**
* Motion Bank research, http://motionbank.org/
*
* Example of how to load a 3D path through Piecemaker2 API
*/
import org.piecemaker2.api.*;
import org.piecemaker2.models.*;
PieceMakerApi api;
@fjenett
fjenett / VLCPlayer.java
Last active August 29, 2015 14:18
Example showing how to load a video from Piecemaker2 API
/**
* VLC player bindings
*
* https://github.com/caprica/vlcj
* http://capricasoftware.co.uk/#/projects/vlcj/tutorial/direct-rendering
*
* 2.2.0 did not work, using 2.1.5 on OS-X:
* http://download.videolan.org/pub/videolan/vlc/2.1.5/macosx/
*/
@fjenett
fjenett / .gitignore
Last active June 13, 2018 18:54
Dockerfile for react.js / Sass app based on brunch.io
.DS_Store
@fjenett
fjenett / sketch.js
Created May 4, 2013 10:54
Testing Rhino, Processing and Underscore interplay.
// make sure Processing core.jar is in your CLASSPATH
// download and put underscore.js next to this file
// pass the working directory as first argument:
// $ java org.mozilla.javascript.tools.shell.Main sketch.js "`pwd`"
var currentDir = arguments[0] || '.',
sketchWidth = 320,
sketchHeight = 240,
sketchName = 'Underscore test',
sketchProto = null,
@fjenett
fjenett / gist:4181328
Created December 1, 2012 09:44
Renumber / rename a bunch of JPGs
for f in *.jpg; do ff=`echo $f | sed 's/.jpg//' | sed 's/^0*//'`; ff=$(( $ff - 85 )); ff=$( printf '%06s' $ff ); echo $ff; mv $f $ff.jpg; done
@fjenett
fjenett / gist:3979612
Created October 30, 2012 10:58
Simple JavaCV example in Processing
/**
* JavaCV in Processing 2.0b5 on MacBook with 64bit
*
* OpenCV from MacPorts:
* - /opt/local/macports/macports.conf needs to have "build_arch" to be set to x86_64
* - now just do: sudo port install opencv
*
* Sketch has the .jar files from this download inside "code" folder (just drag-drop them on sketch window):
* - http://code.google.com/p/javacv/downloads/detail?name=javacv-0.2-bin.zip
*/