Files
AppleWin/source/VidHD.h
T
TomCh 80ec6e5545 Improve Configuration GUI for better slot/card selection (#853, PR #1462)
. Add PropSheetPage: Slots (and include 'Reset to Default')
  - include config options for some cards
. Remove PropSheetPages: Sound & Disk
. Config page: refactor and add 'Reset all to Default'
. Input page: refactor
. Advanced page: refactor
2026-03-07 22:00:07 +00:00

55 lines
1.4 KiB
C++

#pragma once
#include "Card.h"
#include "Interface.h"
class VidHDCard : public Card
{
public:
VidHDCard(UINT slot) :
Card(CT_VidHD, slot)
{
if (m_slot == SLOT0)
ThrowErrorInvalidSlot();
m_memMode = 0;
m_SCREENCOLOR = 0;
m_NEWVIDEO = 0;
m_BORDERCOLOR = 0;
m_SHADOW = 0;
GetVideo().SetVidHD(true);
}
virtual ~VidHDCard(void)
{
GetVideo().SetVidHD(false);
}
virtual void Destroy(void) {}
virtual void Reset(const bool powerCycle);
virtual void Update(const ULONG nExecutedCycles) {}
virtual void InitializeIO(LPBYTE pCxRomPeripheral);
static BYTE __stdcall IORead(WORD pc, WORD addr, BYTE bWrite, BYTE value, ULONG nExecutedCycles);
void VideoIOWrite(WORD pc, WORD addr, BYTE bWrite, BYTE value, ULONG nExecutedCycles);
bool IsSHR(void) { return (m_NEWVIDEO & 0xC0) == 0xC0; } // 11000000 = Enable SHR(b7) | Linearize SHR video memory(b6)
bool IsDHGRBlackAndWhite(void) { return (m_NEWVIDEO & (1 << 5)) ? true : false; }
bool IsWriteAux(void);
static void UpdateSHRCell(bool is640Mode, bool isColorFillMode, uint16_t addrPalette, bgra_t* pVideoAddress, uint32_t a);
static const std::string& GetSnapshotCardName(void);
virtual void SaveSnapshot(YamlSaveHelper& yamlSaveHelper);
virtual bool LoadSnapshot(YamlLoadHelper& yamlLoadHelper, UINT version);
private:
static const UINT SHR_MEMORY_END = 0x9FFF;
UINT m_memMode; // Only used by II/II+
BYTE m_SCREENCOLOR;
BYTE m_NEWVIDEO;
BYTE m_BORDERCOLOR;
BYTE m_SHADOW;
};