Created
October 25, 2015 00:48
-
-
Save shiffman/57efea78b97bb92011b9 to your computer and use it in GitHub Desktop.
Flipping Video in Processing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import processing.video.*; | |
Capture cam; | |
void setup() { | |
size(640, 480); | |
cam = new Capture(this, 640, 480); | |
cam.start(); | |
} | |
void captureEvent(Capture cam) { | |
cam.read(); | |
} | |
void draw() { | |
pushMatrix(); // just so nothing else is affected | |
scale(-1, 1); | |
image(cam, -cam.width, 0); | |
popMatrix(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment