Info

Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.

Help with writing code to calibrate Matlab images saved as .fig files

1 Ansicht (letzte 30 Tage)
Jason Malizia
Jason Malizia am 30 Jun. 2016
Geschlossen: MATLAB Answer Bot am 20 Aug. 2021
Hi all,
I need to write a code that can transform an image (complete with x, y and c axis data), let's call this image 'needscalib.fig', to another image, called 'calib.fig'. The transformation will involve rotation, scaling, and skewing.
To start with, I know Matlab has built in functions to do this transformation on image files (fitgeotrans and imwarp). However, imwarp does not work on .fig files and I am unsure if fitgeotrans uses the information contained in the axis to solve for the tform matrix. If I can use these scripts, that would be great and help on how to get these scripts to work with .fig files would be very appreciated. Otherwise, I'm at a loss of how to write the script.
Solving for the transformation matrix should be semi-easy. I will use impoint to get the position of several identical points on 'needscalib.fig' and 'calib.fig'. I can then solve for the transformation matrix that will convert the coordinates obtained from 'needscalib.fig' to 'calib.fig' using some type of regression. The question is, how can I use this transformation matrix to move the location of the pixels in 'needscalib.fig' to their appropriate position? One thing to point out is that 'needscalib.fig' and 'calib.fig' will not have the same number of pixels.
-Jason Malizia
  1 Kommentar
Samuel Vergara
Samuel Vergara am 30 Jun. 2016
If there a built in function, maybe is easier transform your data and uses that.

Antworten (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by