Skip to content
Extraits de code Groupes Projets
Valider e702d9ed rédigé par Karl Blomster's avatar Karl Blomster
Parcourir les fichiers

fixed the ffmpegsource indexing progress dialog to work with files larger than 4gb.

Originally committed to SVN as r2330.
parent ff6876b4
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -190,8 +190,9 @@ void FFmpegSourceVideoProvider::Close() { ...@@ -190,8 +190,9 @@ void FFmpegSourceVideoProvider::Close() {
if (VideoSource) if (VideoSource)
FFMS_DestroyVideoSource(VideoSource); FFMS_DestroyVideoSource(VideoSource);
VideoSource = NULL; VideoSource = NULL;
if (FrameAllocated) // this seems to cause a heap corruption in debug mode
avpicture_free(&FrameRGB); /* if (FrameAllocated)
avpicture_free(&FrameRGB); */
FrameAllocated = false; FrameAllocated = false;
if (BufferRGB) if (BufferRGB)
delete BufferRGB; delete BufferRGB;
...@@ -206,15 +207,15 @@ void FFmpegSourceVideoProvider::Close() { ...@@ -206,15 +207,15 @@ void FFmpegSourceVideoProvider::Close() {
// Update indexing progress // Update indexing progress
int __stdcall FFmpegSourceVideoProvider::UpdateIndexingProgress(int State, int64_t Current, int64_t Total, void *Private) { int __stdcall FFmpegSourceVideoProvider::UpdateIndexingProgress(int State, int64_t Current, int64_t Total, void *Private) {
IndexingProgressDialog *Progress = (IndexingProgressDialog *)Private; IndexingProgressDialog *Progress = (IndexingProgressDialog *)Private;
Progress->ProgressDialog->SetProgress(Current, Total);
if (Progress->IndexingCanceled) { if (Progress->IndexingCanceled)
// Close();
return 1; return 1;
} else {
// noone cares about a little bit of a rounding error here anyway
Progress->ProgressDialog->SetProgress((1000*Current)/Total, 1000);
return 0; return 0;
} }
}
/////////////// ///////////////
// Get frame // Get frame
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Veuillez vous inscrire ou vous pour commenter