1

When changing the camera from perspective to orthographic, the cameras position also seem to change so that 0,0,0 is located in the top left hand corner.

Is this behaviour correct?

See Example

Orthographic

var h = window.innerHeight;
var w = window.innerWidth;

var viewSize = h;
var aspectRatio = w/h; //1 unit should be one pixel
var left = (-aspectRatio * viewSize) / 2;
var right = (aspectRatio * viewSize) / 2;
var top = viewSize / 2;
var bottom = -viewSize / 2;
var near = 1;
var far = 100;

camera = new THREE.OrthographicCamera( left, right, top, bottom, near, far );

Ortho

Perspective

camera = new THREE.PerspectiveCamera(50, window.innerWidth / window.innerHeight, 1, 10000);
camera.position.z = 500;

Perspective

Community
  • 1
  • 1
Ivan Bacher
  • 5,855
  • 9
  • 36
  • 56
  • FYI, see http://stackoverflow.com/questions/17558085/three-js-orthographic-camera/17567292#17567292 for a discussion regarding `OrthographicCamera` units. – WestLangley Dec 09 '15 at 18:06

1 Answers1

2

CSS3DRenderer does not support OrthographicCamera.

three.js r.73

WestLangley
  • 102,557
  • 10
  • 276
  • 276