libyggdrasil  v1.0.0
bsp::mid::drv::Display< Context > Struct Template Reference

Display implementation for Midgard. More...

#include <display.hpp>

Public Types

enum  Orientation { Orientation::Portrait = 0x00 }
 

Public Member Functions

 Display (const Display &)=delete
 

Static Public Member Functions

static bool init (Orientation orientation=Orientation::Portrait) noexcept
 
static bool deinit ()
 Deinit function. More...
 
static void reset () noexcept
 
static void turnOn () noexcept
 
static void turnOff () noexcept
 
static u16 getWidth ()
 
static u16 getHeight ()
 
static void setPalette (const std::array< u32, 256 > &palette)
 
static std::array< u32, 256 > getDefaultPalette ()
 
static ALWAYS_INLINE void * getFramebufferAddress ()
 
static ALWAYS_INLINE void setPixel (u16 x, u16 y, u8 color)
 
static ALWAYS_INLINE void clear (u8 color)
 Clear the display to a color. More...
 

Friends

template<auto , template< auto > typename>
struct bsp::drv::Display
 Declare Display frontend as friend. More...
 

Detailed Description

template<auto Context>
struct bsp::mid::drv::Display< Context >

Display implementation for Midgard.

Warning
Do not use this on its own!
Template Parameters
ContextDisplay Context

Member Enumeration Documentation

◆ Orientation

template<auto Context>
enum bsp::mid::drv::Display::Orientation
strong
Enumerator
Portrait 

Constructor & Destructor Documentation

◆ Display()

template<auto Context>
bsp::mid::drv::Display< Context >::Display ( const Display< Context > &  )
delete

Member Function Documentation

◆ clear()

template<auto Context>
static ALWAYS_INLINE void bsp::mid::drv::Display< Context >::clear ( u8  color)
inlinestatic

Clear the display to a color.

Parameters
colorIndex for the color

◆ deinit()

template<auto Context>
static bool bsp::mid::drv::Display< Context >::deinit ( )
inlinestatic

Deinit function.

Returns
Success

◆ getDefaultPalette()

template<auto Context>
static std::array<u32, 256> bsp::mid::drv::Display< Context >::getDefaultPalette ( )
inlinestatic

◆ getFramebufferAddress()

template<auto Context>
static ALWAYS_INLINE void* bsp::mid::drv::Display< Context >::getFramebufferAddress ( )
inlinestatic

◆ getHeight()

template<auto Context>
static u16 bsp::mid::drv::Display< Context >::getHeight ( )
inlinestatic

◆ getWidth()

template<auto Context>
static u16 bsp::mid::drv::Display< Context >::getWidth ( )
inlinestatic

◆ init()

template<auto Context>
static bool bsp::mid::drv::Display< Context >::init ( Orientation  orientation = Orientation::Portrait)
inlinestaticnoexcept

< LcdClk = 27429 kHz

◆ reset()

template<auto Context>
static void bsp::mid::drv::Display< Context >::reset ( )
inlinestaticnoexcept

◆ setPalette()

template<auto Context>
static void bsp::mid::drv::Display< Context >::setPalette ( const std::array< u32, 256 > &  palette)
inlinestatic

◆ setPixel()

template<auto Context>
static ALWAYS_INLINE void bsp::mid::drv::Display< Context >::setPixel ( u16  x,
u16  y,
u8  color 
)
inlinestatic

◆ turnOff()

template<auto Context>
static void bsp::mid::drv::Display< Context >::turnOff ( )
inlinestaticnoexcept

◆ turnOn()

template<auto Context>
static void bsp::mid::drv::Display< Context >::turnOn ( )
inlinestaticnoexcept

Friends And Related Function Documentation

◆ bsp::drv::Display

template<auto Context>
template<auto , template< auto > typename>
friend struct bsp::drv::Display
friend

Declare Display frontend as friend.


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