Assigning white pixels to specific locations

4 次查看(过去 30 天)
Say that we have a black image (i.e. zeros) of size 64x64, and say that I want to fill those 3x3 windows pixels in the middle of the image with white (i.e. ones), how can I do that in MATLAB?
Thanks.

采纳的回答

Tapan
Tapan 2015-2-7
I = zeros(64); I(32:35,32:35)=1;

更多回答(0 个)

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by