HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
Public Types | Public Member Functions
v1::pixel_row< T > Class Template Reference

#include <hikogui/pixel_map.hpp>

Public Types

using value_type = T
 

Public Member Functions

 pixel_row (T *pixels, std::size_t width) noexcept
 
std::size_t width () const noexcept
 
T const * data () const noexcept
 Get a pointer to the pixel data.
 
T * data () noexcept
 Get a pointer to the pixel data.
 
T const & operator[] (std::size_t columnNr) const noexcept
 Get a access to a pixel in the row.
 
T & operator[] (std::size_t columnNr) noexcept
 Get a access to a pixel in the row.
 
T const & at (std::size_t columnNr) const noexcept
 Get a access to a pixel in the row.
 
T & at (std::size_t columnNr) noexcept
 Get a access to a pixel in the row.
 

Detailed Description

template<typename T>
class v1::pixel_row< T >

A row of pixels.

Member Function Documentation

◆ at() [1/2]

template<typename T >
T const & v1::pixel_row< T >::at ( std::size_t columnNr) const
inlinenoexcept

Get a access to a pixel in the row.

This function does bound checking.

Parameters
columnNrThe column number in the row.
Returns
a reference to a pixel.

◆ at() [2/2]

template<typename T >
T & v1::pixel_row< T >::at ( std::size_t columnNr)
inlinenoexcept

Get a access to a pixel in the row.

This function does bound checking.

Parameters
columnNrThe column number in the row.
Returns
a reference to a pixel.

◆ data() [1/2]

template<typename T >
T const * v1::pixel_row< T >::data ( ) const
inlinenoexcept

Get a pointer to the pixel data.

◆ data() [2/2]

template<typename T >
T * v1::pixel_row< T >::data ( )
inlinenoexcept

Get a pointer to the pixel data.

◆ operator[]() [1/2]

template<typename T >
T const & v1::pixel_row< T >::operator[] ( std::size_t columnNr) const
inlinenoexcept

Get a access to a pixel in the row.

Parameters
columnNrThe column number in the row.
Returns
a reference to a pixel.

◆ operator[]() [2/2]

template<typename T >
T & v1::pixel_row< T >::operator[] ( std::size_t columnNr)
inlinenoexcept

Get a access to a pixel in the row.

Parameters
columnNrThe column number in the row.
Returns
a reference to a pixel.

The documentation for this class was generated from the following file: