]> git.pld-linux.org Git - packages/xine-lib.git/blob - xine-lib-missing.patch
- release 12 (by relup.sh)
[packages/xine-lib.git] / xine-lib-missing.patch
1 --- xine-lib-1.2.3/src/xine-engine/accel_vaapi.h.orig   1970-01-01 01:00:00.000000000 +0100
2 +++ xine-lib-1.2.3/src/xine-engine/accel_vaapi.h        2013-07-20 18:26:54.064253047 +0200
3 @@ -0,0 +1,135 @@
4 +/*
5 + * Copyright (C) 2008 the xine project
6 + *
7 + * This file is part of xine, a free video player.
8 + *
9 + * xine is free software; you can redistribute it and/or modify
10 + * it under the terms of the GNU General Public License as published by
11 + * the Free Software Foundation; either version 2 of the License, or
12 + * (at your option) any later version.
13 + *
14 + * xine is distributed in the hope that it will be useful,
15 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17 + * GNU General Public License for more details.
18 + *
19 + * You should have received a copy of the GNU General Public License
20 + * along with this program; if not, write to the Free Software
21 + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
22 + *
23 + *
24 + * Common acceleration definitions for vaapi
25 + *
26 + *
27 + */
28 +
29 +#ifndef HAVE_XINE_ACCEL_VAAPI_H
30 +#define HAVE_XINE_ACCEL_VAAPI_H
31 +
32 +#ifdef __cplusplus
33 +extern "C" {
34 +#endif
35 +
36 +#ifdef HAVE_CONFIG_H
37 +#include "config.h"
38 +#endif
39 +
40 +#include <va/va_x11.h>
41 +#include <pthread.h>
42 +#ifdef HAVE_FFMPEG_AVUTIL_H
43 +#  include <avcodec.h>
44 +#else
45 +#  include <libavcodec/avcodec.h>
46 +#endif
47 +
48 +#if LIBAVCODEC_VERSION_MAJOR >= 53 || (LIBAVCODEC_VERSION_MAJOR == 52 && LIBAVCODEC_VERSION_MINOR >= 32)
49 +#  define AVVIDEO 2
50 +#else
51 +#  define AVVIDEO 1
52 +#  define pp_context   pp_context_t
53 +#  define pp_mode      pp_mode_t
54 +#endif
55 +
56 +#define NUM_OUTPUT_SURFACES 22
57 +
58 +#define SURFACE_FREE            0
59 +#define SURFACE_ALOC            1
60 +#define SURFACE_RELEASE         2
61 +#define SURFACE_RENDER          3
62 +#define SURFACE_RENDER_RELEASE  5
63 +
64 +struct vaapi_equalizer {
65 +  VADisplayAttribute brightness;
66 +  VADisplayAttribute contrast;
67 +  VADisplayAttribute hue;
68 +  VADisplayAttribute saturation;
69 +};
70 +
71 +typedef struct ff_vaapi_context_s ff_vaapi_context_t;
72 +
73 +struct ff_vaapi_context_s {
74 +  VADisplay         va_display;
75 +  VAContextID       va_context_id;
76 +  VAConfigID        va_config_id;
77 +  int               width;
78 +  int               height;
79 +  int               sw_width;
80 +  int               sw_height;
81 +  int               va_profile;
82 +  unsigned int      va_colorspace;
83 +  VAImage           va_subpic_image;
84 +  VASubpictureID    va_subpic_id;
85 +  int               va_subpic_width;
86 +  int               va_subpic_height;
87 +  int               is_bound;
88 +  void              *gl_surface;
89 +  unsigned int      soft_head;
90 +  unsigned int      valid_context;
91 +  unsigned int      va_head;
92 +  unsigned int      va_soft_head;
93 +  vo_driver_t       *driver;
94 +  unsigned int      last_sub_image_fmt;
95 +  VASurfaceID       last_sub_surface_id;
96 +  struct vaapi_equalizer va_equalizer;
97 +  VAImageFormat     *va_image_formats;
98 +  int               va_num_image_formats;
99 +  VAImageFormat     *va_subpic_formats;
100 +  int               va_num_subpic_formats;
101 +};
102 +
103 +typedef struct ff_vaapi_surface_s ff_vaapi_surface_t;
104 +typedef struct vaapi_accel_s vaapi_accel_t;
105 +
106 +struct ff_vaapi_surface_s {
107 +  unsigned int        index;
108 +  vaapi_accel_t       *accel;
109 +  VASurfaceID         va_surface_id;
110 +  unsigned int        status;
111 +};
112 +
113 +struct vaapi_accel_s {
114 +  unsigned int        index;
115 +  vo_frame_t          *vo_frame;
116 +
117 +#if AVVIDEO > 1
118 +  int (*avcodec_decode_video2)(vo_frame_t *frame_gen, AVCodecContext *avctx, AVFrame *picture,
119 +                               int *got_picture_ptr, AVPacket *avpkt);
120 +#else
121 +  int (*avcodec_decode_video)(vo_frame_t *frame_gen, AVCodecContext *avctx, AVFrame *picture,
122 +                              int *got_picture_ptr, uint8_t *buf, int buf_size);
123 +#endif
124 +  VAStatus (*vaapi_init)(vo_frame_t *frame_gen, int va_profile, int width, int height, int softrender);
125 +  int (*profile_from_imgfmt)(vo_frame_t *frame_gen, enum PixelFormat pix_fmt, int codec_id, int vaapi_mpeg_sofdec);
126 +  ff_vaapi_context_t *(*get_context)(vo_frame_t *frame_gen);
127 +  int (*guarded_render)(vo_frame_t *frame_gen);
128 +  ff_vaapi_surface_t *(*get_vaapi_surface)(vo_frame_t *frame_gen);
129 +  void (*render_vaapi_surface)(vo_frame_t *frame_gen, ff_vaapi_surface_t *va_surface);
130 +  void (*release_vaapi_surface)(vo_frame_t *frame_gen, ff_vaapi_surface_t *va_surface);
131 +};
132 +
133 +#ifdef __cplusplus
134 +}
135 +#endif
136 +
137 +#endif
138 +
This page took 0.052215 seconds and 3 git commands to generate.