~ubuntu-branches/ubuntu/utopic/blender/utopic-proposed

« back to all changes in this revision

Viewing changes to release/scripts/modules/bpy_extras/io_utils.py

  • Committer: Package Import Robot
  • Author(s): Matthias Klose
  • Date: 2014-02-19 11:24:23 UTC
  • mfrom: (14.2.23 sid)
  • Revision ID: package-import@ubuntu.com-20140219112423-rkmaz2m7ha06d4tk
Tags: 2.69-3ubuntu1
* Merge with Debian; remaining changes:
  - Configure without OpenImageIO on armhf, as it is not available on
    Ubuntu.

Show diffs side-by-side

added added

removed removed

Lines of Context:
409
409
    if mode == 'ABSOLUTE':
410
410
        return filepath_abs
411
411
    elif mode == 'RELATIVE':
412
 
        return os.path.relpath(filepath_abs, base_dst)
 
412
        try:  # can't always find the relative path (between drive letters on windows)
 
413
            return os.path.relpath(filepath_abs, base_dst)
 
414
        except ValueError:
 
415
            return filepath_abs
413
416
    elif mode == 'STRIP':
414
417
        return os.path.basename(filepath_abs)
415
418