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

how to get camera to world matrix in blender system? #21

Closed
aaawww222 opened this issue Feb 16, 2024 · 1 comment
Closed

how to get camera to world matrix in blender system? #21

aaawww222 opened this issue Feb 16, 2024 · 1 comment

Comments

@aaawww222
Copy link

Hi,

Thanks for the great work! Can I ask how we can get camera to world matrix in blender coordinate convention after this script:

    with open(json_file, 'r', encoding='utf8') as reader:
        json_content = json.load(reader)

    camera_matrix = np.eye(4)
    camera_matrix[:3, 0] = np.array(json_content['x'])
    camera_matrix[:3, 1] = -np.array(json_content['y'])
    camera_matrix[:3, 2] = -np.array(json_content['z'])
    camera_matrix[:3, 3] = np.array(json_content['origin'])

Thanks!

@lingtengqiu
Copy link
Collaborator

see in #53

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants