Return to previous page Return to menu Go to next page

2.3 Function specification

  Title  
Function specifications
  Function  
Run length stretch
  Function name  
CMP_DecRunlen
No
1

  format  Sint32 CMP_DecRunlen (void * in, void ** out, Sint32 size)
 Argument  in (Input): Compressed data input buffer pointer.
:  out (input): Address of the decompressed data output buffer pointer.
  (Output): Deletion data output tail pointer.
 Buffsize (input): Output buffer size [BYTE].
 Return value  Processing result
:  CMP_DEC_OK (0): Successful completion. The input data has been expanded to the end.
:  CMP_DEC_STOP (1): The decompression process is suspended. The output buffer size has been expanded.
  CMP_DEC_ERR (-1): Abnormal termination. The input data is abnormal.
  CMP_DEC_ERR_H_ALGO (-2): Abnormal termination. Unsupported algorithm.
  CMP_DEC_ERR_H_UNIT (-3): Abnormal termination. Unsupported processing unit.
 Function  Decompresses compressed data.
:  Processes compressed data by the run-length compression tool CMPRUN.EXE of this system.
 This function is a decompression function that interprets the header of the input data and matches the compression parameters.
 Starts .
 Compressed data is read from  in.
Write decompressed data to  *  * out. * out is the post-in
 increments . The user sets the * out value set before startup and the * out value after startup.
The size of the decompressed data can be determined from the difference between  and  values.
  If the decompressed data exceeds bufsze [byte], processing is interrupted there. Interrupted
Even in the case of . , the correct decompressed data for the buffer size is written to the output buffer.
 There is . 

      Note: Both input buffer and output buffer are reserved by the user. Ahead of each buffer The head address must match the start address of the 4-byte boundary . The output buffer must be large enough to obtain decompressed data, and the processing unit It must be an integer multiple of the number of bytes.
Remarks

< Figure 2.1 Explanation of arguments of extension function


Return to previous page Return to menu Go to next page