Commit Graph

150 Commits

Author SHA1 Message Date
Michael Fabian 'Xaymar' Dirks 5ba4694890 strings: Add 'Manual' state and rename Rate Control Method to Mode 2019-07-22 00:57:34 +02:00
Michael Fabian 'Xaymar' Dirks e579b10dcd codecs/hevc: Fix issue with duplicated maps 2019-07-22 00:56:23 +02:00
Michael Fabian 'Xaymar' Dirks f530f9ee9f ui/debug_handler: Fix warnings about unused variables 2019-07-22 00:55:02 +02:00
Michael Fabian 'Xaymar' Dirks 8b429db62e ffmpeg/avframe-queue: Fix warning about 'unsigned/signed !=' 2019-07-22 00:55:01 +02:00
Michael Fabian 'Xaymar' Dirks 6851f2321a encoders/generic: Set the time base correctly
There is a small but important difference in the way OBS Studio and FFmpeg handle the FPS time base. This change fixes the problem and makes all encoders go back to sanity.
2019-07-22 00:55:01 +02:00
Michael Fabian 'Xaymar' Dirks 2472668f1d encoders/generic: Slight reformatting of the visible encoder name 2019-07-21 11:55:14 +02:00
Michael Fabian 'Xaymar' Dirks 6eadcfe821 ffmpeg/tools: Hide additional common capabilities
Shortens the visible encoder name by removing the "Requires Flush" and Threading clutter that no longer matters and is automatically handled.
2019-07-21 11:55:13 +02:00
Michael Fabian 'Xaymar' Dirks 7663a25bb3 encoders/generic: Hide encoders that don't have a UI handler
This prevents the uninformed from using an encoder that they really shouldn't be using, thus reducing the amount of issues that come from showing too many encoders.
2019-07-21 11:55:13 +02:00
Michael Fabian 'Xaymar' Dirks 38f154531c encoder: Deprecate encoders based on old implementation 2019-07-21 11:55:13 +02:00
Michael Fabian 'Xaymar' Dirks 666fe5fdfb plugin: Add function to check for UI handlers 2019-07-21 11:55:13 +02:00
Michael Fabian 'Xaymar' Dirks f744b1e9cb ffmpeg/avframe-queue: Set AVFrame buffer alignment to 32-byte
This is twice the required alignment for modern SSE, but it has a clear reason. On both Intel and AMD systems, a 32-byte alignment was ~15% faster than a 16-byte alignment when used with memcpy, which just so happens to be one of the main uses for these frames. Unless the encoder internally keeps its own queue of AVFrames and copies them itself, this will result in a massive speed up across all encoders.
2019-07-21 10:33:27 +02:00
Michael Fabian 'Xaymar' Dirks 9552d12ee8 codecs/hevc: Add shared codec data for HEVC 2019-07-21 02:42:52 +02:00
Michael Fabian 'Xaymar' Dirks f15769ddb7 ui/debug_handler: Don't leak the temporary AVCodecContext* 2019-07-21 02:41:45 +02:00
Michael Fabian 'Xaymar' Dirks 8b80dc57ad strings: Extra shared strings for states, ratecontrol and keyframes 2019-07-21 02:40:48 +02:00
Michael Fabian 'Xaymar' Dirks 83c9de95f9 encoders/generic: Fix key value separators and apply settings correctly 2019-07-20 23:38:45 +02:00
Michael Fabian 'Xaymar' Dirks 090dd9dbdc encoders/generic: Fix threading priority and thread count override 2019-07-13 00:16:42 +02:00
Michael Fabian 'Xaymar' Dirks d145c672ad utility: Don't use PROJECT_NAME macro for logging 2019-07-13 00:16:42 +02:00
Michael Fabian 'Xaymar' Dirks b7fdd5491a ui/debug_handler: Print flags as normal values instead of hexadecimal 2019-07-13 00:16:42 +02:00
Michael Fabian 'Xaymar' Dirks cdb03a488e encoders/generic: Clean up code slightly 2019-07-13 00:16:42 +02:00
Michael Fabian 'Xaymar' Dirks bab3bb8853 strings: Add text for bitrate and buffer 2019-07-13 00:16:42 +02:00
Michael Fabian 'Xaymar' Dirks c8470d3b23 strings: Add shared translation strings 2019-07-13 00:16:38 +02:00
Michael Fabian 'Xaymar' Dirks c7f326d428 utility: Change vstr and dstr macros to D_STR and D_VSTR 2019-07-13 00:15:54 +02:00
Michael Fabian 'Xaymar' Dirks 830ebf31d9 ui/prores_aw_handler: Disable profile file while encoding 2019-07-07 16:55:02 +02:00
Michael Fabian 'Xaymar' Dirks 076df05b37 ui/debug_handler: Fix flags 2019-07-07 16:54:48 +02:00
Michael Fabian 'Xaymar' Dirks 3bbbea7b42 ui/debug_handler: Add debug handler for implementing new UI Handlers 2019-07-07 16:34:15 +02:00
Michael Fabian 'Xaymar' Dirks 97a53d261f encoders/generic: Fix getting stuck in EAGAIN endless loop
Also removes some left over debug logs.
2019-07-07 15:07:09 +02:00
Michael Fabian 'Xaymar' Dirks e45a82350e encoders/generic: Fix crash and disable static properties 2019-07-07 14:44:08 +02:00
Michael Fabian 'Xaymar' Dirks b6ad026eb3 encoders/generic: Allow overriding of thread count 2019-07-07 14:33:58 +02:00
Michael Fabian 'Xaymar' Dirks df63677529 encoders/generic: Allow overriding color format
Some encoders don't have all options available with the automatically detected color format, so allowing the user to override the detected color format opens up more options.
2019-07-07 14:26:51 +02:00
Michael Fabian 'Xaymar' Dirks d1ff4a7adc encoders/generic: Don't instantly drop frames on EAGAIN
Instead of instantly dropping frames on EAGAIN, try first recieving a packet (if not already done so) and then resubmit the same frame. If it still doesn't work, drop the frame as we have no way to deal with that situation yet.
2019-07-07 13:50:47 +02:00
Michael Fabian 'Xaymar' Dirks e5bf18f2a6 ui/prores_aw_handler: Implement UI Handler for prores_aw 2019-07-07 13:46:11 +02:00
Michael Fabian 'Xaymar' Dirks b442914ebe encoders/generic: Replace generated UI with the new UI Handlers 2019-07-07 13:46:09 +02:00
Michael Fabian 'Xaymar' Dirks 8fb69d6870 plugin: Add global codec to UI Handler map 2019-07-07 13:42:39 +02:00
Michael Fabian 'Xaymar' Dirks dbdf915a07 ui/handler: Implement UI Handler interface class
Adds the ability to override the UI for very specific encoders in order to properly support customized and detailed UI for each encoder. This design is flexible and allows for any kind of UI generator to work, without relying on an actual object too much.
2019-07-07 13:42:22 +02:00
Michael Fabian 'Xaymar' Dirks 9ce8f39efc plugin: Implement support for initializers and finalizers 2019-07-07 13:39:23 +02:00
Michael Fabian 'Xaymar' Dirks 99003d5193 utility: Add initializer functions 2019-07-07 12:57:30 +02:00
Michael Fabian 'Xaymar' Dirks c5d81e41a6 encoders/prores_aw: Update to match new std::shared_ptr<AVFrame> code 2019-07-07 12:18:43 +02:00
Michael Fabian 'Xaymar' Dirks 2f0cd790ed encoders/generic: Update to match new std::shared_ptr<AVFrame> code 2019-07-07 12:14:46 +02:00
Michael Fabian 'Xaymar' Dirks c5ff5d224d ffmpeg/avframe-queue: Upgrade to shared_ptr AVFrame
Removes problems with memory leaks due to lost references and other issues.
2019-07-07 12:14:24 +02:00
Michael Fabian 'Xaymar' Dirks e7c12a52f3 ffmpeg/generic: Strip generated options and always apply bitrate and profile in update 2019-07-07 01:12:06 +02:00
Michael Fabian 'Xaymar' Dirks 976e5dba4f encoders/generic: Reduce warnings, fix encoding, remove threading options, and profiling
* Improved encoding loop can now deal with early and late receive requests.
* Lots of warnings fixed.
* Removed all threading options (they were broken anyway).
* Added some profiler calls.
2019-07-07 00:34:56 +02:00
Michael Fabian 'Xaymar' Dirks 16015f180b plugin: Use av_codec_is_encoder instead of custom check 2019-07-07 00:32:21 +02:00
Michael Fabian 'Xaymar' Dirks 042c934516 ffmpeg/tools: Remove a few warnings and translate more errors 2019-07-07 00:32:05 +02:00
Michael Fabian 'Xaymar' Dirks 53651c29be ffmpeg/avframe-queue: Fix a few warnings 2019-07-07 00:31:33 +02:00
Michael Fabian 'Xaymar' Dirks 0a20b750b8 encoders/generic: Implement video encoding and always use frame queue
This implements video encoding for the generic encoder by using frame queue and a set lag amount (in frames). The lag amount determines for how many frames no repeated attempts at submitting or retrieving a frame should be made, and after that many frames have been submitted the generic encoder will try to retrieve packets if at all possible. If not possible, it will delay for as long as possible to show an Encoder overloaded message.
2019-07-06 14:22:15 +02:00
Michael Fabian 'Xaymar' Dirks 9a58a6a5ff encoders/generic: Implement generic encoder for all ffmpeg encoders 2019-07-06 13:10:00 +02:00
Michael Fabian 'Xaymar' Dirks 143b7f585f ffmpeg/tools: Add function to translate encoder capabilities 2019-07-06 13:09:21 +02:00
Michael Fabian 'Xaymar' Dirks 93c6f0b35a encoders/prores_aw: Fix warnings and formatting 2019-07-06 13:09:21 +02:00
Michael Fabian 'Xaymar' Dirks 3154443e18 ffmpeg/swscale: Fix warning and broken get_target_size 2019-07-06 13:09:21 +02:00
Michael Fabian 'Xaymar' Dirks ec75fe23fe Initial code (pre-GitHub)
Contains:
- ffmpeg object wrappers
- base encoder class
- Apply ProRes encoder (prores_aw)
- OBS plugin structure
2018-11-13 19:04:13 +01:00