How to calculate the inclination angle of whole box which their 4 vertices are stored in cell array with respect to the horizontal x-axis?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
How to calculate the inclination angle of whole box which their 4 vertices are stored in cell array with respect to the horizontal x-axis?
There is cell with size 1*23 , In each part of cell there are four (x,y) coordinates stored (23 Bounding boxes coordinates )as the following:
c = {{[x1 , y1], [x2, y2], [x3 , y3 ], [x4 , y4 ]}, {[x1 , y1], [x2, y2], [x3 , y3 ], [x4 , y4 ]}, ........... }
The attached file is xy coordinates of the vertices of the boxes.
The coordinates are in the order:
(left-bottom), (right-bottom), (left-top), (right-top).where each coordinate is an (x, y) pair.. i.e([x1 , y1], [x2, y2], [x3 , y3 ], [x4 , y4 ])
2 Kommentare
Image Analyst
am 12 Mai 2022
Not sure all those brackets make sense. Can you attach your c in a .mat file?
props = regionprops(mask, 'BoundingBox');
allBB = vertcat(regionprops.BoundingBox); % Put into an N-by-4 matrix.
Akzeptierte Antwort
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Map Display finden Sie in Help Center und File Exchange
Produkte
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!