Skip to content

Instantly share code, notes, and snippets.

View nicolsc's full-sized avatar

Nicolas Lesconnec nicolsc

  • Paris# - France
View GitHub Profile
@nicolsc
nicolsc / gist:3be93112535051918470
Created June 16, 2014 13:48
ffmpeg - screenshots
ffmpeg -i {file} -f image2 -vf fps=fps=1/{seconds} img%03d.jpg
function mycircle(r,g,b,a,width,height, targetID,canvasContainerID){
/* Default values */
r = r || 0;
g = g ||0;
b = b || 0;
width = width || 100;
height = height || 100;
targetID = targetID || 'canvas';
@nicolsc
nicolsc / draw-a-rectangle
Last active December 17, 2015 12:39
Draw a rectangle in a canvas, and output its "base64". Params : red, green,blue, alpha, width, height, target dom id, container dom id
function myrect(r,g,b,a,width,height, targetID,canvasContainerID){
/* Default values */
r = r || 0;
g = g ||0;
b = b || 0;
width = width || 100;
height = height || 100;
targetID = targetID || 'canvas';