image convert question

2 次查看(过去 30 天)
There has an image with name of depthFrame, which can be show by using function imshow(depthFrame []); the value of depthFrame is double with the Min 0 Max 3975; Now I want to show this image on axes object of GUI, however,when I use function image(depthFrame ,'Parent',ax_handles2), it does not help to show on the axes. I think it must be something wrong with range of the value,but I do not know how to convert it. Please help! Thank you very much! PS: when I use data cursor to get the information of the pix, what I get as follow: X:157 Y:89 Index: 1221 RGB: 0.306 0.306 0.306

采纳的回答

Image Analyst
Image Analyst 2012-2-18
So don't use image(). Use imshow(depthFrame, []) instead. The issue is that if your image is double it's supposed to be in the range 0-1. You can get around that if you use the [] option in imshow. I see no reason to use image() or imagesc() at all, and don't get me started on pcolor()!

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Convert Image Type 的更多信息

标签

尚未输入任何标签。

Community Treasure Hunt

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

Start Hunting!

Translated by