Commit Graph

66 Commits

Author SHA1 Message Date
Jonathan Thomas
5b77abdf27 The timeline classes are finally working correctly, and have the following features:
1) Layers (unlimited # of layers)
2) IN, OUT, and Position (time)
3) X, Y offset
4) Alpha
5) Rotation
6) Transparency + compositing + overlays
2012-11-08 04:35:21 -06:00
Jonathan Thomas
6e9f2a6a9b Changed audio and video PTS to start at 0, and it fixed the final issues I have had with generating valid videos in multiple codecs. 2012-10-28 23:38:24 -05:00
Jonathan Thomas
7dd94a02e4 Added code to flush the encoders, and also write the final frame's audio samples 2012-10-28 03:35:50 -05:00
Jonathan Thomas
60ffebe1fe Replaced avcodec_encode_audio with avcodec_encode_audio2, and completely redid the way PTS values are calculated and set. Another nice improvement! 2012-10-27 21:36:08 -05:00
Jonathan Thomas
bf93f6941e Fixed some major issues with the FFmpegWriter, which was not setting the correct PTS values 2012-10-26 17:15:17 -05:00
Jonathan Thomas
5fcead37f2 Added frame counter to writer class, to help generate a valid PTS 2012-10-26 02:11:39 -05:00
Jonathan Thomas
a34902f0f5 Removed some unneeded code in the FFMpegWriter 2012-10-24 11:10:35 -05:00
Jonathan Thomas
617088cebf Yet another huge refactor, to use shared_ptr objects instead of actual pointers, due to the difficulties in managing the lifecycle of pointers between the timeline, clip, and readers. Seems to work great, and solves all sorts of bugs. =) 2012-10-14 03:43:52 -05:00
Jonathan Thomas
a601bcef2d 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.
2012-10-12 00:54:53 -05:00
Jonathan Thomas
a23e32874e Tweaked the number of FFmpeg threads, to optimize codec performance. 2012-08-31 15:19:17 -05:00
Jonathan Thomas
8831dd0c49 Enabled multi-threading decoding and encoding with libavcodec, setting the thread_count property. This make a huge improvement in CPU performance, for codecs that support this property. 2012-08-28 22:53:12 -05:00
Jonathan Thomas
0f3758bc29 Fixed a big regression where the "omp" tag was not correct. Also, restructured the encoder to be much faster, and changed "omp master" to "omp single". 2012-08-28 15:53:18 -05:00
Jonathan Thomas
ed697a9c15 Added pool of software image scalers to the FFmpegWriter / encoder, and removed OMP critical section. Also, refactored some audio and video codecs, and changed "resize" to "scale" for speed improvements. 2012-08-24 15:57:49 -05:00
Jonathan Thomas
1ec7128a09 Fixed a huge bug where the FFmpegWriter was not scaling colors to 8 bit, and that would crash on certain colors being used in an image. Also, added a new, experimental waveform visualization to the encoder. 2012-08-22 17:31:12 -05:00
Jonathan Thomas
2b5d317123 Fixed a multi-threaded encoding bug with audio-only files. 2012-08-20 22:23:31 -05:00
Jonathan Thomas
b98b8f8968 Fixed many bugs on the multi-threaded encoder, simplified the API, and removed some memory leaks. 2012-08-20 14:26:49 -05:00
Jonathan Thomas
97b2717744 Fixed many bugs on the multi-threaded FFmpegWriter. Added audio multi-threading, and it mostly works... with a few bugs remaining. 2012-08-20 02:59:35 -05:00
Jonathan Thomas
3f2855735e Added experimental multi-threaded features to the FFmpegWriter 2012-08-20 00:02:09 -05:00
Jonathan Thomas
d1af1b5fef Huge refactor, switched almost all methods to using pointers for Frames, and moved some key method calls outside the critical OMP sections. Also, refactored the sws scaler, to create a pool of 32 scalers, and give each thread it's own scaler. This refactor resulted in a 40%+ increase in speed on the FFmpegReader class.
I also added a cmake build flag for the google perftools library, to assist on profiling performance issues.
2012-08-15 17:27:14 -05:00
Jonathan Thomas
1bbfa060cf Fixed a huge regression with PTS, that caused all sorts of issues with encoded videos, especially webm. 2012-08-11 20:28:05 -05:00
Jonathan Thomas
7eeb8f7c80 Added a few new options 2012-08-11 03:39:00 -05:00
Jonathan Thomas
1b1b84dde8 Added 2 additional options for SetOption, and split the preparing of streams and the writing header into separate methods. 2012-08-11 03:19:52 -05:00
Jonathan Thomas
191d905299 Improved SetOption to recognize a few codecContext variables as well (such as g, qmin, and qmax) 2012-08-11 02:59:03 -05:00
Jonathan Thomas
d380292210 Removed unneeded rescaling, since the codec and stream always have the same frame rate 2012-08-06 20:13:01 -05:00
Jonathan Thomas
363cb8f257 Commented out unused error string, which breaks ffmpeg 53 2012-08-06 17:13:05 -05:00