show image independently
5 ビュー (過去 30 日間)
古いコメントを表示
i was building a program for capturing image from webcam, and show it using imshow(image) but suddenly after the image is captured, the image is shown in the part of gui, what i mean is to show the image independently, help me guys! thx!
0 件のコメント
採用された回答
Jan
2011 年 10 月 21 日
imshow displays the image in the current AXES-object. I assume "showing the image independently" means to display it in a new figure. Then:
newFigureH = figure;
newAxesH = axes('Parent', newFigureH);
imshow(rand(100, 100, 3), 'Parent', newAxesH);
7 件のコメント
Walter Roberson
2011 年 10 月 22 日
No, Izzo, where Jan showed "figure" you require a figure number, and cannot use an image handle. An image is a single bit-mapped drawing such as a photograph, and cannot contain any other objects (except an annotation object.)
If img is the image you want to show, then you need to adapt Jan's example to
newFigureH = figure;
newAxesH = axes('Parent', newFigureH);
imshow(img, 'Parent', newAxesH);
その他の回答 (0 件)
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!