Fix #108501: Image Editor glitch after texture painting undo #108533

Closed
Dalai Felinto wants to merge 1 commits from dfelinto/blender:fix-image-editor into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.

When doing the second undo, the image wasn't properly marked for full
update.

There reason was that in some cases the partial_updater was
totally reconstructed: first_changeset_id and last_changeset_id were both 0.

While the user_imp->last_changeset_id was still its last value (e.g., 3).

The fix is to have the partial updater validator to check for the
last change set as well (it was only checking for the first change set).

This way we cover both scenarios when user_imp->last_changeset_id is out
of the range of the partial update history.

When doing the second undo, the image wasn't properly marked for full update. There reason was that in some cases the partial_updater was totally reconstructed: `first_changeset_id` and `last_changeset_id` were both 0. While the `user_imp->last_changeset_id` was still its last value (e.g., 3). The fix is to have the partial updater validator to check for the last change set as well (it was only checking for the first change set). This way we cover both scenarios when user_imp->last_changeset_id is out of the range of the partial update history.
Dalai Felinto added the
Module
Sculpt, Paint & Texture
Interest
Images & Movies
labels 2023-06-02 10:44:39 +02:00
Jeroen Bakker was assigned by Dalai Felinto 2023-06-02 10:44:40 +02:00
Dalai Felinto added 1 commit 2023-06-02 10:44:53 +02:00
When doing the second undo, the image wasn't properly marked for full
update.

There reason was that in some cases the partial_updater was
totally reconstructed: `first_changeset_id` and `last_changeset_id` were both 0.

While the `user_imp->last_changeset_id` was still its last value (e.g., 3).

The fix is to have the partial updater validator to check for the
last change set as well (it was only checking for the first change set).

This way we cover both scenarios when user_imp->last_changeset_id is out
of the range of the partial update history.
Jeroen Bakker approved these changes 2023-06-02 10:59:51 +02:00
Jeroen Bakker left a comment
Member

Change makes sense

Change makes sense
Member

@dfelinto @Jeroen-Bakker , can we add this to 3.3 backporting list?

@dfelinto @Jeroen-Bakker , can we add this to 3.3 backporting list?
Pratik Borhade closed this pull request 2023-06-06 11:26:40 +02:00
Author
Owner

@dfelinto @Jeroen-Bakker , can we add this to 3.3 backporting list?

Good point. I added it to the 3.3 list.

> @dfelinto @Jeroen-Bakker , can we add this to 3.3 backporting list? Good point. I added it to the 3.3 list.

Pull request closed

Sign in to join this conversation.
No reviewers
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Code Documentation
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
FBX
Interest
Freestyle
Interest
Geometry Nodes
Interest
glTF
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 & 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
Viewport & EEVEE
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Asset Browser Project
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
Asset System
Module
Core
Module
Development Management
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Module
Viewport & EEVEE
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Severity
High
Severity
Low
Severity
Normal
Severity
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
3 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#108533
No description provided.