O'Reilly logo

Computer Vision for the Web by Foat Akhmadeev

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Understanding a digital image

It is likely that you already know that an image consists of pixels, which is a big step in understanding image processing. You already saw in the previous topics that a matrix is just a one-dimensional array. However, it represents two-dimensional array and its elements are presented in a row-major order layout. It is more efficient in terms of speed and memory to create a matrix in such a way. Our images are two dimensional too! Each pixel reflects the value of an array element. Consequently, it is obvious that a matrix is the best structure for image representation. Here, we will see how to work with a matrix and how to apply matrix conversion operations on an image.

Loading an image into a matrix

The JSFeat library ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required