Skip to content

Commit

Permalink
Fixes: #977
Browse files Browse the repository at this point in the history
  • Loading branch information
David Gillen committed Oct 1, 2018
1 parent 70f9d9a commit 8196aed
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/easeljs/display/DisplayObject.js
Original file line number Diff line number Diff line change
Expand Up @@ -1083,7 +1083,8 @@ this.createjs = this.createjs||{};
p.hitTest = function(x, y) {
var ctx = DisplayObject._hitTestContext;
ctx.setTransform(1, 0, 0, 1, -x, -y);
this.draw(ctx);
// hit tests occur in a 2D context, so don't attempt to draw a GL only Texture into a 2D context
this.draw(ctx, !(this.bitmapCache && !(this.bitmapCache._cacheCanvas instanceof WebGLTexture) ));

var hit = this._testHit(ctx);
ctx.setTransform(1, 0, 0, 1, 0, 0);
Expand Down

0 comments on commit 8196aed

Please sign in to comment.