LZNV Tester CPP File Contents


   Function _unloadDLL


_loadDLL is a sample function that shows how to unload the LZNV SDK DLL


/// \brief      LZNV_Encode_File performs a straight forward file compression without the need of any prior buffer manipulation.

/// \note       The function will perform internal buffering. If you want to perform your own buffering, please use LZNV_Encode_Buffer.

/// \param[in]  _encoding_method            One of the methods _LZNV_ULTRAFAST_COMPRESSION to _LZNV_BETTER_COMPRESSION or _LZNV_HUFFMAN_COMPRESSION to _LZNV_RLE64_COMPRESSION.

/// \param[in]  _memory_level            The working size of the LZ algorithm. _LZNV_BUFFER_SIZE_256KB_INDX to _LZNV_BUFFER_SIZE_16MB_INDX.

/// \param[in]  _wchr_filename_to_compress            Input file path to compress. Unicode WCHAR.

/// \param[in]  _wchr_output_filename            Output file path to compress. Unicode WCHAR.

/// \return     returns NO_ERROR (0) in case of no errors or one of the error codes defined in LZNV_Defines.h header file

///             possible values:

///             - _LZNV_ERROR_INVALID_COMPRESSION_METHOD      

///             - _LZNV_ERROR_INVALID_BUFFER_SIZE            

///             - _LZNV_ERROR_EXPORTED_MAIN_FUNC_NOT_FOUND    

///             - _LZNV_ERROR_INVALID_PROCESS_SIZE            

///              


int32_t _unLoadDLL()

{

    if (LZNV_DLL_handle != NULL)

    {

        FreeLibrary(LZNV_DLL_handle);

    }


    return 0;

}