1 /*
2 * Copyright Stefano Sabatini <stefasab gmail com>
3 * Copyright Anton Khirnov <anton khirnov net>
4 * Copyright Michael Niedermayer <michaelni gmx at>
5 *
6 * This file is part of FFmpeg.
7 *
8 * FFmpeg is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Lesser General Public
10 * License as published by the Free Software Foundation; either
11 * version 2.1 of the License, or (at your option) any later version.
12 *
13 * FFmpeg is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Lesser General Public License for more details.
17 *
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with FFmpeg; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21 */
22
28
33
35 {
40 }
41
43 *dst = *src;
48 }
49 }
50
52 {
54 if (!ret)
56 *ret = *ref;
57
60
66 }
74 }
76
80 nb_channels))) {
84 }
87 } else
89 }
92 return ret;
93 }
94
96 {
97 int i;
98
100
104 /* free buffer: picrefs stored in the pool are not
105 * supposed to contain a free callback */
109
115 }
116 }
118
122 }
123 }
124
126 {
127 int i;
129
132
135
146 }
147
152 break;
153 }
154 }
157 } else
159 }
160
162 {
163 if (!ref)
164 return;
169 return;
170 }
172 }
181 }
182
184 {
187 }
188
190 {
191 // copy common properties
194
200 break;
201 }
203 default: break;
204 }
205
208 }
209
212 {
214 int channels;
215
216 switch (outlink->
type) {
217
221 if(!buf)
226 break;
227
231 if(!buf)
236 channels,
238 break;
239
240 default:
242 }
244 return buf;
245 }