💡 LightUp 7.1 | SketchUp's only real-time renderer that uses object-based rendering
Download Trial
Component Axes
-
When I create a component via .add_group and then .to_component, the component axes are set to the lower left extremities. Meanwhile, making a component via the Edit menu, I can specify the Component Axes in the dialog.
How can I set or move the component axes when I create the definition via Ruby?Many thanks for any assistance!
--J
-
FYI, You can change the insertion point
insertion_point=
.You can also apply a transform to the entire entities of the definition ...
ctr = cdef.bounds.center # Center of untransformed bounds # Arrays are compatible with translational transformations; xform = [ctr.x, ctr.y, 0].vector_to(ORIGIN) cdef_ents = cdef.entities # Move all the entities so that the axis is in the bottom center; cdef_ents.transfrom_entities(xform, cdef_ents.to_a)
-
Boom! That worked!
Thank you sir!--J
Advertisement