Image Class

Header: #include "easyar/image.hpp"

Inherits: RefBase

Description

Image stores an image data and represents an image in memory.

Image raw data can be accessed as char array. The width/height/stride information are also accessible.

Public Functions

Image()
virtual ~Image()
int width() const
int height() const
int stride() const
PixelFormat format() const
const void* data() const

Image()

Creates a Image object.

virtual ~Image()

Destroys the Image object.

int width() const

Returns image width.

int height() const

Returns image height.

int stride() const

Returns image stride.

PixelFormat format() const

Returns image format. Generally, you will get a YUV image from camera on mobile devices and BGR image from camera on desktop devices.

const void* data() const

Returns image raw data as a char array.