Commit Graph

24 Commits

Author SHA1 Message Date
Michael Fabian 'Xaymar' Dirks c84c301d49 obs/gs: Apply coding guidelines 2023-04-05 18:50:59 +02:00
Michael Fabian 'Xaymar' Dirks 4ead07c23a ffmpeg: Apply coding guidelines 2023-04-05 18:50:57 +02:00
Michael Fabian 'Xaymar' Dirks 3533a86b96 ffmpeg/tools: Adjust to match ffmpeg-mux color settings
The 'obs-ffmpeg-mux.c' file specifies different color parameters than StreamFX does. This causes re-muxing to go haywire, and editors that trust these tags suddenly spew out bad colors for BT.601 and sRGB.

Reverts #478
2023-03-28 13:11:21 +02:00
Michael Fabian 'Xaymar' Dirks 303c14de4e ffmpeg/tools: Fix incorrect transfer characteristics
Both Rec. 601 and sRGB looked extremely wrong before, resulting in weird or warped colors. Since it is very difficult to find up to date and accurate information on standards, we should simply go for what has the most widespread support.
2023-03-28 13:11:12 +02:00
Michael Fabian 'Xaymar' Dirks 9938422d5c ffmpeg/tools: Set correct information when encoding
Improves the previous logic and makes it compatible with the new additions in 26.x, such as sRGB. This was previously broken as the focus was on existing features which could be tested without requiring a compiler to be installed.

Incorrect understanding of how sRGB works with RGB and YCC/YUV formats also caused sRGB to be treated as RGB when I444 was selected. This should also now be fixed, hopefully permanently.

Fixes #331
2023-03-28 13:11:00 +02:00
Michael Fabian 'Xaymar' Dirks 66b1715d78 ffmpeg/tools: Fix compatibility with Ubuntu 18.04 2023-03-28 12:52:22 +02:00
Michael Fabian 'Xaymar' Dirks 63a5873413 project: Remove non-standard std:: prefix from types 2023-03-28 12:52:22 +02:00
Michael Fabian 'Xaymar' Dirks f3b3af2030 ffmpeg/tools: Ensure we aren't comparing against a nullptr 2023-03-28 12:52:21 +02:00
Michael Fabian 'Xaymar' Dirks dbb71cf801 project: Code cleanup and reapply formatting
Changes applied:

* Moved utility files to /util/.
* Removed unused #includes.
* Removed unused ::ffmpeg::tools function.
* Removed unused variables.
* Fixed missing parentheses in the version macro.
* Fixed missing override on virtual function overrides and removed unnecessary virtual keyword from them.
* Disabled additional warning for ATL headers on MSVC only.
* Replaced direct printf parameters with their macro equivalent.
* Replaced C-style casts with C++-style casts.
* Applied clang-format again after an earlier change to the CMake file broke the integration for it.
2023-03-28 12:52:20 +02:00
Michael Fabian 'Xaymar' Dirks f7da7283fb ffmpeg/tools: Add string value mapping to print_av_option 2023-03-28 12:52:19 +02:00
Michael Fabian 'Xaymar' Dirks 68a49498e6 common: Rename LOG_ to DLOG_ to avoid macro confusion 2023-03-28 12:52:17 +02:00
Michael Fabian 'Xaymar' Dirks b60f68fcb8 ffmpeg/tools: Fix incorrect colors for sRGB 2023-03-28 12:40:46 +02:00
Michael Fabian 'Xaymar' Dirks 071760b867 ffmpeg-encoder/nvenc: Invert "no-scenecut" option for "Adaptive I-Frames"
Our "Adaptive I-Frames" is the inverse of the expected parameter to "no-scenecut" in FFmpegs NVENC.

Related #191
2023-03-28 12:40:41 +02:00
Michael Fabian 'Xaymar' Dirks c03fc933bb ffmpeg-encoder/d3d11: Set highest eviction priority for buffers
This should ideally prevent textures from being removed from the GPU while the encoder is actively using them.
2020-04-11 15:23:07 +02:00
Michael Fabian 'Xaymar' Dirks 908d1f0a20 project: Modernize code to proper C++ 2020-04-09 00:17:25 +02:00
Michael Fabian 'Xaymar' Dirks cc9d3486b2 project: Fix Linux support by fixing errors and warnings
With this, GCC 8 and above should now be able to compile the project both in obs-studio and as a standalone install. Some features are currently still not fully supported and require extra work, but the majority of things are supported and work out of the box. Exact feature parity can be looked up here on the wiki: https://github.com/Xaymar/obs-StreamFX/wiki/Platform-Feature-Parity

Related: #119 #98 #30
2020-04-02 20:37:45 +02:00
Michael Fabian 'Xaymar' Dirks 3ad2424b22 ffmpeg-encoder: Throw std::runtime_error instead of std::exception 2020-04-02 17:05:02 +02:00
Michael Fabian 'Xaymar' Dirks 59fa1d36d7 common: Common header include for improved platform support
This header includes all common data between headers used in the plugin. This should improve cross-platform compiling support whenever possible, as all platform-dependent common includes and defines can be done here.
2020-04-02 17:02:01 +02:00
Michael Fabian 'Xaymar' Dirks 4f7c1cb35e ffmpeg-encoder: Various warning fixes and cleanup
Also don't include it from plugin.cpp if it's not enabled.
2020-03-27 20:10:29 +01:00
Michael Fabian 'Xaymar' Dirks e2c83f546e ffmpeg/tools: Allow overriding option context 2020-03-07 01:48:06 +01:00
Michael Fabian 'Xaymar' Dirks 5223d3980f ffmpeg/tools: Also log default values 2020-03-07 00:33:55 +01:00
Michael Fabian 'Xaymar' Dirks b306cebd6b project: More warnings fixed 2020-01-14 01:39:13 +01:00
Michael Fabian 'Xaymar' Dirks 0a16ce07dc project: Merged FFmpeg Encoders Step 2 2020-01-13 22:40:15 +01:00
Michael Fabian 'Xaymar' Dirks 3eea289679 project: Merged FFmpeg Encoders Step 1 2020-01-13 01:52:30 +01:00