News:

 

Topic: [Fixed] .obj import + mtl files  (Read 2622 times)

0 Members and 1 Guest are viewing this topic.

  • No avatar
  • Posts: 2101
  • Polygon
January 18, 2018, 05:00:24 pm
Hi IStonia,

I thought this issue had been resolved. But I am seing an issue when importing an .obj file with a missing .mtl file.

With other applications I use, if the .mtl file is missing, they will create a default material for each of the "mat ID" within the .obj file.

For example. within an .obj file, you will have a "Usemtl {name}" in front of a set of faces, such as:-

usemtl Mat1
s 2
f 5/5/5 6/6/6 2/2/2 4/4/4
usemtl Mat2
s 2
f 5/5/5 3/3/3 1/1/1 6/6/6

Now if the .obj file is imported without the .mtl file, other application will create a default material for each of those mat IDs, so you would see
Mat1
Mat2
which are applied to the assign faces.

If the .mtl file is missing when importing into Nvil, those mat IDs are ignored and a single defualt material is assigned to all faces.


If you can find time, could you please look into this.
« Last Edit: January 19, 2018, 03:49:17 am by steve »

  • No avatar
  • Posts: 3705
  • Developer
  • Administrator
  • Polygon

  • No avatar
  • Posts: 2101
  • Polygon
January 19, 2018, 03:49:02 am
Excellent, many thanks.