Commit Graph

45 Commits

Author SHA1 Message Date
Syoyo Fujita
82ae20b833 +1 version num. 2015-06-25 20:32:46 +09:00
Syoyo Fujita
164c152216 Initialized a material.
Add warning message to `err` when material file not found.
2015-06-25 20:24:24 +09:00
Syoyo Fujita
3058419d7d Update README. Add bugfix notes. 2015-06-23 16:18:29 +09:00
Ricardo Sánchez-Sáez
fb361547e5 Fix groups being ignored if they have 'usemtl' just before 'g' 2015-06-22 16:14:16 +01:00
Syoyo Fujita
805bd814fa Invert 'Tr'. Fixes #43. 2015-06-20 19:41:41 +09:00
Syoyo Fujita
1adfc794ae Fix sscanf_s seg fault on windows. Fixes #41 2015-06-09 23:49:52 +09:00
MutterOberin
42d6bfbafb Changed pow function to use double overload 2015-06-01 16:39:36 +02:00
Alexander Bock
0aab63eb20 Fixing ptrdiff_t compile error 2015-05-23 22:15:23 +02:00
Alexander Bock
49e82e2e00 Fix compile warnings under VS 2013 /W4 warning level 2015-05-23 22:13:00 +02:00
Will Usher
527000abd6 Add support for referencing multiple mtllibs 2015-05-01 17:32:25 -06:00
Syoyo Fujita
8d300917a3 Update README.
Bump version 0.9.9.
2015-03-03 13:16:56 +09:00
Syoyo Fujita
79af31df5a Merge branch 'master' of https://github.com/skurmedel/tinyobjloader into skurmedel-master 2015-03-03 12:16:38 +09:00
Simon Otter
4ea1cf0b77 Implemented a parser and updated tiny_obj_loader.cc to use it unless a define is set. 2015-03-03 01:37:28 +01:00
Joe Hermaszewski
9d7012673e Fix a small typo 2015-02-27 19:58:43 +00:00
Syoyo Fujita
f0fdaa307d slight change to fixIndex 2015-02-18 12:48:50 +09:00
Syoyo Fujita
285f5b0cfd Merge branch 'patch-1' of https://github.com/CoolerExtreme/tinyobjloader into CoolerExtreme-patch-1
Conflicts:
	tiny_obj_loader.cc
2015-02-18 12:45:34 +09:00
Syoyo Fujita
1390f7f707 Fix compilation. 2015-02-15 17:05:57 +09:00
Syoyo Fujita
9979275835 Format source code. 2015-02-15 16:51:38 +09:00
CoolerExtreme
011e1b3ebd Slight typo 2015-02-13 06:37:37 +05:30
CoolerExtreme
f28d2eef88 Fix parseString ? and slight change to fixIndex
function parseString seemed to not increment token after it used strspn to get the length of the whitespace characters at the beginning of token. So strcspn called right after that would return 0 and the created string would be an empty string.

Seems to have been working so far since it gets passed strings that don't begin with whitespace characters.
2015-02-12 23:31:06 +05:30
Syoyo Fujita
672f252195 Fix per-face material. 2015-02-07 00:01:37 +09:00
Julian Simioni
b214cfb4b9 Fix unused variable warnings 2014-10-29 18:54:35 -07:00
Syoyo Fujita
957fa36e70 typo. 2014-09-14 19:52:44 +09:00
Syoyo Fujita
e4d4c65a17 Fix material ID assignment.
Fix build of example/obj_sticher.
2014-09-14 19:51:24 +09:00
Syoyo Fujita
cbba0a807e Initial support of multi-materials per group.
Introduce material_id attribute per face.
2014-09-13 23:49:25 +09:00
Mykhailo Parfeniuk
33cd9a4768 Added multiple materials per shape/object 2014-09-07 14:19:22 +03:00
Mattias Harrysson
f72fb80ac9 fix compiler warnings 2014-06-02 20:52:44 +02:00
Narendra Umate
b45fbe6345 Fixed trim newline bugs. 2014-05-16 13:54:05 -04:00
E J Burns
9b4a9343a1 Fixed ior init. 2014-04-29 15:22:01 +01:00
E J Burns
b89a46c417 Code Modified to remove use of C++11 features.
Tested compilation with VS2012, clang++ 3.4 and g++.
2014-04-29 13:36:09 +01:00
E J Burns
08ff49d2d0 Added a LoadObj function that reads from a std::istream.
+ Added a LoadObj function that reads from a std::istream.  This should allow
   more generic usage and possibly make testing a little easier.
   o This LoadObj accepts a function that returns a
     std::unique_ptr<std::istream> for a material.
 + Modified LoadMtl to read from a std::istream to allow more generic
   usage.
 + Modified test.cc to check that the changes work as expected and nothing was
   broken.

Tests:
 + Compiled test.cc, checked diff of output against pre change output.
   Same output where expected.
2014-04-28 20:26:03 +01:00
YarmUI
86b9c625db set default material 2014-04-21 19:14:06 +09:00
Matt Pharr
6372ccbef2 Add support for parsing 'illum' and 'd'/'Tr' statements. 2014-04-09 09:46:03 -07:00
Sean Jones
7afab4ad56 Cppcheck suggested performance improvement
variables should be passed by reference.
They are passed by value. It could be passed as a (const) reference which is usually faster and recommended in C++.

This gives a 9% performance boost in my project.
26.28s to load instead of 28.94s
2013-11-25 20:54:46 +00:00
caryanne
b17d15f5a0 added clearing of unknown parameters map
not doing so caused undefined behavior in objects with multiple
materials using custom parameters.
2013-11-14 16:51:06 -05:00
Syoyo Fujita
1544f0c865 Parse ior and transmittance of material parameter.
Add .obj sticher example.
2013-09-11 13:03:24 +09:00
Syoyo Fujita
5284dcb19f Parse multiple group name. Not yet finished fully though. 2013-06-29 13:00:22 +09:00
Syoyo Fujita
6556411006 Add support of group tag('g') 2013-04-25 17:01:52 +09:00
Syoyo Fujita
3ae1bea017 Fix parsing triple. 2012-11-10 14:46:44 +09:00
Syoyo Fujita
c552dbc582 Fix texcoord array indexing. 2012-09-06 00:19:38 +09:00
Syoyo Fujita
04e2eccaa9 Fix build on linux. 2012-08-22 01:38:02 +09:00
YarmUI
fb35a684e5 bugfix 2012-08-21 18:46:10 +09:00
YarmUI
d62fdaf89d update .mtl loader (Ke, Ns, map_Ka, map_Kd, map_Ks, map_Ns) 2012-08-21 18:35:37 +09:00
Syoyo Fujita
66528fbd6c Add initial support for loading .mtl. Thanks githole for the patch! 2012-08-20 13:20:06 +09:00
Syoyo Fujita
cf78dd845b Initial commit. 2012-08-19 14:36:48 +09:00