Skip to content

Instantly share code, notes, and snippets.

View ktamas77's full-sized avatar
🏠
Working from home

Tamas Kalman ktamas77

🏠
Working from home
View GitHub Profile
@pingud98
pingud98 / Graphicequal
Created October 9, 2013 22:53
Graphic equaliser in processing (equalizer)
/**
Hacked together from the minim tutorial examples
**/
import ddf.minim.analysis.*;
import ddf.minim.*;
Minim minim;
//AudioPlayer jingle;
FFT fftLin;
@clayton
clayton / ffmpeg-install.sh
Created August 9, 2013 18:55
Install FFMPEG on OS X with HomeBrew to convert Mp4 to WebM
# Installation
brew install ffmpeg --with-vpx --with-vorbis --with-libvorbis --with-vpx --with-vorbis --with-theora --with-libogg --with-libvorbis --with-gpl --with-version3 --with-nonfree --with-postproc --with-libaacplus --with-libass --with-libcelt --with-libfaac --with-libfdk-aac --with-libfreetype --with-libmp3lame --with-libopencore-amrnb --with-libopencore-amrwb --with-libopenjpeg --with-openssl --with-libopus --with-libschroedinger --with-libspeex --with-libtheora --with-libvo-aacenc --with-libvorbis --with-libvpx --with-libx264 --with-libxvid
# Easy Peasy
ffmpeg -i video.mp4 video.webm
@XueshiQiao
XueshiQiao / gource.sh
Last active November 10, 2019 15:56 — forked from cgoldberg/gource.sh
Generate a MP4 Video for your Git project commits using Gource!
# 1.install gource using HomeBrew
$ brew install gource
# 2.install avconv
git clone git://git.libav.org/libav.git
cd libav
# it will take 3-5 minutes to complie, be patient.
./configure --disable-yasm
make && make install
#include "sha1.h"
#include <SoftwareSerial.h>
SoftwareSerial SerialRNXV(2, 3);
int irVal = 0;
int distOn = 0; // getting distance
const int ms = 1; // unit of milliseconds
bool authed = false;
@mbeale
mbeale / gist:4741709
Last active December 12, 2015 08:08
Complete example for PHP Recurly.js BuildSubscriptionForm
<?php
require_once('recurlyphp/lib/recurly.php');
// Required for the API
Recurly_Client::$subdomain = 'yoursubdomain'
Recurly_Client::$apiKey = 'apikey';
Recurly_js::$privateKey = 'privatekey';
$signature = Recurly_js::sign(array('account'=>array('account_code'=>'aaa1234588'),'subscription' => array(
'plan_code' => 'plan_trial',
@ryanjbonnell
ryanjbonnell / gist:4074061
Last active November 26, 2021 13:40
Install PHP APC on Mac OS X 10.8 "Mountain Lion"
# Compile PCRE - Perl Compatible Regular Expressions
cd /usr/local/src
curl -O ftp://ftp.csx.cam.ac.uk//pub/software/programming/pcre/pcre-8.31.tar.gz
tar -xvzf pcre-8.31.tar.gz
cd pcre-8.31
./configure
make
sudo make install
# Compile Autoconf
@nikcub
nikcub / README.md
Created October 4, 2012 13:06
Facebook PHP Source Code from August 2007
@mathiasverraes
mathiasverraes / phplint.sh
Created July 12, 2012 07:42
Recursive PHP Lint script
#!/bin/bash
for file in `find .`
do
EXTENSION="${file##*.}"
if [ "$EXTENSION" == "php" ] || [ "$EXTENSION" == "phtml" ]
then
RESULTS=`php -l $file`
@kevcao
kevcao / phplog
Created July 6, 2012 00:51
phplog
#!/usr/bin/php
<?php
print_r($argv);
if (count($argv) < 3) {
die("wrong number of arguments\n");
}
@hellerbarde
hellerbarde / latency.markdown
Created May 31, 2012 13:16 — forked from jboner/latency.txt
Latency numbers every programmer should know

Latency numbers every programmer should know

L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns             
Compress 1K bytes with Zippy ............. 3,000 ns  =   3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns  =  20 µs
SSD random read ........................ 150,000 ns  = 150 µs

Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs