Open Daniel4144 opened 6 months ago
@Daniel4144, would you like to submit a pull request for your implementation? The community could then review and see them in action.
@shaynie I can certainly share the custom handle, if you want?
But it is not optimized for general use (does not scale well with object size, etc.) and does not contain the suggested planar translation.
It's just a very simple alternative to the existing prefab BoundingBoxWithHandles
created from existing MRTK components (which are great btw, made it easy to create this).
I submitted a pull request for the translation handle types (was surprisingly simple to implement).
For maximum flexibility additional handle types for scaling (1D, 2D, 3D) would make sense in my opinion, although I don't need them at the moment.
Describe the problem
Unity provides great tools for object movement. Although MRTK also has nice options for creating such handles, I am missing especially one option: The planar handles for two dimensional translation. In my opinion it is often desired to move an object in two dimensions, e.g. ignoring depth or height, which is not possible with the available bounds handles.
Describe the solution you'd like
An additional
HandleType
'HandleType.Translation2D' for theBoundsHandleInteractable
component to translate in two dimensions.Describe alternatives you've considered
I have considered using the
MoveAxisConstraint
for a workaround, but it feels more like a hack than an actual solution considering there is already theBoundsControl
with theBoundsHandleInteractables
to create handles easily.Additional context
Unity tool handles:
My custom handles, without the planar translation handle:
An additional option that could be useful is the switch between local/global coordinate manipulation (e.g. to rotate around the global vertical axis), but that is maybe easier to implement externally by simply adjusting the rotation of the handle continuously.