How to divide an image into blocks(non overlapping)?

I'm facing a problem in dividing an image into non overlapping blocks. I am supposed to take a Fourier transform of the divided blocks.can i use "blockproc" to do this?

2 commentaires

Geoff Hayes
Geoff Hayes le 1 Oct 2014
Modifié(e) : Geoff Hayes le 1 Oct 2014
Yes, you can use blockproc to do this. See the examples at blockproc for details on how to do this.
Note that you will need the Image Processing Toolbox to use this function.
Thank you Geoff Hayes

Connectez-vous pour commenter.

 Réponse acceptée

Image Analyst
Image Analyst le 1 Oct 2014

1 vote

You can use mat2cell() or indexing(). Both of these methods are shown in the FAQ: http://matlab.wikia.com/wiki/FAQ#How_do_I_split_an_image_into_non-overlapping_blocks.3F
If you also want to call a function on each block, then you can use blockproc() as illustrated in my two attached demos.

Plus de réponses (0)

Community Treasure Hunt

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

Start Hunting!

Translated by