Average: Custom Normal's functions probably doesn't work #102872

Closed
opened 2022-11-30 12:11:32 +01:00 by Tim Pronin · 5 comments

System Information
Operating system: Windows-10-10.0.19044-SP0 64 Bits
Graphics card: NVIDIA GeForce RTX 2060/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 516.94

Blender Version
Broken: version: 3.3.1, branch: master, commit date: 2022-10-04 18:35, hash: b292cfe5a9
Worked: (newest version of Blender that worked as expected)

Short description of error
Mesh > Normals > Averame > Custom Normal functions (F9) probably doesn't work.

Exact steps for others to reproduce the error

  1. Add any mesh.
  2. Switch mode to Edit Mode.
  3. Select all components.
  4. Call menu Mesh > Normals > Average > Custom Normals. At this point normals changed.
  5. Open bottom menu or press F9 and try change any sliders.
    Changes will not occur. I assumed that this was a mistake, because. these sliders are repeated in the modifier Weighted Normal, but there they work fine!
**System Information** Operating system: Windows-10-10.0.19044-SP0 64 Bits Graphics card: NVIDIA GeForce RTX 2060/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 516.94 **Blender Version** Broken: version: 3.3.1, branch: master, commit date: 2022-10-04 18:35, hash: `b292cfe5a9` Worked: (newest version of Blender that worked as expected) **Short description of error** Mesh > Normals > Averame > Custom Normal functions (F9) probably doesn't work. **Exact steps for others to reproduce the error** 1) Add any mesh. 2) Switch mode to Edit Mode. 3) Select all components. 4) Call menu Mesh > Normals > Average > Custom Normals. At this point normals changed. 5) Open bottom menu or press F9 and try change any sliders. Changes will not occur. I assumed that this was a mistake, because. these sliders are repeated in the modifier Weighted Normal, but there they work fine!
Author

Added subscriber: @timpronin

Added subscriber: @timpronin
Member

Changed status from 'Needs Triage' to: 'Confirmed'

Changed status from 'Needs Triage' to: 'Confirmed'
Member

Added subscriber: @PratikPB2123

Added subscriber: @PratikPB2123
Philipp Oeser removed the
Interest
Modeling
label 2023-02-09 15:27:09 +01:00
Member

Actually, I think Weight & Threshold sliders should not show in case of Type : Custom Normal and should show for both Type : Face Area & Type : Corner Angle

In code, it looks like we are gathering loop_weight with val.

  • this is always 1.0 for EDBM_CLNOR_AVERAGE_LOOP
  • this is taken from BM_face_calc_area for EDBM_CLNOR_AVERAGE_FACE_AREA
  • this is taken from BM_loop_calc_face_angle for EDBM_CLNOR_AVERAGE_ANGLE

Code then compares not equal those values with given threshold, but for EDBM_CLNOR_AVERAGE_LOOP this will never trigger (since all values are the same), thus count is always zero which makes the effective n_weight always 1. So all loop split normals are averaged for a vertex with the same weight (seems to make sense to me -- at is just plain average)

Long story short: the condition to show Weight & Threshold sliders is just flipped (these only apply for the methods that take neighbor faces into account).

Will post a PR fixing this shortly.

Actually, I think `Weight` & `Threshold` sliders should **not** show in case of `Type` : `Custom Normal` and **should** show for both `Type` : `Face Area` & `Type` : `Corner Angle` In code, it looks like we are gathering `loop_weight` with `val`. - this is always 1.0 for `EDBM_CLNOR_AVERAGE_LOOP` - this is taken from `BM_face_calc_area` for `EDBM_CLNOR_AVERAGE_FACE_AREA` - this is taken from `BM_loop_calc_face_angle` for `EDBM_CLNOR_AVERAGE_ANGLE` Code then compares not equal those values with given threshold, but for `EDBM_CLNOR_AVERAGE_LOOP` this will never trigger (since all values are the same), thus `count` is always zero which makes the effective `n_weight` always 1. So all loop split normals are averaged for a vertex with the same weight (seems to make sense to me -- at is just plain average) Long story short: the condition to show `Weight` & `Threshold` sliders is just flipped (these only apply for the methods that take neighbor faces into account). Will post a PR fixing this shortly.
Philipp Oeser self-assigned this 2024-05-16 12:48:55 +02:00
Member

Fix is up, see !121864

Fix is up, see !121864
Blender Bot added
Status
Resolved
and removed
Status
Confirmed
labels 2024-05-21 10:38:29 +02:00
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Code Documentation
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
FBX
Interest
Freestyle
Interest
Geometry Nodes
Interest
glTF
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 & 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
Viewport & EEVEE
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Asset Browser Project
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
Asset System
Module
Core
Module
Development Management
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Module
Viewport & EEVEE
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Severity
High
Severity
Low
Severity
Normal
Severity
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
3 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#102872
No description provided.