Click or drag to resize

IDfsFileInfoGetEncodeKey Method

Gets the compression encoding key.

When a file is compressed, all dynamic items are compressed with the same encoding key, and hence also all dynamic items have the same spatial axis.

When a file is compressed, the encoding key defines for each value stored in the file the indices [xi, yi, zy] in the data matrix where the value belongs. Hence, the i'th data value belongs in the data matrix on Data[ xKey[i], yKey[i], zKey[i]], or using linear indexing: Data[xKey[i] + yKey[i]*xCount + zKey[i]*xCount*yCount].

For a 2D axis all zKey values are zero. For a 1D axis all yKey and zKey values are zero.

When reading data from dynamic items, data is automatically uncompressed when loaded, hence the encoding keys are only for information. Some files also compresses static items, and compresses these also, however using a dummy axis of the size of the encoding key, and manual decoding needs to take place, see dfsDecodeT(T, Int32, Int32, Int32, Int32, Int32, Int32, T) and dfsEncodeT(T, Int32, Int32, Int32, Int32, Int32, Int32).

Data outside the encoding key gets the delete value.

For a file with 2D data all zi's are zero, and for a 1D file, zi's and yi's are zero.

It is only valid to call this function if IsFileCompressed returns true.

Namespace:  DHI.Generic.MikeZero.DFS
Assembly:  DHI.Generic.MIKEZero.DFS (in DHI.Generic.MIKEZero.DFS.dll) Version: 19.0.0.0 (11.1.1.1111)
Syntax
void GetEncodeKey(
	out int[] xKey,
	out int[] yKey,
	out int[] zKey
)

Parameters

xKey
Type: SystemInt32
yKey
Type: SystemInt32
zKey
Type: SystemInt32
See Also