Search the Community
Showing results for tags 'dataURL'.
-
I have a set of image textures produced from by loading an SVG dataURL with PIXI.loader. I need a fairly performant way to change the underlying data of these textures. The name of the texture has to remain the same. Any ideas?
-
WebGL supports textures with base64 Data URLs, following the format "data:[mediatype];base64,[base64string]". However, when creating a texture with a data url in Babylon.js: var material = new BABYLON.StandardMaterial("0", scene);material.diffuseTexture = new BABYLON.Texture(dataUrl, scene, false, false, BABYLON.Texture.CUBIC_MODE);the browser console shows the message: Uncaught TypeError: Cannot read property 'replace' of nullIs there something I am doing wrong or is it a Babylon bug? I attached my full test code. Thanks! index.html
-
Hi, I'm trying to make a screenshot from my application with canvas.toDataURL() but I've an empty image in result. Is there a special method to call to achieve that ? My code is very simple : var engine = new BABYLON.Engine(myCanvas);...// Triggered by an eventvar base64 = myCanvas.toDataURL();var img = new Image();img.src = base64;return img;The image is transparent. Is it normal ? How can I create a correct screenshot of the current scene ? Thanks.