Centimeters

Avatar
  • updated
  • Declined

Doing a lot of UI for VR, it’s tedious to add a ‘0.0’ before each physical size for elements of few centimeters. Would be really helpful to have the option to set centimeters instead of meters in preference setting. Moreover, in that case the default size for cube; rectangle, etc. should be 10 centimeters. 
Thanks.

Reporting a bug? please specify Unity version:
Reporting a bug? please specify Shapes version:
Reporting a bug? please specify Render Pipeline:
Pinned replies
Avatar
Freya Holmér creator
  • Answer
  • Declined

I think this is a little too far outside of how Unity input fields and units work in general. Having input fields that show a different unit than the underlying value should be avoided as much as possible, and it makes for ambiguities when reading data from shapes. for instance, if you set a radius in cm, and set a value of 50, when reading that data from code, should it return 50 or 0.5? I'd say 0.5, but then there's a strong disconnect between values you see and the values you get in code. sticking to the same units across the board makes things more consistent and predictable

but, then again, the source is open, so you're welcome to change how it works on your end if you want! but I don't think I'd want this as a builtin feature in Shapes I'm afraid

Avatar
Freya Holmér creator
  • Answer
  • Declined

I think this is a little too far outside of how Unity input fields and units work in general. Having input fields that show a different unit than the underlying value should be avoided as much as possible, and it makes for ambiguities when reading data from shapes. for instance, if you set a radius in cm, and set a value of 50, when reading that data from code, should it return 50 or 0.5? I'd say 0.5, but then there's a strong disconnect between values you see and the values you get in code. sticking to the same units across the board makes things more consistent and predictable

but, then again, the source is open, so you're welcome to change how it works on your end if you want! but I don't think I'd want this as a builtin feature in Shapes I'm afraid