From c888fe027c338f337123de4da2de1ac73b0f7587 Mon Sep 17 00:00:00 2001 From: Christian König Date: Wed, 4 May 2011 18:56:32 +0200 Subject: [g3dvl] Implement MPEG2 VLD Based uppon xine's slice_xvmc.c. This gets VDPAU up and running. --- src/gallium/include/pipe/p_video_context.h | 7 +++---- src/gallium/include/pipe/p_video_state.h | 32 ++++++++++++++++++------------ 2 files changed, 22 insertions(+), 17 deletions(-) (limited to 'src/gallium/include/pipe') diff --git a/src/gallium/include/pipe/p_video_context.h b/src/gallium/include/pipe/p_video_context.h index 80bbb6e1376..512b5b22d77 100644 --- a/src/gallium/include/pipe/p_video_context.h +++ b/src/gallium/include/pipe/p_video_context.h @@ -199,14 +199,13 @@ struct pipe_video_decode_buffer */ struct pipe_motionvector *(*get_mv_stream)(struct pipe_video_decode_buffer *decbuf, int ref_frame); -#if 0 /** * decode a bitstream */ void (*decode_bitstream)(struct pipe_video_decode_buffer *decbuf, - unsigned num_bufs, - struct pipe_buffer **bitstream_buf); -#endif + unsigned num_bytes, const void *data, + struct pipe_mpeg12_picture_desc *picture, + unsigned num_ycbcr_blocks[3]); /** * unmap decoder buffer before flushing diff --git a/src/gallium/include/pipe/p_video_state.h b/src/gallium/include/pipe/p_video_state.h index 8bd84c2846a..54fb1b7a595 100644 --- a/src/gallium/include/pipe/p_video_state.h +++ b/src/gallium/include/pipe/p_video_state.h @@ -99,37 +99,43 @@ struct pipe_ycbcr_block enum pipe_mpeg12_dct_type coding:8; }; -#if 0 struct pipe_picture_desc { - enum pipe_video_format format; + enum pipe_video_profile profile; }; struct pipe_mpeg12_picture_desc { struct pipe_picture_desc base; - /* TODO: Use bitfields where possible? */ - struct pipe_surface *forward_reference; - struct pipe_surface *backward_reference; unsigned picture_coding_type; - unsigned fcode; - unsigned intra_dc_precision; unsigned picture_structure; - unsigned top_field_first; unsigned frame_pred_frame_dct; - unsigned concealment_motion_vectors; unsigned q_scale_type; - unsigned intra_vlc_format; unsigned alternate_scan; + unsigned intra_dc_precision; + unsigned intra_vlc_format; + unsigned concealment_motion_vectors; + unsigned f_code[2][2]; + + bool mpeg1; + uint8_t *intra_quantizer_matrix; + uint8_t *non_intra_quantizer_matrix; + + /* predictor for DC coefficients in intra blocks */ + int16_t dc_dct_pred[3]; + + int quantizer_scale; + +#if 0 + /* TODO: Use bitfields where possible? */ + unsigned top_field_first; unsigned full_pel_forward_vector; unsigned full_pel_backward_vector; - struct pipe_buffer *intra_quantizer_matrix; - struct pipe_buffer *non_intra_quantizer_matrix; struct pipe_buffer *chroma_intra_quantizer_matrix; struct pipe_buffer *chroma_non_intra_quantizer_matrix; -}; #endif +}; #ifdef __cplusplus } -- cgit v1.2.3