fengyuanchen / cropper

⚠️ [Deprecated] No longer maintained, please use https://github.com/fengyuanchen/jquery-cropper
MIT License
7.75k stars 1.74k forks source link

picture seems to move along as we resize the crop box #1079

Closed vikram01718 closed 4 years ago

vikram01718 commented 4 years ago

I dont know whether this is a bug or my mistake

what i do Step 1 - choose the image file to be cropped Step 2 - set the height and width of image according to the fixed width container (any size image should be fixed and its going fine)

step 3 - set it to

myCropper = new Cropper(img, {
                    viewmode:1,
                    aspectRatio:16/9,
                    guides:false
                });

now the problem begins if the cropbox is on the picture, nothiiing happens, but if the cropbox went to transparent area (which i require), the image shift to the right ofthe image boundry exactly the same amount of pixels we have selected transparent area in the left or double amount of pixels if we have selected the transparent area in riGHT pr

Though the cropped canvas returned is very well and accurate but this looks confusing

Kindly suggest