VirtualC64 v5.0 beta
Commodore 64 Emulator
Loading...
Searching...
No Matches
DmaDebuggerTypes.h
Go to the documentation of this file.
1// -----------------------------------------------------------------------------
2// This file is part of VirtualC64
3//
4// Copyright (C) Dirk W. Hoffmann. www.dirkwhoffmann.de
5// This FILE is dual-licensed. You are free to choose between:
6//
7// - The GNU General Public License v3 (or any later version)
8// - The Mozilla Public License v2
9//
10// SPDX-License-Identifier: GPL-3.0-or-later OR MPL-2.0
11// -----------------------------------------------------------------------------
13
14#pragma once
15
16#include "Reflection.h"
17#include "BusTypes.h"
18
19namespace vc64 {
20
21//
22// Enumerations
23//
24
32typedef DMA_DISPLAY_MODE DmaDisplayMode;
33
34struct DmaDisplayModeEnum : util::Reflection<DmaDisplayModeEnum, DmaDisplayMode> {
35
36 static constexpr long minVal = 0;
37 static constexpr long maxVal = DMA_DISPLAY_MODE_ODD_EVEN_LAYERS;
38 static bool isValid(auto value) { return value >= minVal && value <= maxVal; }
39
40 static const char *prefix() { return "DMA_DISPLAY_MODE"; }
41 static const char *key(long value)
42 {
43 switch (value) {
44
45 case DMA_DISPLAY_MODE_FG_LAYER: return "FG_LAYER";
46 case DMA_DISPLAY_MODE_BG_LAYER: return "BG_LAYER";
47 case DMA_DISPLAY_MODE_ODD_EVEN_LAYERS: return "ODD_EVEN_LAYERS";
48 }
49 return "???";
50 }
51};
52
53
54//
55// Structures
56//
57
58typedef struct
59{
60 // DMA debugger
61 bool dmaDebug;
62 bool dmaChannel[6];
63 u32 dmaColor[6];
64 DmaDisplayMode dmaDisplayMode;
65 u8 dmaOpacity;
66
67 // Cutter
68 u16 cutLayers;
69 u8 cutOpacity;
70}
71DmaDebuggerConfig;
72
73}
VirtualC64 project namespace.
Definition CmdQueue.cpp:16
DMA_DISPLAY_MODE
DMA debugger display mode.
Definition DmaDebuggerTypes.h:27
@ DMA_DISPLAY_MODE_FG_LAYER
Modulate the foreground layer.
Definition DmaDebuggerTypes.h:28
@ DMA_DISPLAY_MODE_BG_LAYER
Modulate the background layer.
Definition DmaDebuggerTypes.h:29
@ DMA_DISPLAY_MODE_ODD_EVEN_LAYERS
Modulate both layers.
Definition DmaDebuggerTypes.h:30