sgdk: Map Struct Reference

sgdk

- Main Page
- Related Pages
- Classes
- Files

- Class List

Public Attributes
Map Struct Reference

Map structure containing information for large background/plane update based on MapDefinition. More...

`#include <map.h>`

List of all members.

## Public Attributes

u16 | w
u16 | h
u16 * | metaTiles
void * | blocks
void * | blockIndexes
u16 * | blockRowOffsets
VDPPlane | plane
u16 | baseTile
u32 | posX
u32 | posY
u16 | planeWidthMask
u16 | planeHeightMask
u16 | lastXT
u16 | lastYT
u16 | hScrollTable [240]
u16 | vScrollTable [20]
void(* | prepareMapDataColumnCB )(struct Map *map, u16 *bufCol1, u16 *bufCol2, u16 xm, u16 ym, u16 height)
void(* | prepareMapDataRowCB )(struct Map *map, u16 *bufRow1, u16 *bufRow2, u16 xm, u16 ym, u16 width)
u16(* | getMetaTileCB )(struct Map *map, u16 x, u16 y)
void(* | getMetaTilemapRectCB )(struct Map *map, u16 x, u16 y, u16 w, u16 h, u16 *dest)

## Detailed Description

Map structure containing information for large background/plane update based on MapDefinition.

Parameters:

  w | map width in block (128x128 pixels block)
  h | map height in block (128x128 pixels block)
  metaTiles | internal - unpacked data of MapDefinition.metaTiles
  blocks | internal - unpacked data of MapDefinition.blocks
  blockIndexes | internal - unpacked data of MapDefinition.blockIndexes
  blockRowOffsets | internal - direct access of MapDefinition.blockRowOffsets
  plane | VDP plane where MAP is draw
  baseTile | Base tile attributes used to provide base tile index offset and base palette index (see TILE_ATTR_FULL() macro)
  posX | current view position X set using MAP_scrollTo(..) method
  posY | current view position Y set using MAP_scrollTo(..) method
  planeWidthMask | internal
  planeHeightMask | internal
  lastXT | internal
  lastYT | internal
  prepareMapDataColumnCB | internal
  prepareMapDataRowCB | internal
  hScrollTable | internal
  vScrollTable | internal
  getMetaTileCB | internal
  getMetaTilemapRectCB | internal

The documentation for this struct was generated from the following file:

- map.h

All Classes Files Functions Variables Typedefs Enumerations Enumerator Defines