adds compatibility with default renderer

This commit is contained in:
Francisco Dans 2015-05-12 12:13:34 +02:00
parent 2d6632afb8
commit eb4d739bca

View File

@ -177,21 +177,21 @@ var ballRenderer = require('./ball.js');
if(typeof this.ballRenderer === "undefined"){ if(typeof this.ballRenderer === "undefined"){
this.ballRenderer = new ballRenderer(this._canvas); this.ballRenderer = new ballRenderer(this._canvas);
} }
this._renderTile(tile, key, 0, null, null, null, pos); // this._renderTile(tile, key, 0, null, null, null, pos);
// var prof = Profiler.metric('torque.renderer.point.renderLayers').start(); var prof = Profiler.metric('torque.renderer.point.renderLayers').start();
// var layers = this._shader.getLayers(); var layers = this._shader.getLayers();
// for(var i = 0, n = layers.length; i < n; ++i ) { for(var i = 0, n = layers.length; i < n; ++i ) {
// var layer = layers[i]; var layer = layers[i];
// if (layer.name() !== "Map") { if (layer.name() !== "Map") {
// var sprites = this._sprites[i] || (this._sprites[i] = {}); var sprites = this._sprites[i] || (this._sprites[i] = {});
// // frames for each layer // frames for each layer
// for(var fr = 0; fr < layer.frames().length; ++fr) { for(var fr = 0; fr < layer.frames().length; ++fr) {
// var frame = layer.frames()[fr]; var frame = layer.frames()[fr];
// var fr_sprites = sprites[frame] || (sprites[frame] = []); var fr_sprites = sprites[frame] || (sprites[frame] = []);
// this._renderTile(tile, key - frame, frame, fr_sprites, layer); this._renderTile(tile, key - frame, frame, fr_sprites, layer, null, pos);
// } }
// } }
// } }
// prof.end(true); // prof.end(true);
}, },