| H | |
| HBlank, PPU | |
| I | |
| Idle | |
| Initialize | |
| InsertCartridge, GBA | |
| Interrupt, CPU | |
| L | |
| LoadBios, GBA | |
| M | |
| main | |
| MainWindow, MainWindow | |
| Memory, Memory | |
| O | |
| OAMSprites, OAMSprites | |
| OverflowTimer, timer_data | |
| P | |
| pack_rgb, PPU | |
| Palette, Palettes | |
| Parse, Breakpoint | |
| PPU, PPU | |
| R | |
| Read16, Memory | |
| Read32, Memory | |
| Read8, Memory | |
| render_bg_textmode, PPU | |
| render_bg_textmode_tile4, PPU | |
| render_bg_textmode_tile8, PPU | |
| render_mode0, PPU | |
| render_mode1, PPU | |
| render_mode2, PPU | |
| render_mode3, PPU | |
| render_mode4, PPU | |
| render_mode5, PPU | |
| render_objsprites, PPU | |
| render_sprite, PPU | |
| render_sprite_fixed, PPU | |
| render_sprite_rotscale, PPU | |
| Resize, DebuggerInterface | |
| S | |
| SetAccessAddr, Memory | |
| SetAddFlags, CPU | |
| SetAddFlagsByVal, CPU | |
| SetGPRegisterValue, CPU | |
| SetPC, CPU | |
| SetRedrawAll, DebuggerInterface | |
| SetSubFlags, CPU | |
| SetSubFlagsByVal, CPU | |
| SetToReloadValue, timer_data | |
| SoftwareInterrupt, CPU | |
| Start, GBA | |
| StartDebug, GBA | |
| StartDisasm, GBA | |
| SWI_CpuFastSet, CPU | |
| SWI_CpuSet, CPU | |
| T | |
| Timers, timer_data | |
| ToString, Breakpoint | |
| TransferIncrementAddresses, dma_data |
Generates a HBlank interrupt if the environment allows that.
inline void HBlank()
This is the main function of DMAChannels.
inline bool Idle()
Performs idle operations on timers.
inline void Idle( int cyclesCount )
Set the cpu to a starting state
void Initialize()
Initializes ncurses and the windows fields in the interface.
void Initialize()
Initializes a window and opengl with its vbs and shaders
int Initialize( int screenMultiplier = 1 )
Fills the ROM memory reading data from a file.
bool InsertCartridge( char * fileName )
Writes to the IF Register the interrupt code.
inline void Interrupt( int code )
Loads the bios into its memory space (0x00000000-0x02000000) reading data from a file.
bool LoadBios( char * filename )
Entry Point of the application
int main( int argc, char ** argv )
MainWindow( PPU * p, Memory * m )
Builds memory.
Memory()
Builds our oamsprites object.
OAMSprites( Memory * mem )
Performs overflow operation on timer (generates irq if enabled, restarts with reload value, increments successive if countup is enabled).
inline void OverflowTimer( int index )
Packs 3 channels into a 16 bit RGBA_5_5_5_1 format integer.
inline uint16_t pack_rgb( int r, int g, int b )
Builds the Palettes object.
Palettes( Memory * mem )
Parses a condition string.
bool Parse( char * str )
Builds a PPU.
PPU( Memory * mem, CPU * cpu, Palettes * pal, OAMSprites * spr )
Reads 16 bit at the given emulated address.
inline uint16_t Read16( uint32_t addr )
Reads 32 bit at the given emulated address.
inline uint32_t Read32( uint32_t addr )
Reads 8 bit at the given emulated address.
inline uint8_t Read8( uint32_t addr )
Renders a background in text mode.
inline void render_bg_textmode( PPU * ppu, uint16_t bgcnt, uint16_t bghofs, uint16_t bgvofs, uint16_t * outBuffer )
Renders a background with 16/16 palettes/color mode.
inline void render_bg_textmode_tile4( PPU * ppu, uint16_t bgcnt, uint16_t bghofs, uint16_t bgvofs, uint16_t * outBuffer )
Renders a background with 256/1 colors/palette mode.
inline void render_bg_textmode_tile8( PPU * ppu, uint16_t bgcnt, uint16_t bghofs, uint16_t bgvofs, uint16_t * outBuffer )
Renders a background with rendering mode 0.
void render_mode0( PPU * ppu, unsigned char * outBuffer )
UNIMPLEMENTED.
void render_mode1( PPU * ppu, unsigned char * outBuffer )
UNIMPLEMENTED.
void render_mode2( PPU * ppu, unsigned char * outBuffer )
UNIMPLEMENTED.
void render_mode3( PPU * ppu, unsigned char * outBuffer )
Renders a background with rendering mode 4.
void render_mode4( PPU * ppu, unsigned char * outBuffer )
UNIMPLEMENTED.
void render_mode5( PPU * ppu, unsigned char * outBuffer )
Renders all the sprites of the ppu into its sprites buffer PPU.buffer_obj.
inline void render_objsprites( PPU * ppu, void * tilesMem )
Renders a sprite (into sprites buffer).
inline void render_sprite( PPU * ppu, OAMSprite * sprite, void * tilesMem )
Renders a sprite (into sprites buffer) that has rotation/scale disabled.
inline void render_sprite_fixed( PPU * ppu, OAMSprite * sprite, void * tilesMem )
Renders a sprite (into sprites buffer) that has rotation/scale enabled.
inline void render_sprite_rotscale( PPU * ppu, OAMSprite * sprite, void * tilesMem )
Resizes windows to fill the available area.
void Resize()
Sets last access zone according to the address.
inline void SetAccessAddr( uint32_t addr )
Sets the correct flags after an addition.
inline void SetAddFlags( int op1, int op2, int destinationID )
Sets the correct flags after an addition.
inline void SetAddFlagsByVal( int op1, int op2, uint32_t val )
Set the value of a register in current Mode.
inline void SetGPRegisterValue( int regid, uint32_t val )
Sets the program counter.
inline void SetPC( uint32_t val )
Sets the right flags to make a full refresh happen at the next Draw call.
void SetRedrawAll()
Sets the correct flags after a subtraction.
inline void SetSubFlags( int op1, int op2, int destinationID )
Sets the correct flags after a subtraction.
inline void SetSubFlagsByVal( int op1, int op2, uint32_t val )
Sets a timer to its reload value.
inline void SetToReloadValue( int index )
Generates a Software Interrupt.
inline void SoftwareInterrupt( uint8_t id, int pcOff )
Starts GBA execution.
void Start()
Starts GBA execution with a debugger (slower than Start).
void StartDebug()
Old OBSOLETE function.
void StartDisasm()
Fastly executes Software Interrupt 0xC (CpuFastSet).
inline void SWI_CpuFastSet()
Fastly executes Software Interrupt 0xB (CpuSet).
inline void SWI_CpuSet()
Builds the timers handler utility.
Timers( Memory * mem, CPU * cpu )
Makes the Break Rule readable by putting it into a string.
void ToString( char * str )
Increment the addresses following the control register rules.
inline void TransferIncrementAddresses( int chan, int sz )