peary::utils::pixel

Basic pixel class. More…

#include <peary/utils/datatypes.hpp>

Public Functions

Name
pixel() =defaultDefault pixel constructor.
virtual ~pixel() =defaultDefault pixel destructor.
pixel(const pixel & ) =defaultCopy constructor and assignment operator.
pixel & operator=(const pixel & ) =default
pixel(pixel && ) =defaultMove constructor and assignment operator.
pixel & operator=(pixel && ) =defaultMove assignment operator.

Protected Functions

Name
virtual void print(std::ostream & ) constPrint pixel data to output stream This function is intended to be overridden by derived classes to provide custom printing of pixel data.

Friends

Name
std::ostream & operator«(std::ostream & out, const pixel & px) Print pixel data to output stream.

Detailed Description

  class peary::utils::pixel;
  

Basic pixel class.

Storage element for pixel configurations and pixel data. It is to be implemented by the pixel classes attached to a device class and deriving from this common base class.

Public Functions Documentation

function pixel

  pixel() =default
  

Default pixel constructor.

function ~pixel

  virtual ~pixel() =default
  

Default pixel destructor.

function pixel

  pixel(
    const pixel & 
) =default
  

Copy constructor and assignment operator.

function operator=

  pixel & operator=(
    const pixel & 
) =default
  

function pixel

  pixel(
    pixel && 
) =default
  

Move constructor and assignment operator.

function operator=

  pixel & operator=(
    pixel && 
) =default
  

Move assignment operator.

Protected Functions Documentation

function print

  inline virtual void print(
    std::ostream & 
) const
  

Print pixel data to output stream This function is intended to be overridden by derived classes to provide custom printing of pixel data.

Friends

friend operator«

  friend std::ostream & operator<<(
    std::ostream & out,

    const pixel & px
);
  

Print pixel data to output stream.

Parameters:

  • out Output stream to print to
  • px Reference to the pixel object to print

Return: Reference to the output stream

This function is used to print the pixel data to an output stream. It can be overridden by derived classes to provide custom printing.


Updated on 2025-11-14 at 11:31:23 +0100