support newer ffmpeg versions

Origin commit data
------------------
Branch: master
Commit: 752e1e4368
Author: martii <you@example.com>
Date: 2012-07-13 (Fri, 13 Jul 2012)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
martii
2012-07-13 16:22:19 +02:00
parent 1048c08e40
commit 122fd5afa9
3 changed files with 93 additions and 0 deletions

View File

@@ -24,6 +24,9 @@
#include <stdlib.h>
#include <string.h>
// >>> MARTII
#include <libavformat/avformat.h>
// <<< MARTII
#include "manager.h"
#include "common.h"
@@ -214,6 +217,17 @@ static int Command(void *_context, ManagerCmd_t command, void * argument) {
case MANAGER_SET: {
int id = *((int*)argument);
// >>> MARTII
// What's the argument supposed to be? apid or local index? --martii
if (id >= TrackCount) {
int apid = id;
for (id = 0; id < TrackCount; id++) {
if (((AVStream *) (Tracks[id].stream))->id == apid)
break;
}
}
// <<< MARTII
audio_mgr_printf(20, "%s::%s MANAGER_SET id=%d\n", FILENAME, __FUNCTION__, id);
if (id < TrackCount)