WIP: Fix to ensure consistent bolt sizes regardless of the user's unit scale preference. #16
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "Ado/add_mesh_BoltFactory:scaling_fix"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fix for #15
This change primarily addresses scaling "issues" or preferences. It now uses a calculated scale instead of the fixed scale defined by the GLOBAL_SCALE variable. Users working with the default scale for this addon will not notice any changes, as it will produce bolts at the "correct" size. For workflows using a scale of 0.001, the bolts will now also be correctly sized.
I've included a couple of pictures for reference. If any clarification is needed, please let me know. I hope this gets merged as soon as possible!
Summary of Changes:
Added adjusted_scale Formula:
@ -170,2 +176,2 @@
min=0.001 * createMesh.GLOBAL_SCALE, soft_min=0, # limit to 0.001*createMesh.GLOBAL_SCALE to avoid calculation error
max=MAX_INPUT_NUMBER * createMesh.GLOBAL_SCALE,
name='Flat Dist (mm)', default=3.0,
min=0.001, soft_min=0, # limit to 0.001*createMesh.GLOBAL_SCALE to avoid calculation error
"createMesh.GLOBAL_SCALE" not needed in the comment.
I've tried with Blender 4.3 on LMDE and the changes work as advertised.
Note: Pending pull #13 adds new lines that contain GLOBAL SCALE around the correction of the thread/shank length - so there is a logic conflict which will need to be resolved in whichever lands second.
Thank you
Checkout
From your project repository, check out a new branch and test the changes.