Commit graph

194 commits

Author SHA1 Message Date
Michael Fabian 'Xaymar' Dirks
af660cfc1d cmake: (Windows) Fix incorrect reference to CMAKE_PACKAGE_PREFIX 2023-03-28 13:11:16 +02:00
Christopher P Yarger
483e3a5f2d cmake: (MacOS) Add .pkg installer generation
Enables users of the Mac Operating System to use an automated installer instead of the manual installation method which is prone to user errors. This is done via the use of "Packages", which generates a .pkg file according to the requirements we present it.
2023-03-28 13:11:16 +02:00
Michael Fabian 'Xaymar' Dirks
8189076cd2 cmake: Fix version detection code
When the CMake script was rewritten, not much attention was put into the versioning code, resulting in odd behavior which was never found or fixed. For example, the automatic splitting of the suffix from the number never worked, and the build number was being stored in the wrong variable.
2023-03-28 13:11:15 +02:00
Michael Fabian 'Xaymar' Dirks
d24fb07dcc cmake: Update download logic 2023-03-28 13:11:15 +02:00
Michael Fabian 'Xaymar' Dirks
d8bb1cecc5 cmake: (MacOS) Fix linker path for libraries 2023-03-28 13:11:15 +02:00
Michael Fabian 'Xaymar' Dirks
597a240d73 project: 0.10.0b1 2023-03-28 13:11:14 +02:00
Michael Fabian 'Xaymar' Dirks
24f1cd0cde cmake: (MacOS) Install to a more reasonable structure 2023-03-28 13:11:14 +02:00
Michael Fabian 'Xaymar' Dirks
cb2621f98b cmake: Don't require code signing on MacOS 2023-03-28 13:11:14 +02:00
Michael Fabian 'Xaymar' Dirks
5b893ca5d6 cmake: Add otool post-build steps for MacOS 2023-03-28 13:11:14 +02:00
Michael Fabian 'Xaymar' Dirks
03a8168beb project: Version 0.10.0a2
* 3D Transform should now appear again.
* Automatic disabling of unsupported features should now work in CMake.
* Fixed a compilation error on some versions of GCC.
2023-03-28 13:11:12 +02:00
Michael Fabian 'Xaymar' Dirks
01f16e6d1f cmake: Fix features being enabled on unsupported platforms 2023-03-28 13:11:12 +02:00
Michael Fabian 'Xaymar' Dirks
be699c643c cmake: Fix TRANSFORM typo 2023-03-28 13:11:12 +02:00
Michael Fabian 'Xaymar' Dirks
c95afab9d4 project: Version 0.10.0a1
- #437 Use 'git describe --tags' for versioning.
- #439 Add support for overriding the automatically detected version.
- #454 Fixed new versioning code breaking when the tag is on the current commit.
- #427, #428 Fix Qt interaction before OBS Studio is actually ready.
- #452 Fixed building without updater but with UI.
- #447 Redesigned Color Grading to support two rendering modes:
    - Direct Rendering applies the entire color grading function to every single pixel, and is thus more accurate, but much slower.
    - #-Bit LUT Rendering first applies the color grading function to a LUT that varies in accuracy, and then uses that LUT to render the actual output instead, which is much faster but less accurate.
- #447 Optimized Direct Rendering in Color Grading to be up to 25% faster, while using 50% less VRAM.
- #440 Removed support for Ubuntu 18.04 as it ships seriously outdated versions of libraries we use.
2023-03-28 13:11:12 +02:00
Michael Fabian 'Xaymar' Dirks
e59a33423e cmake: Always use long git describe 2023-03-28 13:11:11 +02:00
Michael Fabian 'Xaymar' Dirks
26a76e0451 filters/color-grade: Redesign for use with LUTs
There is hardly any reason for us to recalculate everything all the time. LUTs can cache the work once, and then re-use it every time necessary, drastically reducing the impact of Color Grading by almost 60% (on some GPUs even more). Additionally this fixes the negative gamma issue, which plagued the filter for a while.

In the future, once PR 4199 (https://github.com/obsproject/obs-studio/pull/4199) has been merged, we can cut away one intermediate rendering step currently required to make the effect work. Hopefully this will be with the 27.x release of OBS Studio.
2023-03-28 13:11:11 +02:00
Michael Fabian 'Xaymar' Dirks
eba0a467d5 gfx/lut: Add a simple but efficient LUT producer and consumer
For simple image and video editing, LUTs (Look-Up Tables) are vastly superior to running the entire editing operation on each pixel - especially if all the processing can be done inside a single shader.

Due to the post-processing requirements for our LUTs, we are limited to 8 bits per channel - though clever use of the unused Alpha channel may result in additional space. For our purposes however, this is definitely enough.
2023-03-28 13:11:11 +02:00
Michael Fabian 'Xaymar' Dirks
73f9257633 effects: Add RGB, HSV, and YUV conversion functions 2023-03-28 13:11:11 +02:00
Michael Fabian 'Xaymar' Dirks
a027a57d09 effects: Add generic shared header with common code 2023-03-28 13:11:11 +02:00
Michael Fabian 'Xaymar' Dirks
b1b6fa2cf9 cmake: Add packaging support for Windows, Linux and Mac
Also adds packaging for the proposed unified plugin format.
2023-03-28 13:11:10 +02:00
Michael Fabian 'Xaymar' Dirks
5ac894c59c cmake: Refactor component and dependency system
A complete redesign of the component and dependency system is necessary in order to support additional platforms, such as MacOS and other Linux platforms. Additionally it results in a much cleaner code base, which is less confusing overall.

Eventually it might be necessary to push components of StreamFX into their own CMake projects, as it is getting kind of complex now. Especially with the push for a proper plugin manager, things get dicey for big plugins like StreamFX.
2023-03-28 13:11:10 +02:00
Michael Fabian 'Xaymar' Dirks
851e1e8939 cmake: Add proper version override support 2023-03-28 13:11:09 +02:00
Michael Fabian 'Xaymar' Dirks
2d522f3c50 cmake: Improve versioning system 2023-03-28 13:11:07 +02:00
Michael Fabian 'Xaymar' Dirks
2f8a0935c5 project: Version 0.10.0a
* encoders/ffmpeg: Implement AMF H.264 and H.265 handlers
* locale: New Crowdin updates (Turkish) (#373)
* examples: Added adjustable luminance to hexagon size (#364)
* cmake: Add option to override download versions and hashes
2023-03-28 13:11:07 +02:00
Michael Fabian 'Xaymar' Dirks
ff3f8cff03 encoders/ffmpeg: Implement AMF H.264 and H.265 handlers
Adds support for the AMD Advanced Media Framework H.264 and H.265 encoders via FFmpeg. The majority of settings are supported, and the UI/UX experience mimics that of the NVENC implementation. Various settings are left out due to their complexity and should be controlled via the custom parameters field.
2023-03-28 13:11:06 +02:00
Michael Fabian 'Xaymar' Dirks
2eb59a58f8 cmake: Add option to override download versions and hashes
Allows users to override the built-in download values with custom ones, in order to build with different versions of OBS or the depencencies used.
2023-03-28 13:11:03 +02:00
Michael Fabian 'Xaymar' Dirks
f796c85527 util/bitmask: Move bitmask functionality its own file 2023-03-28 13:11:03 +02:00
Xaymar
5185c720ea cmake: Restore default visibility
The MODULE_EXPORT and EXPORT macros in libOBS do not correctly mark a function or type as visible on GCC, which results in the newly added flag hiding everything from view, instead of just what should be hidden.
2023-03-28 13:11:03 +02:00
Michael Fabian 'Xaymar' Dirks
e866bc97d2 cmake: Update to libOBS 26.0.x 2023-03-28 13:11:02 +02:00
Michael Fabian 'Xaymar' Dirks
85a88902de cmake: Check for "Darwin" instead of "Mac" to support MacOS 2023-03-28 13:11:01 +02:00
Xaymar
3d70814b93 cmake: Set correct flags when building with obs-studio
The commit 8163e3e917 introduced a complete refactor of the CMake script in order to improve future updates, but accidentally broke building with OBS Studio due to only testing the standalone model. By correctly adjusting the option name again, this should work again with this change.

Fixed: #351
2023-03-28 13:11:01 +02:00
Michael Fabian 'Xaymar' Dirks
3097a4f552 cmake: Refactor to modernize and improve readability
Refactors the entire file to be more readable while also improving the possibility of future improvements. Components are now resolved in one go instead of being all over the place, and shared dependencies are now only resolved once instead of multiple times.

For future compatibility sake, all features now default to enabled and will instead show a warning if they can't be enabled, or if their dependencies can't be found. Pay attention to the build log if you encounter this, as it should hint you towards what is missing. Some features are also now optional, instead of being required.

Furthermore the "Reference" and "Package" mode for building have been removed as supporting them has been a problematic thing from the start. While their structure technically matches the one that is downloaded, effectively they can result in unpredictable issues.

A number of other issues have also been fixed, like Qt being invoked for non-Qt source files.
2023-03-28 13:11:00 +02:00
Michael Fabian 'Xaymar' Dirks
808da4894b cmake: Upgrade C/C++ compiler adjustments to modern CMake 2023-03-28 13:11:00 +02:00
Michael Fabian 'Xaymar' Dirks
f3a57513ad cmake: Set proper CMake policies by version 2023-03-28 13:11:00 +02:00
Michael Fabian 'Xaymar' Dirks
67227f2c03 cmake: Improve readability 2023-03-28 13:10:59 +02:00
Michael Fabian 'Xaymar' Dirks
f3c10c5044 project: Version 0.9.0 2023-03-28 12:52:28 +02:00
Michael Fabian 'Xaymar' Dirks
f907fc80b0 updater: Add functionality to check for updates
Implements a manual and automatic update checker with support for both release and testing update channels, allowing users to stay as up to date as possible. It is fully compliant with privacy regulations around the world, as it stays completely silent and inactive until the user gives the Ok to connect to GitHub for the latest releases.
2023-03-28 12:52:27 +02:00
Michael Fabian 'Xaymar' Dirks
6d3b0f1266 cmake: Add optional dependency nlohmann::json 2023-03-28 12:52:27 +02:00
Michael Fabian 'Xaymar' Dirks
1107c1e390 util/curl: Add C++ wrapper for CURL 2023-03-28 12:52:27 +02:00
Michael Fabian 'Xaymar' Dirks
bec062a7bd project: Version 0.9.0a3
* #307 Fix MSVC exclusive strcmp crash in FFmpeg Encoders.
* #310 Add shadertoy effect.
* #311 Move template files to custom directory.
* #312 Hide encoders that the current system does not support.
* #313 Enable FFmpeg Encoders on Linux.
2023-03-28 12:52:26 +02:00
Michael Fabian 'Xaymar' Dirks
a39fd89ba7 util/library: Cross-platform handler for library loading
Adds a utility class and functions to load libraries and symbols from libraries somewhat safely. Libraries are immediately unloaded when the last reference to them is lost, so the shared_ptr should be stored if the library is actually needed.
2023-03-28 12:52:23 +02:00
Michael Fabian 'Xaymar' Dirks
4947ae9a13 cmake: Enable FFmpeg Encoders on Linux 2023-03-28 12:52:22 +02:00
Michael Fabian 'Xaymar' Dirks
c20ac4a413 templates: Add generated configuration file 2023-03-28 12:52:21 +02:00
Michael Fabian 'Xaymar' Dirks
0ecf971446 templates: Move template files to better directory 2023-03-28 12:52:21 +02:00
Michael Fabian Dirks
d2f81d8956 project: Version 0.9.0a2
* #270 Add additional shadertoy effects (by Oncorporation/Surn).
* #275 Improve installer user experience.
* #277 Add CI caching to improve build speeds.
* #286 Rename LOG_ to DLOG_ to avoid macro confusion.
* #287 Add new 'Thank You' entries.
* #288 Fix memory leaks caused by obs::source_tracker.
* #289 Fix memory leaks caused by configuration and UI.
* #290 Don't use namespaces that don't exist.
* #292 Fix/Work around a memory leak in gs::vertex_buffer.
* #293 Fix missing include in plugin.hpp.
* #294 Fix Clang toolset integration.
* #296 Fix FFmpeg encoder fallback support.
* #298 Fix NVENC logging incorrect values.
* #300 Remove level 5.2 from NVENC H.264.
* #301 Show warnings for exceptions thrown from tasks in a threadpool.
* #302 Clean up code to fix all warnings and reapply formatting.
* #304 Update Ubuntu 19.10 to 20.04 and revert to system-installed clang.
2023-03-28 12:52:21 +02:00
Michael Fabian 'Xaymar' Dirks
09c151a9d2 cmake: Don't enable useless warnings on GCC
Using '-Wpedantic' on any GCC warnings enables a lot of annoying warnings that don't actually warn about anything. Some of the warnings seem to exist purely for maintaining a certain code style, and have no actual effect on the program itself. Since there is no way to selectively disable warnings like on MSVC, removing it is the easiest choice.
2023-03-28 12:52:20 +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
12a6a76341 cmake: Fix Clang toolset support 2023-03-28 12:52:18 +02:00
Michael Fabian 'Xaymar' Dirks
731dbd26a7 cmake, ci: Add caching support to speed up builds 2023-03-28 12:52:17 +02:00
Michael Fabian 'Xaymar' Dirks
16489c4180 project: Improve user experience in the Installer
Adds a BeforeInstall step to the InnoSetup installer which uses the msvc-redist-helper tool to automatically check for the necessary DLLs and install the required redistributable if some are found to be missing.

Additionally slightly modernized the installer with a design that isn't from the 90s, and paves the way for preventing updating StreamFX while OBS Studio is still running.
2023-03-28 12:52:16 +02:00
Michael Fabian 'Xaymar' Dirks
df97f71655 project: Version 0.9.0a1 2023-03-28 12:52:16 +02:00