Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Need help JAVA problem Look at the following image which is 256x256x8. the 8 is color bit (grayscale): http://s000.tinyupload.com/index.php?file_id=94569703793462768168 Note: you can use this image

Need help JAVA problem

Look at the following image which is 256x256x8. the 8 is color bit (grayscale): http://s000.tinyupload.com/index.php?file_id=94569703793462768168

Note: you can use this image only or any 256x256 grayscale image in .dat or .pgm (not pgn) format

Generate an image with the following spatial resolutions:

i) 128 (256/2) using 2x2 matrix ii) 64, using 4x4 matrix iii) 32 using 8x8 matrix iv) 16 using 16x16 matrix. The resulting image should still be 256x256. ie the image will be pixelated

to do this, read every byte of image above into a two dimension array having same dimension as image. then by iterating into 2d array as the mask is applied (mask is through each grouping of values and average of each group is calculated).

ii) Then apply quantization to image. for image above, each pixel is 256 gray level = 8 bit. reduce this to 16 gray level (4 bit) , 2 bit and 1 bit.

Here, every byte of file is read into a two dimension array with same dimension as image file. we then iterate through 2d array dividing by a divisor to scale down bit size. this is run for each pixe3l in image. the result is then output to a pgm image file.

Let me know if you have any questions

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Intelligent Information And Database Systems Asian Conference Aciids 2012 Kaohsiung Taiwan March 2012 Proceedings Part 2 Lnai 7197

Authors: Jeng-Shyang Pan ,Shyi-Ming Chen ,Ngoc-Thanh Nguyen

2012th Edition

3642284892, 978-3642284892

More Books

Students also viewed these Databases questions