define double(img(:,:,1))

답변 (1개)

Wayne King
Wayne King 2012년 3월 20일

0 개 추천

That code is casting the first "page" of img (a 3D array) to type double.
So perhaps img is uint8 to begin with (or something like that)
img = uint8(ones(256,256,3));
xy = double(img(:,:,1));
class(img)
class(xy)

카테고리

도움말 센터File Exchange에서 Interactive Control and Callbacks에 대해 자세히 알아보기

태그

질문:

2012년 3월 20일

Community Treasure Hunt

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

Start Hunting!

Translated by