Classes | Public Member Functions | Public Attributes | Protected Attributes | Properties

Romulus.Nes.SmallNameTable Class Reference

Represents a combined nametable and attribute large enough to hold a (256, 256) background. More...

Inheritance diagram for Romulus.Nes.SmallNameTable:
Romulus.Nes.SmallExtendedNameTable< T >

List of all members.

Classes

struct  NameTableData
 Contains references to name table data. More...

Public Member Functions

 SmallNameTable ()
 Creates a SmallNameTable.
void SetTile (int x, int y, int value)
 Sets the pattern index for one tile.
int GetTile (int x, int y)
 Gets the pattern index for one tile.
void SetPalette (int x, int y, int value)
 Sets the palette index for one tile.
int GetPalette (int x, int y)
 Gets the palette index for one tile.
NameTableData GetBackingData ()
 Gets references to the raw NameTable data.
virtual void Clear ()
 Clears the name table data.

Public Attributes

const int Width = 32
 The size of the name table.
const int Height = 32
 The size of the name table.

Protected Attributes

byte[,] tiles
 Pattern index data.
byte[,] palettes
 Palette index data.

Properties

TileEntry this [int x, int y] [get, set]
 Gets or sets data for one tile.

Detailed Description

Represents a combined nametable and attribute large enough to hold a (256, 256) background.


Constructor & Destructor Documentation

Romulus.Nes.SmallNameTable.SmallNameTable (  ) 

Creates a SmallNameTable.


Member Function Documentation

virtual void Romulus.Nes.SmallNameTable.Clear (  )  [virtual]

Clears the name table data.

Reimplemented in Romulus.Nes.SmallExtendedNameTable< T >.

NameTableData Romulus.Nes.SmallNameTable.GetBackingData (  ) 

Gets references to the raw NameTable data.

Returns:

Reimplemented in Romulus.Nes.SmallExtendedNameTable< T >.

int Romulus.Nes.SmallNameTable.GetPalette ( int  x,
int  y 
)

Gets the palette index for one tile.

Parameters:
x The location of the tile to get.
y The location of the tile to get.
Returns:
The palette index.
int Romulus.Nes.SmallNameTable.GetTile ( int  x,
int  y 
)

Gets the pattern index for one tile.

Parameters:
x The location of the tile to get.
y The location of the tile to get.
Returns:
The pattern index.
void Romulus.Nes.SmallNameTable.SetPalette ( int  x,
int  y,
int  value 
)

Sets the palette index for one tile.

Parameters:
x The location of the tile to set.
y The location of the tile to set.
value Palette index.
void Romulus.Nes.SmallNameTable.SetTile ( int  x,
int  y,
int  value 
)

Sets the pattern index for one tile.

Parameters:
x The location of the tile to set.
y The location of the tile to set.
value Pattern index.

Member Data Documentation

The size of the name table.

Palette index data.

byte [,] Romulus.Nes.SmallNameTable.tiles [protected]

Pattern index data.

The size of the name table.


Property Documentation

TileEntry Romulus.Nes.SmallNameTable.this[int x, int y] [get, set]

Gets or sets data for one tile.

Parameters:
x Tile location.
y Tile location.
Returns:
Data for the specified tile.

Reimplemented in Romulus.Nes.SmallExtendedNameTable< T >.


The documentation for this class was generated from the following file:
 All Classes Namespaces Functions Variables Enumerations Properties Events