Skip to content
Snippets Groups Projects
Commit 88b10014 authored by Noah Eigenfeld's avatar Noah Eigenfeld
Browse files

Fixed some formatting

parent 3d98f0da
No related branches found
No related tags found
1 merge request!2Save image
...@@ -43,7 +43,7 @@ int main() { ...@@ -43,7 +43,7 @@ int main() {
cout << "ESC pressed. Program closing..." << endl; cout << "ESC pressed. Program closing..." << endl;
break; break;
} }
else if (key == ' ') { //spacebar pressed: take a picture else if (key == ' ') { //spacebar pressed: take a picture
picture = frame; picture = frame;
key = -1; key = -1;
...@@ -55,12 +55,10 @@ int main() { ...@@ -55,12 +55,10 @@ int main() {
if (key == 27 || key == 32) { if (key == 27 || key == 32) {
cout << "ESC or SPACE pressed. Returning to video..." << endl; cout << "ESC or SPACE pressed. Returning to video..." << endl;
break; break;
} else if (key == 115) {
bool maybe = imwrite("./testimage.jpg", picture);
cout << "s was pressed. saving image " << maybe << endl;
} }
if (key == 115) {
bool maybe = imwrite("./testimage.jpg", picture);
cout << "s was pressed. saving image " << maybe << endl;
}
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment