aboutsummaryrefslogtreecommitdiffstats
path: root/src/main.cpp
diff options
context:
space:
mode:
authorladevieq <ladevie.quentin@gmail.com>2021-01-01 20:48:57 +0100
committerladevieq <ladevie.quentin@gmail.com>2021-01-01 20:48:57 +0100
commitca7f65d7cc2d82ce1bd752785fd100a1855b4dc3 (patch)
treeae1e04c5141e4addda292189bc378f4944e4afe4 /src/main.cpp
parent84d6440f507a33d526acd15e55f73d99f747c8ec (diff)
Hit function return hit struct
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 97624ea..b769dd3 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -81,8 +81,9 @@ int main() {
vkrenderer renderer {};
// Image dimensions
- const float aspect_ratio = 16.0 / 9.0;
- const size_t width = 1920;
+ // const float aspect_ratio = 16.0 / 9.0;
+ const float aspect_ratio = 1.0 / 1.0;
+ const size_t width = 400;
const size_t height = width / aspect_ratio;
const uint32_t samples_per_pixel = 1;
const uint32_t max_depth = 100;
@@ -100,7 +101,8 @@ int main() {
.viewport_width = 2.f * aspect_ratio,
.viewport_height = 2.f,
.proj_plane_distance = 1.f,
- .sphere_position = { 0.f, 0.f, -1.f },
+ .sphere = { { 0.f, 0.f, -1.f }, 0.5f },
+ // .sphere = { { 0.f, -100.5f, -1.f }, 100.f },
};
// World hittable objects