From b72b2eba7102bf0934032feba13b4475497fd71a Mon Sep 17 00:00:00 2001 From: JackCarterSmith Date: Sat, 13 Aug 2022 15:47:46 +0200 Subject: [PATCH] Temporary remove MTL support --- RSEModel/src/Model-Extractor.c | 18 +++++++++--------- RSEModel/src/obj_exporter.c | 13 +++++++------ RSEModel/src/obj_exporter.h | 11 ++++++----- RSEModel/src/options.h | 11 ++++++----- RSPModelLib/include/RSPModel_errordefs.h | 10 +++++----- RSPModelLib/src/hob_parser.c | 11 ++++++----- RSPModelLib/src/hob_parser.h | 11 ++++++----- RSPModelLib/src/hob_struct.h | 10 +++++----- RSPModelLib/src/options.h | 11 ++++++----- 9 files changed, 56 insertions(+), 50 deletions(-) diff --git a/RSEModel/src/Model-Extractor.c b/RSEModel/src/Model-Extractor.c index 4dcdd18..24bbbf7 100644 --- a/RSEModel/src/Model-Extractor.c +++ b/RSEModel/src/Model-Extractor.c @@ -1,9 +1,10 @@ /** - * \file Model-Extractor.c - * \date 25/07/2022 - * \author JackCarterSmith - * \copyright GPL-v3.0 - * \brief HOB model parser and export to Waveform OBJ format. + * @file Model-Extractor.c + * @date 25/07/2022 + * @author JackCarterSmith + * @copyright GPL-v3.0 + * @brief HOB model parser and export to Waveform OBJ format. + * */ #include @@ -105,7 +106,6 @@ static unsigned char checkInputArgs(T_PROG_OPTIONS* opt_ptr, int p_arg_nbr, char // Set default options opt_ptr->raw = 0; opt_ptr->output_dir = 1; - opt_ptr->export_mtl = 1; if (p_arg_nbr > 1) { for ( i = 1; i < p_arg_nbr; i++) { @@ -129,9 +129,9 @@ static unsigned char checkInputArgs(T_PROG_OPTIONS* opt_ptr, int p_arg_nbr, char } else if (strcmp(p_args[i], "-no-subdir") == 0) { opt_ptr->output_dir = 0; printf("[OPTN] Export to current directory.\n"); - } else if (strcmp(p_args[i], "-no-mtl") == 0) { + } else if (strcmp(p_args[i], "-mtl") == 0) { opt_ptr->export_mtl = 0; - printf("[OPTN] No materials datas.\n"); + printf("[OPTN] Export materials datas.\n"); } else { printf("[ERR] Unknown option: %s\n", p_args[i]); } @@ -179,7 +179,7 @@ static void dispHelp() { printf("Options:\n -h Print this message\n"); printf(" -v -vv Activate verbose console output\n"); printf(" -no-subdir Export models inside current folder\n"); - printf(" -no-mtl Disable materials datas export with model\n"); + //printf(" -mtl Export materials datas with model\n"); printf("\n"); printf("Usage: RSE-Model_%s [options] \n", PRG_VERSION); printf("\n"); diff --git a/RSEModel/src/obj_exporter.c b/RSEModel/src/obj_exporter.c index f2464a6..b60256f 100644 --- a/RSEModel/src/obj_exporter.c +++ b/RSEModel/src/obj_exporter.c @@ -1,9 +1,10 @@ /** - * \file obj_exporter.c - * \date 27/07/2022 - * \author JackCarterSmith - * \copyright GPL-v3.0 - * \brief Export datas to Waveform OBJ format. + * @file obj_exporter.c + * @date 27/07/2022 + * @author JackCarterSmith + * @copyright GPL-v3.0 + * @brief Export datas to Waveform OBJ format. + * */ #include @@ -115,7 +116,7 @@ unsigned char exportOBJModel(T_RSPMODEL_OBJECT* hob_objects, const char *out_pat obj_delete(objConstruct); - return NO_ERROR; + return RSPLIB_SUCCESS; } static void mtlPathPatch(const char* out_file, const char* obj_name) { diff --git a/RSEModel/src/obj_exporter.h b/RSEModel/src/obj_exporter.h index df1ec34..035141e 100644 --- a/RSEModel/src/obj_exporter.h +++ b/RSEModel/src/obj_exporter.h @@ -1,9 +1,10 @@ /** - * \file obj_exporter.h - * \date 27/07/2022 - * \author JackCarterSmith - * \copyright GPL-v3.0 - * \brief Export datas to Waveform OBJ format. + * @file obj_exporter.h + * @date 27/07/2022 + * @author JackCarterSmith + * @copyright GPL-v3.0 + * @brief Export datas to Waveform OBJ format. + * */ #ifndef SRC_OBJ_EXPORTER_H_ diff --git a/RSEModel/src/options.h b/RSEModel/src/options.h index ec369ab..fd512b2 100644 --- a/RSEModel/src/options.h +++ b/RSEModel/src/options.h @@ -1,9 +1,10 @@ /** - * \file options.h - * \date 29/07/2022 - * \author JackCarterSmith - * \copyright GPL-v3.0 - * \brief Shared options structure definition and declaration. + * @file options.h + * @date 29/07/2022 + * @author JackCarterSmith + * @copyright GPL-v3.0 + * @brief Shared options structure definition and declaration. + * */ #ifndef OPTIONS_H_ diff --git a/RSPModelLib/include/RSPModel_errordefs.h b/RSPModelLib/include/RSPModel_errordefs.h index fa33c03..d707066 100644 --- a/RSPModelLib/include/RSPModel_errordefs.h +++ b/RSPModelLib/include/RSPModel_errordefs.h @@ -1,9 +1,9 @@ /** - * \file RSPModel_errordefs.h - * \date 26/07/2022 - * \author JackCarterSmith - * \copyright GPL-v3.0 - * \brief Errors type definition file. Used mostly by methods in this project. + * @file RSPModel_errordefs.h + * @date 26/07/2022 + * @author JackCarterSmith + * @copyright GPL-v3.0 + * @brief Errors type definition file. Used mostly by methods in this project. * */ diff --git a/RSPModelLib/src/hob_parser.c b/RSPModelLib/src/hob_parser.c index 7de9d42..c8f934e 100644 --- a/RSPModelLib/src/hob_parser.c +++ b/RSPModelLib/src/hob_parser.c @@ -1,9 +1,10 @@ /** - * \file hob_parser.c - * \date 26/07/2022 - * \author JackCarterSmith - * \copyright GPL-v3.0 - * \brief Decode HOB file structure. + * @file hob_parser.c + * @date 26/07/2022 + * @author JackCarterSmith + * @copyright GPL-v3.0 + * @brief Decode HOB file structure. + * */ #include diff --git a/RSPModelLib/src/hob_parser.h b/RSPModelLib/src/hob_parser.h index 32b350d..a2cb907 100644 --- a/RSPModelLib/src/hob_parser.h +++ b/RSPModelLib/src/hob_parser.h @@ -1,9 +1,10 @@ /** - * \file hob_parser.h - * \date 26/07/2022 - * \author JackCarterSmith - * \copyright GPL-v3.0 - * \brief Decode HOB file structure. + * @file hob_parser.h + * @date 26/07/2022 + * @author JackCarterSmith + * @copyright GPL-v3.0 + * @brief Decode HOB file structure. + * */ #include "options.h" diff --git a/RSPModelLib/src/hob_struct.h b/RSPModelLib/src/hob_struct.h index b374150..f90e5f6 100644 --- a/RSPModelLib/src/hob_struct.h +++ b/RSPModelLib/src/hob_struct.h @@ -1,9 +1,9 @@ /** - * \file hob_struct.h - * \date 26/07/2022 - * \author JackCarterSmith - * \copyright GPL-v3.0 - * \brief HOB file mapping definition. + * @file hob_struct.h + * @date 26/07/2022 + * @author JackCarterSmith + * @copyright GPL-v3.0 + * @brief HOB file mapping definition. * */ diff --git a/RSPModelLib/src/options.h b/RSPModelLib/src/options.h index 1168992..a88baae 100644 --- a/RSPModelLib/src/options.h +++ b/RSPModelLib/src/options.h @@ -1,9 +1,10 @@ /** - * \file options.h - * \date 29/07/2022 - * \author JackCarterSmith - * \copyright GPL-v3.0 - * \brief Shared options structure definition and declaration. + * @file options.h + * @date 29/07/2022 + * @author JackCarterSmith + * @copyright GPL-v3.0 + * @brief Shared options structure definition and declaration. + * */ #ifndef OPTIONS_H_