Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

this is the given image.... this is what you should end up with... % This is my code, is there an easier, more elegant way

image text in transcribed

this is the given image....

image text in transcribed

this is what you should end up with...

image text in transcribed

% This is my code, is there an easier, more elegant way to write this???

im = imread('balloon.jpg'); im(im >= 0 & im = 32 & im = 64 & im = 96 & im = 128 & im = 160 & im = 192 & im = 224 & im (P5.2) A grayscale (black and white) image is a numeric matrix just as we've been working with for a while Each number in the matrix represents the intensity of a pixel with 255 representing white, 0 representing black, and numbers in between representing shades of gray. Download balloon. jpg from the homework folder on TritonEd and save it to your Current Folder, then create a script called las tnameBalloon.mand add the following code to the script: 1 im- im read ('balloon.jpg.); % import the image 2 imshow(im) % display the image When you run this script MATLAB will import balloon. jpg and display the image. Check the base workspace and you should see that im exists as a 492-by-740 matrix. Now add code to the script you created above to achieve the following Replace all elements in m that are eater than or equal to... gr and less than.. with the number.. 32 64 96 128 160 192 224 32 64 96 128 160 192 224 256 0 32 64 96 128 160 192 224 After you add the code necessary to make these modifications, use imshow (im) again to display the modified image. Use File - Save As... in the Figure window to save your new, reduced-resolution image as a PNG graphic named lastnameBalloon png. You should end up with an image like the one on the next page when you're done

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_2

Step: 3

blur-text-image_3

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

DB2 11 The Ultimate Database For Cloud Analytics And Mobile

Authors: John Campbell, Chris Crone, Gareth Jones, Surekha Parekh, Jay Yothers

1st Edition

1583474013, 978-1583474013

More Books

Students also viewed these Databases questions