I try to load a model by using OBJLoader and MTLLoader, however textures isn’t loaded uncompelete.
core code is inspired by office demo
mtlLoader.setMaterialOptions({side:THREE.DoubleSide}).load(model.mtl, (mtlParseResult) => {
const materials = MtlObjBridge.addMaterialsFromMtlLoader(mtlParseResult)
objLoader.addMaterials(materials)
objLoader.load(
model.obj,
this._loadSuccess.bind(this),
this._loadProgress.bind(this),
this._onError.bind(this)
)
and mtl file is
# 3ds Max Wavefront OBJ Exporter v0.97b - (c)2007 guruware
# �������ļ�:15.12.2020 16:47:34
newmtl _1903_0359_00020_04_high_1903_0359_00020_01_high1903_0359_00020_01_MID
Ns 6.0000
Ni 1.5000
d 1.0000
Tr 0.0000
Tf 1.0000 1.0000 1.0000
illum 2
Ka 0.5500 0.5500 0.5500
Kd 0.5500 0.5500 0.5500
Ks 0.0000 0.0000 0.0000
Ke 0.0000 0.0000 0.0000
map_Ka /1903_0359_00020_01_low.jpg
map_Kd /1903_0359_00020_01_low.jpg
newmtl _1903_0359_00020_04_high_1903_0359_00020_02_high1903_0359_00020_02_MID
Ns 0.0000
Ni 1.5000
d 1.0000
Tr 0.0000
Tf 1.0000 1.0000 1.0000
illum 2
Ka 0.5500 0.5500 0.5500
Kd 0.0000 0.0000 0.0000
Ks 0.0000 0.0000 0.0000
Ke 0.0000 0.0000 0.0000
map_Ka /1903_0359_00020_02_low.jpg
map_Kd /1903_0359_00020_02_low.jpg
newmtl 1903_0359_00020_03_MID
Ns 0.0000
Ni 1.5000
d 1.0000
Tr 0.0000
Tf 1.0000 1.0000 1.0000
illum 2
Ka 0.5500 0.5500 0.5500
Kd 0.0000 0.0000 0.0000
Ks 0.0000 0.0000 0.0000
Ke 0.0000 0.0000 0.0000
map_Ka /1903_0359_00020_03_low.jpg
map_Kd /1903_0359_00020_03_low.jpg
newmtl 1903_0359_00020_04_MID
Ns 0.0000
Ni 1.5000
d 1.0000
Tr 0.0000
Tf 1.0000 1.0000 1.0000
illum 2
Ka 1.0000 1.0000 1.0000
Kd 1.0000 1.0000 1.0000
Ks 0.0000 0.0000 0.0000
Ke 0.0000 0.0000 0.0000
map_Ka /1903_0359_00020_04_low.jpg
map_Kd /1903_0359_00020_04_low.jpg
mtl has 4 textures but it only render 2 textures finally. is there any way to accomplish it? thanks!