Page MenuHome

Multires: normals not updating when using smooth shading
Closed, ResolvedPublic

Description

System Information
Operating system: Linux
Graphics card: Nvidia GeForce GTX 1050 Ti

Blender Version
Broken:
March 06, 14:18:14 - 3fc7d51ed3d3Beta

Worked:

Short description of error

Smooth Shading in sculpting mode does not update correctly when you deactivate Overlays.

Exact steps for others to reproduce the error

  1. Open Blender.
  2. Right click on cube shade smooth.
  3. Change to sculpt Mode.
  4. Use Mutires modifier.
  5. Deactivate Overlays.
  6. Try to sculpt

You can watch the behavior here.

Event Timeline

Sebastian Parborg (zeddb) triaged this task as Confirmed, Medium priority.

Overlays is not something i can control from sculpt/multires.

It looks like normals are not being recalculated for some reason.

Now it doesn't work with smooth shading (overlays doesn't seem to matter anymore).

Hello, for some reason with a more complex scene the bug behavior changes, now it computes after strokes end, with an addition now I can't undo strokes, it will only undo to the first sculpt stroke, not to the previous stroke.

here is the file with more complex scene.

Jeroen Bakker (jbakker) renamed this task from Smooth Shading in sculpting mode does not update correctly when deactivate Overlays. to Smooth Shading Not Updating When Using MultiRes Sculpting.May 15 2019, 10:20 AM
Alex (Sen) added a subscriber: Alex (Sen).EditedMay 23 2019, 4:22 AM

I just realized that I reported something very similar here: T64586
Although, it happens independent from the overlays to me.

Another report about this can also be found here: T64778

The last version of 2.8 where the normal updates for multires still worked at all was: version: 2.80 (sub 60), branch: blender2.7, commit date: 2019-05-03 21:09, hash: rBee0d8426ab6d

This is too bad because it makes sculpting somewhat unusable in 2.8.

The normal update also occurs when simply leaving sculpt-mode by going back to object-mode or when changing anything in the object geometry-data.

Brecht Van Lommel (brecht) raised the priority of this task from Confirmed, Medium to Confirmed, High.

Marking as high priority given the number of reports.

One of the next commits is the source of the issue.

rBb2f1a6587410: Sculpt: Refactor draw manager sculpt drawing mechanism (Skipped due to compile error)
rBfb3b2ab709bf: Cleanup: Remove unused code in sculpt_mode, workbench and draw manager (Skipped due to compile error)
rBf302224e161c: Cleanup: Eevee: Remove Flat normal shader variation (First compilable bad commit)

Will fix the issues per commit to see who is the actual source of the issue.
rBfb3b2ab709bf: Cleanup: Remove unused code in sculpt_mode, workbench and draw manager Seems to be the issue. It removed the function DRW_cache_mesh_sculpt_coords_ensure and the call to it. Will need to check with @Clément Foucault (fclem) what would be the correct solution to move forward.

@Clément Foucault (fclem) solution to move forward is:

if you want to fix this do it in drw_sculpt_generate_calls to avoid duplication. I think its a matter of porting what sculpt_update_pbvh_normals was doing