+import os
+
class MaterialMap:
def __init__(self, materials):
self.technique = materials[0].technique
- self.name = "material_map_"+self.technique
+ if self.technique:
+ self.name = "material_map_"+os.path.splitext(self.technique)[0]
+ else:
+ self.name = "material_map"
self.materials = materials
self.srgb_colors = materials[0].srgb_colors
for m in self.materials: