Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit a20e4ed

Browse files
committed
Update document and version.
1 parent 1ab0d14 commit a20e4ed

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

README.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ Tiny but powerful single file wavefront obj loader written in C++. No dependency
2121
What's new
2222
----------
2323

24+
* Mar 13, 2016 : Introduce `load_flag_t` and flat normal calculation flag! Thanks Vazquinhos!
2425
* Jan 29, 2016 : Support n-polygon(no triangulation) and OpenSubdiv crease tag! Thanks dboogert!
2526
* Nov 26, 2015 : Now single-header only!.
2627
* Nov 08, 2015 : Improved API.
@@ -163,8 +164,8 @@ std::vector<tinyobj::shape_t> shapes;
163164
std::vector<tinyobj::material_t> materials;
164165

165166
std::string err;
166-
bool triangulate = false;
167-
bool ret = tinyobj::LoadObj(shapes, materials, err, inputfile.c_str(), triangulate);
167+
int flags = 1; // see load_flags_t enum for more information.
168+
bool ret = tinyobj::LoadObj(shapes, materials, err, inputfile.c_str(), flags);
168169

169170
if (!err.empty()) { // `err` may contain warning message.
170171
std::cerr << err << std::endl;

test.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ main(
272272
//assert(true == TestLoadObj("cornell_box.obj"));
273273
//assert(true == TestLoadObj("cube.obj"));
274274
assert(true == TestStreamLoadObj());
275-
assert(true == TestLoadObj("catmark_torus_creases0.obj", NULL, false));
275+
assert(true == TestLoadObj("catmark_torus_creases0.obj", NULL, 0));
276276
}
277277

278278
return 0;

tiny_obj_loader.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
//
66

77
//
8+
// version 0.9.22: Introduce `load_flags_t`.
89
// version 0.9.20: Fixes creating per-face material using `usemtl`(#68)
910
// version 0.9.17: Support n-polygon and crease tag(OpenSubdiv extension)
1011
// version 0.9.16: Make tinyobjloader header-only

0 commit comments

Comments
 (0)