| 查看: 2164 | 回复: 7 | ||
[求助]
MATLAB生成BMP格式的图片默认就是索引图像吗? 已有2人参与
|
| 我用MATLAB生成的BMP图片,矩阵是在0-1之间的double型的481*641的矩阵,为什么imwrite(I,'I.BMP','BMP')后得到图像是8位索引图像,而imwrite(I,'I.jpeg','jpeg','bitdepth',12)得到的是12位的灰度图像?我想得到24位的真彩图像(bmp的),要怎么弄呢?帮帮忙,谢谢大家。 |
» 猜你喜欢
材料与化工304求B区调剂
已经有7人回复
0703化学336分求调剂
已经有4人回复
[复试调剂]西南科技大学国防/材料导师推荐
已经有6人回复
化学工程321分求调剂
已经有12人回复
211本,11408一志愿中科院277分,曾在中科院自动化所实习
已经有4人回复
材料专硕326求调剂
已经有5人回复
东南大学364求调剂
已经有5人回复
国自科面上基金字体
已经有7人回复
药学383 求调剂
已经有4人回复
286求调剂
已经有5人回复
2楼2014-02-18 18:41:47
【答案】应助回帖
感谢参与,应助指数 +1
|
多用用F1帮助,看看函数说明就行。 关于bmp:只支持1-bit, 8-bit, and 24-bit uncompressed images 关于jpg:只支持8-bit, 12-bit, and 16-bit Baseline JPEG images 关于pgn:这个符合你的需求:1-bit, 2-bit, 4-bit, 8-bit, and 16-bit grayscale images; 8-bit and 16-bit grayscale images with alpha channels; 1-bit, 2-bit, 4-bit, and 8-bit indexed images; 24-bit and 48-bit truecolor images; 24-bit and 48-bit truecolor images with alpha channels 关于0-1转换0-255:If the input array is of class double, and the image is a grayscale or RGB color image, imwrite assumes the dynamic range is [0,1] and automatically scales the data by 255 before writing it to the file as 8-bit values. |

3楼2014-02-19 09:15:10
|
4楼2014-02-19 09:29:10
gorgan
木虫之王 (文学泰斗)
无意苦争春
- 应助: 698 (博士)
- 贵宾: 3.457
- 金币: 135818
- 散金: 4559
- 红花: 988
- 沙发: 9410
- 帖子: 164073
- 在线: 7070.6小时
- 虫号: 2539501
- 注册: 2013-07-10
- 性别: GG
- 专业: 计算数学与科学工程计算

5楼2014-02-19 13:34:30
gorgan
木虫之王 (文学泰斗)
无意苦争春
- 应助: 698 (博士)
- 贵宾: 3.457
- 金币: 135818
- 散金: 4559
- 红花: 988
- 沙发: 9410
- 帖子: 164073
- 在线: 7070.6小时
- 虫号: 2539501
- 注册: 2013-07-10
- 性别: GG
- 专业: 计算数学与科学工程计算

6楼2014-02-19 13:40:25
7楼2014-02-19 15:56:47
8楼2014-06-28 20:58:55













回复此楼