ericdrowell / KineticJS

KineticJS is an HTML5 Canvas JavaScript framework that extends the 2d context by enabling canvas interactivity for desktop and mobile applications.
http://www.kineticjs.com
3.98k stars 752 forks source link

Problem with image.cache(). when scale is set #957

Open bordeux opened 10 years ago

bordeux commented 10 years ago

Here is my problem: http://jsfiddle.net/bordeux/54TRx/

How can i fix it? I need image.cache(), becase without it, i cant use filters.

bordeux commented 10 years ago

any ideas?

lavrton commented 10 years ago

Set scale after cache. Or pass width and height params to cache function ( height = imageHeight * scaleX, same for width)

bordeux commented 10 years ago

is't this bug? I fixed it in _cache function: https://gist.github.com/bordeux/d72f8d41996129780762

pronebird commented 10 years ago

It is a bug. Can we apply scale the way translate is applied on cached canvas?