Lines Matching refs:prefs

208     LZ4F_preferences_t prefs;  member
337 LZ4F_preferences_t prefs; in LZ4F_compressFrameBound() local
340 if (preferencesPtr!=NULL) prefs = *preferencesPtr; in LZ4F_compressFrameBound()
341 else MEM_INIT(&prefs, 0, sizeof(prefs)); in LZ4F_compressFrameBound()
342 prefs.autoFlush = 1; in LZ4F_compressFrameBound()
344 return headerSize + LZ4F_compressBound_internal(srcSize, &prefs, 0);; in LZ4F_compressFrameBound()
363 LZ4F_preferences_t prefs; in LZ4F_compressFrame_usingCDict() local
370 prefs = *preferencesPtr; in LZ4F_compressFrame_usingCDict()
372 MEM_INIT(&prefs, 0, sizeof(prefs)); in LZ4F_compressFrame_usingCDict()
373 if (prefs.frameInfo.contentSize != 0) in LZ4F_compressFrame_usingCDict()
374prefs.frameInfo.contentSize = (U64)srcSize; /* auto-correct content size if selected (!=0) */ in LZ4F_compressFrame_usingCDict()
376 prefs.frameInfo.blockSizeID = LZ4F_optimalBSID(prefs.frameInfo.blockSizeID, srcSize); in LZ4F_compressFrame_usingCDict()
377 prefs.autoFlush = 1; in LZ4F_compressFrame_usingCDict()
378 if (srcSize <= LZ4F_getBlockSize(prefs.frameInfo.blockSizeID)) in LZ4F_compressFrame_usingCDict()
379prefs.frameInfo.blockMode = LZ4F_blockIndependent; /* only one block => no need for inter-block … in LZ4F_compressFrame_usingCDict()
384 … if (dstCapacity < LZ4F_compressFrameBound(srcSize, &prefs)) /* condition to guarantee success */ in LZ4F_compressFrame_usingCDict()
387 …ize = LZ4F_compressBegin_usingCDict(cctx, dstBuffer, dstCapacity, cdict, &prefs); /* write header… in LZ4F_compressFrame_usingCDict()
594 cctxPtr->prefs = *preferencesPtr; in LZ4F_compressBegin_usingCDict()
597 { U16 const ctxTypeID = (cctxPtr->prefs.compressionLevel < LZ4HC_CLEVEL_MIN) ? 1 : 2; in LZ4F_compressBegin_usingCDict()
600 if (cctxPtr->prefs.compressionLevel < LZ4HC_CLEVEL_MIN) { in LZ4F_compressBegin_usingCDict()
611 if (cctxPtr->prefs.compressionLevel < LZ4HC_CLEVEL_MIN) { in LZ4F_compressBegin_usingCDict()
614 … LZ4_resetStreamHC((LZ4_streamHC_t *) cctxPtr->lz4CtxPtr, cctxPtr->prefs.compressionLevel); in LZ4F_compressBegin_usingCDict()
621 if (cctxPtr->prefs.frameInfo.blockSizeID == 0) in LZ4F_compressBegin_usingCDict()
622 cctxPtr->prefs.frameInfo.blockSizeID = LZ4F_BLOCKSIZEID_DEFAULT; in LZ4F_compressBegin_usingCDict()
623 cctxPtr->maxBlockSize = LZ4F_getBlockSize(cctxPtr->prefs.frameInfo.blockSizeID); in LZ4F_compressBegin_usingCDict()
626 … (cctxPtr->prefs.frameInfo.blockMode == LZ4F_blockLinked) * 64 KB : /* only needs windows size */ in LZ4F_compressBegin_usingCDict()
627 … cctxPtr->maxBlockSize + ((cctxPtr->prefs.frameInfo.blockMode == LZ4F_blockLinked) * 128 KB); in LZ4F_compressBegin_usingCDict()
642 if (cctxPtr->prefs.frameInfo.blockMode == LZ4F_blockLinked) { in LZ4F_compressBegin_usingCDict()
644 … LZ4F_initStream(cctxPtr->lz4CtxPtr, cdict, cctxPtr->prefs.compressionLevel, LZ4F_blockLinked); in LZ4F_compressBegin_usingCDict()
657 + ((cctxPtr->prefs.frameInfo.blockMode & _1BIT ) << 5) in LZ4F_compressBegin_usingCDict()
658 + ((cctxPtr->prefs.frameInfo.blockChecksumFlag & _1BIT ) << 4) in LZ4F_compressBegin_usingCDict()
659 + ((cctxPtr->prefs.frameInfo.contentSize > 0) << 3) in LZ4F_compressBegin_usingCDict()
660 + ((cctxPtr->prefs.frameInfo.contentChecksumFlag & _1BIT ) << 2) in LZ4F_compressBegin_usingCDict()
661 + (cctxPtr->prefs.frameInfo.dictID > 0) ); in LZ4F_compressBegin_usingCDict()
663 *dstPtr++ = (BYTE)((cctxPtr->prefs.frameInfo.blockSizeID & _3BITS) << 4); in LZ4F_compressBegin_usingCDict()
665 if (cctxPtr->prefs.frameInfo.contentSize) { in LZ4F_compressBegin_usingCDict()
666 LZ4F_writeLE64(dstPtr, cctxPtr->prefs.frameInfo.contentSize); in LZ4F_compressBegin_usingCDict()
671 if (cctxPtr->prefs.frameInfo.dictID) { in LZ4F_compressBegin_usingCDict()
672 LZ4F_writeLE32(dstPtr, cctxPtr->prefs.frameInfo.dictID); in LZ4F_compressBegin_usingCDict()
784 if (cctxPtr->prefs.compressionLevel < LZ4HC_CLEVEL_MIN) in LZ4F_localSaveDict()
810 …Func_t const compress = LZ4F_selectCompression(cctxPtr->prefs.frameInfo.blockMode, cctxPtr->prefs.… in LZ4F_compressUpdate()
815 if (dstCapacity < LZ4F_compressBound_internal(srcSize, &(cctxPtr->prefs), cctxPtr->tmpInSize)) in LZ4F_compressUpdate()
836 compress, cctxPtr->lz4CtxPtr, cctxPtr->prefs.compressionLevel, in LZ4F_compressUpdate()
837 cctxPtr->cdict, cctxPtr->prefs.frameInfo.blockChecksumFlag); in LZ4F_compressUpdate()
839 if (cctxPtr->prefs.frameInfo.blockMode==LZ4F_blockLinked) cctxPtr->tmpIn += blockSize; in LZ4F_compressUpdate()
848 compress, cctxPtr->lz4CtxPtr, cctxPtr->prefs.compressionLevel, in LZ4F_compressUpdate()
849 cctxPtr->cdict, cctxPtr->prefs.frameInfo.blockChecksumFlag); in LZ4F_compressUpdate()
853 if ((cctxPtr->prefs.autoFlush) && (srcPtr < srcEnd)) { in LZ4F_compressUpdate()
857 compress, cctxPtr->lz4CtxPtr, cctxPtr->prefs.compressionLevel, in LZ4F_compressUpdate()
858 cctxPtr->cdict, cctxPtr->prefs.frameInfo.blockChecksumFlag); in LZ4F_compressUpdate()
863 …if ((cctxPtr->prefs.frameInfo.blockMode==LZ4F_blockLinked) && (lastBlockCompressed==fromSrcBuffer)… in LZ4F_compressUpdate()
875 && !(cctxPtr->prefs.autoFlush)) in LZ4F_compressUpdate()
889 if (cctxPtr->prefs.frameInfo.contentChecksumFlag == LZ4F_contentChecksumEnabled) in LZ4F_compressUpdate()
917 …compress = LZ4F_selectCompression(cctxPtr->prefs.frameInfo.blockMode, cctxPtr->prefs.compressionLe… in LZ4F_flush()
921 compress, cctxPtr->lz4CtxPtr, cctxPtr->prefs.compressionLevel, in LZ4F_flush()
922 cctxPtr->cdict, cctxPtr->prefs.frameInfo.blockChecksumFlag); in LZ4F_flush()
923 if (cctxPtr->prefs.frameInfo.blockMode==LZ4F_blockLinked) cctxPtr->tmpIn += cctxPtr->tmpInSize; in LZ4F_flush()
957 if (cctxPtr->prefs.frameInfo.contentChecksumFlag == LZ4F_contentChecksumEnabled) { in LZ4F_compressEnd()
966 if (cctxPtr->prefs.frameInfo.contentSize) { in LZ4F_compressEnd()
967 if (cctxPtr->prefs.frameInfo.contentSize != cctxPtr->totalInSize) in LZ4F_compressEnd()