Generally either
import * as seedcodec from 'seisplotjs-seedcodec'
seedcodec.xxxx
or
import * as seisplotjs from 'seisplotjs'
seisplotjs.seedcodec.xxxx
Decompress the samples from the provided DataView and return an array of the decompressed values. Only 16 bit short, 32 bit int, 32 bit float and 64 bit double along with Steim1 and Steim2 are supported.
(number)
compression format as defined in SEED blockette 1000
(DataView)
input DataView to be decoded
(number)
the number of samples that can be decoded from array
b
(boolean)
if true, dataView is little-endian (intel byte order)
b
.
Array<number>
:
array of length
numSamples
.
Extends Error
(string)
Extends Error
(string)
Constants for the various compresstion types.
ascii
Type: number
16 bit integer, or java short
Type: number
24 bit integer
Type: number
32 bit integer, or java int
Type: number
ieee float
Type: number
ieee double
Type: number
Steim1 compression
Type: number
Steim2 compression
Type: number
CDSN 16 bit gain ranged
Type: number
(A)SRO
Type: number
DWWSSN 16 bit
Type: number
Decode the indicated number of samples from the provided byte array and return an integer array of the decompressed values. Being differencing compression, there may be an offset carried over from a previous data record. This offset value can be placed in bias, otherwise leave the value as 0.
(DataView)
input DataView to be decoded
(number)
the number of samples that can be decoded from array
b
(boolean)
if true, dataView is little-endian (intel byte order)
b
.
(number)
the first difference value will be computed from this value.
If set to 0, the method will attempt to use the X(0) constant instead.
any
:
int array of length
numSamples
.
Decode the indicated number of samples from the provided byte array and return an integer array of the decompressed values. Being differencing compression, there may be an offset carried over from a previous data record. This offset value can be placed in bias, otherwise leave the value as 0.
(DataView)
(number)
the number of samples that can be decoded from array
b
(boolean)
if true, swap reverse the endian-ness of the elements of
byte array
b
.
(number)
the first difference value will be computed from this value.
If set to 0, the method will attempt to use the X(0) constant instead.
(any)
input byte array to be decoded
Array<number>
:
int array of length
numSamples
.