I'm doing a THREE.JS development under a WebView. All is working fine under FMP, connected to FMS.
But if I open it under WebDirect, I get this error: 'SecurityError (DOM Exception 18): The operation is insecure.'
It has something to do with the texture who is not loading.
I had another error about CORS before that one (XMLHttpRequest cannot load is not allowed by Access-Control-Allow-Origin).
I resolved it by enabling CORS on IIS for the FMS server. Now the CORS error is gone. But stuck with the DOM exception 18.
Here the path used for:
Load WebDirect: http://remote.plancher2000.com/fmi/webd#Développement
Loading JPG texture: THREE.TextureLoader().load('http://remote.plancher2000.com/Escaliers 3D/1-3-2-5-Bois.jpg')
It should be working, because if I load this Three.js Web page sample in a Web Viewer in WebDirect, it works.
The image used there load from the same path/server (relative location, see below).
var texture1 = textureLoader.load( "textures/crate.gif" );
Removing the first part 'http://remote.plancher2000.com/' to leave only 'Escaliers 3D/1-3-2-5-Bois.jpg' prevent texture from loading and gave error 'XMLHttpRequest cannot load Escaliers 3D/1-3-2-5-Bois.jpg. Cross origin requests are only supported for HTTP.' and 'DOM 19' (related to previous error) on WebDirect.
How can I find out it's related to what, and resolve it?
This problem is on Safari, Chrome and IE. From Mac to PC.