Smooth Shading renders semi abrupt triangles #89320

Closed
opened 2021-06-20 22:00:29 +02:00 by Facundo Albarracin Garnica · 19 comments

System Information
Operating system: Windows 10
Graphics card: Radeon RX 590

Blender Version
Broken: 2.93.0, 84da05a8b8, master, 2021-06-02
Worked: 2.92.0, 02948a2cab, master, 2021-02-24

Short description of error
I haven't checked Cycles because I don't use it, but in Eevee; Render View, Material Preview, and Render per se, render the triangles that constitute each quad/ngon/triangles even if the mesh is smooth shaded. For better understanding please see the comparison of versions in the attached image. The faces are with smooth shading and there are no custom normals. The way it renders is as if it were a mixture of smooth and flat shading.

If you set them as flat, it clearly renders very flat as usual, but when set as smooth, I don't know, it looks like the normals vectors that Blender normally would arrange for smooth shading do not properly blend at the borders of each face. Even if the face is a quad, which is composed by 2 tris, the edge that separates those "imaginary" tris is also rendered.

This didn't happen before. The transition between the faces was really smooth before this version.
Thank you and sorry for the trouble.

Exact steps for others to reproduce the error
You can create any shape, set it as smooth shading, and it should already be visible. To make it more explicit, move any vertex/edge, so that there is an abrupt change in the direction of the "vertex flow". If you raise specularity it's easier to spot. This enhances the thing and makes the abrupt change in normals be clearly visible. In previous versions the transition would be really smooth, here it looks as if it was flat (though it isn't because if you set it as flat, then the transition is much more abrupt).

Blender 2.93 Smooth Shading Triangles Rendered.png

**System Information** Operating system: Windows 10 Graphics card: Radeon RX 590 **Blender Version** Broken: 2.93.0, 84da05a8b806, master, 2021-06-02 Worked: 2.92.0, 02948a2cab44, master, 2021-02-24 **Short description of error** I haven't checked Cycles because I don't use it, but in Eevee; Render View, Material Preview, and Render per se, render the triangles that constitute each quad/ngon/triangles even if the mesh is smooth shaded. For better understanding please see the comparison of versions in the attached image. The faces are with smooth shading and there are no custom normals. The way it renders is as if it were a mixture of smooth and flat shading. If you set them as flat, it clearly renders very flat as usual, but when set as smooth, I don't know, it looks like the normals vectors that Blender normally would arrange for smooth shading do not properly blend at the borders of each face. Even if the face is a quad, which is composed by 2 tris, the edge that separates those "imaginary" tris is also rendered. This didn't happen before. The transition between the faces was really smooth before this version. Thank you and sorry for the trouble. **Exact steps for others to reproduce the error** You can create any shape, set it as smooth shading, and it should already be visible. To make it more explicit, move any vertex/edge, so that there is an abrupt change in the direction of the "vertex flow". If you raise specularity it's easier to spot. This enhances the thing and makes the abrupt change in normals be clearly visible. In previous versions the transition would be really smooth, here it looks as if it was flat (though it isn't because if you set it as flat, then the transition is much more abrupt). ![Blender 2.93 Smooth Shading Triangles Rendered.png](https://archive.blender.org/developer/F10183880/Blender_2.93_Smooth_Shading_Triangles_Rendered.png)

Added subscriber: @Celessude

Added subscriber: @Celessude

Added subscriber: @WCN

Added subscriber: @WCN

Do AO or shadow settings affect this?

I am not a Blender developer.

Do AO or shadow settings affect this? I am not a Blender developer.

Nope, I tried that too before creating the report. I tried everything really. So I concluded it has to be the way the engine deals with calculated normal vectors for smooth blend. I might be wrong though because I'm not a developer either. But that's what it looks like because same file is displayed and rendered correctly in previous versions. Any files actually, I tried the same with all my projects and as I mentioned in the report, it can be reproduced by simply adding any shape in the scene. I simply referred to a sphere because is the best for testing smooth/flatness contrary to a cube, but a cube should do the same as well; it's just that because its shape is by definition way more abrupt (90 degrees each face from others) it would be harder to spot the thing because you are expecting it to be a really abrupt change and not so smooth.

Nope, I tried that too before creating the report. I tried everything really. So I concluded it has to be the way the engine deals with calculated normal vectors for smooth blend. I might be wrong though because I'm not a developer either. But that's what it looks like because same file is displayed and rendered correctly in previous versions. Any files actually, I tried the same with all my projects and as I mentioned in the report, it can be reproduced by simply adding any shape in the scene. I simply referred to a sphere because is the best for testing smooth/flatness contrary to a cube, but a cube should do the same as well; it's just that because its shape is by definition way more abrupt (90 degrees each face from others) it would be harder to spot the thing because you are expecting it to be a really abrupt change and not so smooth.

Also, it might be a video card thing too. I've had some graphic rather than functionality bugs before in some versions which ended up being the AMD graphics card's latest driver for the time. But I haven't had issues since december regarding that. And the latest driver works perfectly with 2.92 and previous versions. So I don't know, I'm just reporting this just in case there's an issue regarding normals blend when smoothing for version 2.93.
I'll continue using 2.92 meanwhile since there's not that much I make use of in the latest 2.93 to be honest.

Also, it might be a video card thing too. I've had some graphic rather than functionality bugs before in some versions which ended up being the AMD graphics card's latest driver for the time. But I haven't had issues since december regarding that. And the latest driver works perfectly with 2.92 and previous versions. So I don't know, I'm just reporting this just in case there's an issue regarding normals blend when smoothing for version 2.93. I'll continue using 2.92 meanwhile since there's not that much I make use of in the latest 2.93 to be honest.

Added subscriber: @ktdfly

Added subscriber: @ktdfly

Duplicated #88368?

Duplicated #88368?
Member

Added subscriber: @lichtwerk

Added subscriber: @lichtwerk
Member

Changed status from 'Needs Triage' to: 'Needs User Info'

Changed status from 'Needs Triage' to: 'Needs User Info'
Member

Just to make sure we are all on the same page: could you share an example .blend file where this issue is demonstrated?

Just to make sure we are all on the same page: could you share an example .blend file where this issue is demonstrated?

Yes, I prepared a basic setup and it's attached here.
Btw it seems to be the same as the one that's marked as duplicated by Mikhail Matrosov. I really looked for duplicates when creating the report but I filtered by smooth and since I found nothing I created it. If it's the same, sorry for the doubles.

Just a basic sphere.blend

Yes, I prepared a basic setup and it's attached here. Btw it seems to be the same as the one that's marked as duplicated by Mikhail Matrosov. I really looked for duplicates when creating the report but I filtered by smooth and since I found nothing I created it. If it's the same, sorry for the doubles. [Just a basic sphere.blend](https://archive.blender.org/developer/F10186554/Just_a_basic_sphere.blend)

Added subscriber: @chemicalcrux

Added subscriber: @chemicalcrux

It definitely looks different in older versions of Blender. I had a copy of 2.8 lying around, and I can't see the sharp edges that show up in 2.93

I triangulated the mesh, just to make sure it doesn't depend on non-planar quads (because those quads sure were non-planar :p ). 2.93 on top, 2.8 down below

image.png

They look identical with flat faces. The other smooth/sharp options didn't have any effect.

I'll try bisecting this -- between v2.92.0 and v2.93.0

It definitely looks different in older versions of Blender. I had a copy of 2.8 lying around, and I can't see the sharp edges that show up in 2.93 I triangulated the mesh, just to make sure it doesn't depend on non-planar quads (because those quads sure were non-planar :p ). 2.93 on top, 2.8 down below ![image.png](https://archive.blender.org/developer/F10186668/image.png) They look identical with flat faces. The other smooth/sharp options didn't have any effect. I'll try bisecting this -- between v2.92.0 and v2.93.0

This was introduced by 1c22b551d0

I think the problem is that these faces are actually pointing away from the light. If you switch to Cycles, the faces are both in shadow.

If you move the light so that it's on the correct side of the faces, then it will look completely smooth.

So, the 2.92 behavior is wrong, because it showed a reflection for a light that was on the wrong side of the face. But the 2.93 behavior causes the right face to receive no specular lighting, whilst the left face receives significant specular lighting.

I guess the logic in the above commit uses the normal of the face being considered, rather than the smoothed normal? Not sure if it'd be practical to do that; I have very little experience here.

This was introduced by 1c22b551d0 I think the problem is that these faces are actually pointing *away* from the light. If you switch to Cycles, the faces are both in shadow. If you move the light so that it's on the correct side of the faces, then it will look completely smooth. So, the 2.92 behavior is wrong, because it showed a reflection for a light that was on the wrong side of the face. But the 2.93 behavior causes the right face to receive no specular lighting, whilst the left face receives significant specular lighting. I guess the logic in the above commit uses the normal of the face being considered, rather than the smoothed normal? Not sure if it'd be practical to do that; I have very little experience here.

Actually, 2.93 is wrong. I just put one source of light here and one sphere, and all is seen by one camera angle. But if you have organic shapes which have lots of these irregularities I made by moving only the vertex in the sphere example, and also take into account the several lights a scene can have, that which you said about "reflection for a light that was on the wrong side of the face" loses the logic. Here is a render in a scene (with like 7 lights and 1 HDRI) of the same girl I posted on the first attachment. It is also subsurfaced in order to make it smooth, but it can still be clearly seen.

More examples.png

Actually, 2.93 is wrong. I just put one source of light here and one sphere, and all is seen by one camera angle. But if you have organic shapes which have lots of these irregularities I made by moving only the vertex in the sphere example, and also take into account the several lights a scene can have, that which you said about "reflection for a light that was on the wrong side of the face" loses the logic. Here is a render in a scene (with like 7 lights and 1 HDRI) of the same girl I posted on the first attachment. It is also subsurfaced in order to make it smooth, but it can still be clearly seen. ![More examples.png](https://archive.blender.org/developer/F10186995/More_examples.png)

Also, one more thing. If we get really technical. Yes, 2.92 is wrong. But also 2.93 is wrong. What smooth shading does is an approximation by blending normals. It doesn't mean it is correct physically. The math does what is best in order to simulate reality based as well in what the user thinks best approximates. In this case, smooth shade is better than flat, because it is an organic smooth shape. Of course the less geometry the less accurate it is the simulation. But previous versions did a better job of making the thing look smooth rather than flat than this version 2.93 (and also 3.00 after looking at this report https://developer.blender.org/T88368).

Also, one more thing. If we get really technical. Yes, 2.92 is wrong. But also 2.93 is wrong. What smooth shading does is an approximation by blending normals. It doesn't mean it is correct physically. The math does what is best in order to simulate reality based as well in what the user thinks best approximates. In this case, smooth shade is better than flat, because it is an organic smooth shape. Of course the less geometry the less accurate it is the simulation. But previous versions did a better job of making the thing look smooth rather than flat than this version 2.93 (and also 3.00 after looking at this report https://developer.blender.org/T88368).
Member

Changed status from 'Needs User Info' to: 'Needs Triage'

Changed status from 'Needs User Info' to: 'Needs Triage'
Member

Turns out #88368 (Regression: broken normal shading, sharp edges appear on smooth surfaces.) wasnt resolved fully, will merge these reports

Turns out #88368 (Regression: broken normal shading, sharp edges appear on smooth surfaces.) wasnt resolved fully, will merge these reports
Member

Closed as duplicate of #88368

Closed as duplicate of #88368
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 project
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#89320
No description provided.