ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder
ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 DeSkew a parallelogram

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Size 
UserName:
Password:
Mode 
Format  BoldItalicizedUnderline Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkInsert EmailBrowse for an image to attach to your post Browse for a zip to attach to your post Insert CodeInsert QuoteInsert List
   
Message 

 

Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Black Eye [B)]
Frown [:(] Shocked [:0] Angry [:(!] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
Waheed Posted - May 04 2021 : 12:00:25
Is there a single statement to change a parallelogram shape to a rectangle. Assuming I know the skew angle (15 degrees)?


I'm aware of this procedure:
procedure RotateAndCrop(Angle: Double; AntiAliasMode: TIEAntialiasMode = ierFast; Rate: Double = 1.3; CropAlgorithm: TIECropAlgorithm = iecaSkewedDocument);


but I don't want to crop the image.


-----------------
3 Monitors
Windows 10
Delphi 6,2007 and 10.2
ImageEn v.9


3   L A T E S T    R E P L I E S    (Newest First)
xequte Posted - May 07 2021 : 15:56:50
Yes, that is correct.

Nigel
Xequte Software
www.imageen.com
Waheed Posted - May 07 2021 : 09:03:31
Is this drawing correct?

ImageEnView1.Proc.Crop([DPoint(x1, y1), DPoint(x2, y2), DPoint(x3, y3), DPoint(x4, y4)]);



-----------------
3 Monitors
Windows 10
Delphi 6,2007 and 10.2
ImageEn v.9
xequte Posted - May 04 2021 : 17:14:42
Hi Waheed

Do an equilateral crop using the four corners of the parallelogram:

https://www.imageen.com/help/TImageEnProc.Crop.html

e.g. if your parallelogram is 500 wide and 400 high and offset is 50:

ImageEnView1.Proc.Crop([DPoint(50, 0), DPoint(500, 0), DPoint(450, 400), DPoint(0, 400)]);





Nigel
Xequte Software
www.imageen.com