]> git.tdb.fi Git - libs/gl.git/blobdiff - blender/io_mspgl/util.py
Fix filename handling in the Blender exporter on Windows
[libs/gl.git] / blender / io_mspgl / util.py
index cb4b326181c75f6604f621e0939e54928a3552af..ca13875befe31aeae05433d84ebc04ae073b5342 100644 (file)
@@ -1,3 +1,5 @@
+import os
+
 class Progress:
        def __init__(self, context):
                self.task = ""
@@ -61,3 +63,8 @@ def get_colormap(srgb):
                return linear_to_srgb
        else:
                return lambda x: x
+
+def basename(path):
+       if path.startswith("//"):
+               path = path[2:]
+       return os.path.basename(path)