Include sceneChooser function
This commit is contained in:
12
main.cpp
12
main.cpp
@@ -319,7 +319,7 @@ void cornellSmoke() {
|
|||||||
|
|
||||||
cam.aspectRatio = 1.0;
|
cam.aspectRatio = 1.0;
|
||||||
cam.imageWidth = 600;
|
cam.imageWidth = 600;
|
||||||
cam.samplesPerPixel = 200;
|
cam.samplesPerPixel = 600;
|
||||||
cam.maxDepth = 50;
|
cam.maxDepth = 50;
|
||||||
cam.background = colour(0,0,0);
|
cam.background = colour(0,0,0);
|
||||||
|
|
||||||
@@ -406,9 +406,7 @@ void finalScene(int imageWidth, int samplesPerPixel, int maxDepth) {
|
|||||||
cam.render(world);
|
cam.render(world);
|
||||||
}
|
}
|
||||||
|
|
||||||
int main(void) {
|
void sceneChooser(int sceneToShow) {
|
||||||
int sceneToShow = 4;
|
|
||||||
|
|
||||||
switch (sceneToShow) {
|
switch (sceneToShow) {
|
||||||
case 1:
|
case 1:
|
||||||
bouncingSpheres();
|
bouncingSpheres();
|
||||||
@@ -445,3 +443,9 @@ int main(void) {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int main(void) {
|
||||||
|
|
||||||
|
// Choose a scene to render.
|
||||||
|
sceneChooser(1);
|
||||||
|
}
|
Reference in New Issue
Block a user