Fixed WebGL renderer when no display callback was specified

This commit is contained in:
Richard Davey 2017-06-08 00:55:42 +01:00
parent 2cc3a391c4
commit da0ddeab54
2 changed files with 5 additions and 1 deletions

View file

@ -1,4 +1,4 @@
var CHECKSUM = {
build: '739c09e0-4bd6-11e7-ac7d-595a6798b3a1'
build: 'ae3fbaf0-4bdc-11e7-8d01-0d1ecc83299a'
};
module.exports = CHECKSUM;

View file

@ -41,6 +41,7 @@ var DynamicBitmapTextWebGLRenderer = function (renderer, gameObject, interpolati
var glyphH = 0;
var x = 0;
var y = 0;
var rotation = 0;
var xw = 0;
var yh = 0;
var tx = 0;
@ -92,6 +93,7 @@ var DynamicBitmapTextWebGLRenderer = function (renderer, gameObject, interpolati
for (var index = 0; index < textLength; ++index)
{
charCode = text.charCodeAt(index);
if (charCode === 10)
{
xAdvance = 0;
@ -102,6 +104,7 @@ var DynamicBitmapTextWebGLRenderer = function (renderer, gameObject, interpolati
}
glyph = chars[charCode];
if (!glyph)
{
continue;
@ -113,6 +116,7 @@ var DynamicBitmapTextWebGLRenderer = function (renderer, gameObject, interpolati
glyphH = glyph.height;
x = (indexCount + glyph.xOffset + xAdvance) * scale;
y = (glyph.yOffset + yAdvance) * scale;
rotation = 0;
if (lastGlyph !== null)
{