2007年10月4日 星期四
Week3 Ch2 Reading
P26.27
關於圖片的資訊. 我試著讀取.JPG跟.BMP的圖
JPG的圖只有到
ColorType: 'truecolor'
FormatSignature: ''
NumberOfSamples: 3
CodingMethod: 'Huffman'
CodingProcess: 'Sequential'
Comment: {}
就結束了
而BMP的圖片比他多了
ColorType: 'truecolor'
FormatSignature: 'BM'
NumColormapEntries: 0
Colormap: []
RedMask: []
GreenMask: []
BlueMask: []
ImageDataOffset: 54
BitmapHeaderSize: 40
NumPlanes: 1
CompressionType: 'none'
BitmapSize: 1454436
HorzResolution: 0
VertResolution: 0
NumColorsUsed: 0
NumImportantColors: 0
這些資訊
不知道這些資訊的意思為何
還有
Colortype裡 我讀取的圖都是truecolor
沒有其他種類
不知道裡面還有哪些種類 跟代表的意思為何??
Week 3 Homework-Chapter 2
本次作業閱讀的問題如下:
1.
TIFF:Tagged Image File Format
HDF:Hierarchical Data Format
PCX:Design for MS-DOS-based and Microsoft products.
ICO:display icons in Microsoft Windows.
CUR:mouse cursor in Microsoft systems.
上面的圖片格式,課本有做簡單的介紹,不知道是否能親眼見到一下。
2.
PGM
我在網路上稍微搜尋了一下跟PGM有關的資料,部份資料如下:
A PGM image represents a grayscale graphic image. There are many psueudo-PGM formats in use where everything is as specified herein except for the meaning of individual pixel values. For most purposes, a PGM image can just be thought of an array of arbitrary integers, and all the programs in the world that think they're processing a grayscale image can easily be tricked into processing something else.
他說明了PGM是一個跟灰階圖片有關的影像,之後就.....????
3.
imfinfo('picture')
這邊我Key in了自己的圖片 show出來的圖片訊息與課本不太相似
ans=
Filename: 'D:\picture\msn\雷.jpg'
FileModDate: '19-Sep-2007 23:32:51'
FileSize: 104242
Format: 'jpg'
FormatVersion: ''
Width: 300
Height: 300
BitDepth: 24
ColorType: 'truecolor'
FormatSignature: ''
NumberOfSamples: 3
CodingMethod: 'Huffman'
CodingProcess: 'Sequential'
Comment: {}
是否代表有辦法透過指令修改show的information?
Week3 -CH2-
看完課本後,了解到索引影像有包含color map 和 index 這2個讓我想到要顯示一張彩色的圖的時 候,難道是靠這2個才能顯示的嗎? 那這2個是有怎樣的關聯呢?
2. 2.5.1
vector image是如何放大圖片而不會模糊呢?
week3_CH2
為什麼長*寬=灰階數值?或並非運算意義?
2. P.24 --- 最後一個指令 >>a(100,200,1:3)
為什麼用"1:3"?
3. P.27 --- the number of bits per pixel(given by BitDepth)
看不懂意思.雖然有聽人解釋為"每個pixel有一個顏色,而這個顏色被以1 bit表示,所以不是1就是0."可是還是不能理解那P.27有個範例表示:BitDepth:24又是怎麼算的?另外,truecolor是什麼顏色表示型態?
week3
2.page 24 有一行程式碼為 a(100,200,1:3) 關於第三個參數(1:3)是什麼意思?
3.page 25 有提到 grayscale 為 two-dimensional matrix , two-dimensional matrix 是什麼?
2007年10月3日 星期三
Week 03 - Chapter 2 Images and MATLAB
◈ 主題 :
INTRODUCTION TO DIGITAL IMAGEPROCESSING
Chapter 2: IMAGE AND MATLAB
◈ 問題 :
① Page 22/pixval on指令實作問題
雖然可正常執行該指令,但Command Window裡總有Warning顯示。
Ans:
figure,imshow('autumn.tif'),impixelinfo;
figure,imshow('autumn.tif'),imdistline;
_______________________________
② Page 31/VectorˋRaster
collection of lines or vectors是指一次收集一整列所有pixel的資訊
嗎?
collection of dots是指一次收集一個點(pixel)的資訊嗎?
還是說這裡的linesˋvectorˋdots是指圖片資訊的排列方式或是...?
Ans:
這裡的"lines"是指"線"。
_______________________________
③ Page 33/第一行
"BMP format is a fairly simple example of a binary image
format。"
是說BMP是binary image?每個pixel一個bit?
Ans:
這裡的binary是"數位"的意思。
_______________________________
④ Page 33/倒數第二行
是指BMP只在BitCount小於等於8時使用Color Table?
Color Table = Color map?調色盤?
BitCount是?
Ans:
使用Color Table的用意在於每個pixel的顏色是以Color Table上的
index來紀錄,不需要每個pixel都紀錄RGB三個值,節省空間。所
以如果Color Table裡的顏色很多,例如是整張圖所有顏色數的
1/2,那麼儲存這麼多顏色也就與直接存每個pixel的RGB值一樣
花費空間。於是需要對Color Table上的顏色數設限,這裡的限制
是8個bit(8bit可表示0~255,於是可表示出256色)。
_______________________________
⑤ Page 34/2.5.4的第二點
"2. GIF doesn't allow binary or grayscale images,except as can
be produced with RGB values."
GIF不支援binaryˋgrayscale,除了是從RGB值產生的。
如果真的是這樣翻譯的話,那麼"除了是從RGB值產生的"是什麼意思?
Ans:
binary還是可以不以一個bit為0為1來表示顏色,而改以存顏色的
RGB值。(原本當我們看到那一個bit為0時就知道是什麼色,為1
時就知道是什麼色。但還是可以不存0或1而改存RGB值,於是看
到該點所存的RGB值就知道是什麼色。)
grayscale還是可以以RGB三值表示顏色,只是三個值會一樣。
_______________________________
⑥ Page 35/alpha channels and gamma correction。
不太懂alpha channels是什麼?文中描述為"ways of associate
variable transparencies with an image",一張圖組合不同透明度
的方式?
也不太懂gamma correction是什麼?
Ans:
顯示器有先偏亮有些偏暗,使用gamma correction後便可調整至
正常狀態。
WEEK3-CH02
2. PAGE 22 根據cxr=p,為什麼TIF的P值為0.多
3. PAGE 24 a(100,200,1:3) 1:3代表什麼?
4. PAGE 24 a(100,200,:) :又代表什麼?
Week3-Images & MatLab
會Show出hexadecimal dump function如下
42 4D 6E 18 00 00 00 00 00 00 36 00 00 00 28 00 BMn.......6...(.
00 00 42 00 00 00 1F 00 00 00 01 00 18 00 00 00 ..B.............
00 00 38 18 00 00 C4 0E 00 00 C4 0E 00 00 00 00 ..8.............
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
除了寬度、高度(像素位單位)以外,還可以知道哪些?
如果要從裡面看,要怎麼判斷呢??
2.我將灰階和彩色各一圖片合併起來時,要imread時,出現下列錯誤:
>> a=imread('123.tif');
Warning: RGB image has 4 (not 3) samples per pixel.
為什麼呢?
WEEK3-CH02
c*p=r
c=column value
p=row value
column value和row value分別是指什麼 ? P.22
2.>>figure,imshow{'emu.tif'},pixval on
>>em=imread('emu.tif');
figure,imshow{'em'},pixval on
有差別 !? P25.
3.a(100,200,1:3) 1:3是什麼意思? P24.
WEEK3-CH02 program
但是這個平面數是指甚麼東西?而在我的想法中彩色的pages應該是3,而我用size去看也沒錯,不過為甚麼灰階的圖卻沒有顯示pages?
2.page29. 在RGB轉灰階圖的部分,我用了他的指令rgb2gray之後再用一次gray2rgb要將他轉回rgb他卻出現
"??? Undefined function or method 'gray2rgb' for input arguments of type 'uint8'."
而我將它改成任何data type都一樣只是後面的'uint8'改了,雖然我不知道灰階改rgb會有什麼改變,但是課本上有將他列出來應該是可以使用才對,怎麼會出現這個問題呢?
Week03_ch2
2.PGM在轉換格式時為什麼可以簡化轉換程序,以及為什麼讀寫PGM非常容易呢?.............page.32