mirror of
https://github.com/TheRedShip/RT_GPU.git
synced 2025-09-27 18:48:36 +02:00
+ | bvh opti
This commit is contained in:
@ -18,10 +18,12 @@ pl 0 0 -2 0 0 1 1 // back wall
|
|||||||
pl 0 0 2 0 0 -1 5 // front wall
|
pl 0 0 2 0 0 -1 5 // front wall
|
||||||
pl 2 0 0 -1 0 0 3 // right wall
|
pl 2 0 0 -1 0 0 3 // right wall
|
||||||
pl -2 0 0 1 0 0 2 // left wall
|
pl -2 0 0 1 0 0 2 // left wall
|
||||||
# pl 0 2 0 0 -1 0 0 // ceiling
|
pl 0 2 0 0 -1 0 0 // ceiling
|
||||||
pl 0 -2 0 0 1 0 2 // floor
|
pl 0 -2 0 0 1 0 2 // floor
|
||||||
|
|
||||||
|
|
||||||
qu -1 1.999 -1 2 0 0 0 0 2 6
|
qu -1 1.999 -1 2 0 0 0 0 2 6
|
||||||
|
# sp 1 1 0 0.5 6
|
||||||
|
|
||||||
OBJ obj/Dragon_80K.obj
|
OBJ obj/Dragon_80K.obj
|
||||||
|
|
||||||
|
@ -2,6 +2,7 @@ hitInfo traceRay(Ray ray);
|
|||||||
|
|
||||||
vec3 GetEnvironmentLight(Ray ray)
|
vec3 GetEnvironmentLight(Ray ray)
|
||||||
{
|
{
|
||||||
|
return vec3(0.);
|
||||||
vec3 sun_pos = vec3(-0.5, 0.5, 0.5);
|
vec3 sun_pos = vec3(-0.5, 0.5, 0.5);
|
||||||
float SunFocus = 1.5;
|
float SunFocus = 1.5;
|
||||||
float SunIntensity = 1.;
|
float SunIntensity = 1.;
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
/* By: ycontre <ycontre@student.42.fr> +#+ +:+ +#+ */
|
/* By: ycontre <ycontre@student.42.fr> +#+ +:+ +#+ */
|
||||||
/* +#+#+#+#+#+ +#+ */
|
/* +#+#+#+#+#+ +#+ */
|
||||||
/* Created: 2024/09/27 14:51:49 by TheRed #+# #+# */
|
/* Created: 2024/09/27 14:51:49 by TheRed #+# #+# */
|
||||||
/* Updated: 2025/01/18 19:21:00 by ycontre ### ########.fr */
|
/* Updated: 2025/01/18 19:28:58 by ycontre ### ########.fr */
|
||||||
/* */
|
/* */
|
||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
|
|
||||||
@ -20,8 +20,8 @@ int main(int argc, char **argv)
|
|||||||
return (1);
|
return (1);
|
||||||
|
|
||||||
Window window(&scene, WIDTH, HEIGHT, "RT_GPU", 0);
|
Window window(&scene, WIDTH, HEIGHT, "RT_GPU", 0);
|
||||||
// Shader shader("shaders/vertex.vert", "shaders/frag.frag", "shaders/compute.glsl");
|
Shader shader("shaders/vertex.vert", "shaders/frag.frag", "shaders/compute.glsl");
|
||||||
Shader shader("shaders/vertex.vert", "shaders/frag.frag", "shaders/debug.glsl");
|
// Shader shader("shaders/vertex.vert", "shaders/frag.frag", "shaders/debug.glsl");
|
||||||
|
|
||||||
GLint max_gpu_size;
|
GLint max_gpu_size;
|
||||||
glGetIntegerv(GL_MAX_SHADER_STORAGE_BLOCK_SIZE, &max_gpu_size);
|
glGetIntegerv(GL_MAX_SHADER_STORAGE_BLOCK_SIZE, &max_gpu_size);
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
/* By: ycontre <ycontre@student.42.fr> +#+ +:+ +#+ */
|
/* By: ycontre <ycontre@student.42.fr> +#+ +:+ +#+ */
|
||||||
/* +#+#+#+#+#+ +#+ */
|
/* +#+#+#+#+#+ +#+ */
|
||||||
/* Created: 2024/10/13 16:16:24 by TheRed #+# #+# */
|
/* Created: 2024/10/13 16:16:24 by TheRed #+# #+# */
|
||||||
/* Updated: 2025/01/18 19:22:30 by ycontre ### ########.fr */
|
/* Updated: 2025/01/18 19:24:04 by ycontre ### ########.fr */
|
||||||
/* */
|
/* */
|
||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user