mirror of
https://github.com/photonstorm/phaser
synced 2024-11-28 23:51:31 +00:00
Don't render if there's no texture
This commit is contained in:
parent
d72e86cc2a
commit
3d31e27926
2 changed files with 8 additions and 2 deletions
|
@ -21,7 +21,10 @@
|
||||||
*/
|
*/
|
||||||
var VideoCanvasRenderer = function (renderer, src, interpolationPercentage, camera, parentMatrix)
|
var VideoCanvasRenderer = function (renderer, src, interpolationPercentage, camera, parentMatrix)
|
||||||
{
|
{
|
||||||
renderer.batchSprite(src, src.frame, camera, parentMatrix);
|
if (src.videoTexture)
|
||||||
|
{
|
||||||
|
renderer.batchSprite(src, src.frame, camera, parentMatrix);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
module.exports = VideoCanvasRenderer;
|
module.exports = VideoCanvasRenderer;
|
||||||
|
|
|
@ -21,7 +21,10 @@
|
||||||
*/
|
*/
|
||||||
var VideoWebGLRenderer = function (renderer, src, interpolationPercentage, camera, parentMatrix)
|
var VideoWebGLRenderer = function (renderer, src, interpolationPercentage, camera, parentMatrix)
|
||||||
{
|
{
|
||||||
this.pipeline.batchSprite(src, camera, parentMatrix);
|
if (src.videoTexture)
|
||||||
|
{
|
||||||
|
this.pipeline.batchSprite(src, camera, parentMatrix);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
module.exports = VideoWebGLRenderer;
|
module.exports = VideoWebGLRenderer;
|
||||||
|
|
Loading…
Reference in a new issue