To do that I use 3 points on the picture and the same 3 points on the shape I want to compare.
How do I do ?
1. I open the picture in Inkscape. Make a triangle with 3 known points and some other VIP points
2. I create a new layer and import the shape there. On the shape I already have the same 3 points and VIP points.
3. I read the coords of the 3 points from the shape (let say x1,y1, x2,y2 and x3, y3) this is the matrix A of the plane of the shape.
4. I do the same on the picture (let say a1, b1, a2, b2 and a3, b3) this is the B matrix of the plane on the picture.
5. to put the shape in correlation with the picture, I need to transform the shape and put it on the picture. This is done by matrix calculation outside Inkscape A -> A-1, A-1 * B, (A-1*B)T, where A-1 is the inverse of matrix A and (A-1 * B)T is the transposed of A-1 * B.
Doing so I get the coefficients I need to make the transformation in Inkscape using the matrix.
Is it possible to make an extension where we could select the 3 points and tell the system where we want them to be placed ?
As the picture is too large for the forum, I deleted the picture on the left and keep only the part shape (on the left) ... and trace curved lines indicating which point must go where ... so I want the shape on the right to go on the shape on the left (here is a basic sample as the position of the insect is the same on the left and the right ...)
download/file.php"postlink-local" href="download/fileac62.svg">download/file.php
- Attachments
-
- 2 Trichoptera Stenophylax permistus obs be test Vanmeerbeeck 12128551 GC image and VIP compare - shape only.svg
- (13.05 KiB) Downloaded 647 times
-
- 1 Trichoptera Stenophylax permistus obs be test Vanmeerbeeck 12128551 GC image and VIP compare - avant - shape only.svg
- (13.98 KiB) Downloaded 615 times
Last edited by tetrao on Sat Nov 25, 2017 6:07 am, edited 1 time in total.