There's a bunch of duplication here compared to the focus-on-object case. I think we could just have two branches to find pos
and then share the rest of the code?
No need to do this so explicitly, doing pos / count
below should automatically perform the cast and apply to all components.
pos += transform_get_column(&dofmat, 3);
should work fine here, no need for an intermediate variable or componentwise addition.
I think using coll.all_objects
here removes the need to recurse over child collections, so this could just be done in blender_camera_focal_distance
.
Instead of hiding the UI elements here, I think it would be better to disable (gray out) the unavailable ones.
Cycles also seems fine to me, but I don't know what the policy on compatibility is here. Personally, I think it's fine to just fix it.
I've implemented an initial version of this in !123278, no support for color picker yet.
I feel like we should just remove the translation in projection_orthographic
instead of explicitly undoing it here.
The rather boring outcome of an interesting investigation 😄
Before realizing the problem, I tested a number of other approaches:
- "Tweak": The tweak mentioned in footnote 5 of @nathanvegd…