1
/**************************************************************************
3
* Copyright 2011 Advanced Micro Devices, Inc.
6
* Permission is hereby granted, free of charge, to any person obtaining a
7
* copy of this software and associated documentation files (the
8
* "Software"), to deal in the Software without restriction, including
9
* without limitation the rights to use, copy, modify, merge, publish,
10
* distribute, sub license, and/or sell copies of the Software, and to
11
* permit persons to whom the Software is furnished to do so, subject to
12
* the following conditions:
14
* The above copyright notice and this permission notice (including the
15
* next paragraph) shall be included in all copies or substantial portions
18
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
19
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
20
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
21
* IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR
22
* ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
23
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
24
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
26
**************************************************************************/
31
#include "winsys/radeon_winsys.h"
32
#include "vl/vl_video_buffer.h"
34
#include "ac_uvd_dec.h"
36
/* driver dependent callback */
37
typedef struct pb_buffer *(*ruvd_set_dtb)(struct ruvd_msg *msg, struct vl_video_buffer *vb);
39
/* create an UVD decode */
40
struct pipe_video_codec *si_common_uvd_create_decoder(struct pipe_context *context,
41
const struct pipe_video_codec *templat,
42
ruvd_set_dtb set_dtb);
44
/* fill decoding target field from the luma and chroma surfaces */
45
void si_uvd_set_dt_surfaces(struct ruvd_msg *msg, struct radeon_surf *luma,
46
struct radeon_surf *chroma, enum ruvd_surface_type type);