update config

This commit is contained in:
H3XploR
2025-02-14 01:50:24 +01:00
parent eb251c97e4
commit 16f49eb686
4 changed files with 65 additions and 16 deletions
+29
View File
@@ -0,0 +1,29 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* config.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: yantoine <yantoine@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/02/14 01:41:17 by yantoine #+# #+# */
/* Updated: 2025/02/14 01:50:00 by yantoine ### ########.fr */
/* */
/* ************************************************************************** */
#include "miniRT.h"
// ----- Parsing du fichier de configuration -----
int load_config(const char *filename)
{
int fd;
char line[256];
float ratio;
fd = open(filename, "r");
if (!fd)
{
printf("Erreur : impossible d'ouvrir %s\n", filename);
return ;
}
return (fd);
}