2025-01-23 17:19:53 +01:00
|
|
|
#include "scene/BVH.h"
|
2025-01-24 00:19:11 +01:00
|
|
|
#include "util/ModelLoader.h"
|
|
|
|
|
#include "window/Window.h"
|
2025-01-23 15:26:32 +01:00
|
|
|
|
2025-01-24 00:19:11 +01:00
|
|
|
int main()
|
|
|
|
|
{
|
2025-01-23 17:19:53 +01:00
|
|
|
BVH bvh;
|
2025-01-24 09:50:51 +01:00
|
|
|
bvh.addModels(ModelLoader::loadModel("../cube.fbx"), glm::mat4());
|
2025-01-23 17:19:53 +01:00
|
|
|
bvh.generate();
|
2025-01-24 00:19:11 +01:00
|
|
|
Window w(1920, 1080);
|
2025-01-24 16:12:17 +01:00
|
|
|
std::vector<unsigned char> texture(1920 * 1080 * 3);
|
2025-01-24 00:19:11 +01:00
|
|
|
for (int j = 10; j < 100; ++j)
|
|
|
|
|
{
|
|
|
|
|
for (int i = 0; i < 1920; ++i)
|
|
|
|
|
{
|
2025-01-24 16:12:17 +01:00
|
|
|
texture[(j * 1920 + i) * 3] = 0xff;
|
|
|
|
|
texture[(j * 1920 + i) * 3 + 1] = 0xff;
|
|
|
|
|
texture[(j * 1920 + i) * 3 + 2] = 0x0;
|
2025-01-24 00:19:11 +01:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
while (true)
|
|
|
|
|
{
|
|
|
|
|
w.update(texture);
|
|
|
|
|
}
|
|
|
|
|
return 0;
|
2025-01-23 12:33:39 +01:00
|
|
|
}
|