Merge branch 'main' of github.com:TheRedShip/RT_GPU

This commit is contained in:
TheRedShip
2025-01-17 16:30:33 +01:00
4 changed files with 79 additions and 37 deletions

View File

@ -6,7 +6,7 @@
/* By: tomoron <tomoron@student.42angouleme.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/01/16 15:00:49 by tomoron #+# #+# */
/* Updated: 2025/01/16 22:00:15 by tomoron ### ########.fr */
/* Updated: 2025/01/17 14:53:58 by tomoron ### ########.fr */
/* */
/* ************************************************************************** */
@ -27,8 +27,9 @@ class ObjParser
void addFace(std::stringstream &line, std::vector<glm::vec3> &vertices, int mat, Scene &scene);
long int checkVertexIndex(int index, size_t size);
void parseMtl(std::stringstream &line, std::map<std::string, int> &materials, Scene &scene);
void addTriangleFromPolygon(std::vector<glm::vec3> &vertices, Scene &scene);
bool addTriangleFromPolygon(std::vector<glm::vec3> &vertices, Scene &scene, int mat, int inv);
void addTriangle(glm::vec3 v1, glm::vec3 v2, glm::vec3 v3, int mat, Scene &scene);
int pointInTriangle(glm::vec3 pts[3], std::vector<glm::vec3> vertices, size_t cur);
std::ifstream _file;
std::vector<glm::vec3> vertex;