Presentation is loading. Please wait.

Presentation is loading. Please wait.

Digital Image Processing HW1 Yi-Chun Wei Visual Communications Lab National Central University Mar. 2, 2012.

Similar presentations


Presentation on theme: "Digital Image Processing HW1 Yi-Chun Wei Visual Communications Lab National Central University Mar. 2, 2012."— Presentation transcript:

1 Digital Image Processing HW1 Yi-Chun Wei Visual Communications Lab National Central University Mar. 2, 2012

2 Outline Work Chart Introduction to Bitmap File Homework Details - Construct color histogram - Color image transform to gray-level image - Resize the image Grading Demo Schedule References 2

3 Work Chart 3 Extract header information 512*512 Extract pixel information Construct the histogram on Y Channel HW1-1 Transform to gray-level image Resize image 512*512 640*480 HW1-2

4 Introduction to Bitmap File(1/2) 4 Bitmap File Header Identifier (ID)2 File Size4 Reserved4 Bitmap Data Offset4 Bitmap Info Header Bitmap Header Size4 Width4 Height4 Planes2 Bits Per Pixel2 Compression4 Bitmap Data Size4 H-Resolution4 V-Resolution4 Used Colors4 Important Colors4 Color Table (Palette) PaletteN*4 Bitmap Array Bitmap DataN/A Header file - File header (14 bytes) - Info header (54 bytes) Image content - Bit array (pixel information) Color table - ex: a 8 bit image, N= 2 8 Y. C. Dong, “Digital Image Processing HW1”, 2009

5 Introduction to Bitmap File(2/2) 5 Header + Color palette Header 54 bytes 54 bytes + 1024 bytes Image content 24-bit Lena 8-bit Lena Scale: 512*512 Y. C. Dong, “Digital Image Processing HW1”, 2009

6 Color Image Transform to Gray- Level Image 6 Y = 0.299R + 0.587G + 0.114B 24-bit Lena8-bit Lena

7 Gray-level Histogram 7 Y histogram number Blue 196 Green 122 Red 83 Gray level pixel value Gray level ?

8 Resize Image 8 P: Desired Point Q: Known Points (four closet pixels) R: Point on the line with known points Z = A X + B Y + C XY+ D J. Nett,” Bilinear Interpolation”, 2009. Bilinear Interpolation: Gray level valueknown points Where A, B, C and D are obtained from the gray-level of the four neighbors.

9 Grading Demo Code (80%) - Extract header file (20%) - Color image transform to gray-level image (20%) - Construct color histogram (20%) - Resize image to 640*480 (20%) Report (20%) - Plot all your experimental results. (10%) - Describe your finding as rich as possible. (10%) 9

10 Demo Schedule Thursday night, March, 2012. - Begin around at 19:00 at R3-307.(VCLab) 10 NOTE:  We will use another image to test your code.  The details will be announced on our course website. ( http://140.115.156.251/vclab/html/course/DIP2012.html )

11 References Lena 24-bit color image, 512*512 http://www.indinf.pub.ro/catalinp/proiect/lena512.bmp About Bmp format website http://en.wikipedia.org/wiki/BMP_file_formathttp://en.wikipedia.org/wiki/BMP_file_format (wiki) http://crazycat1130.pixnet.net/blog/post/1345538- %E9%BB%9E%E9%99%A3%E5%9C%96%EF%BC%88bitma p%EF%BC%89%E6%AA%94%E6%A1%88%E6%A0%BC%E5 %BC%8F 11


Download ppt "Digital Image Processing HW1 Yi-Chun Wei Visual Communications Lab National Central University Mar. 2, 2012."

Similar presentations


Ads by Google