addTexture problem


(Graffitiswat) #1

Hi, I'm trying to use the addTexture api function with no success. Even having CORS enabled and requesting the image from https I always get an error in the script (ResourceLoader: https://... failed image...).

I might be doing something wrong, is there any simple example of how to use the addTexture?

Thanks


(Klaasnienhuis) #2

I've successfully added textures in my dev environment while I had disabled web security in chrome. I followed the answers in this stackoverflow discussion: http://stackoverflow.com/questions/3102819/disable-same-origin-policy-in-chrome to disable the web security. To add the texture I've followed the simple code example here on sketchfab: https://sketchfab.com/developers/viewer/functions#api-addTexture

My SSL certificate will be installed tomorrow. I'll try to get it working without disabling the security after that.