mirror of
https://github.com/konvajs/konva.git
synced 2025-06-28 15:23:44 +08:00
applyFilter should generate a temp canvas based on the size of the image dimensions, not the user defined dimensions
This commit is contained in:
parent
47a0605e00
commit
58ef06d372
2
dist/kinetic-core.js
vendored
2
dist/kinetic-core.js
vendored
@ -4514,7 +4514,7 @@ Kinetic.Image = Kinetic.Shape.extend({
|
|||||||
* filter has been applied
|
* filter has been applied
|
||||||
*/
|
*/
|
||||||
applyFilter: function(config) {
|
applyFilter: function(config) {
|
||||||
var canvas = new Kinetic.Canvas(this.attrs.width, this.attrs.height);
|
var canvas = new Kinetic.Canvas(this.attrs.image.width, this.attrs.image.height);
|
||||||
var context = canvas.getContext();
|
var context = canvas.getContext();
|
||||||
context.drawImage(this.attrs.image, 0, 0);
|
context.drawImage(this.attrs.image, 0, 0);
|
||||||
try {
|
try {
|
||||||
|
2
dist/kinetic-core.min.js
vendored
2
dist/kinetic-core.min.js
vendored
File diff suppressed because one or more lines are too long
@ -80,7 +80,7 @@ Kinetic.Image = Kinetic.Shape.extend({
|
|||||||
* filter has been applied
|
* filter has been applied
|
||||||
*/
|
*/
|
||||||
applyFilter: function(config) {
|
applyFilter: function(config) {
|
||||||
var canvas = new Kinetic.Canvas(this.attrs.width, this.attrs.height);
|
var canvas = new Kinetic.Canvas(this.attrs.image.width, this.attrs.image.height);
|
||||||
var context = canvas.getContext();
|
var context = canvas.getContext();
|
||||||
context.drawImage(this.attrs.image, 0, 0);
|
context.drawImage(this.attrs.image, 0, 0);
|
||||||
try {
|
try {
|
||||||
|
Loading…
Reference in New Issue
Block a user