+import os
+
class TextureExporter:
def __init__(self):
self.inline_data = True
else:
tex_res.statements.append(Statement("min_filter", Token('NEAREST')))
- if not self.inline_data:
+ if not self.inline_data and texture.image.filepath:
from .util import image_name
- tex_res.statements.append(Statement("external_image", image_name(texture.image)))
+ tex_res.statements.append(Statement("external_image", os.path.basename(texture.image.filepath)))
else:
texdata = ""
colorspace = texture.image.colorspace_settings.name