If you want to create scenes that are compatible with both IE and ieWebGL, there is a way to do so.
You can begin by referencing the demos' sources on the ieWebGL site to get started.
Building the scene will require a different structure, involving loading some three.js scripts using require.js.
Here is an example that appears to be effective:
<script src="http://iewebgl.com/scripts/webglhelper.js" type="text/javascript"></script>
<script src="path/require.js"></script>
<script src="other_three.js-scripts"></script>
<script>
// creating a placeholder for the "console" object in case it is not available (e.g., when not under debugger)
var console = console || {
'warn': function (msg) { },
'log': function (msg) { },
'error': function (msg) { }
};
var container, camera, controls, scene, renderer;
function start()
{
require
(
["path/build/three.min.js", "path/examples/js/controls/your_controls.js"],
function ()
{
init();
animate();
}
);
}
function init()
{
container = document.getElementById('renderCanvas');
// setting up the renderer
renderer = new THREE.WebGLRenderer({ 'canvas': container });
renderer.setSize(window.innerWidth, window.innerHeight);
scene = new THREE.Scene();
...
}
...
</script>
<!-- dynamically creating the appropriate canvas element based on the browser and WebGL support -->
<script id="WebGLCanvasCreationScript"type="text/javascript">WebGLHelper.CreateGLCanvasInline('renderCanvas', start)</script>