Another huge refactor and lots of big fixes! Time mapping now works... mostly. The jumpy / glitchy images have been solved by copying the AVFrame into an AVPicture, which does not get clobbered on the next decode.

Also, added a new frame number overaly (in the top, left part of the image), and a new AddColor() method, to change the size and color of the frame's image...

Padded the end of the FFmpegWriter / WriteTrailer() method, to avoid having a codec ignore the last many frames.
This commit is contained in:
Jonathan Thomas
2012-10-12 00:54:53 -05:00
parent 217c54a5ae
commit a601bcef2d
12 changed files with 109 additions and 82 deletions

View File

@@ -169,27 +169,6 @@ void Cache::Display()
}
}
// Display the list of cache and clear the cache (mainly for debugging reasons)
void Cache::DisplayAndClear()
{
cout << "----- Cache List (" << frames.size() << ") ------" << endl;
int i = 1;
while(!frame_numbers.empty())
{
// Print the frame number
int frame_number = frame_numbers.back();
cout << " " << i << ") --- Frame " << frame_number << endl;
// Remove this frame
Remove(frame_number);
// increment counter
i++;
}
// Reset total bytes
total_bytes = 0;
}