bpy.types.Gizmo's boolean scaling properties seem incorrectly inter-related #73858

Closed
opened 2020-02-15 23:03:12 +01:00 by Jesse Yurkovich · 6 comments

System Information
Operating system: Windows-10-10.0.18362-SP0 64 Bits
Graphics card: GeForce GTX 1070 with Max-Q Design/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 441.66

Blender Version
Broken: version: 2.83 (sub 3), branch: master, commit date: 2020-02-14 23:40, hash: 92a56bbe6a
Worked: (optional)

Short description of error

The gist is that:

mpr = self.gizmos.new(...)
mpr.use_draw_scale = True
mpr.use_draw_offset_scale = True

behaves differently than (simply reordering the booleans):

mpr = self.gizmos.new(...)
mpr.use_draw_offset_scale = True
mpr.use_draw_scale = True

The boolean properties seem inter-related but it's not clear if that's by-design as it's not documented anywhere.

Is the following a copy-paste error?

RNA_GIZMO_GENERIC_FLAG_RW_DEF(flag_use_draw_offset_scale, flag, WM_GIZMO_DRAW_OFFSET_SCALE);
RNA_GIZMO_GENERIC_FLAG_NEG_RW_DEF(flag_use_draw_scale, flag, WM_GIZMO_DRAW_OFFSET_SCALE);

Exact steps for others to reproduce the error

gizmo_prop_issue.blend

  • Load the attached .blend (which should have the python open in the script editor already)

  • Run the supplied python in the editor

  • Select the default cube and search for the "Test Mesh Symmetry" operator and invoke it

    • Notice that it works correctly -- the gizmo remains properly scaled as you zoom in and out in the 3d view
  • Change the code that was loaded to switch the order of calls (the # DOES NOT WORK!! part)

  • Repeat above

    • Notice that it does not work correctly now -- the gizmo does not scale correctly. Why did a seemingly unrelated change in boolean order create this situation?
**System Information** Operating system: Windows-10-10.0.18362-SP0 64 Bits Graphics card: GeForce GTX 1070 with Max-Q Design/PCIe/SSE2 NVIDIA Corporation 4.5.0 NVIDIA 441.66 **Blender Version** Broken: version: 2.83 (sub 3), branch: master, commit date: 2020-02-14 23:40, hash: `92a56bbe6a` Worked: (optional) **Short description of error** The gist is that: ``` mpr = self.gizmos.new(...) mpr.use_draw_scale = True mpr.use_draw_offset_scale = True ``` behaves differently than (simply reordering the booleans): ``` mpr = self.gizmos.new(...) mpr.use_draw_offset_scale = True mpr.use_draw_scale = True ``` The boolean properties seem inter-related but it's not clear if that's by-design as it's not documented anywhere. Is the following a copy-paste error? ``` RNA_GIZMO_GENERIC_FLAG_RW_DEF(flag_use_draw_offset_scale, flag, WM_GIZMO_DRAW_OFFSET_SCALE); RNA_GIZMO_GENERIC_FLAG_NEG_RW_DEF(flag_use_draw_scale, flag, WM_GIZMO_DRAW_OFFSET_SCALE); ``` **Exact steps for others to reproduce the error** [gizmo_prop_issue.blend](https://archive.blender.org/developer/F8341902/gizmo_prop_issue.blend) - Load the attached .blend (which should have the python open in the script editor already) - Run the supplied python in the editor - Select the default cube and search for the "Test Mesh Symmetry" operator and invoke it - Notice that it works correctly -- the gizmo remains properly scaled as you zoom in and out in the 3d view - Change the code that was loaded to switch the order of calls (the `# DOES NOT WORK!!` part) - Repeat above - Notice that it does not work correctly now -- the gizmo does not scale correctly. Why did a seemingly unrelated change in boolean order create this situation?
Author
Member

Added subscriber: @deadpin

Added subscriber: @deadpin

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

Changed status from 'Needs Triage' to: 'Confirmed'
Jesse Yurkovich changed title from bpy.types.Gizmo's boolean scaling related properties seem incorrectly inter-related to bpy.types.Gizmo's boolean scaling properties seem incorrectly inter-related 2020-03-02 07:42:26 +01:00
Member

Added subscribers: @mano-wii, @ideasman42, @EAW

Added subscribers: @mano-wii, @ideasman42, @EAW
Member

@mano-wii and @ideasman42, could this be the root cause of the "gizmos are now huge" issue?

@mano-wii and @ideasman42, could this be the root cause of the "gizmos are now huge" issue?

This issue was referenced by 8963671bcc

This issue was referenced by 8963671bcc1ca4965d789f139418c0030d8aa067

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Campbell Barton self-assigned this 2020-09-23 07:52:49 +02:00
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
5 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#73858
No description provided.