Digital Image Processing HW 1 Extraction of Bitmap

Digital Image Processing #HW 1 -Extraction of Bitmap Header File -Manipulation of Image Pixel Information Contact Information Tzu-Jui Wang (王子睿) Visual Communications Lab Dep. of Communications Engineering, National Central University No. 300, Jhongda Rd. , Jhongli City, Taoyuan County 32001, Taiwan (R. O. C. ) Phone: +886958801691 E-mail: juliuswang 0728@gmail. com

Outline • • Reference Work Flow Introduction to Bitmap File Homework Details – Extract Header File – Construct Histogram – Extract Region of Interest with Specified Coordinate Set • Grading Policy • Demo Schedule

Reference • A Beginners Guide To Bitmaps, – http: //local. wasp. uwa. edu. au/~pbourke/dataformats/ bitmaps/ – http: //atlc. sourceforge. net/bmp. html • Data type in Computer, wiki resources, – http: //en. wikipedia. org/wiki/Integer_(computer_scie nce) Those might be useful !

Work Flow 24 -bit Input coordinate set (xi, yi), i=1, . . , 4 of bounding box 8 -bit Extract header information Extract pixel information Construct histogram on R, G, B channels, respectively Extract region of interest (x 1, y 1) (x 2, y 2) (x 3, y 4) (x 4, y 4)

Introduction to Bitmap File (1/2) File header (14 bytes) Header file (Image profile) Info header (50 bytes) Empty for 24 -bit image Image content Pixel information Bitmap File Header Identifier (ID) File Size Reserved Bitmap Data Offset Bitmap Info Header Bitmap Header Size Width Height Planes Bits Per Pixel Compression Bitmap Data Size H-Resolution V-Resolution Used Colors Important Colors Color Table (Palette) Palette Bitmap Array Bitmap Data 2 4 4 4 2 2 4 4 4 N*4 N/A i. e. a 8 -bit image, N = 28

Introduction to Bitmap File (2/2) 54 bytes Header 54 bytes + 1024 bytes Header + Color palette Image content 24 -bit lena. bmp 8 -bit lena. bmp

Construct Histogram • Histogram on R, G, B channels Frequency Figure 1: beatles. bmp Figure 2: RGB histogram Pixel value

Extract Region of Interest with Specified Coordinate Set • Suppose given (x 1, y 1), (x 2, y 2), (x 3, y 3), (x 4, y 4) – The bounding box will be as followed (x 1, y 1) (x 2, y 2) Final output (x 3, y 3) (x 4, y 4) Bounding box

Grading Policy – Code & Demo (80%) • Everyone will be asked few questions. • Extract Header File (20%) – We’ll test your system with images except lovely Lena. • Construct Histogram (30%) – Same as the above. • Extract Region of Interest with Specified Coordinate Set (30%) – Arbitrarily give four coordinates, and create a new bitmap file with extracted region.

Grading Policy – Report (20%) • Report (20%) – Plot all your experimental results. (10%) – Depict the. bmp format as clear as possible. (5%) – Describe your findings as rich as possible. (5%) • We don’t force you to write down how you feel about this homework. But, you can still show it up. – Too trivial, too hard, …too ? – You can describe any difficulty you’ve encountered.

Demo Time • Demo time will be at 2010. 07, begin around 7: 00 pm (2 weeks later) at R 3 -307 (VCLab). • Demo orders will be announced later, 5 minutes for each, please refer TA’s website. – http: //140. 115. 156. 251/vclab/html/course/DIP 2010. h tml – Bring your codes and report. – No delay is allowed except a special cause.
- Slides: 11