Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions BasicImages/BasicImages.pde
Original file line number Diff line number Diff line change
@@ -1 +1,23 @@
PImage kobe;
float scaleFactor=0.5;

void setup () {
size(800, 600);
kobe=loadImage("Kobe.jpg");
noCursor();
}

void draw() {
image(kobe, mouseX, mouseY, kobe.width*scaleFactor, kobe.height*0.5);
tint(0,255,0);
image(kobe, mouseX, mouseY, kobe.width*0.5, kobe.height*0.5);
}

void keyPressed() {
if (keyCode==UP) {
scaleFactor += 0.1;
}
if (keyCode==DOWN) {
scaleFactor -= 0.1;
}
}
Binary file added BasicImages/data/Kobe.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions FilteringImages/FilteringImages.pde
Original file line number Diff line number Diff line change
@@ -1 +1,15 @@
PImage kobe;
float scaleFactor=0.5;



void setup () {
size(800, 600);
kobe=loadImage("Kobe.jpg");
}

void draw() {
background(0);
image(kobe, mouseX, mouseY, kobe.width*scaleFactor, kobe.height*0.5);
filter(INVERT);
}
Binary file added FilteringImages/data/Kobe.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added FilteringImages/data/Steph Curry.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 23 additions & 0 deletions IndependentImagePractice/IndependentImagePractice.pde
Original file line number Diff line number Diff line change
@@ -1 +1,24 @@
PImage kobe;
PImage steph;
//declaring images

void setup () {
size(800, 600);
kobe=loadImage("Kobe.jpg");
steph=loadImage("steph.jpg");
kobe.mask(steph);
steph.mask(kobe);
tint(255,215,28);
//declaring images and masks
}

void draw() {
background(map(mouseY, 0, height, 0, 255)); //mask order changes when mouseY changes
image(kobe, 0, 0); //load image on canvas
image(steph, 0, 0); //load image

}

void keyPressed() { //when key is pressed
tint(random(255),random(255),random(255)); //random tint when key is pressed
}
Binary file added IndependentImagePractice/data/Kobe.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added IndependentImagePractice/data/steph.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 14 additions & 0 deletions MaskingImages/MaskingImages.pde
Original file line number Diff line number Diff line change
@@ -1 +1,15 @@
PImage StephCurry2;
PImage Kobe;

void setup() {
size(800,600);
StephCurry2=loadImage("Steph Curry2.jpg");
Kobe=loadImage("Kobe.jpg");
StephCurry2.mask(Kobe);
}

void draw() {
background(map(mouseY,0,height,0,255));
image(Kobe,0,0);
image(StephCurry2,0,0);
}
Binary file added MaskingImages/data/Kobe.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added MaskingImages/data/Steph Curry.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added MaskingImages/data/Steph Curry2.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.