Regression: Image Editor Speed & Quality Regression #106092

Closed
opened 2023-03-24 10:47:32 +01:00 by Steffen Dünner · 13 comments

System Information
Operating system: Linux-5.15.0-67-generic-x86_64-with-glibc2.35 64 Bits
Graphics card: NVIDIA GeForce RTX 2070 Super/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 530.30.02

Blender Version
Broken: version: 3.6.0 Alpha, branch: main, commit date: 2023-03-24 07:09, hash: 08a6361b3ff8
3.5.0 Release Candidate
Worked: 3.4.1, 3.3.5
Caused by 2ffc9b72ad

Short description of error
I noticed a regression in both speed and quality in the Image Editor in latest main / release candidates. At first I thought my renderings showed artefacts (horizontal / vertical lines, kinks in perfectly straight lines) but when I loaded the same images in older versions of Blender (3.4.1 and earlier), the artefacts were gone.
When zooming in and out, performance is also much worse / stuttering while in 3.4.1 everything is buttery smooth. Panning is not affected, at least not that much.
I attached two simple 4k test patterns that show the problems.
One Bayer Matrix and a simple spiral.

Exact steps for others to reproduce the error

  • Open Blender, press F11 to open an Image Editor

  • Load the "Bayer_Matrix.png"

  • Press 1 on the numpad to set the zoom to 100%

  • In 3.4.1 it looks like this:
    image

  • In 3.6.0 like this:
    image
    Notice the 2 lines where there shouldn't be any

  • Zoom in and out of this image. Notice the speed difference between 3.4.1 and 3.6.0

  • Load the "Spiral.png"

  • 3.4.1:
    image

  • 3.6.0:
    image
    See the "kinks" in the spiral

**System Information** Operating system: Linux-5.15.0-67-generic-x86_64-with-glibc2.35 64 Bits Graphics card: NVIDIA GeForce RTX 2070 Super/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 530.30.02 **Blender Version** Broken: version: 3.6.0 Alpha, branch: main, commit date: 2023-03-24 07:09, hash: `08a6361b3ff8` 3.5.0 Release Candidate Worked: 3.4.1, 3.3.5 Caused by 2ffc9b72ad8db4bc2565119c0a74dbfab9a76e3d **Short description of error** I noticed a regression in both speed and quality in the Image Editor in latest main / release candidates. At first I thought my renderings showed artefacts (horizontal / vertical lines, kinks in perfectly straight lines) but when I loaded the same images in older versions of Blender (3.4.1 and earlier), the artefacts were gone. When zooming in and out, performance is also much worse / stuttering while in 3.4.1 everything is buttery smooth. Panning is not affected, at least not that much. I attached two simple 4k test patterns that show the problems. One Bayer Matrix and a simple spiral. **Exact steps for others to reproduce the error** - Open Blender, press F11 to open an Image Editor - Load the "Bayer_Matrix.png" - Press 1 on the numpad to set the zoom to 100% - In 3.4.1 it looks like this: ![image](/attachments/e95359a1-5ace-4a60-b54b-e0bad85a6d49) - In 3.6.0 like this: ![image](/attachments/86846cf3-c05f-42da-86dd-251a37040220) Notice the 2 lines where there shouldn't be any - Zoom in and out of this image. Notice the speed difference between 3.4.1 and 3.6.0 - Load the "Spiral.png" - 3.4.1: ![image](/attachments/87a13e69-2dd3-4db9-abe9-87efacc7c0d0) - 3.6.0: ![image](/attachments/fb5fbefd-74c3-4da8-a0d4-b84549d99786) See the "kinks" in the spiral
Steffen Dünner added the
Priority
Normal
Type
Report
Status
Needs Triage
labels 2023-03-24 10:47:33 +01:00

I have the described problem also in 3.5 on Mac OSX.
See in 100% lines and heavy flickering when moving the image. This is not in 3.4.1

version: 3.5.0 Release Candidate, branch: blender-v3.5-release, commit date: 2023-03-24 01:57, hash: 6caccf6b9f, type: Release
build date: 2023-03-24, 11:04:39
platform: 'macOS-13.2.1-x86_64-i386-64bit'

I have the described problem also in 3.5 on Mac OSX. See in 100% lines and heavy flickering when moving the image. This is not in 3.4.1 version: 3.5.0 Release Candidate, branch: blender-v3.5-release, commit date: 2023-03-24 01:57, hash: 6caccf6b9f20, type: Release build date: 2023-03-24, 11:04:39 platform: 'macOS-13.2.1-x86_64-i386-64bit'
Member

Thanks for the report. I can confirm. Bisecting...

Thanks for the report. I can confirm. Bisecting...
Pratik Borhade changed title from Image Editor Speed & Quality Regression to Regression: Image Editor Speed & Quality Regression 2023-03-27 08:30:09 +02:00
Pratik Borhade added
Priority
High
and removed
Priority
Normal
labels 2023-03-27 08:30:26 +02:00
Member
Caused by 2ffc9b72ad8db4bc2565119c0a74dbfab9a76e3d @Jeroen-Bakker ^
Jeroen Bakker self-assigned this 2023-03-27 08:52:46 +02:00
Member

After the lines are solved we can increase the performance (there is a setting for that), but I didn't enable it because it would add more artifacts then shown here.

I will spend some time here this week. Although I don't think it will be ready for the 3.5 release which is in two days. This fix might take longer time to fix. I will keep it as high prio for now.

After the lines are solved we can increase the performance (there is a setting for that), but I didn't enable it because it would add more artifacts then shown here. I will spend some time here this week. Although I don't think it will be ready for the 3.5 release which is in two days. This fix might take longer time to fix. I will keep it as high prio for now.
Jeroen Bakker added this to the EEVEE & Viewport project 2023-03-27 08:57:27 +02:00
Member

After doing some tries to fix it the required changes requires some larger changes in order to fix these artifacts. Due to this and the upcoming release of Blender 3.5.0 I don't believe it is reasonable to target the fix for that release. I would suggest to land it in main and backport it to 3.5.1 eventually.

After doing some tries to fix it the required changes requires some larger changes in order to fix these artifacts. Due to this and the upcoming release of Blender 3.5.0 I don't believe it is reasonable to target the fix for that release. I would suggest to land it in main and backport it to 3.5.1 eventually.
Hans Goudey added
Type
Bug
and removed
Type
Report
labels 2023-03-27 14:44:19 +02:00
Contributor

I think I've reported this as well, under #106390

So my report is likely also a duplicate. Worth noting that like the previous image editor performance issues, this one also affects not only the drawing of the editor, but also the UI performance, so resizing any border of the image editor is laggy as well.

I think I've reported this as well, under https://projects.blender.org/blender/blender/issues/106390 So my report is likely also a duplicate. Worth noting that like the previous image editor performance issues, this one also affects not only the drawing of the editor, but also the UI performance, so resizing any border of the image editor is laggy as well.
Jeroen Bakker added this to the 3.6 LTS milestone 2023-04-11 08:58:46 +02:00
Member

Although there is an initial fix that brings the performance back to 3.4 era (#106173). There are ideas how to improve the performance back to 3.0 era. This requires more development and should not be handled as a bug report. Idea of the solution is to check if the image fits in GPU memory and if this is the case we draw the image using a single GPU texture.

If it doesn't fit we will fall back to the current implementation. For this to work we need to revert

  • Keep track of GPUTextures without checking the limit texture size
    option in the user preference. This should be a variant of a previous
    implementation that was removed a year ago. But without doing any
    resizing. Related commit that reverted previous implementation
    f41c7723c9
  • When this texture cannot be created we should fall back to the current screen
    space solution
  • Add an image based solution when texture fits on the GPU without resizing.

For now I am confident that that #106173 can be added to 3.6. I expect more smaller changes to reduce some artifacts so I don't want it to land in 3.5. The solution to get back to the performance of 3.0 era requires around 1 week of development time and will plan that for 3.6 as well. When this will be done depends on the priority of
other issues as well.

I will lower the priority of this issue as there is a plan to move forward, but requires more development time than is expected from a bug-fix.

Although there is an initial fix that brings the performance back to 3.4 era (#106173). There are ideas how to improve the performance back to 3.0 era. This requires more development and should not be handled as a bug report. Idea of the solution is to check if the image fits in GPU memory and if this is the case we draw the image using a single GPU texture. If it doesn't fit we will fall back to the current implementation. For this to work we need to revert - Keep track of GPUTextures without checking the limit texture size option in the user preference. This should be a variant of a previous implementation that was removed a year ago. But without doing any resizing. Related commit that reverted previous implementation f41c7723c93bc9e784634887da8b682787729538 - When this texture cannot be created we should fall back to the current screen space solution - Add an image based solution when texture fits on the GPU without resizing. For now I am confident that that #106173 can be added to 3.6. I expect more smaller changes to reduce some artifacts so I don't want it to land in 3.5. The solution to get back to the performance of 3.0 era requires around 1 week of development time and will plan that for 3.6 as well. When this will be done depends on the priority of other issues as well. I will lower the priority of this issue as there is a plan to move forward, but requires more development time than is expected from a bug-fix.
Jeroen Bakker added
Priority
Normal
and removed
Priority
High
labels 2023-04-11 09:09:14 +02:00
Contributor

I will lower the priority of this issue as there is a plan to move forward, but requires more development time than is expected from a bug-fix.

This report specifically concerns the performance regression from 3.4 to 3.5. Not 3.0 to 3.5. It should stay high priority and be fixed ASAP, because the regression is rather extreme in the way it impacts day to day UV editing work.

If you have an idea how to bring the performance back to 3.0 levels, then that's not a bug report and should perhaps be created as a new task. But this one isn't. This one is a bug report, the one that documents regression from 3.4 to 3.5. It should be fixed, solved and closed.

> I will lower the priority of this issue as there is a plan to move forward, but requires more development time than is expected from a bug-fix. > This report specifically concerns the performance regression from 3.4 to 3.5. Not 3.0 to 3.5. It should stay high priority and be fixed ASAP, because the regression is rather extreme in the way it impacts day to day UV editing work. If you have an idea how to bring the performance back to 3.0 levels, then that's not a bug report and should perhaps be created as a new task. But this one isn't. This one is a bug report, the one that documents regression from 3.4 to 3.5. It should be fixed, solved and closed.
Member

@Rawalanche That only addresses the second part of this report.

Note that priority is determined by many factors and according to our rules include the amount of work as well. So I keep to what I said before:

  • add initial fix to almost 3.4 speed in 3.6 by committing #106173. This fixes only a part of what is addressed here. And still requires more work to fix potential artifacts.
  • In main branch we should check and fix potential drawing artifacts Is also part of this this report.

This task isn't only about the performance, also about the quality of the drawing.

@Rawalanche That only addresses the second part of this report. Note that priority is determined by many factors and according to our rules include the amount of work as well. So I keep to what I said before: - add initial fix to almost 3.4 speed in 3.6 by committing #106173. This fixes only a part of what is addressed here. And still requires more work to fix potential artifacts. - In main branch we should check and fix potential drawing artifacts Is also part of this this report. This task isn't only about the performance, also about the quality of the drawing.
Contributor

@Rawalanche That only addresses the second part of this report.

Note that priority is determined by many factors and according to our rules include the amount of work as well. So I keep to what I said before:

  • add initial fix to almost 3.4 speed in 3.6 by committing #106173. This fixes only a part of what is addressed here. And still requires more work to fix potential artifacts.
  • In main branch we should check and fix potential drawing artifacts Is also part of this this report.

This task isn't only about the performance, also about the quality of the drawing.

Wait, so we will have to wait entire 4 months for a next major 3.6 release just to have the performance back to essential usable levels? I assumed the "initial" fix would be in 3.5.1...?

> @Rawalanche That only addresses the second part of this report. > > Note that priority is determined by many factors and according to our rules include the amount of work as well. So I keep to what I said before: > - add initial fix to almost 3.4 speed in 3.6 by committing #106173. This fixes only a part of what is addressed here. And still requires more work to fix potential artifacts. > - In main branch we should check and fix potential drawing artifacts Is also part of this this report. > > This task isn't only about the performance, also about the quality of the drawing. Wait, so we will have to wait entire 4 months for a next major 3.6 release just to have the performance back to essential usable levels? I assumed the "initial" fix would be in 3.5.1...?
Member

That depends on the quality of the fix. Currently it introduces more artifacts so that needs to be solved before it can actually land. Besides that there are some platform specific crashes/issues that are put on my desk, that have a higher priority than this ticket.

So if we are able to fix the artifacts before 3.5.1 is released it might land there.
Fixing issues isn't done in an hour/minute. Sometimes it takes days or weeks (like this one).

That depends on the quality of the fix. Currently it introduces more artifacts so that needs to be solved before it can actually land. Besides that there are some platform specific crashes/issues that are put on my desk, that have a higher priority than this ticket. So if we are able to fix the artifacts before 3.5.1 is released it might land there. Fixing issues isn't done in an hour/minute. Sometimes it takes days or weeks (like this one).
Contributor

That depends on the quality of the fix. Currently it introduces more artifacts so that needs to be solved before it can actually land. Besides that there are some platform specific crashes/issues that are put on my desk, that have a higher priority than this ticket.

So if we are able to fix the artifacts before 3.5.1 is released it might land there.
Fixing issues isn't done in an hour/minute. Sometimes it takes days or weeks (like this one).

Then wouldn't it be possible to just revert the commit to 3.4 state? Even the basic navigation (panning and zooming) in the UV editor is now painful, when it runs about 5-10FPS even on RTX2080Ti.

> That depends on the quality of the fix. Currently it introduces more artifacts so that needs to be solved before it can actually land. Besides that there are some platform specific crashes/issues that are put on my desk, that have a higher priority than this ticket. > > So if we are able to fix the artifacts before 3.5.1 is released it might land there. > Fixing issues isn't done in an hour/minute. Sometimes it takes days or weeks (like this one). Then wouldn't it be possible to just revert the commit to 3.4 state? Even the basic navigation (panning and zooming) in the UV editor is now painful, when it runs about 5-10FPS even on RTX2080Ti.
Blender Bot added
Status
Resolved
and removed
Status
Confirmed
labels 2023-04-11 16:20:41 +02:00

Awesome! I can totally live with this speed&quality fix 👍

Awesome! I can totally live with this speed&quality fix 👍
Sign in to join this conversation.
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 Assignees
5 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#106092
No description provided.