处理多页旋转导出pdf的图片尺寸不对
This commit is contained in:
parent
3c164ad9ff
commit
1f5ec3f907
|
@ -68,6 +68,11 @@ void Dialog_MultiRotateImageFile::ThreadFunc(HGThread thread, HGPointer param)
|
|||
{
|
||||
HGImage img2 = nullptr;
|
||||
HGBase_CreateImage(imgInfo.height, imgInfo.width, imgInfo.type, imgInfo.origin, &img2);
|
||||
|
||||
HGUInt xDpi, yDpi;
|
||||
HGBase_GetImageDpi(img, &xDpi, &yDpi);
|
||||
HGBase_SetImageDpi(img2, xDpi, yDpi);
|
||||
|
||||
HGBase_ImageRotateLeft(img, img2);
|
||||
HGBase_DestroyImage(img);
|
||||
img = img2;
|
||||
|
@ -80,6 +85,11 @@ void Dialog_MultiRotateImageFile::ThreadFunc(HGThread thread, HGPointer param)
|
|||
{
|
||||
HGImage img2 = nullptr;
|
||||
HGBase_CreateImage(imgInfo.height, imgInfo.width, imgInfo.type, imgInfo.origin, &img2);
|
||||
|
||||
HGUInt xDpi, yDpi;
|
||||
HGBase_GetImageDpi(img, &xDpi, &yDpi);
|
||||
HGBase_SetImageDpi(img2, xDpi, yDpi);
|
||||
|
||||
HGBase_ImageRotateRight(img, img2);
|
||||
HGBase_DestroyImage(img);
|
||||
img = img2;
|
||||
|
|
Loading…
Reference in New Issue