20 #ifndef FREERDP_LIB_CORE_BULK_H
21 #define FREERDP_LIB_CORE_BULK_H
23 typedef struct rdp_bulk rdpBulk;
25 #include <freerdp/api.h>
26 #include <freerdp/freerdp.h>
28 #define BULK_COMPRESSION_FLAGS_MASK 0xE0
29 #define BULK_COMPRESSION_TYPE_MASK 0x0F
31 FREERDP_LOCAL UINT32 bulk_compression_max_size(rdpBulk* WINPR_RESTRICT bulk);
33 FREERDP_LOCAL
int bulk_decompress(rdpBulk* WINPR_RESTRICT bulk,
const BYTE* WINPR_RESTRICT pSrcData,
34 UINT32 SrcSize,
const BYTE** WINPR_RESTRICT ppDstData,
35 UINT32* WINPR_RESTRICT pDstSize, UINT32 flags);
36 FREERDP_LOCAL
int bulk_compress(rdpBulk* WINPR_RESTRICT bulk,
const BYTE* WINPR_RESTRICT pSrcData,
37 UINT32 SrcSize,
const BYTE** WINPR_RESTRICT ppDstData,
38 UINT32* WINPR_RESTRICT pDstSize, UINT32* WINPR_RESTRICT pFlags);
40 FREERDP_LOCAL
void bulk_reset(rdpBulk* WINPR_RESTRICT bulk);
42 FREERDP_LOCAL
void bulk_free(rdpBulk* bulk);
44 WINPR_ATTR_MALLOC(bulk_free, 1)
45 FREERDP_LOCAL rdpBulk* bulk_new(rdpContext* context);