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

Support Matrix #3

Open
4 of 6 tasks
but0n opened this issue Jan 21, 2018 · 3 comments
Open
4 of 6 tasks

Support Matrix #3

but0n opened this issue Jan 21, 2018 · 3 comments
Labels

Comments

@but0n
Copy link
Member

but0n commented Jan 21, 2018

  • Translate
  • Scale
  • Rotate
  • LookAt
  • Orthographic
  • Perspective
@but0n but0n added the feature label Jan 21, 2018
@but0n but0n changed the title Support Matrxi Support Matrix Feb 18, 2018
@but0n
Copy link
Member Author

but0n commented Feb 22, 2018

http://blog.csdn.net/zujack/article/details/52460227
https://www.jianshu.com/p/bfc8327eaad3

image

和WebGL相反, ol3d使用行主序(Row major), 左乘

void ol3d_matrix_multi_v3(ol3d_Vector3_t *a, ol3d_matrix_t b) {
    ol3d_matrix_t temp = {a->x, a->y, a->z, 1};
    ol3d_matrix_t result;
    for(unsigned char i = 0; i < 4; i++) {
        result[i] = ol3d_matrix_multi_chunk(temp, b, i);
    }
    a->x = result[0];
    a->y = result[1];
    a->z = result[2];
}

@but0n
Copy link
Member Author

but0n commented Feb 22, 2018

@but0n
Copy link
Member Author

but0n commented Apr 19, 2018

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

No branches or pull requests

1 participant