while(1) {
olLoadIdentity3();
olLoadIdentity();
- olPerspective(24, 1, 1, 100);
- olTranslate3(0, 0, 4);
+ olPerspective(60, 1, 1, 100);
+ olTranslate3(0, 0, -3);
for(i=0; i<2; i++) {
olScale3(0.6, 0.6, 0.6);
void olFrustum (float l, float r, float b, float t, float n, float f)
{
float m[16] = {
- (2*n)/(r-l), 0, (r+l)/(r-l), 0,
- 0, (2*n)/(t-b), (t+b)/(t-b), 0,
- 0, 0, -(f+n)/(f-n), (-2*f*n)/(f-n),
- 0, 0, -1, 0,
+ (2*n)/(r-l), 0, 0, 0,
+ 0, (2*n)/(t-b), 0, 0,
+ (r+l)/(r-l), (t+b)/(t-b), -(f+n)/(f-n), -1,
+ 0, 0, (-2*f*n)/(f-n), 0,
};
olMultMatrix3(m);