Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blendit does not handel object transforms made with respect to viewport #1

Open
imaginelenses opened this issue Sep 15, 2022 · 0 comments
Assignees
Labels
bug Something isn't working help wanted Extra attention is needed

Comments

@imaginelenses
Copy link
Owner

Object rotation with respect to the viewport does not work as expected. This is because Blendit does not track changes made to the viewport. And when regenerating .blend file the viewport is fixed

When rotating an object along the viewport axis:

  • orient_type and orient_matrix_type, in bpy.ops.transform.rotate, is set to 'VIEW'

When rotating an object along a particular axis (X, Y, Z):

  • orient_type and orient_matrix_type, in bpy.ops.transform.rotate, is set to 'GLOBAL'

In an ideal world I'd like Blender log bpy.ops.transform.rotate in the 'GLOBAL' context.

Without that I'd like to subscribe to bpy.ops.transform.rotate events, using the Blender Message Bus, and then store the bpy.types.RegionView3D values. (I'm not sure how to.)

This would, however, be an imperfect solution as the viewport can change between the time the event is published and bpy.types.RegionView3D values are read.

@imaginelenses imaginelenses added bug Something isn't working help wanted Extra attention is needed labels Sep 15, 2022
@imaginelenses imaginelenses self-assigned this Sep 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant