Modernization of the legacy vJoy-based RIO cockpit interface for Win10/11, removing the vJoy dependency in favor of a custom VHF/UMDF HID driver, rewritten in C#/.NET 8 as a background tray app with per-game profiles. - Reorganize: legacy C++ -> legacy/, cockpit art -> docs/reference/ - RioJoy.sln: src/RioJoy.Core (lib) + src/RioJoy.Tray (tray app), net8.0-windows x64 - driver/ placeholder for the RioGamepad WDK driver - docs/PLAN.md (7-phase plan; profiles + serial-yield model) - docs/PROTOCOL.md (RIO wire format + iRIO input-map reference) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
65 lines
1.4 KiB
C++
65 lines
1.4 KiB
C++
#ifndef __CPLASMA_H__
|
|
#define __CPLASMA_H__
|
|
|
|
#define ESC 27
|
|
class CPlasma : public C232Comm
|
|
{
|
|
public:
|
|
DWORD m_dwStart;
|
|
int m_nOldRank;
|
|
int m_nOldScore;
|
|
enum {
|
|
ATTR_NORMAL = 0,
|
|
ATTR_HALF = 1,
|
|
ATTR_LINE = 2,
|
|
ATTR_REVERSE = 4,
|
|
ATTR_FLASH = 8,
|
|
ATTR_PROTECTED = 128
|
|
};
|
|
enum { PLASMA_OFF, PLASMA_ON, PLASMA_FLASH };
|
|
|
|
int m_nGlobalState;
|
|
// Time m_timeLastPlasma2;
|
|
public:
|
|
CPlasma () {
|
|
Open (2);
|
|
m_dwStart = GetTickCount ();
|
|
PlasmaClear ();
|
|
PlasmaCursor (CPlasma::PLASMA_OFF);
|
|
m_nOldRank = INT_MIN;
|
|
m_nOldScore = INT_MIN;
|
|
|
|
m_nGlobalState = -1;
|
|
}
|
|
virtual ~CPlasma () {
|
|
PlasmaCursor (CPlasma::PLASMA_OFF);
|
|
PlasmaClear ();
|
|
Close ();
|
|
}
|
|
public:
|
|
void SendPacket (const BYTE* pbPacket, char nLen);
|
|
void PlasmaClear ();
|
|
|
|
void PlasmaCursor (char n = PLASMA_OFF);
|
|
void PlasmaCursorHome ();
|
|
void PlasmaCursorX (char n);
|
|
void PlasmaCursorY (char n);
|
|
|
|
void PlasmaFontAttr (char n);
|
|
void PlasmaFont (char n);
|
|
|
|
void PlasmaText (const char *szText);
|
|
POINT GetFontSize (int Font);
|
|
|
|
void PlasmaBoxDraw (RECT tag);
|
|
void PlasmaBoxFill (RECT tag);
|
|
void PlasmaPosText (const char *szText, char x = 0, char y = 0, char Attr = 0, char Font = 5);
|
|
void PlasmaScoreDraw (const char *Rank, const char *Score, BOOL bFlag);
|
|
|
|
void DoPlasma(char nMode);
|
|
private:
|
|
void PlasmaDisplay (int Gamestate, const char *szName, const char *Rank, const char *Score);
|
|
};
|
|
|
|
|
|
#endif |