History

avfilter/af_pan: Do not use SWR_CH_MAX

Michael Niedermayer committed 12 years ago

Commit ce1bb4b1 parent ced765c1 file · +5 −5Browse files

Unified · Split

libavfilter/af_pan.c+5−5
@@ -50,7 +50,7 @@ typedef struct PanContext { · 49 unmodified lines
50 50
51 int pure_gains;51 int pure_gains;
52 /* channel mapping specific */52 /* channel mapping specific */
53 int channel_map[SWR_CH_MAX];53 int channel_map[MAX_CHANNELS];
54 struct SwrContext *swr;54 struct SwrContext *swr;
55} PanContext;55} PanContext;
56 56
@@ -271,11 +271,11 @@ static int config_props(AVFilterLink *link) · 214 unmodified lines
271 271
272 // sanity check; can't be done in query_formats since the inlink272 // sanity check; can't be done in query_formats since the inlink
273 // channel layout is unknown at that time273 // channel layout is unknown at that time
274 if (link->channels > SWR_CH_MAX ||274 if (link->channels > MAX_CHANNELS ||
275 pan->nb_output_channels > SWR_CH_MAX) {275 pan->nb_output_channels > MAX_CHANNELS) {
276 av_log(ctx, AV_LOG_ERROR,276 av_log(ctx, AV_LOG_ERROR,
277 "libswresample support a maximum of %d channels. "277 "af_pan support a maximum of %d channels. "
278 "Feel free to ask for a higher limit.\n", SWR_CH_MAX);278 "Feel free to ask for a higher limit.\n", MAX_CHANNELS);
279 return AVERROR_PATCHWELCOME;279 return AVERROR_PATCHWELCOME;
280 }280 }
281 281

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