diff options
-rw-r--r-- | .gitignore | 40 | ||||
-rw-r--r-- | dev/a1_textrain/a1_textrain.pde | 15 |
2 files changed, 22 insertions, 33 deletions
@@ -1,20 +1,20 @@ -.DS_Store* - -# These directories are meant for installing files generated inside the dev/ directory -# They are in the git repo only so that students will checkout the intended directory -# structure from the start, but we do not want to add anything inside them to git. -# So, we ignore all files inside the directories except for a README. - -bin/* -!bin/README.md - -include/* -!include/README.md - -lib/* -!lib/README.md - -share/* -!share/README.md - -.vscode +.DS_Store*
+
+# These directories are meant for installing files generated inside the dev/ directory
+# They are in the git repo only so that students will checkout the intended directory
+# structure from the start, but we do not want to add anything inside them to git.
+# So, we ignore all files inside the directories except for a README.
+
+bin/*
+!bin/README.md
+
+include/*
+!include/README.md
+
+lib/*
+!lib/README.md
+
+share/*
+!share/README.md
+
+.vscode
diff --git a/dev/a1_textrain/a1_textrain.pde b/dev/a1_textrain/a1_textrain.pde index f1b7456..2db8c36 100644 --- a/dev/a1_textrain/a1_textrain.pde +++ b/dev/a1_textrain/a1_textrain.pde @@ -86,7 +86,7 @@ void draw() { // DRAW THE INPUTIMAGE ACROSS THE ENTIRE SCREEN
// Note, this is like clearing the screen with an image. It will cover up anything drawn before this point.
// So, draw your text rain after this!
- inputImage.filter(GRAY);
+ inputImage.filter(GRAY);
set(0, 0, inputImage);
loadPixels();
//Debug toggle
@@ -98,18 +98,7 @@ void draw() { pixels[k]=color(255);
}
}
- }
-
- for (int i=0;i<inputImage.width-1;i++) {
- for (int j=0;j<inputImage.height-1;j++) {
- color swap;
- swap=pixels[i+j*inputImage.width];
- println(red(pixels[i+j*inputImage.width]));
- println(red(pixels[(inputImage.width-i)+j*inputImage.width]));
- pixels[i+j*inputImage.width]=pixels[(inputImage.width-i)+j*inputImage.width]; //<>//
- pixels[(inputImage.width-i)+j*inputImage.width]=swap;
- }
- }
+ } //<>//
updatePixels();
int x=0;
|