comparison Renderer/Engine/sys.cc @ 1048:5e62924bd7d9 draft

add ScaleXY (not for allExecute...)
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Wed, 08 Dec 2010 06:22:15 +0900
parents f87218eed9fc
children
comparison
equal deleted inserted replaced
1047:f87218eed9fc 1048:5e62924bd7d9
265 for (int i = 0; i < 4; i++) { 265 for (int i = 0; i < 4; i++) {
266 v[i] = t[0]*m[i] + t[1]*m[i+4] + t[2]*m[i+8] + t[3]*m[i+12]; 266 v[i] = t[0]*m[i] + t[1]*m[i+4] + t[2]*m[i+8] + t[3]*m[i+12];
267 } 267 }
268 } 268 }
269 269
270 void
271 ScaleMatrix(float *m, float v)
272 {
273 for(int i=0;i<16;i++)
274 m[i] *= v;
275 }
276
277 void
278 ScaleMatrixXY(float *m, float x, float y)
279 {
280 for(int i=0;i<3;i++) {
281 m[i] *= x;
282 m[i+4] *= y;
283 }
284 }
285