Maniphest T32209

Autosave ignores multires sculpting (patch attached)
Closed, Resolved

Assigned To
Antonis Ryakiotakis (psy-fi)
Authored By
Nicholas Bishop (nicholasbishop)
Jul 28 2012, 7:19 PM
Tags
  • BF Blender
  • Sculpt, Paint & Texture
Subscribers
Antonis Ryakiotakis (psy-fi)
Campbell Barton (campbellbarton)
Jonathan Ringstad (Amadiro)
Nicholas Bishop (nicholasbishop)
Sergey Sharybin (sergey)

Description

Steps to reproduce from the default cube:
1) Add multires and subdivide five times (exact number of subdivisions doesn't matter)
2) Enable sculpt mode
3) Sculpt a brush stroke on the mesh
4) Wait for an autosave to occur
5) Open the autosave file

Result: the autosaved file will show an unmodified mesh (missing the brush stroke.)

Regular file save calls ED_sculpt_force_update() to correct this, but autosave doesn't seem to have the right context. I've attached a patch that seems to work, looping over all meshes via G.main, but as I'm not familiar with this part of the code I'd like confirmation this is OK.

Revisions and Commits

Abandoned
rB Blender

Event Timeline

Nicholas Bishop (nicholasbishop) edited a custom field.Jul 28 2012, 7:19 PM
Nicholas Bishop (nicholasbishop) attached 1 file(s): F18439: autosave-multires-fix-00.diff.
Sergey Sharybin (sergey) added a comment.Jul 30 2012, 9:51 PM

Nick, would check your patch.

Sergey Sharybin (sergey) added a comment.Aug 1 2012, 11:05 AM

Fixed in svn rev49438. Thanks for the report and patch, closing now.

Sergey Sharybin (sergey) changed the task status from Unknown Status to Resolved.Aug 1 2012, 11:05 AM
Jonathan Ringstad (Amadiro) changed the task status from Resolved to Unknown Status.Aug 8 2014, 11:49 PM
Jonathan Ringstad (Amadiro) added a subscriber: Jonathan Ringstad (Amadiro).

This seems to be an issue again with 2.71 (772af36).

To reproduce:

  • open blender
  • in preferences, set autosave to 1 minute
  • save preferences, quit blender
  • open blender with default scene
  • go into sculpt mode
  • manipulate cube
  • leave blender running for 5 minutes, without exiting sculpt mode
  • kill blender forcefully

When recovering the autosave afterwards, the sculpted changes are not there. Just lost about an hour of sculpting work that way.

Jonathan Ringstad (Amadiro) triaged this task as High priority.Aug 9 2014, 1:02 AM

Confirmed with a freshly built blender (ee8dafe). Upping priority to "high", which seems appropriate, since this can cause total loss of the users work.

Sergey Sharybin (sergey) lowered the priority of this task from High to Normal.Aug 11 2014, 9:13 AM
Sergey Sharybin (sergey) added a subscriber: Antonis Ryakiotakis (psy-fi).

Please don't triage priority by self. For every reporter his own report is top-prio, no doubts. But this confuses our bug smashing process.

Me or @Antonis Ryakiotakis (psy-fi) will have a look asap.

Antonis Ryakiotakis (psy-fi) claimed this task.Aug 11 2014, 3:53 PM
Antonis Ryakiotakis (psy-fi) added a revision: D734: Fix T32209.Aug 11 2014, 5:05 PM
Antonis Ryakiotakis (psy-fi) added a subscriber: Campbell Barton (campbellbarton).

OK, this is undo related. The issue is that we write the undo stack in the file which pretty much ignores the edit stacks completely (same would happen in edit mode). Issue also exists with quit.blend.

@Campbell Barton (campbellbarton) can you take a look at the attached patch?

Antonis Ryakiotakis (psy-fi) changed the task status from Unknown Status to Resolved.Oct 10 2014, 12:05 PM
Antonis Ryakiotakis (psy-fi) added a commit: rB585d2f31a9c4: Fix T32209 quitting not saving latest data if you are in edit or sculpt mode on….

Closed by commit rB585d2f31a9c4.

Antonis Ryakiotakis (psy-fi) added a comment.Oct 13 2014, 11:22 AM

After discussion we agreed that we wouldn't want to slow down autosave - remember it gets called even during rendering, it should really be as fast as possible.

Anyway, I think solution here is to warn explicitly that edit mode and sculpt mode are not supported here.

Sergey Sharybin (sergey) mentioned this in T48929: autosave doesn't save like normal save.Jul 26 2016, 5:35 PM