History

vdpau: add a constructor for AVVDPAUContext.

We will likely want to add new fields to it in the future, so this is needed to avoid breaking ABI.

Anton Khirnov committed 13 years ago

Commit 728c4651 parent ca22d1d3 files · +18 −0Browse files

Unified · Split

3 files
  1. doc/APIchanges +2 −0
  2. libavcodec/vdpau.c +5 −0
  3. libavcodec/vdpau.h +11 −0
doc/APIchanges+2−0
@@ -15,6 +15,8 @@ API changes, most recent first: · 14 unmodified lines
15 15
162013-11-xx - xxxxxxx - lavc 55.26.0 - vdpau.h162013-11-xx - xxxxxxx - lavc 55.26.0 - vdpau.h
17 Add av_vdpau_get_profile().17 Add av_vdpau_get_profile().
18 Add av_vdpau_alloc_context(). This function must from now on be
19 used for allocating AVVDPAUContext.
18 20
192013-11-xx - xxxxxxx - lavc 55.25.0 - avcodec.h212013-11-xx - xxxxxxx - lavc 55.25.0 - avcodec.h
20 Add ITU-R BT.2020 and other not yet included values to color primaries,22 Add ITU-R BT.2020 and other not yet included values to color primaries,
libavcodec/vdpau.c+5−0
@@ -133,4 +133,9 @@ do { \ · 132 unmodified lines
133 return AVERROR(EINVAL);133 return AVERROR(EINVAL);
134}134}
135 135
136AVVDPAUContext *av_vdpau_alloc_context(void)
137{
138 return av_mallocz(sizeof(AVVDPAUContext));
139}
140
136/* @}*/141/* @}*/
libavcodec/vdpau.h+11−0
@@ -74,6 +74,10 @@ union AVVDPAUPictureInfo { · 73 unmodified lines
74 * during initialization or through each AVCodecContext.get_buffer()74 * during initialization or through each AVCodecContext.get_buffer()
75 * function call. In any case, they must be valid prior to calling75 * function call. In any case, they must be valid prior to calling
76 * decoding functions.76 * decoding functions.
77 *
78 * The size of this structure is not a part of the public ABI and must not
79 * be used outside of libavcodec. Use av_vdpau_alloc_context() to allocate an
80 * AVVDPAUContext.
77 */81 */
78typedef struct AVVDPAUContext {82typedef struct AVVDPAUContext {
79 /**83 /**
@@ -126,6 +130,13 @@ typedef struct AVVDPAUContext { · 46 unmodified lines
126#endif130#endif
127} AVVDPAUContext;131} AVVDPAUContext;
128 132
133/**
134 * Allocate an AVVDPAUContext.
135 *
136 * @return Newly-allocated AVVDPAUContext or NULL on failure.
137 */
138AVVDPAUContext *av_vdpau_alloc_context(void);
139
129/**140/**
130 * Get a decoder profile that should be used for initializing a VDPAU decoder.141 * Get a decoder profile that should be used for initializing a VDPAU decoder.
131 * Should be called from the AVCodecContext.get_format() callback.142 * Should be called from the AVCodecContext.get_format() callback.

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t