keeping certain imrect properties fixed

1 Ansicht (letzte 30 Tage)
Allen Kelly
Allen Kelly am 10 Dez. 2014
Hi guys,
I have a program where i'm using imrect to define a region of interest that's plotted as a line graph, with each point on the line representing the image averaged along the X-axis. Therefore, the imrect width determines the region of the image that is averaged to create the line plot.
Its straightforward enough to allow the user to input the values of the image into text boxes to update the position of imrect, but I also want the user to be able to manually manipulate the imrect object.
I can do this to an extent but there are 2 features of the imrect object I want to keep fixed: 1) Height of the rectangle. 2) Width cannot be less than 1
I'm assuming I can do this with "addNewPositionCallback" but i'm not sure how.
Any help would be greatly appreciated, thanks guys
Cheers,
Allen

Antworten (0)

Community Treasure Hunt

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

Start Hunting!

Translated by