how to convert a image to matrix?

10 visualizzazioni (ultimi 30 giorni)
azar
azar il 24 Feb 2014
Commentato: Simon Song il 1 Mag 2020
how to convert a image to matrix?

Risposta accettata

Jos (10584)
Jos (10584) il 24 Feb 2014
M = imread('MyImage.png')
M is a matrix ...
  3 Commenti
Laurent
Laurent il 24 Feb 2014
size(M)
will give you the length of each dimension.
ndims(M)
gives you the number of dimensions of your image, which will probably be 2.
Simon Song
Simon Song il 1 Mag 2020
nice solution!

Accedi per commentare.

Più risposte (0)

Categorie

Scopri di più su Convert Image Type in Help Center e File Exchange

Tag

Non è stata ancora inserito alcun tag.

Community Treasure Hunt

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

Start Hunting!

Translated by