Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Width, 0.0f, 0.0f, 0.0f
- pt.set(((( r - l ) / size.x) * 2.0f) / ( r - l ), 0.0f, 0.0f, 0.0f);
- mTempMatrix.setRow(0, pt);
- // 0.0f, -Height, 0.0f, 0.0f
- pt.set(0.0f, ((( b - t ) / size.y) * -2.0f) / ( b - t ), 0.0f, 0.0f);
- mTempMatrix.setRow(1, pt);
- // 0.0f, 0.0f, Depth?, 0.0f
- pt.set(0.0f, 0.0f, 1.0f, 0.0f);
- mTempMatrix.setRow(2, pt);
- F32 one_x_pix = 1.0 / size.x;
- F32 one_y_pix = 1.0 / size.y;
- // X, -Y, Z, 1.0f
- pt.set((-2.0 / size.x) - (1.0 - one_x_pix), (2.0 / size.y) + (1.0 - one_y_pix), 1.0f, 1.0f);
- mTempMatrix.setRow(3, pt);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement