mirror of https://github.com/odrling/Aegisub
Update FFMS2 providers to account for FFMS2 API change in last commit.
Also update ffms2.lib to corresponding version. Originally committed to SVN as r2948.
This commit is contained in:
parent
cd8d965324
commit
5717f81ef2
Binary file not shown.
|
@ -95,7 +95,7 @@ void FFmpegSourceAudioProvider::LoadAudio(Aegisub::String filename) {
|
||||||
}
|
}
|
||||||
|
|
||||||
for (int i = 0; i < NumTracks; i++) {
|
for (int i = 0; i < NumTracks; i++) {
|
||||||
FFTrack *FrameData = FFMS_GetTITrackIndex(Index, i, FFMSErrMsg, MsgSize);
|
FFTrack *FrameData = FFMS_GetTrackFromIndex(Index, i, FFMSErrMsg, MsgSize);
|
||||||
if (FrameData == NULL) {
|
if (FrameData == NULL) {
|
||||||
FFMS_DestroyFFIndex(Index);
|
FFMS_DestroyFFIndex(Index);
|
||||||
Index = NULL;
|
Index = NULL;
|
||||||
|
@ -146,7 +146,7 @@ void FFmpegSourceAudioProvider::LoadAudio(Aegisub::String filename) {
|
||||||
throw MsgString;
|
throw MsgString;
|
||||||
}
|
}
|
||||||
|
|
||||||
const TAudioProperties AudioInfo = *FFMS_GetTAudioProperties(AudioSource);
|
const TAudioProperties AudioInfo = *FFMS_GetAudioProperties(AudioSource);
|
||||||
|
|
||||||
if (AudioInfo.Float)
|
if (AudioInfo.Float)
|
||||||
throw _T("FFmpegSource audio provider: I don't know what to do with floating point audio");
|
throw _T("FFmpegSource audio provider: I don't know what to do with floating point audio");
|
||||||
|
|
|
@ -56,7 +56,7 @@ wxMutex FFmpegSourceProvider::CleaningInProgress;
|
||||||
|
|
||||||
///////////////
|
///////////////
|
||||||
// Update indexing progress
|
// Update indexing progress
|
||||||
int FFMS_CC FFmpegSourceProvider::UpdateIndexingProgress(int State, int64_t Current, int64_t Total, void *Private) {
|
int FFMS_CC FFmpegSourceProvider::UpdateIndexingProgress(int64_t Current, int64_t Total, void *Private) {
|
||||||
IndexingProgressDialog *Progress = (IndexingProgressDialog *)Private;
|
IndexingProgressDialog *Progress = (IndexingProgressDialog *)Private;
|
||||||
|
|
||||||
if (Progress->IndexingCanceled)
|
if (Progress->IndexingCanceled)
|
||||||
|
|
|
@ -59,7 +59,7 @@ public:
|
||||||
static wxMutex CleaningInProgress;
|
static wxMutex CleaningInProgress;
|
||||||
bool CleanCache();
|
bool CleanCache();
|
||||||
|
|
||||||
static int FFMS_CC UpdateIndexingProgress(int State, int64_t Current, int64_t Total, void *Private);
|
static int FFMS_CC UpdateIndexingProgress(int64_t Current, int64_t Total, void *Private);
|
||||||
FFIndex *DoIndexing(FFIndex *Index, wxString Filename, wxString Cachename, int Trackmask, bool IgnoreDecodeErrors);
|
FFIndex *DoIndexing(FFIndex *Index, wxString Filename, wxString Cachename, int Trackmask, bool IgnoreDecodeErrors);
|
||||||
wxString GetCacheFilename(const wxString& filename);
|
wxString GetCacheFilename(const wxString& filename);
|
||||||
|
|
||||||
|
|
|
@ -149,10 +149,10 @@ void FFmpegSourceVideoProvider::LoadVideo(Aegisub::String filename, double fps)
|
||||||
}
|
}
|
||||||
|
|
||||||
// load video properties
|
// load video properties
|
||||||
VideoInfo = FFMS_GetTVideoProperties(VideoSource);
|
VideoInfo = FFMS_GetVideoProperties(VideoSource);
|
||||||
|
|
||||||
// get frame info data
|
// get frame info data
|
||||||
FFTrack *FrameData = FFMS_GetVSTrackIndex(VideoSource);
|
FFTrack *FrameData = FFMS_GetTrackFromVideo(VideoSource);
|
||||||
if (FrameData == NULL)
|
if (FrameData == NULL)
|
||||||
throw _T("FFmpegSource video provider: failed to get frame data");
|
throw _T("FFmpegSource video provider: failed to get frame data");
|
||||||
const TTrackTimeBase *TimeBase = FFMS_GetTimeBase(FrameData);
|
const TTrackTimeBase *TimeBase = FFMS_GetTimeBase(FrameData);
|
||||||
|
@ -163,7 +163,7 @@ void FFmpegSourceVideoProvider::LoadVideo(Aegisub::String filename, double fps)
|
||||||
|
|
||||||
// build list of keyframes and timecodes
|
// build list of keyframes and timecodes
|
||||||
for (int CurFrameNum = 0; CurFrameNum < VideoInfo->NumFrames; CurFrameNum++) {
|
for (int CurFrameNum = 0; CurFrameNum < VideoInfo->NumFrames; CurFrameNum++) {
|
||||||
CurFrameData = FFMS_GetTFrameInfo(FrameData, CurFrameNum, FFMSErrorMessage, MessageSize);
|
CurFrameData = FFMS_GetFrameInfo(FrameData, CurFrameNum, FFMSErrorMessage, MessageSize);
|
||||||
if (CurFrameData == NULL) {
|
if (CurFrameData == NULL) {
|
||||||
wxString temp(FFMSErrorMessage, wxConvUTF8);
|
wxString temp(FFMSErrorMessage, wxConvUTF8);
|
||||||
ErrorMsg << _T("Couldn't get framedata for frame ") << CurFrameNum << _T(": ") << temp;
|
ErrorMsg << _T("Couldn't get framedata for frame ") << CurFrameNum << _T(": ") << temp;
|
||||||
|
|
Loading…
Reference in New Issue