Base class for all typed Cvb::Block types.
More...
#include <cvb/block.hpp>
Inherited by Block< T, ArrayAccess >, Block< T, LinearAccess >, and Block< T, VpatAccess >.
|
CVB_FORCE_INLINE const AccessTrait & | Access () const noexcept |
| Gets the pixel access.
|
|
CVB_FORCE_INLINE AccessTrait & | Access () noexcept |
| Gets the pixel access.
|
|
CVB_FORCE_INLINE size_t | Length () const noexcept |
| Gets the total number of pixels in this block.
|
|
CVB_FORCE_INLINE Size2D< int > | Size () const noexcept |
| Gets the size of this block.
|
|
CVB_FORCE_INLINE int | Width () const noexcept |
| Gets the width of this block.
|
|
CVB_FORCE_INLINE int | Height () const noexcept |
| Gets the height of this block.
|
|
bool | Valid () const noexcept |
| Gets whether this block is valid.
|
|
template<class AccessTrait>
class Cvb::BlockBase< AccessTrait >
Base class for all typed Cvb::Block types.
This base class contains the common, untyped methods of the Cvb::Block to reduce binary size.
- Template Parameters
-
AccessTrait | Trait to access a coordinate. |
◆ Access() [1/2]
template<class AccessTrait>
CVB_FORCE_INLINE const AccessTrait & Access |
( |
| ) |
const |
|
inlinenoexcept |
Gets the pixel access.
- Returns
- Const reference to the
Access
object.
◆ Access() [2/2]
template<class AccessTrait>
CVB_FORCE_INLINE AccessTrait & Access |
( |
| ) |
|
|
inlinenoexcept |
Gets the pixel access.
- Returns
- Mutable reference to the
Access
object.
◆ Height()
template<class AccessTrait>
CVB_FORCE_INLINE int Height |
( |
| ) |
const |
|
inlinenoexcept |
Gets the height of this block.
- Returns
- The height in pixels.
◆ Length()
template<class AccessTrait>
CVB_FORCE_INLINE size_t Length |
( |
| ) |
const |
|
inlinenoexcept |
Gets the total number of pixels in this block.
This is effectively Size().Width() * Size().Height().
- Returns
- The total number of pixels in this block.
◆ Size()
template<class AccessTrait>
CVB_FORCE_INLINE Size2D< int > Size |
( |
| ) |
const |
|
inlinenoexcept |
Gets the size of this block.
- Returns
- The size in pixels.
◆ Valid()
template<class AccessTrait>
Gets whether this block is valid.
- Returns
- true if Size() is not empty and the access is valid.
◆ Width()
template<class AccessTrait>
CVB_FORCE_INLINE int Width |
( |
| ) |
const |
|
inlinenoexcept |
Gets the width of this block.
- Returns
- The width in pixels.