Revision beb70e07
Added by Leszek Koltunski over 8 years ago
src/main/java/org/distorted/library/EffectQueueMatrix.java | ||
---|---|---|
208 | 208 |
|
209 | 209 |
Matrix.translateM(viewMatrix, 0, x,-y, z); |
210 | 210 |
|
211 |
viewMatrix[4] += sx*viewMatrix[0]; // Multiply viewMatrix by 1 x 0 0 , i.e. X-shear. TODO: change this so it is symmetric w respect to all the axis.
|
|
211 |
viewMatrix[4] += sx*viewMatrix[0]; // Multiply viewMatrix by 1 x 0 0 , i.e. X-shear. |
|
212 | 212 |
viewMatrix[5] += sx*viewMatrix[1]; // 0 1 0 0 |
213 | 213 |
viewMatrix[6] += sx*viewMatrix[2]; // 0 0 1 0 |
214 | 214 |
viewMatrix[7] += sx*viewMatrix[3]; // 0 0 0 1 |
215 | 215 |
|
216 |
viewMatrix[0] += sy*viewMatrix[4]; // Multiply viewMatrix by 1 0 0 0 , i.e. Y-shear. TODO: change this so it is symmetric w respect to all the axis.
|
|
216 |
viewMatrix[0] += sy*viewMatrix[4]; // Multiply viewMatrix by 1 0 0 0 , i.e. Y-shear. |
|
217 | 217 |
viewMatrix[1] += sy*viewMatrix[5]; // y 1 0 0 |
218 | 218 |
viewMatrix[2] += sy*viewMatrix[6]; // 0 0 1 0 |
219 | 219 |
viewMatrix[3] += sy*viewMatrix[7]; // 0 0 0 1 |
220 | 220 |
|
221 |
// TODO: implement Z-shear. |
|
222 |
|
|
221 |
viewMatrix[4] += sz*viewMatrix[8]; // Multiply viewMatrix by 1 0 0 0 , i.e. Z-shear. |
|
222 |
viewMatrix[5] += sz*viewMatrix[9]; // 0 1 0 0 |
|
223 |
viewMatrix[6] += sz*viewMatrix[10];// 0 z 1 0 |
|
224 |
viewMatrix[7] += sz*viewMatrix[11];// 0 0 0 1 |
|
225 |
|
|
223 | 226 |
Matrix.translateM(viewMatrix, 0,-x, y, -z); |
224 | 227 |
} |
225 | 228 |
} |
Also available in: Unified diff
Fix for Bug #21: implement z-shear.