Setting origin to Center of Mass on zero-volume objects produces wrong results now in 2.79 #52434

Closed
opened 2017-08-18 09:38:55 +02:00 by Kai Kostack · 9 comments

System Information
Windows 7 x64

Blender Version
Broken: 2.79 RC
Worked: 2.78c

Short description of error
Setting the origin to "Center of Mass" for mesh objects which are not closed and manifold now produces wrong and inconsistent results. Results even change on repetition.

Exact steps for others to reproduce the error

  1. Create a plane
  2. Set 3D cursor to any location but (0, 0, 0)
  3. Set origin of plane to cursor
  4. Set origin of plane to "Center of Mass" (change the type in the operator panel)
    As a result the origin won't be set to the actual center of the plane. Repeating the last step will change the result even.

The .blend only requires step 4:
median-center-on-zero-volume-wrong.blend

Martin Felke found this bug, thanks to him.

**System Information** Windows 7 x64 **Blender Version** Broken: 2.79 RC Worked: 2.78c **Short description of error** Setting the origin to "Center of Mass" for mesh objects which are not closed and manifold now produces wrong and inconsistent results. Results even change on repetition. **Exact steps for others to reproduce the error** 1. Create a plane 2. Set 3D cursor to any location but (0, 0, 0) 3. Set origin of plane to cursor 4. Set origin of plane to "Center of Mass" (change the type in the operator panel) As a result the origin won't be set to the actual center of the plane. Repeating the last step will change the result even. The .blend only requires step 4: [median-center-on-zero-volume-wrong.blend](https://archive.blender.org/developer/F717094/median-center-on-zero-volume-wrong.blend) Martin Felke found this bug, thanks to him.
Author

Changed status to: 'Open'

Changed status to: 'Open'
Author

Added subscriber: @KaiKostack-3

Added subscriber: @KaiKostack-3
Campbell Barton was assigned by Aaron Carlisle 2017-08-20 06:41:34 +02:00

Added subscriber: @pixelgrapher

Added subscriber: @pixelgrapher

In 2.79 RC2, it appears that repeating step 4 causes the origin to asymptotically move closer towards the center.

In 2.79 RC2, it appears that repeating step 4 causes the origin to asymptotically move closer towards the center.
Member

Added subscriber: @jta

Added subscriber: @jta

This issue was referenced by 361c7cbbc5

This issue was referenced by 361c7cbbc57720db3b04698c7e45fe72297e2b24

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'

Added subscriber: @sreich

Added subscriber: @sreich

So I really don't like this.
Setting the origin already has too many options, when is "Origin to Geometry" ever actually useful, especially since we have the "Center of Mass" option.
If anything we should remove the "Geometry" option.
This is not a trivial matter as well, in the past I had several users being confused by this.

If the new method is actually better for solid objects (I would like to believe it since it's the same shoelace algorithm working on tetrahedra but haven't seen the evidence for it) then we should make it work instead of adding another option.
IMO a proper fix would be to figure out why it fails and then either fix it or detect the failing cases and use the appropriate algorithm.

So I really don't like this. Setting the origin already has too many options, when is "Origin to Geometry" ever actually useful, especially since we have the "Center of Mass" option. If anything we should remove the "Geometry" option. This is not a trivial matter as well, in the past I had several users being confused by this. If the new method is actually better for solid objects (I would like to believe it since it's the same shoelace algorithm working on tetrahedra but haven't seen the evidence for it) then we should make it work instead of adding another option. IMO a proper fix would be to figure out why it fails and then either fix it or detect the failing cases and use the appropriate algorithm.
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
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, Assets & 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
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
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
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
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
6 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#52434
No description provided.