Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
KODI::GAME::CControllerGrid Class Reference

Class to encapsulate grid operations. More...

#include <ControllerGrid.h>

Public Member Functions

 CControllerGrid ()=default
 
 CControllerGrid (const CControllerGrid &other)=default
 
 ~CControllerGrid ()
 
void SetControllerTree (const CControllerTree &controllerTree)
 Create a grid from a controller tree.
 
unsigned int GetWidth () const
 Get the width of the controller grid.
 
unsigned int GetHeight () const
 Get the height (deepest controller) of the controller grid.
 
const ControllerGridGetGrid () const
 Access the controller grid.
 
ControllerVector GetControllers (unsigned int playerIndex) const
 Get the controllers in use by the specified player.
 

Detailed Description

Class to encapsulate grid operations.

Constructor & Destructor Documentation

◆ CControllerGrid() [1/2]

KODI::GAME::CControllerGrid::CControllerGrid ( )
default

◆ CControllerGrid() [2/2]

KODI::GAME::CControllerGrid::CControllerGrid ( const CControllerGrid & other)
default

◆ ~CControllerGrid()

CControllerGrid::~CControllerGrid ( )
default

Member Function Documentation

◆ GetControllers()

ControllerVector CControllerGrid::GetControllers ( unsigned int playerIndex) const

Get the controllers in use by the specified player.

Parameters
playerIndexThe column in the grid to get controllers from

◆ GetGrid()

const ControllerGrid & KODI::GAME::CControllerGrid::GetGrid ( ) const
inline

Access the controller grid.

◆ GetHeight()

unsigned int KODI::GAME::CControllerGrid::GetHeight ( ) const
inline

Get the height (deepest controller) of the controller grid.

The height is cached when the controller grid is created to avoid iterating the grid

◆ GetWidth()

unsigned int KODI::GAME::CControllerGrid::GetWidth ( ) const
inline

Get the width of the controller grid.

◆ SetControllerTree()

void CControllerGrid::SetControllerTree ( const CControllerTree & controllerTree)

Create a grid from a controller tree.


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