~ | Better fps handling

This commit is contained in:
RedShip
2025-02-25 19:03:35 +01:00
committed by tomoron
parent 47c0c38662
commit 0aaf4d0492
6 changed files with 71 additions and 7 deletions

View File

@ -6,7 +6,7 @@
/* By: ycontre <ycontre@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/10/13 16:15:41 by TheRed #+# #+# */
/* Updated: 2025/03/18 16:17:38 by tomoron ### ########.fr */
/* Updated: 2025/03/18 16:23:53 by tomoron ### ########.fr */
/* */
/* ************************************************************************** */
@ -31,6 +31,8 @@ class Window
bool shouldClose();
void process_input();
void reduceTimeFrame();
static void keyCallback(GLFWwindow *window, int key, int scancode, int action, int mods);
static void mouseMoveCallback(GLFWwindow *window, double xpos, double ypos);

32
includes/RT/sansnom.hpp Normal file
View File

@ -0,0 +1,32 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* sansnom.hpp :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: ycontre <ycontre@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/02/19 18:04:15 by ycontre #+# #+# */
/* Updated: 2025/02/19 18:19:47 by ycontre ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef ashf
# define ashf
class RT
{
public:
RT(Arguments &args, Window &window);
~RT();
private:
Window &window;
GLuint VAO;
std::vector<GLuint> &textures;
Scene *scene;
ShaderProgram raytracing_program;
};
#endif