~ | relativ epath

This commit is contained in:
RedShip
2025-01-31 21:24:06 +01:00
parent 2ea01daf4b
commit 3e122a972e
2 changed files with 4 additions and 4 deletions

View File

@ -6,7 +6,7 @@
/* By: ycontre <ycontre@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/01/16 21:48:48 by TheRed #+# #+# */
/* Updated: 2025/01/25 14:25:57 by tomoron ### ########.fr */
/* Updated: 2025/01/31 19:30:54 by ycontre ### ########.fr */
/* */
/* ************************************************************************** */
@ -78,7 +78,7 @@ void BVH::subdivide(std::vector<Triangle> &triangles)
if (_primitive_count <= 4)
return ;
const int num_test_per_axis = 10;
const int num_test_per_axis = 5;
int best_axis = 0;
float best_pos = 0;

View File

@ -6,7 +6,7 @@
/* By: ycontre <ycontre@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/01/16 15:00:33 by tomoron #+# #+# */
/* Updated: 2025/01/29 18:26:31 by ycontre ### ########.fr */
/* Updated: 2025/01/31 19:53:44 by ycontre ### ########.fr */
/* */
/* ************************************************************************** */
@ -321,7 +321,7 @@ void ObjParser::parseMtl(std::stringstream &input_line, Scene &scene)
throw std::runtime_error("OBJ: syntax error while getting material texture");
mat->texture_index = scene.getTextures().size();
scene.addTexture("scenes/obj/" + path);
scene.addTexture(getFilePath(_filename) + path);
}
else
std::cerr << "unsupported material setting : " << identifier << std::endl;