~ | Better fps handling

This commit is contained in:
RedShip
2025-02-25 19:03:35 +01:00
parent 3d2bcce9ca
commit a878a4c0fd
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/02/15 22:54:27 by tomoron ### ########.fr */
/* Updated: 2025/02/25 18:12:37 by ycontre ### ########.fr */
/* */
/* ************************************************************************** */
@ -30,6 +30,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