#include <matrixUtil.h>

Public Member Functions | |
| bool | isValid () const |
| Returns whether the object is filled with data. | |
| void | free () |
| Clears the object. | |
| Result | getSum (I x0, I y0, I xend, I yend) const |
| Computes the sum of a rectangle (in constant time). | |
| Result | getSum (const Block &b) const |
| A shortcut to get the sum of a block. | |
| template<class Input > | |
| void | fill (Input inp, I width, I height) |
| Prepares object to make sums for a matrix. | |
Public Attributes | |
| MatrixSlice< T, I > | sums |
| Internal matrix containing precomputed partial sums. | |
It's parametrized by "type of the result", "type of the input" and "indexing type" (defaults to Int). Uses shallow copying.
Definition at line 113 of file matrixUtil.h.
| void MatrixSummer< T, I >::fill | ( | Input | inp, | |
| I | width, | |||
| I | height | |||
| ) | [inline] |
Prepares object to make sums for a matrix.
If the summer has already been used before, the method assumes it was for a matrix of the same size
Definition at line 134 of file matrixUtil.h.
1.5.8