ESPixelStick Firmware
Firmware for the ESPixelStick
Loading...
Searching...
No Matches
InputFPPRemote.cpp File Reference
#include "ESPixelStick.h"
#include "input/InputFPPRemote.h"
#include "service/FPPDiscovery.h"
#include "input/InputFPPRemotePlayFile.hpp"
#include "input/InputFPPRemotePlayList.hpp"
#include <Int64String.h>
Include dependency graph for InputFPPRemote.cpp:

Macros

#define AllocatePlayer(ClassType, ChannelID)
 
#define DeAllocatePlayer()
 

Macro Definition Documentation

◆ AllocatePlayer

#define AllocatePlayer ( ClassType,
ChannelID )
Value:
{ \
if(!PlayerInfo.InUse) \
{ \
static_assert(sizeof(PlayerInfo.Player) >= sizeof(ClassType)); \
new(PlayerInfo.Player) ClassType(ChannelID); \
PlayerInfo.InUse = true; \
pInputFPPRemotePlayItem = (c_InputFPPRemotePlayItem*)(&PlayerInfo.Player[0]); \
} \
else \
{ \
logcon("ERROR: Trying to start the player when it is already running"); \
} \
}
Definition InputFPPRemotePlayItem.hpp:26

◆ DeAllocatePlayer

#define DeAllocatePlayer ( )
Value:
{ \
if(PlayerInfo.InUse) \
{ \
pInputFPPRemotePlayItem = nullptr; \
PlayerInfo.InUse = false; \
((c_InputFPPRemotePlayItem*)(&PlayerInfo.Player[0]))->~c_InputFPPRemotePlayItem(); \
memset(PlayerInfo.Player, 0x0, sizeof(PlayerInfo.Player)); \
} \
else \
{ \
logcon(F("ERROR: Trying to stop player when no player is running")); \
} \
}