shading issue - cycles

did a shape
and tried a lot of things but still getting bad shading triangle on quad face

how to get rid of that bad shading ?
see big front quad
there is a line in diagonal !
this appears in viewport and render

made a test with subsurf and render looks not too bad
but viewport still show diagonal a little bit

see images

thanks
happy bl

Attachments



Maybe try switching from smoothshading to flat shading? (If you haven’t already)

Blender splits quads automatically for rendering, and artifacts like this will appear on simple meshes with smooth shading applied

Another option, if you want to keep the smooth shading, is to add a few loop cuts across the mesh and bevel its sharp edges

already tried a few more subdivide vertical
and I see several diagonals

even with subsurf still can see some residual diagonals

this is a bad headhache for shading worst one i’v seen in a long time

thanks

happy bl

can you post a .blend for me?

I think this may be able to be fixed with custom split-normal data

just did a test
I uploaded factory settings

and shading is good

what could be doing this ?

this is test file with factory setting

edit
I forgot to remove some UV images which are not needed

thanks
happy bl

Attachments

shading-bad1.blend (3.58 MB)

how do you change the custom split normal
never used that one before !

thanks
happy bl

I think it was caused by auto-smooth option in the object data panel.

Do a render with it on, and a render with it off and see if there is a difference

Custom split normals:

In the object data panel enable custom normal data (In the geometry data panel).

Then in edit mode, select sharp edges of your mesh and then in the toolbar->shading set those edges to sharp. then enable auto-smooth
Then you can set the object to shading->smooth, and it will take into account your sharp edges, and not interpolate shading between it’s adjacent faces :slight_smile:

here is my normal file set up and I can see the bad shading

can you see it too ?

here is viewport with bad shading
but now render seems ok

thanks
happy cl

Attachments

shading2.blend (215 KB)


First off, you need to recalculate your normals, they are inverted… I can see the artifacts in viewport, but not in render… hmmm

I will send over a file in a minute with how i would create this object to avoid shading artifacts :slight_smile:

You need to manually triangulate the face, connect the verts in the opposite way to what is causing the shading error and it seems to fix it :slight_smile: (On the lowest poly example)

Before:


After:


I did but needed to flip over for this shape

but even with that still see the diagonal in viewport
but render seems to be better

mind you viewport is far from being realist only a rough and fast approximation
so should not trust it anyway

thanks
happy cl

wait connect manually can you show what you did ?

I know this is unusual shape and might need some tweeking
I mean most objects are not inward like that so might be confusing for shading
or could be a bug

thanks
happy bl

Did you try manually triangulating the mesh like i showed before?

That removed the artifact from the low poly mesh.

Its due to the angles between the verts that make up the quad, its an impossibilty for a flat face to fit the verts, so a triangulated face is all that is shown. inspect the angles between your vertices on these faces and you will see what i mean.

so if you manually triangulate the face in the opposite direction to how blender has, the angles are less extreme and the artifact is no longer visable :slight_smile:

Sorry, didnt notice your last post…

heres what i did:

I selected the two verts in edit mode and pressed J to connect the vertex path.

This then produces cleaner tris that dont produce the artifact. The artifact was top left to bottom right, so i connected top right to bottom left :slight_smile:


tried that and it only changes the angle of the diagonal
and more function of viewing angle too or light rays

thanks
happy bl

Attachments


in any case later I will need to add some thickness to this shape for better rendering
so will see if it comes back later,
I can always add some subsurf which help a little more

thanks for quick feedback
happy cl

No problem, I thought that may happen with the Tri method…

As i said earlier, there is no possible way (i know of) to render a quad of that shape with out artifacts.

One quick fix is to select the face and use the operation: make planar faces.

This changes the shape of the face pretty drastically, but completely removes the artifact


I did a rotation of the object
and now I can see a twist in that front face

which is not suppose to be there
strange I mean I started with a cube and simply move faces
so all faces should be co planar
but they are not somehow

will redo it and see if I get same result

edit
got same results
the bottom face is rectangle down to 1 mm

but front face is twisted and probably back one too
got to better understand why it is crewed up like that !

thanks
happy cl