Opening an image with 'relative path' selected, gets absolute path. #38808
Labels
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
6 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender#38808
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
System Information
OS X 10.8.5 (12F45)
NVIDIA GeForce GT 650M 1024 MB
Blender Version
8d023c1
Broken: 2.69.11
8d023c1
Worked: 2.69.0 r60991
Short description of error
If you open an image and check the option 'relative path' it returns the absolute path.
Exact steps for others to reproduce the error
It seems like the error is in 'bpy.ops.image.open()'. If you have opened an image in the UV/Image Editor and after that use the browse button under 'source' ('bpy.ops.buttons.file_browse()') it does return the relative path.
Changed status to: 'Open'
Added subscriber: @jasperge-2
Added subscriber: @dfelinto
confirmed on OSX
It seems that even in 2.69 opening an image via script would always set the path to be absolute.
For example:
This issue was referenced by blender/blender-addons-contrib@b6bb6d1b2c
This issue was referenced by
b6bb6d1b2c
Changed status from 'Open' to: 'Resolved'
Closed by commit
b6bb6d1b2c
.Added subscriber: @sebastian_k
It seems this error came back somehow.
I am getting the exact same broken behavior in 2.73.8 (
86a2e9d
).Here's a sample folder with image and blendfile. Notice the image is loaded with relative path. However, if i open the same image with alt+o or the open image button, it gets an absolut path, even though the relative path checkbox is activated.
rel_path.zip
Changed status from 'Resolved' to: 'Open'
Hmm, it seems there are some strange things going on. If I open your test file, I indeed have the error. But if I open another image, it does have a relative path. Also with other files. If I completely remove the image (shift + click on the X), save the file and re-open, I can also open the image with relative path.
Blender version 2.73.8 (
cdc1dab
)Added subscriber: @jensverwiebe
I found it.
The cause of the problem is in image_ops.c line 1090:
Either the !exist must be changesd or we need an extra test. But this way the path for
an existing file would never be changed, a new file will !
I think we can/should remove the "!exists" test.
Cambo ?
Jens
The logic for
exists
is:This came from the observation that dragging and dropping an image, could modify its path.
However as @sebastian_k noticed, re-opening same image makes path absolute, fixing.
This issue was referenced by
5115e86246
Changed status from 'Open' to: 'Resolved'
Closed by commit
5115e86246
.I still find this a bit fuzzy.
The checkbox for relative/absolute is available still, so as a user I would expect that it works. Especially because in all image related buttons in Cycles the textbox to change the source path is not available, only from inside the image editor.
@sebastian_k, it is awkward.
The issue with using existing data its already used elsewhere & IMHO opening an image really shouldn't modify existing loaded data.
We could have a notification when loading an image "Info: Using existing image", Then at least the user know whats going on, it could even notify that the existing image has different relative setting.
If they want to change paths then - they can select the image and change the paths.