kottore / away3d

Automatically exported from code.google.com/p/away3d
0 stars 0 forks source link

OBJParser - assign wrong material (shifted by one group) #150

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Try to load OBJ file and MTL with multiple groups.

What is the expected output? What do you see instead?
Materials are assigned to groups but shifted by one. 

What version of the product are you using? On what operating system?
away3D 4.0 [bromstick]

Please provide any additional information below.
When parser read 'usemtl', create new material ID and set it as active 
material, but doesn't set it to _currentGroup.

OBJParser, add this line, under line 194:
if (_currentGroup) _currentGroup.materialID = _activeMaterialID;

Original issue reported on code.google.com by piotr.ra...@gmail.com on 4 Mar 2011 at 8:28

GoogleCodeExporter commented 8 years ago

Original comment by fabric...@gmail.com on 17 Mar 2011 at 10:48