diff options
author | Christian König <[email protected]> | 2012-01-04 14:46:33 +0100 |
---|---|---|
committer | Christian König <[email protected]> | 2012-01-15 12:40:44 +0100 |
commit | 8ea416f35de0c664ef47b71841756758f22d7faa (patch) | |
tree | 7245da0914e37a7d73fce094f068f9eff793c8bd /src/gallium/include | |
parent | 9af70c90dba9ed9902778883b675062fa0168b48 (diff) |
vl: move away from state like parameters
Again based on Maartens work, but keep begin_frame
and end_frame functions for now.
Signed-off-by: Christian König <[email protected]>
Diffstat (limited to 'src/gallium/include')
-rw-r--r-- | src/gallium/include/pipe/p_video_decoder.h | 38 | ||||
-rw-r--r-- | src/gallium/include/pipe/p_video_state.h | 18 |
2 files changed, 18 insertions, 38 deletions
diff --git a/src/gallium/include/pipe/p_video_decoder.h b/src/gallium/include/pipe/p_video_decoder.h index 62169ffc567..5499ffa86cb 100644 --- a/src/gallium/include/pipe/p_video_decoder.h +++ b/src/gallium/include/pipe/p_video_decoder.h @@ -60,40 +60,18 @@ struct pipe_video_decoder void (*destroy)(struct pipe_video_decoder *decoder); /** - * set the picture parameters for the next frame - * only used for bitstream decoding - */ - void (*set_picture_parameters)(struct pipe_video_decoder *decoder, - struct pipe_picture_desc *picture); - - /** - * set the quantification matrixes - */ - void (*set_quant_matrix)(struct pipe_video_decoder *decoder, - const struct pipe_quant_matrix *matrix); - - /** - * set target where video data is decoded to - */ - void (*set_decode_target)(struct pipe_video_decoder *decoder, - struct pipe_video_buffer *target); - - /** - * set reference frames for motion compensation - */ - void (*set_reference_frames)(struct pipe_video_decoder *decoder, - struct pipe_video_buffer **ref_frames, - unsigned num_ref_frames); - - /** * start decoding of a new frame */ - void (*begin_frame)(struct pipe_video_decoder *decoder); + void (*begin_frame)(struct pipe_video_decoder *decoder, + struct pipe_video_buffer *target, + struct pipe_picture_desc *picture); /** * decode a macroblock */ void (*decode_macroblock)(struct pipe_video_decoder *decoder, + struct pipe_video_buffer *target, + struct pipe_picture_desc *picture, const struct pipe_macroblock *macroblocks, unsigned num_macroblocks); @@ -101,6 +79,8 @@ struct pipe_video_decoder * decode a bitstream */ void (*decode_bitstream)(struct pipe_video_decoder *decoder, + struct pipe_video_buffer *target, + struct pipe_picture_desc *picture, unsigned num_buffers, const void * const *buffers, const unsigned *sizes); @@ -108,7 +88,9 @@ struct pipe_video_decoder /** * end decoding of the current frame */ - void (*end_frame)(struct pipe_video_decoder *decoder); + void (*end_frame)(struct pipe_video_decoder *decoder, + struct pipe_video_buffer *target, + struct pipe_picture_desc *picture); /** * flush any outstanding command buffers to the hardware diff --git a/src/gallium/include/pipe/p_video_state.h b/src/gallium/include/pipe/p_video_state.h index 9a70eb7c468..ad726d8cdfa 100644 --- a/src/gallium/include/pipe/p_video_state.h +++ b/src/gallium/include/pipe/p_video_state.h @@ -138,14 +138,11 @@ struct pipe_mpeg12_picture_desc unsigned full_pel_forward_vector; unsigned full_pel_backward_vector; unsigned num_slices; -}; - -struct pipe_mpeg12_quant_matrix -{ - struct pipe_quant_matrix base; const uint8_t *intra_matrix; const uint8_t *non_intra_matrix; + + struct pipe_video_buffer *ref[2]; }; struct pipe_mpeg12_macroblock @@ -191,6 +188,7 @@ struct pipe_mpeg12_macroblock struct pipe_mpeg4_picture_desc { struct pipe_picture_desc base; + int32_t trd[2]; int32_t trb[2]; uint16_t vop_time_increment_resolution; @@ -205,19 +203,17 @@ struct pipe_mpeg4_picture_desc uint8_t rounding_control; uint8_t alternate_vertical_scan_flag; uint8_t top_field_first; -}; - -struct pipe_mpeg4_quant_matrix -{ - struct pipe_quant_matrix base; const uint8_t *intra_matrix; const uint8_t *non_intra_matrix; + + struct pipe_video_buffer *ref[2]; }; struct pipe_vc1_picture_desc { struct pipe_picture_desc base; + uint32_t slice_count; uint8_t picture_type; uint8_t frame_coding_mode; @@ -247,6 +243,8 @@ struct pipe_vc1_picture_desc uint8_t maxbframes; uint8_t deblockEnable; uint8_t pquant; + + struct pipe_video_buffer *ref[2]; }; #ifdef __cplusplus |