|
orthogonal = ({left, right, top, bottom, near, far }) => {
return new DOMMatrix([
2/(right - left), 0, 0, 0,
0, 2/(top - bottom), 0, 0,
0, 0, -2/(far - near), 0,
-(right + left)/(right - left), -(top + bottom)/(top - bottom),
-(far + near)/(far - near), 1
]);
}
W.camera({x:4.5,y:2,z:0,rx:-20,ry:30,fov:22});
Projection
|