MATLAB Answers

edgecolor of pixels of imagesc

18 views (last 30 days)
Ankit Labh
Ankit Labh on 25 May 2020
Edited: Image Analyst on 25 May 2020
I want the black edge color for the boundaries of each pixel drawn using imagesc. If I use pcolor, I get the black boundary around pixels. How can I get the same using 'imagesc'?

  0 Comments

Sign in to comment.

Answers (1)

Image Analyst
Image Analyst on 25 May 2020
Edited: Image Analyst on 25 May 2020
You can't. And if you use pcolor, you don't either. The tiles you see in pcolor are NOT pixels. Look closely. If you want to show a 4x4 array with pcolor, do you see a 4x4 array of pixels?
m = magic(4)
pcolor(m);
No, you don't. Those black lines goes through the MIDDLE of the pixels, they don't surround them. And to make it worse, you see a 3x3 array of tiles, not a 4x4 array. Very deceiving so that's why I never use pcolor().

  0 Comments

Sign in to comment.