v1.1.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Modules Pages
Classes | Typedefs | Enumerations
Video

Video graphics subsystem. More...

Classes

struct  Sifteo::BG0Drawable
 A VRAM accessor for drawing graphics in the BG0 mode. More...
 
struct  Sifteo::BG0ROMDrawable
 A VRAM accessor for drawing graphics in the BG0_ROM mode. More...
 
struct  Sifteo::BG1Drawable
 A VRAM accessor for drawing graphics in the BG1 mode. More...
 
struct  Sifteo::BG1Mask
 A BG1 tile mask. In other words, this is a 16x16-bit two-dimensional vector. More...
 
struct  Sifteo::BG2Drawable
 A VRAM accessor for drawing graphics in the BG2 mode. More...
 
struct  Sifteo::Colormap
 An accessor for the colormap, with up to 16 colors. More...
 
struct  Sifteo::ColormapSlot
 A ColormapSlot refers to a single colormap index on a single cube. More...
 
struct  Sifteo::FBDrawable< tWidth, tHeight, tBitsPerPixel >
 A templatized VRAM accessor for drawing pixel graphics, in one of the cube's supported framebuffer drawing modes. More...
 
struct  Sifteo::RelocatableTileBuffer< tW, tH, tF >
 A drawable that's backed by plain memory, usable with multiple cubes. More...
 
struct  Sifteo::RGB565
 Represents a 16-bit 5:6:5 color, the native format used by our display. More...
 
struct  Sifteo::SpriteLayer
 A SpriteLayer represents the VRAM attributes for the sprite rendering layer in BG0_SPR_BG1 mode. More...
 
struct  Sifteo::SpriteRef
 SpriteRefs refer to a single sprite on a single cube. More...
 
struct  Sifteo::StampDrawable
 A VRAM accessor for the STAMP mode, a special purpose 16-color framebuffer mode which supports color-keying and tiling. More...
 
struct  Sifteo::TileBuffer< tW, tH, tF >
 A drawable that's backed by plain memory, instead of by a VideoBuffer. More...
 
struct  Sifteo::VideoBuffer
 A memory buffer which holds graphics data. More...
 

Typedefs

typedef FBDrawable< 128, 48, 1 > Sifteo::FB128Drawable
 Typedef for the FBDrawable instance used in FB128 mode.
 
typedef FBDrawable< 32, 32, 4 > Sifteo::FB32Drawable
 Typedef for the FBDrawable instance used in FB32 mode.
 
typedef FBDrawable< 64, 64, 1 > Sifteo::FB64Drawable
 Typedef for the FBDrawable instance used in FB64 mode.
 

Enumerations

enum  Sifteo::BG0ROMDrawable::ColorMode
 Color modes, XOR'ed with the tile IDs below.
 
enum  Sifteo::BG0ROMDrawable::Palette
 Palette IDs, XOR'ed with the tile IDs below.
 
enum  Sifteo::Rotation
 Rotation and mirroring modes, for setRotation(). More...
 
enum  Sifteo::BG0ROMDrawable::Tiles {
  Sifteo::BG0ROMDrawable::FONT_SPACE = 0, Sifteo::BG0ROMDrawable::SOLID_BG = 0, Sifteo::BG0ROMDrawable::SOLID_FG = 104, Sifteo::BG0ROMDrawable::V_BARGRAPH = 224,
  Sifteo::BG0ROMDrawable::H_BARGRAPH = 231
}
 Well-known tile numbers. More...
 
enum  Sifteo::VideoMode {
  Sifteo::POWERDOWN_MODE = _SYS_VM_POWERDOWN, Sifteo::BG0_ROM = _SYS_VM_BG0_ROM, Sifteo::SOLID_MODE = _SYS_VM_SOLID, Sifteo::FB32 = _SYS_VM_FB32,
  Sifteo::FB64 = _SYS_VM_FB64, Sifteo::FB128 = _SYS_VM_FB128, Sifteo::BG0 = _SYS_VM_BG0, Sifteo::BG0_BG1 = _SYS_VM_BG0_BG1,
  Sifteo::BG0_SPR_BG1 = _SYS_VM_BG0_SPR_BG1, Sifteo::BG2 = _SYS_VM_BG2, Sifteo::STAMP = _SYS_VM_STAMP
}
 Supported video modes. More...
 

Detailed Description

Video graphics subsystem.

Enumeration Type Documentation

Rotation and mirroring modes, for setRotation().

In every video mode, the hardware can perform orthogonal rotation and mirroring cheaply. This happens at render-time, not continuously. For example, if you're doing partial screen drawing with setWindow() and you change the current rotation, the new rotation mode will affect future drawing but not past drawing.

Well-known tile numbers.

Enumerator
FONT_SPACE 

First character in the font, ASCII space.

SOLID_BG 

Solid background-colored tile (space)

SOLID_FG 

Solid foreground-colored tile.

V_BARGRAPH 

First tile in the vertical bargraph series.

H_BARGRAPH 

First tile in the horizontal bargraph series.

Supported video modes.

Each "video mode" is a separate way of interpreting the VideoBuffer memory in order to compose a frame of graphics.

Most of the video modes map directly to a collection of one or more drawables, which may be accessed via this VideoBuffer class. Some video modes are special-purpose, like POWERDOWN.

A cube can only be in one video mode at a time, though it's possible to use setWindow() to render portions of the screen in different modes. If you do this, take notice of how different modes reuse the same memory for different purposes.

Enumerator
POWERDOWN_MODE 

Power saving mode, LCD is off.

BG0_ROM 

BG0, with tile data from internal ROM.

SOLID_MODE 

Solid color, from colormap[0].

FB32 

32x32 pixel 16-color framebuffer

FB64 

64x64 pixel 2-color framebuffer

FB128 

128x48 pixel 2-color framebuffer

BG0 

BG0 background layer.

BG0_BG1 

BG0 background plus BG1 overlay.

BG0_SPR_BG1 

BG0 background, 8 sprites, BG1 overlay.

BG2 

16x16 tiled mode with affine transform

STAMP 

Reconfigurable 16-color framebuffer with transparency.