va.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef _VLC_VA_H
00025 #define _VLC_VA_H 1
00026
00027 typedef struct vlc_va_t vlc_va_t;
00028 struct vlc_va_t {
00029 char *description;
00030
00031 int (*setup)(vlc_va_t *, void **hw, vlc_fourcc_t *output,
00032 int width, int height);
00033 int (*get)(vlc_va_t *, AVFrame *frame);
00034 void (*release)(vlc_va_t *, AVFrame *frame);
00035 int (*extract)(vlc_va_t *, picture_t *dst, AVFrame *src);
00036 void (*close)(vlc_va_t *);
00037 };
00038
00039 static inline int vlc_va_Setup(vlc_va_t *va, void **hw, vlc_fourcc_t *output,
00040 int width, int height)
00041 {
00042 return va->setup(va, hw, output, width, height);
00043 }
00044 static inline int vlc_va_Get(vlc_va_t *va, AVFrame *frame)
00045 {
00046 return va->get(va, frame);
00047 }
00048 static inline void vlc_va_Release(vlc_va_t *va, AVFrame *frame)
00049 {
00050 va->release(va, frame);
00051 }
00052 static inline int vlc_va_Extract(vlc_va_t *va, picture_t *dst, AVFrame *src)
00053 {
00054 return va->extract(va, dst, src);
00055 }
00056 static inline void vlc_va_Delete(vlc_va_t *va)
00057 {
00058 va->close(va);
00059 }
00060
00061 vlc_va_t *vlc_va_NewVaapi(int codec_id);
00062 vlc_va_t *vlc_va_NewDxva2(vlc_object_t *log, int codec_id);
00063
00064 #endif
00065