int (*get_param)(struct pipe_video_context *context, int param);
/**
- * Check if the given pipe_format is supported as a texture or
- * drawing surface.
+ * Check if the given pipe_format is supported as a video buffer
*/
boolean (*is_format_supported)(struct pipe_video_context *context,
enum pipe_format format,
- unsigned usage);
+ enum pipe_video_profile profile);
/**
* create a surface of a texture
*/
struct pipe_video_buffer *(*create_buffer)(struct pipe_video_context *context,
enum pipe_format buffer_format,
- const enum pipe_format resource_formats[3],
enum pipe_video_chroma_format chroma_format,
unsigned width, unsigned height);
void (*flush_buffer)(struct pipe_video_decode_buffer *decbuf,
unsigned num_ycbcr_blocks[3],
struct pipe_video_buffer *ref_frames[2],
- struct pipe_video_buffer *dst,
- struct pipe_fence_handle **fence);
+ struct pipe_video_buffer *dst);
};
/**
/**
* map the input buffer into memory before starting decoding
*/
- void (*map)(struct pipe_video_decode_buffer *decbuf);
+ void (*begin_frame)(struct pipe_video_decode_buffer *decbuf);
+
+ /**
+ * set the quantification matrixes
+ */
+ void (*set_quant_matrix)(struct pipe_video_decode_buffer *decbuf,
+ const uint8_t intra_matrix[64],
+ const uint8_t non_intra_matrix[64]);
/**
* get the pointer where to put the ycbcr blocks of a component
*/
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
*/
- void (*unmap)(struct pipe_video_decode_buffer *decbuf);
+ void (*end_frame)(struct pipe_video_decode_buffer *decbuf);
};
/**
/**
* get a individual sampler view for each plane
*/
- struct pipe_sampler_view **(*get_sampler_views)(struct pipe_video_buffer *buffer);
+ struct pipe_sampler_view **(*get_sampler_view_planes)(struct pipe_video_buffer *buffer);
+
+ /**
+ * get a individual sampler view for each component
+ */
+ struct pipe_sampler_view **(*get_sampler_view_components)(struct pipe_video_buffer *buffer);
/**
* get a individual surfaces for each plane
*/
void (*set_csc_matrix)(struct pipe_video_compositor *compositor, const float mat[16]);
+ /**
+ * reset dirty area, so it's cleared with the clear colour
+ */
+ void (*reset_dirty_area)(struct pipe_video_compositor *compositor);
+
+ /**
+ * set the clear color
+ */
+ void (*set_clear_color)(struct pipe_video_compositor *compositor, float color[4]);
+
/**
* set overlay samplers
*/