Create scene data structure

This commit is contained in:
Camden Dixie O'Brien
2025-09-22 20:36:14 +01:00
parent fe5055f161
commit bbaec554d8
4 changed files with 34 additions and 20 deletions

View File

@@ -2,8 +2,7 @@
#define CAMERA_H
#include "img.h"
#include "obj.h"
#include "vec3.h"
#include "scene.h"
#include <stdint.h>
@@ -19,7 +18,6 @@ camera_t camera_init(
uint32_t img_height, unsigned samples_per_pixel);
void camera_render(
const camera_t *camera, const obj_t *scene, unsigned scene_count,
img_t *img_out);
const camera_t *camera, const scene_t *scene, img_t *img_out);
#endif

12
include/scene.h Normal file
View File

@@ -0,0 +1,12 @@
#ifndef SCENE_H
#define SCENE_H
#include "obj.h"
typedef struct {
vec3_t sky_colour;
obj_t *objs;
unsigned obj_count;
} scene_t;
#endif