Blender
V3.3
|
#include <obj_import_file_reader.hh>
Public Member Functions | |
MTLParser (StringRefNull mtl_library_, StringRefNull obj_filepath) | |
void | parse_and_store (Map< std::string, std::unique_ptr< MTLMaterial >> &r_materials) |
Definition at line 48 of file obj_import_file_reader.hh.
blender::io::obj::MTLParser::MTLParser | ( | StringRefNull | mtl_library_, |
StringRefNull | obj_filepath | ||
) |
Open material library file.
Definition at line 759 of file obj_import_file_reader.cc.
References BLI_path_join(), BLI_split_dir_part(), blender::StringRefBase::data(), FILE_MAX, FILE_MAXDIR, and NULL.
void blender::io::obj::MTLParser::parse_and_store | ( | Map< std::string, std::unique_ptr< MTLMaterial >> & | r_materials | ) |
Read MTL file(s) and add MTLMaterial instances to the given Map reference.
Definition at line 767 of file obj_import_file_reader.cc.
References blender::StringRefBase::begin(), BLI_file_read_text_as_mem(), buffer, blender::io::obj::drop_whitespace(), blender::StringRefBase::end(), material, MEM_freeN, blender::io::obj::parse_float(), blender::io::obj::parse_floats(), blender::io::obj::parse_keyword(), blender::io::obj::parse_texture_map(), blender::io::obj::read_next_line(), and blender::StringRefBase::trim().
Referenced by blender::io::obj::obj_mtl_parser_test::check_impl().