custom WebGL window

04 February 2015 07:46 #1275
I wanted to make my own custom "Could not initialize WebGL" window. I can't find any documentation on this, what is the proper method?

04 February 2015 11:21 #1278

Generally this is being done with a background image placed inside a canvas html-element. Something like this:
<canvas id="canvas-elem" background-image="fallback_image.jpg">

If you use our app.js addon, then your canvas is created dynamically inside canvas_container, and you can just put an image-element under canvas container and remove canvas element in initialization callback:
function init_cb(canvas_elem, success) {
    if (!success) {
        var container = document.getElementById("your_canvas_container ");
        return null;

If you use Web Player then you can follow the recommendations from our documentation.
Blend4Web developer
29 April 2015 00:24 #2191
I redirected users to a new page via the following code:

function initCb(canvas_elem, success) {
		if (!success) {																// If the load was not a success
			//console.log("b4w init failure");										
			document.location = "YOUR_HTML_PAGE.html"; // Display WebGL error page
Please register or log in to leave a reply.