load raw

From DavinciWiki
Jump to: navigation, search


64-bit SafeYes

Description

Load a binary data file

Arguments and Return Values

Arguments: A filename and data dimensions and layout information

Return Value: A numeric array

Usage

Syntax: load_raw(filename = STRING, x = INT, y = INT, z = INT, org = ORG, format = FORMAT, header = INT)

The load_raw() function allows a user to load uncompressed binary data by specifying relevent information about the file.

The x, y and z parameters specify the number of pixels in each axis.

ORG must be one of "bil", "bip", "bsq".

FORMAT must be one of: "byte", "msb_short", "msb_int", "msb_float", "msb_double", "lsb_short", "lsb_int", "lsb_float", "lsb_double".

The header value specifies the size, in bytes, of any header to be skipped.

Examples

dv> a
400x300x1 array of byte, bip format [120,000 bytes]

dv> write(a,"asciifile",raw)

dv> b=load_raw("asciifile",x=400,y=300,z=1,org="bsq",format="byte",header=0)
.400x300x1 array of byte, bsq format [120,000 bytes]

DavinciWiki Mini-Nav Bar

Contents


Contact Developers

  • davinci-dev [AT] mars.asu.edu

All other topics

  • See navigation on the left

Related Functions

Recent Core Changes

Modified On: 07-06-2009

Personal tools