Surfer 6 Binary Grid File Format

Surfer6 grid files .GRD use a layout similar to the ASCII grid format. The only difference is in the identification string and that Surfer6 grid files are binary. Data types used in Surfer6 grid files include:

Type

Description

char

single byte

short

16 bit signed integer

float

32 bit single precision floating point value

double

64 bit double precision floating point value

 

The Surfer6 format has the following layout:

Element

Type

Description

id

char

4 byte identification string ‘DSBB’ which identifies the file as aSurfer6binary grid file.

nx

short

number of grid lines along the X axis (columns)

ny

short

number of grid lines along the Y axis (rows)

xlo

double

minimum X value of the grid

xhi

double

maximum X value of the grid

ylo

double

minimum Y value of the grid

yhi

double

maximum Y value of the grid

zlo

double

minimum Z value of the grid

zhi

double

maximum Z value of the grid

z11, z12, …

float

first row of the grid. Each row has a constant Y coordinate. The first row corresponds to ylo, and the last row corresponds to yhi. Within each row, the Z values are ordered from xlo to xhi.

z21, z22, …

float

second row of the grid

z31, z32, …

float

third row of the grid

float

all other rows of the grid up to yhi

See Also

Surfer 6 ASCII Grid Files

Surfer 7 Grid Files

File Format Chart