Add vaPutSurfaceBuf for Android
[profile/ivi/libva.git] / va / va_android.h
1 #ifndef _VA_ANDROID_H_
2 #define _VA_ANDROID_H_
3
4 #include <va/va.h>
5 #include <ui/Surface.h>
6 class Surface;
7
8 #ifdef __cplusplus
9 extern "C" {
10 #endif
11
12 /*
13  * Returns a suitable VADisplay for VA API
14  */
15 VADisplay vaGetDisplay (
16     void *dpy
17 );
18
19 /*
20  * Output rendering
21  * Following is the rendering interface for X windows, 
22  * to get the decode output surface to a X drawable
23  * It basically performs a de-interlacing (if needed), 
24  * color space conversion and scaling to the destination
25  * rectangle
26  */
27 VAStatus vaPutSurface (
28     VADisplay dpy,
29     VASurfaceID surface,        
30     Surface *draw, /* Android Window/Surface */
31     short srcx,
32     short srcy,
33     unsigned short srcw,
34     unsigned short srch,
35     short destx,
36     short desty,
37     unsigned short destw,
38     unsigned short desth,
39     VARectangle *cliprects, /* client supplied destination clip list */
40     unsigned int number_cliprects, /* number of clip rects in the clip list */
41     unsigned int flags /* PutSurface flags */
42 );
43
44 VAStatus vaPutSurfaceBuf (
45         VADriverContextP ctx,
46                VASurfaceID surface,
47                Drawable draw, /* X Drawable */
48                unsigned char* data,
49                 int* data_len,
50                 short srcx,
51                 short srcy,
52                 unsigned short srcw,
53                 unsigned short srch,
54                 short destx,
55                 short desty,
56                 unsigned short destw,
57                 unsigned short desth,
58                 VARectangle *cliprects, /* client supplied clip list */
59                 unsigned int number_cliprects, /* number of clip rects in the clip list */
60                 unsigned int flags /* de-interlacing flags */
61         );
62 #ifdef __cplusplus
63 }
64 #endif
65
66 #endif /* _VA_ANDROID_H_ */