Filter löschen
Filter löschen

How to code a fixed region of interest?

3 Ansichten (letzte 30 Tage)
Shu Yi Ho
Shu Yi Ho am 24 Jul. 2019
Bearbeitet: Shu Yi Ho am 29 Jul. 2019
How can i hardcode ROI (specific area)? The code below allows me to select ROI with mouse:
rect = getrect(f); % Select ROI with mouse
ori_roi{i} = originalImage( rect(2) : (rect(2)+rect(4)) , rect(1) : (rect(1)+rect(3)) , : ); % store roi in matrix
Solved:
rect = [375.5 581.5 795 363]; % fixed ROI
ori_roi{i} = originalImage( rect(2) : (rect(2)+rect(4)) , rect(1) : (rect(1)+rect(3)) , : ); % store roi in matrix

Antworten (0)

Kategorien

Mehr zu Geometric Transformation and Image Registration finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by