James,
Take a look at the Node Editor source - core - main.js code at lines 2709 - 2735:
code:
// this file allows to render the canvas using WebGL instead of Canvas2D
// this is useful if you plant to render 3D objects inside your nodes
LGraphCanvas.prototype.enableWebGL = function()
{
// TODO
// if (typeof(GL) === undefined) throw("litegl.js must be included to use a WebGL canvas");
// if (typeof(enableWebGLCanvas) === undefined) throw("webglCanvas.js must be included to use this feature");
// this.gl = this.ctx = enableWebGLCanvas(this.canvas);
// this.ctx.webgl = true;
// this.bgcanvas = this.canvas;
// this.bgctx = this.gl;
// GL.create({ canvas: this.bgcanvas });
// this.bgctx = enableWebGLCanvas( this.bgcanvas );
// window.gl = this.gl;
}
/**
* marks as dirty the canvas, this way it will be rendered again
*
* @class LGraphCanvas
* @method setDirty
* @param {bool} fgcanvas if the foreground canvas is dirty (the one containing the nodes)
* @param {bool} bgcanvas if the background canvas is dirty (the one containing the wires)
*/
That is why I think it was removed because of increased complexity involved with WebGL drivers.
It would be great to have a 3D rendering node in the node editor, but it is well beyond my skill set to even consider the challenge. Tie it in with, say the https://threejs.org/ library, it could be fantastic.
Edit: Michael - "WebGL is disabled in the WebKit engine that is included with MoI, because of the added size." -- My Moment of Inspiration has faded.
Maybe MoI 5.0? :-)
Wayne
|