mirror of
https://github.com/buhman/nds.git
synced 2025-06-18 14:35:38 -04:00
86 lines
3.8 KiB
C
86 lines
3.8 KiB
C
#pragma once
|
|
|
|
#include <stdint.h>
|
|
#include <stddef.h>
|
|
#define static_assert _Static_assert
|
|
|
|
struct graphics_engine_b {
|
|
volatile uint32_t DISPCNT;
|
|
volatile uint8_t _pad0[4];
|
|
volatile uint16_t BG0CNT;
|
|
volatile uint16_t BG1CNT;
|
|
volatile uint16_t BG2CNT;
|
|
volatile uint16_t BG3CNT;
|
|
volatile uint16_t BG0HOFS;
|
|
volatile uint16_t BG0VOFS;
|
|
volatile uint16_t BG1HOFS;
|
|
volatile uint16_t BG1VOFS;
|
|
volatile uint16_t BG2HOFS;
|
|
volatile uint16_t BG2VOFS;
|
|
volatile uint16_t BG3HOFS;
|
|
volatile uint16_t BG3VOFS;
|
|
volatile uint16_t BG2PA;
|
|
volatile uint16_t BG2PB;
|
|
volatile uint16_t BG2PC;
|
|
volatile uint16_t BG2PD;
|
|
volatile uint32_t BG2X;
|
|
volatile uint32_t BG2Y;
|
|
volatile uint16_t BG3PA;
|
|
volatile uint16_t BG3PB;
|
|
volatile uint16_t BG3PC;
|
|
volatile uint16_t BG3PD;
|
|
volatile uint32_t BG3X;
|
|
volatile uint32_t BG3Y;
|
|
volatile uint16_t WIN0H;
|
|
volatile uint16_t WIN1H;
|
|
volatile uint16_t WIN0V;
|
|
volatile uint16_t WIN1V;
|
|
volatile uint16_t WININ;
|
|
volatile uint16_t WINOUT;
|
|
volatile uint16_t MOSAIC;
|
|
volatile uint8_t _pad1[2];
|
|
volatile uint16_t BLDCNT;
|
|
volatile uint16_t BLDALPHA;
|
|
volatile uint16_t BLDY;
|
|
volatile uint8_t _pad2[22];
|
|
volatile uint16_t MASTER_BRIGHT;
|
|
volatile uint8_t _pad3[2];
|
|
};
|
|
static_assert((offsetof (struct graphics_engine_b, DISPCNT)) == 0x000);
|
|
static_assert((offsetof (struct graphics_engine_b, BG0CNT)) == 0x008);
|
|
static_assert((offsetof (struct graphics_engine_b, BG1CNT)) == 0x00a);
|
|
static_assert((offsetof (struct graphics_engine_b, BG2CNT)) == 0x00c);
|
|
static_assert((offsetof (struct graphics_engine_b, BG3CNT)) == 0x00e);
|
|
static_assert((offsetof (struct graphics_engine_b, BG0HOFS)) == 0x010);
|
|
static_assert((offsetof (struct graphics_engine_b, BG0VOFS)) == 0x012);
|
|
static_assert((offsetof (struct graphics_engine_b, BG1HOFS)) == 0x014);
|
|
static_assert((offsetof (struct graphics_engine_b, BG1VOFS)) == 0x016);
|
|
static_assert((offsetof (struct graphics_engine_b, BG2HOFS)) == 0x018);
|
|
static_assert((offsetof (struct graphics_engine_b, BG2VOFS)) == 0x01a);
|
|
static_assert((offsetof (struct graphics_engine_b, BG3HOFS)) == 0x01c);
|
|
static_assert((offsetof (struct graphics_engine_b, BG3VOFS)) == 0x01e);
|
|
static_assert((offsetof (struct graphics_engine_b, BG2PA)) == 0x020);
|
|
static_assert((offsetof (struct graphics_engine_b, BG2PB)) == 0x022);
|
|
static_assert((offsetof (struct graphics_engine_b, BG2PC)) == 0x024);
|
|
static_assert((offsetof (struct graphics_engine_b, BG2PD)) == 0x026);
|
|
static_assert((offsetof (struct graphics_engine_b, BG2X)) == 0x028);
|
|
static_assert((offsetof (struct graphics_engine_b, BG2Y)) == 0x02c);
|
|
static_assert((offsetof (struct graphics_engine_b, BG3PA)) == 0x030);
|
|
static_assert((offsetof (struct graphics_engine_b, BG3PB)) == 0x032);
|
|
static_assert((offsetof (struct graphics_engine_b, BG3PC)) == 0x034);
|
|
static_assert((offsetof (struct graphics_engine_b, BG3PD)) == 0x036);
|
|
static_assert((offsetof (struct graphics_engine_b, BG3X)) == 0x038);
|
|
static_assert((offsetof (struct graphics_engine_b, BG3Y)) == 0x03c);
|
|
static_assert((offsetof (struct graphics_engine_b, WIN0H)) == 0x040);
|
|
static_assert((offsetof (struct graphics_engine_b, WIN1H)) == 0x042);
|
|
static_assert((offsetof (struct graphics_engine_b, WIN0V)) == 0x044);
|
|
static_assert((offsetof (struct graphics_engine_b, WIN1V)) == 0x046);
|
|
static_assert((offsetof (struct graphics_engine_b, WININ)) == 0x048);
|
|
static_assert((offsetof (struct graphics_engine_b, WINOUT)) == 0x04a);
|
|
static_assert((offsetof (struct graphics_engine_b, MOSAIC)) == 0x04c);
|
|
static_assert((offsetof (struct graphics_engine_b, BLDCNT)) == 0x050);
|
|
static_assert((offsetof (struct graphics_engine_b, BLDALPHA)) == 0x052);
|
|
static_assert((offsetof (struct graphics_engine_b, BLDY)) == 0x054);
|
|
static_assert((offsetof (struct graphics_engine_b, MASTER_BRIGHT)) == 0x06c);
|
|
static_assert((sizeof (struct graphics_engine_b)) == 0x70);
|