Problem about DICOM Image GUI
12 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
KHOR WEI KOK
am 26 Mär. 2016
Bearbeitet: Walter Roberson
am 2 Apr. 2016
how can i insert list of dicom images into listbox and display in one of axes?? I have a folder containg dicom images and i want to insert list of images into the listbox. Any example for GUI DICOM images?
0 Kommentare
Akzeptierte Antwort
Walter Roberson
am 27 Mär. 2016
dinfo = dir('*.dcm');
dcm_files = {dinfo.name};
set( handles.listbox1, 'String', dcm_files);
...
function listbox1_Callback(src, event, handles)
box_choices = get(src, 'String');
box_chosen = get(src, 'Value');
file_chosen = box_choices{box_chosen};
[ImageData, ImageMap] = imread(file_chosen);
imshow( ImageData, ImageMap, 'Parent', handles.axes_to_display_in);
axis(handles.axes_to_display_in, 'image');
3 Kommentare
Walter Roberson
am 27 Mär. 2016
That is a proper example. Just change "listbox1" to the Tag you used for your listbox, and change "axes_to_display_in" to the tag you used for the axes to display the image in.
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu MATLAB Code Analysis 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!