SLIDE 1
2
Transformations 6 http://www.ugrad.cs.ubc.ca/~cs314/Vjan2016 - - PowerPoint PPT Presentation
University of British Columbia CPSC 314 Computer Graphics Jan-Apr 2016 Tamara Munzner Transformations 6 http://www.ugrad.cs.ubc.ca/~cs314/Vjan2016 Transformation Hierarchies 2 Scaling and Rotating 3 Matrix Stacks challenge of avoiding
2
3
4
Object coordinates World coordinates
5
6
void drawBlock(float k) { pushMatrix(); scale(k,k,k); drawBox(); popMatrix(); }
7
https://developer.mozilla.org/en-US/docs/Web/API/WebGL_API/Tutorial/ Animating_objects_with_WebGL#More_matrix_operations
8
9
4
1
5
3
2
10
11
12
13
1
2
3
1 3 1 2
14
33 32 31 23 22 21 13 12 11
z y x
15
16
17
18