hls::Window<int ROWS, int COLS, typename T>

The template class to represent window buffer in HLS Video Library.
Note: the origin of 2 dimensional window buffer is at bottom-right point.

Template Parameters


  • ROWS - Number of rows in the window buffer.
  • COLS - Number of columns in the window buffer.
  • T - Element(pixel) type.

Class members


val[ROWS][COLS]

2-d array of data in window buffer.

void shift_right()

Shift the window right, i.e. move all stored data within the window left, leave the right-most column (col = 0) for inserting new data.

void shift_left()

Shift the window left, i.e. move all stored data within the window right, leave the left-most column (col = COLS-1) for inserting new data.

void shift_up()

Shift the window up, i.e. move all stored data within the window down, leave the top row (row = ROWS-1) for inserting new data.

void shift_down()

Shift the window down, i.e. move all stored data within the window up, leave the bottom row (row = 0) for inserting new data.

void insert(T value, int row, int col)

Insert a new element value at location (row, col) of the window.

void insert_top(T value[COLS])

Insert a set of new elements in top row of the window.

void insert_bottom(T value[COLS])

Insert a set of new elements in bottom row of the window.

void insert_left(T value[ROWS])

Insert a set of new elements in left-most row of the window.

void insert_right(T value[ROWS])

Insert a set of new elements in right-most row of the window.

T& getval(int row, int col)

Return the data value at location (row, col) of the window.

T& operator ()(int row, int col)

Return the data value at location (row, col) of the window.