[ Spectaculator, ZX Spectrum Emulator ] Home | Downloads | Support [ ZX Spectrum Image ]

Table of contents

The zx-state file format
Block types

ZXSTBLOCK header

All blocks in the file start with this header. The header identifies the block type and how big the data following it is.

If your parser does not recognise the block type, it can simply skip the remaining dwSize bytes to find the next block.

// Block Header. Each real block starts
// with this header.
typedef struct _tagZXSTBLOCK
{
  DWORD dwId;
  DWORD dwSize;
} ZXSTBLOCK, *LPZXSTBLOCK;

Members

dwId
Indicates which type of block follows this header. It is a 4 byte sequence compressed into a DWORD.

e.g. the ZXSTCREATOR block has a block id of 'C', 'R', 'T', 'R'.

dwSize
Specifies the size of the block following this header. It does not include the size of this header.

e.g. for a ZXSTPLUS3 block, dwSize would be calculated thus:

ZXSTPLUS3 pl3;
pl3.blk.dwSize = sizeof( ZXSTPLUS3 ) - sizeof( ZXSTBLOCK );

Requirements

Available since version 1.0


  Copyright © 2001 - 2011 Jonathan Needle Top