From: Mikko Rasa Date: Sun, 6 Mar 2022 10:32:49 +0000 (+0200) Subject: Use bpy.path.basename instead of a custom function X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=1ced0f1993471e4cf8789186edc57f8f900d9b6c;p=libs%2Fgl.git Use bpy.path.basename instead of a custom function --- diff --git a/blender/io_mspgl/export_material.py b/blender/io_mspgl/export_material.py index 9ec0670a..4941a585 100644 --- a/blender/io_mspgl/export_material.py +++ b/blender/io_mspgl/export_material.py @@ -124,7 +124,6 @@ class MaterialExporter: from .datafile import Statement if prop.texture: tex_res = resources[prop.texture.image.name+".tex"] - from .util import basename return mat_res.create_reference_statement(prop.tex_keyword, tex_res) elif not prop.keyword: return diff --git a/blender/io_mspgl/export_texture.py b/blender/io_mspgl/export_texture.py index eb6fa223..e03b1b0c 100644 --- a/blender/io_mspgl/export_texture.py +++ b/blender/io_mspgl/export_texture.py @@ -1,6 +1,7 @@ import os import base64 import codecs +import bpy def pixels_to_rgba(pixels): return (int(p*255) for p in pixels) @@ -41,8 +42,7 @@ class TextureExporter: invert_mask = sum(1<