Three.js 는 WebGL을 통해 대부분의 현대 브라우저에서 scene을 렌더링할 수 있습니다. 오래된 브라우저, 특히 Internet Explorer 10 이하 버전에서는 다른 [link:https://github.com/mrdoob/three.js/tree/master/examples/jsm/renderers 렌더러] (CSS2DRenderer, CSS3DRenderer, SVGRenderer)를 사용해야 합니다. 또한, polyfills를 몇가지 포함해야 할 수도 있는데 [link:https://github.com/mrdoob/three.js/tree/master/examples /examples] 폴더의 파일을 불러올때에는 필수입니다.
오래된 브라우저를 지원할 필요가 없다면, 다른 렌더러를 사용하는 것은 추천하지 않습니다. WebGLRenderer보다 느릴뿐더러 더 적은 기능을 지원하기 때문입니다.
Google Chrome 9+, Firefox 4+, Opera 15+, Safari 5.1+, Internet Explorer 11 및 Microsoft Edge. [link:https://caniuse.com/#feat=webgl Can I use WebGL]에서 어떤 브라우저들이 지원하는지 확인해볼 수 있습니다.
three.js에서 사용된 특성들은 다음과 같습니다. 이 중 몇개는 추가로 polyfills가 필요합니다.
특성 | 사용 범위 | 모듈 |
---|---|---|
Typed Arrays | Source | BufferAttribute, BufferGeometry, etc. |
Web Audio API | Source | Audio, AudioContext, AudioListener, etc. |
WebXR Device API | Source | WebXRManager |
Blob | Source | FileLoader, etc. |
Promise | Examples | GLTFLoader, DRACOLoader, BasisTextureLoader, GLTFExporter, VRButton, ARButton, etc. |
Fetch | Examples | ImageBitmapLoader, etc. |
File API | Examples | GLTFExporter, etc. |
URL API | Examples | GLTFLoader, etc. |
Pointer Lock API | Examples | PointerLockControls |
필요에 따라 polyfills을 import 하세요. IE9를 예로들면 적어도 다음과 같은 polyfills가 필요할 것입니다. these features: