From df2ed1550d69fc05892b9f5d392ff188e46504cd Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 19 Jan 2021 17:24:25 +1100 Subject: [PATCH] Fix T74755: Cap of curve doesn't have smooth shading Copy the smooth setting when filling in curve caps. For drawing this doesn't change behavior as a single normal is used for all faces. The difference may be noticed when converting to a mesh or with modifiers applied. --- source/blender/blenkernel/intern/displist.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source/blender/blenkernel/intern/displist.c b/source/blender/blenkernel/intern/displist.c index 375792a02c2..98af3575081 100644 --- a/source/blender/blenkernel/intern/displist.c +++ b/source/blender/blenkernel/intern/displist.c @@ -488,6 +488,7 @@ void BKE_displist_fill(ListBase *dispbase, while (cont) { int dl_flag_accum = 0; + int dl_rt_accum = 0; cont = 0; totvert = 0; nextcol = 0; @@ -535,6 +536,7 @@ void BKE_displist_fill(ListBase *dispbase, } } dl_flag_accum |= dl->flag; + dl_rt_accum |= dl->rt; } } @@ -544,6 +546,7 @@ void BKE_displist_fill(ListBase *dispbase, dlnew = MEM_callocN(sizeof(DispList), "filldisplist"); dlnew->type = DL_INDEX3; dlnew->flag = (dl_flag_accum & (DL_BACK_CURVE | DL_FRONT_CURVE)); + dlnew->rt = (dl_rt_accum & CU_SMOOTH); dlnew->col = colnr; dlnew->nr = totvert; dlnew->parts = tot;