Skip to content

Commit

Permalink
fix: add smooth shading step to faux bevel operator
Browse files Browse the repository at this point in the history
  • Loading branch information
tristan-hm committed Jan 25, 2022
1 parent 7eabac6 commit 5f09d2c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions faux_bevel.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ def invoke(self, context, event):

self.key_shift = False

self.add_smooth_shading(context)
self.add_bevel_modifier(context)
self.add_weighted_normal_modifer(context)

Expand All @@ -68,6 +69,11 @@ def poll(cls, context):
return len(context.selected_objects) == 1


def add_smooth_shading(self, context):
context.object.data.use_auto_smooth = True
context.object.data.auto_smooth_angle = radians(30)


def add_bevel_modifier(self, context):
bevel = context.object.modifiers.new("ND — Bevel", 'BEVEL')
bevel.segments = 1
Expand Down

0 comments on commit 5f09d2c

Please sign in to comment.