mirror of https://github.com/mpv-player/mpv
fourcc mapping fixed - 10l to someone
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@2682 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
a28c29e8f3
commit
d79da48df5
|
@ -37,7 +37,6 @@ static int add_to_fourcc(char *s, char *alias, unsigned int *fourcc,
|
|||
unsigned int *map)
|
||||
{
|
||||
int i, j, freeslots;
|
||||
char *aliasp;
|
||||
unsigned int tmp;
|
||||
|
||||
/* find first unused slot */
|
||||
|
@ -47,14 +46,13 @@ static int add_to_fourcc(char *s, char *alias, unsigned int *fourcc,
|
|||
if (!freeslots)
|
||||
goto err_out_too_many;
|
||||
|
||||
aliasp = (alias) ? alias : s;
|
||||
do {
|
||||
tmp = mmioFOURCC(s[0], s[1], s[2], s[3]);
|
||||
for (j = 0; j < i; j++)
|
||||
if (tmp == fourcc[j])
|
||||
goto err_out_duplicated;
|
||||
fourcc[i] = tmp;
|
||||
map[i] = mmioFOURCC(aliasp[0], aliasp[1], aliasp[2], aliasp[3]);
|
||||
map[i] = alias ? mmioFOURCC(alias[0], alias[1], alias[2], alias[3]) : tmp;
|
||||
s += 4;
|
||||
i++;
|
||||
} while ((*(s++) == ',') && --freeslots);
|
||||
|
|
Loading…
Reference in New Issue