HI,i want user defined band of image in multiband image processing in GUI in matlab.In the belowUI code ,it is default selected band as 4,3,2 ,but i want this to be user defined in GUI.
4 次查看(过去 30 天)
显示 更早的评论
c = multibandread('paris.lan', [512, 512, 7], 'uint8=>uint8',...
128, 'bil', 'ieee-le', {'Band','Direct',[4 3 2]});
imshow(c)
2 个评论
Aarti Dwivedi
2018-7-5
https://www.mathworks.com/help/matlab/ref/ginput.html If you are looking to get user input from mouse please check the above link to see if it fits your needs.
采纳的回答
Image Analyst
2018-7-5
Have 3 edit fields, one for each ban. The user can type into it. If you're using GUIDE, you can do
band1 = str2double(handles.edtBand1.String);
band2 = str2double(handles.edtBand2.String);
band3 = str2double(handles.edtBand3.String);
bandsToUse = [band1, band2, band3];
multiBandImage = multibandread('paris.lan', [512, 512, 7], 'uint8=>uint8',...
128, 'bil', 'ieee-le', {'Band','Direct',bandsToUse });
imshow(multiBandImage)
2 个评论
Image Analyst
2018-7-5
You can do the same thing with edit fields for user input. Or you can display one frame and ask the user to draw a box over it with imrect() or rbbox().
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Hyperspectral Image Processing 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!