From: Joe Wreschnig Date: Sat, 6 Sep 2014 10:26:38 +0000 (+0200) Subject: Support passing a material name to QuadC. X-Git-Url: https://git.yukkurigames.com/?a=commitdiff_plain;h=ecda6a5274a6b8670526469ab047c57db9275e33;p=featherfall2.git Support passing a material name to QuadC. --- diff --git a/src/yuu/rdr.js b/src/yuu/rdr.js index a03cbec..99b8c3f 100644 --- a/src/yuu/rdr.js +++ b/src/yuu/rdr.js @@ -272,6 +272,9 @@ constructor: function (material) { var buffer = new yuu.VertexBuffer(yuu.V3T2C4_F, 4); this._quad = new yuu.Quad(buffer); + material = yf.isString(material) + ? new yuu.Material(material) + : material; this._rdro = new yuu.Renderable( buffer, yuu.gl.TRIANGLE_STRIP, material, { model: mat4.create() }, 0.0);