We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Problem with resizing existing images

I have been having the exact same issue while resizing of the images using the command image.resize(width,height);
My image appears small and in one corner of a black box of the expected witdth and height/// I dont want to use image proportionality as i want to copy the image exactly to my given size. what should i do??

Hi Hafsa,


Thank you for contacting Aspose support.

First of all, I have split the existing thread to create a new one on your behalf to treat your presented scenario as a distinct incident. Moreover, this way you will be the owner of the thread and can receive automated notification (if required).

Regarding your original issue, the scenario was identified as a bug in the Aspose.Imaging APIs and was long fixed. You should not be experiencing the problem if you are using the latest revisions of Aspose.Imaging APIs. If you are already using the latest version then please share the following information/artifacts for further investigation in this regard.

  • Platform (.NET/Java)
  • Operating System version and architecture (32bit/64bit)
  • Target Framework/JDK
  • Sample image that could show the problem on our side

The workaround to this situation is to create a new canvas of required size, and draw the image over the canvas using the Graphics.DrawImage method. However, it is best we should correct the problem in the Aspose.Imaging APIs for the resize method (if identified as a bug on the part of Aspose.Imaging APIs).

Looking forward to your kind response to assist you further in this regard.