Friday, June 13, 2008

Assignment 7, Q1-method 2

I am having difficulty getting method 1 to work properly but have completed this question using method 2. Please see a copy of my octave command and resulting images.

Please note that I created a "shrinkimg function" in octave and used it repeatedly to shrink my images by factors of 0.75, 0.25 and 0.1. Please click on the octave for more details as I have included # comments # to my code.



To use the function again you simply have to:

1) load your image - octave>A=imread("imagename.jpg");
2) apply shrink function - octave>B=shrinkimg(A, f); # f=0.75, 0.25, 0.1...
3) double your B - octave> C=double(B)/255;
4) then imwrite your new image C...

Here are my new images following the shrink function applied to my first picture.



Here are my new images following the shrink function applied to my second picture.

No comments: