- path, base = os.path.split(out_fn)
- base = os.path.splitext(base)[0]
-
- resources = {}
- self.export_object_resources(context, obj, resources, progress)
-
- obj_res = self.export_object(context, obj, progress, resources=resources)
- refs = obj_res.collect_references()
- if not self.shared_resources:
- numbers = {}
- for r in refs:
- ext = os.path.splitext(r.name)[1]
- n = numbers.get(ext, 0)
- if n>0:
- r.name = "{}_{}{}".format(base, n, ext)
- else:
- r.name = base+ext
- numbers[ext] = n+1
+ def export_object_resources(self, context, obj, resources, material_atlases, progress):
+ if material_atlases is None:
+ material_atlases = {}