FreeRDP
include/freerdp/codec/progressive.h
1 
20 #ifndef FREERDP_CODEC_PROGRESSIVE_H
21 #define FREERDP_CODEC_PROGRESSIVE_H
22 
23 #include <freerdp/api.h>
24 #include <freerdp/types.h>
25 
26 #include <winpr/wlog.h>
27 #include <winpr/collections.h>
28 
29 #include <freerdp/codec/rfx.h>
30 #include <freerdp/codec/color.h>
31 #include <freerdp/codec/region.h>
32 
33 #ifdef __cplusplus
34 extern "C"
35 {
36 #endif
37 
38  typedef struct S_PROGRESSIVE_CONTEXT PROGRESSIVE_CONTEXT;
39 
40  FREERDP_API int progressive_compress(PROGRESSIVE_CONTEXT* WINPR_RESTRICT progressive,
41  const BYTE* WINPR_RESTRICT pSrcData, UINT32 SrcSize,
42  UINT32 SrcFormat, UINT32 Width, UINT32 Height,
43  UINT32 ScanLine,
44  const REGION16* WINPR_RESTRICT invalidRegion,
45  BYTE** WINPR_RESTRICT ppDstData,
46  UINT32* WINPR_RESTRICT pDstSize);
47 
48  FREERDP_API INT32 progressive_decompress(PROGRESSIVE_CONTEXT* WINPR_RESTRICT progressive,
49  const BYTE* WINPR_RESTRICT pSrcData, UINT32 SrcSize,
50  BYTE* WINPR_RESTRICT pDstData, UINT32 DstFormat,
51  UINT32 nDstStep, UINT32 nXDst, UINT32 nYDst,
52  REGION16* WINPR_RESTRICT invalidRegion,
53  UINT16 surfaceId, UINT32 frameId);
54 
55  FREERDP_API INT32
56  progressive_create_surface_context(PROGRESSIVE_CONTEXT* WINPR_RESTRICT progressive,
57  UINT16 surfaceId, UINT32 width, UINT32 height);
58  FREERDP_API int
59  progressive_delete_surface_context(PROGRESSIVE_CONTEXT* WINPR_RESTRICT progressive,
60  UINT16 surfaceId);
61 
62  FREERDP_API BOOL progressive_context_reset(PROGRESSIVE_CONTEXT* WINPR_RESTRICT progressive);
63 
64  FREERDP_API void progressive_context_free(PROGRESSIVE_CONTEXT* progressive);
65 
66  WINPR_ATTR_MALLOC(progressive_context_free, 1)
67  FREERDP_API PROGRESSIVE_CONTEXT* progressive_context_new(BOOL Compressor);
68 
69  WINPR_ATTR_MALLOC(progressive_context_free, 1)
70  FREERDP_API PROGRESSIVE_CONTEXT* progressive_context_new_ex(BOOL Compressor,
71  UINT32 ThreadingFlags);
72 
82  FREERDP_API BOOL progressive_rfx_write_message_progressive_simple(
83  PROGRESSIVE_CONTEXT* progressive, wStream* s, const RFX_MESSAGE* msg);
84 
85 #ifdef __cplusplus
86 }
87 #endif
88 
89 #endif /* FREERDP_CODEC_PROGRESSIVE_H */