summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--obj.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/obj.c b/obj.c
index 403e547..7e1c4e8 100644
--- a/obj.c
+++ b/obj.c
@@ -172,6 +172,11 @@ loadobjmodel(Model *m, OBJ *obj)
mtl->diffusemap->image = dupmemimage(objmtl->map_Kd);
}
+ if(objmtl->map_Ks != nil){
+ mtl->specularmap = alloctexture(sRGBTexture, nil);
+ mtl->specularmap->image = dupmemimage(objmtl->map_Ks);
+ }
+
if(objmtl->norm != nil){
mtl->normalmap = alloctexture(RAWTexture, nil);
mtl->normalmap->image = dupmemimage(objmtl->norm);