1 #ifndef _VIDEO_PACKETIZER_H_
2 #define _VIDEO_PACKETIZER_H_
4 #include <VP_Os/vp_os_types.h>
5 #include <VLIB/video_controller.h>
7 C_RESULT video_packetizer_init( video_controller_t* controller );
8 C_RESULT video_packetizer_close( video_controller_t* controller );
13 // Fills a stream with length bits from code
14 void video_write_data( video_stream_t* const stream, uint32_t code, int32_t length );
16 // Updates stream as its length attributes is a multiple of 8
17 // Updates is done by adding bits
18 C_RESULT video_stuff8( video_stream_t* const stream );
21 /// Read from a stream
23 // Takes length bit from stream and updates it
24 C_RESULT video_read_data( video_stream_t* const stream, uint32_t* code, int32_t length );
26 // Takes length bit from stream without updating it
27 C_RESULT video_peek_data( const video_stream_t* const stream, uint32_t* code, int32_t length );
29 // Updates stream as its length attributes is a multiple of 8
30 // Updates is done by skipping bits
31 C_RESULT video_align8( video_stream_t* const stream );
36 // Flush content of stream in into stream out
37 C_RESULT video_cache_stream( video_controller_t* controller, video_stream_t* in );
39 #endif // _VIDEO_PACKETIZER_H_