CENG466 – HW2 12.11.2003

DUE: 21.11.2003  -  23:59

PART A)

In this homework you will implement convolution and local processing. Your program will read images from file. Then you will apply convolution with some matrix and save the result in a file. Local algorithms will also be implemented in similar manner but they will require operations other than addition and multiplication. 

Your program should run in two modes:

  1. applies built in operations:
  2. applies mask read from file.

Your program will be tested as follows:

parta in.ppm out.ppm b        		<---- this invocation applies a blur mask to image
parta in.ppm out.ppm -f mask.txt      	<---- this invocation applies the mask in 'mask.txt'

mask.txt format is same as ppm format BUT entries are floating point numbers NOT integers. so the following is valid:

3 3
-0.1 -0.1 -0.1
-0.1 0.8 -0.1
-0.1 -0.1 -0.1

You must take care of overflow/underflows in the resulting image. You can check your results with common image processing programs like Paint Shop/Gimp.

PART B)

In this part you will enhance the images using the methods you've learnt. The image given contains a hidden message. You have to enhance it to make the message readable.  Your program should be able to enhance any such images, having similar distortions.

source image (in.ppm)
---->Your Transformation---->
original image (out.ppm) 

????????

Your programs should be run as:

partb in.ppm out.ppm    <--- here 'in.ppm' is the source image and
				 'out.ppm' is the image you generated 

PART C)

 In second set of images you have to combine low resolution color images and high resolution gray level image to obtain a better color image. You can use any of the methods you've learnt. Also feel free to experiment with different methods. Write details in your report. 

Hi-res grayscale image (ingray.ppm)
---> your transformation --->
Desired output image (out.ppm)
Lo-res color image (incolor.ppm)

Your programs should be run as

partc incolor.ppm ingray.ppm out.ppm    <--- here 'incolor.ppm' is the lowres color image, 
					'ingray.ppm' is the hires grayscale image and 
					 'out.ppm' is the image you generated 

 

Notes:

For part A you use following files:

hw2jpg.zip

Convert these images to ppm format using your favorite image manipulation program. 

For parts B&C you use following files:

or all zipped in one file

hw2-images.zip

Here you can find an implementation of canny edge detector: 

canny-86.c

Submission

tar.gz all files and use submit command to submit all files. Include a Makefile to build your sources and a readme file for additional explanations.

Write a report about the results you obtain. Discuss methods and results. Explain methods you use. Bring report to my room (A206) before deadline.

For questions first use newsgroup.