VDP2 control.
#include <srl_vdp2.hpp>
Classes | |
class | NBG0 |
NBG0 interface. More... | |
class | NBG1 |
NBG1 interface. More... | |
class | NBG2 |
NBG2 interface. More... | |
class | NBG3 |
NBG3 interface. More... | |
class | RBG0 |
RBG0 interface. More... | |
class | ScrollScreen |
Functionality available to all Scroll Screen interfaces. More... | |
class | SpriteLayer |
Interface to control VDP2 settings for the Sprite Layer (data from VDP1 framebuffer), such as Display priority and VDP2 color calculation) More... | |
class | VRAM |
Manages VDP2 VRAM allocation. More... | |
Public Types | |
enum class | ColorCalcMode : uint16_t { UseColorRatiosTop = 0x000 , UseColorRatios2nd = 0x200 , UseColorAddition = 0x100 } |
Used to Select behavior of VDP2 Half Transparent Color Calculation. More... | |
enum class | ColorCondition : uint16_t { PriorityLessThan = CC_pr_CN , PriorityEquals = CC_PR_CN , PriorityGreaterThan = CC_PR_cn } |
Sprite Color Calculation Conditions (See SpriteLayer::SetColorCondition() for details) More... | |
enum class | Priority : uint16_t { Layer0 = 0 , Layer1 = 1 , Layer2 = 2 , Layer3 = 3 , Layer4 = 4 , Layer5 = 5 , Layer6 = 6 , Layer7 = 7 } |
VDP2 scroll priorities (Higher layers draw on top of lower layers) | |
enum class | RotationMode { OneAxis , TwoAxis , ThreeAxis } |
setting for RBG0,1 rotation constraints More... | |
enum class | SpriteBank : int16_t { Bank0 = scnSPR0 , Bank1 = scnSPR1 , Bank2 = scnSPR2 , Bank3 = scnSPR3 , Bank4 = scnSPR4 , Bank5 = scnSPR5 , Bank6 = scnSPR6 , Bank7 = scnSPR7 } |
Used to reference the Sprite color calculation ratio and priority registers. More... | |
enum class | VramBank : uint16_t { A0 = 0 , A1 = 1 , B0 = 2 , B1 = 3 } |
used to specify the 4 VRAM banks that are available for VDP2 allocation | |
Static Public Member Functions | |
static void | ClearVRAM () |
Clear all VDP2 VRAM allocations and reset all Scroll Screen VRAM References, as well as all CRAM allocations associated with VDP2 Scroll Screens. | |
static void | Initialize (const Types::HighColor &backColor) |
Initialize VDP2. | |
static void | SetBackColor (const Types::HighColor &color) |
Set the back color. | |
static void | SetColorCalcMode (VDP2::ColorCalcMode Mode=VDP2::ColorCalcMode::UseColorRatiosTop) |
Sets VDP2 Half Transparent Color Calculation Mode (only one mode can be used at once) | |
static void | SetPrintPaletteColor (const uint16_t index, const Types::HighColor &color) |
Set color for print. | |
Static Public Attributes | |
static uint16_t | ActiveScrolls = NBG0ON | NBG3ON |
Bitfield recording all Currently enabled Scroll Screens. | |
static uint16_t | ColorCalcScrolls = NBG0ON | NBG3ON | SPRON |
Bitfield recording all Scroll Screens with VDP2 Color Calculation enabled. | |
|
strong |
Used to Select behavior of VDP2 Half Transparent Color Calculation.
|
strong |
Sprite Color Calculation Conditions (See SpriteLayer::SetColorCondition() for details)
|
strong |
setting for RBG0,1 rotation constraints
Enumerator | |
---|---|
OneAxis | 2d rotation with only roll and zoom
|
TwoAxis | 3d rotation with pitch and yaw, but no roll (modified per line)
|
ThreeAxis | Full 3d rotation with pitch, yaw and roll (modified per pixel)
|
|
strong |
Used to reference the Sprite color calculation ratio and priority registers.
|
inlinestatic |
|
inlinestatic |
Initialize VDP2.
backColor | starting back color |
|
inlinestatic |
Set the back color.
color | Color to use |
|
inlinestatic |
|
inlinestatic |
Set color for print.
index | Color index |
color | Color to set |