25数值矩阵转换为灰度图像 看星星 2022-05-29 152 阅读1分钟 close all;clear all;clc; X=magic(256); I= mat2gray(X); %将矩阵I转换为灰度图像 imshow(I); %显示转换后灰度图像