Skip to content
Snippets Groups Projects
  • Robert Meerman's avatar
    b0502cd8
    Preserve smoothing options when changing a bolt · b0502cd8
    Robert Meerman authored
    Patch D10037
    
    Prior to this patch the effect of applying the "Shade Smooth" object operator and the value of "Vertex > Auto Smooth" were lost when changing an existing bolt (via context-menu's "Change Bolt").
    
    This patch preserves both.
    
    A simple heuristic is used to detect if "Shade Smooth" has been used: the value of use_smooth of the first polygon in the mesh (prior to activating "Change Bolt"). Experiment has shown that "Shade Smooth" / "Shade Flat" are equivalent to setting use_smooth to True/False (respectively) on every polygon in the mesh.
    
    (No heuristic is needed for Auto Smooth, as it is a top-level property of mesh data blocks)
    b0502cd8
    History
    Preserve smoothing options when changing a bolt
    Robert Meerman authored
    Patch D10037
    
    Prior to this patch the effect of applying the "Shade Smooth" object operator and the value of "Vertex > Auto Smooth" were lost when changing an existing bolt (via context-menu's "Change Bolt").
    
    This patch preserves both.
    
    A simple heuristic is used to detect if "Shade Smooth" has been used: the value of use_smooth of the first polygon in the mesh (prior to activating "Change Bolt"). Experiment has shown that "Shade Smooth" / "Shade Flat" are equivalent to setting use_smooth to True/False (respectively) on every polygon in the mesh.
    
    (No heuristic is needed for Auto Smooth, as it is a top-level property of mesh data blocks)