Regression: Multires data is not loaded if it comes from an external file #107151
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
4 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: blender/blender#107151
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
Operating system: Kubuntu 20.04
Graphics card: Geforce 2080 rtx
Blender Version
version: 3.5.0, branch: blender-v3.5-release, commit date: 2023-03-29 02:56, hash:
1be25cfff1
, type: releaseCaused by
3a3d9488a1
If you sculpt an object with Multires and save the data as an external BTX file, when you reload the file, the Multires Data is no longer loaded.
Steps:
Can confirm, will check
Caused by
3a3d9488a1
Multires data is not loaded if it comes form an external fileto Regression: Multires data is not loaded if it comes form an external fileSeems
layerRead_mdisps
runs properly, but maybe it is not playing nice with the mutable thingie from the culprit commit.I was (blindly) testing the following (to no avail):
CC @HooglyBoogly
It looks like the code before the const correctness cleanup relied on some non-threadsafe logic for reading the original multires displacement. We can get that back with the following diff:
However, that's probably not the right thing to do, since this reading isn't threadsafe, and gives a bunch of memory leaks if a bunch of objects with multires modifiers share the same mesh:
I wonder if there's a better place to call
multiresModifier_ensure_external_read
rather than in the evaluation of the multires modifier. Ideally it would be called on the original mesh directly. @Sergey, any idea about that?@HooglyBoogly I am not really sure either what is the best place to read it for the original mesh. Maybe somewhere after the file load, and on the external path property update? And all other places which are not immediately obvious.
Not sure how often this happens setup happens in practice, and would imagine the old code had the same issues.
Can probably add some lock or something.
Thing is, not sure how much time we want to dedicate on making the current external data to work reliably. It was done to support "variants" of the sculpted data. More proper result is to support multires layers as a built-in core feature.
Guys, this feature has been in Blender since it first landed, I don't know about supporting variants. One key aspect of the BTX files is that if you have a 20gb sculpt, you just save it externally so that the different versions of the blend file don't carry with that heavy weight.
So even you supported Sculpt Layers, which would be great, most of the time saving those layers inside of the blend file would be a very bad option, specially if it's a very dense sculpt.
Regression: Multires data is not loaded if it comes form an external fileto Regression: Multires data is not loaded if it comes from an external file@jpbouza-4 Hey. This is definitely a good point.
The layering does not cancel out the external data. There is also a concern of always reading the data from the file, regardless of whether the modifier will need it or not). I did not go into those topics in the previous reply because it seemed more practical to restore old behavior without for the short-term solution, before going deeper into the code.
The main point was that if the proper fix takes too much time and internal redesign to fit the current state of the feature, it might be better not to do those changes as some of the (not-currently-finalised-planned) sculpt development would need to heavily change the current design yet again.
Hope that makes sense.