Commit graph

1500 commits

Author SHA1 Message Date
Michael Fabian 'Xaymar' Dirks
7296bbc16b encoder/ffmpeg: Improve software scaling quality
Might be better to allow end-users to choose swscale quality, if they deem it necessary.
2023-04-05 18:58:46 +02:00
Michael Fabian 'Xaymar' Dirks
b55e4b283b encoder/ffmpeg: Add split framerate with integer fractions
It seems to be possible to encode with a different framerate than what libOBS is configured for. While technically any framerate appears to be possible, it is currently limited to integer fractions only in order to make the implementation much easier. Integer fractions only require skipping N frames and multiplying the denominator by N, where N is the configured integer. For sanity reasons, the limit of N is currently 10.

This allows power users to split their streaming and recording framerates with relative ease, and opt for things such as:
- 30 FPS (1/4) streaming with 120 FPS (1/1) recording.
- 30 FPS (1/10) streaming with 300 FPS (1/1) recording.
- 30 FPS (1/10) streaming with 100 FPS (1/3) recording.
- and so on.
While some of these combinations are just stupid, they are now available to power users.
2023-04-05 18:58:45 +02:00
Michael Fabian 'Xaymar' Dirks
bbac990644 encoder/ffmpeg: Assume extra data and sei are present on first frame
While this may break some unusual encoders that require additional frames for extra data or sei data to be present, it fixes the problem where encoders would never record at all. May need to look into a different solution in the future.

Fixes #911
2023-04-05 18:58:45 +02:00
Romain Vigier
3d293bac6a cmake: Require nlohmann-json when building the front-end
Nlohmann-json is used in the about dialog, yet wasn't required when building the front-end, leading to failing compilation. This ensures that it is correctly required.
2023-04-05 18:58:45 +02:00
Michael Fabian 'Xaymar' Dirks
bfd8155ddc templates: Prefer per-user installations on MacOSX
With OBS Studio 28.0 comes another restriction: Per-User Plugins. This is currently only enforced on ARM64, but may soon be enforced on all architectures. Adjusting the Packages installer to generate the correct files is relatively easy.

Unfortunately the MacOS Package Installer has some problems figuring out if it should show the user the correct step or not, and may even ignore our settings entirely. This bug has been first reported in 2010, and has since then been re-reported in 2016, 2017, 2018, 2019, and 2020 where it was finally turned into a community wiki on StackOverflow.
2023-04-05 18:58:45 +02:00
Michael Fabian 'Xaymar' Dirks
2451c8418e templates: Add error message if MacOSX is below 10.15 2023-04-05 18:58:44 +02:00
Michael Fabian 'Xaymar' Dirks
d4ef043043 cmake: Export Loadable Bundles on MacOS
With OBS Studio 28.0.0 a new requirement was added to MacOS plugin: Loadable Bundles. These bundles are similar to Application Bundles, and have many of the same features, but are designed to be loaded by Applications instead of being the Application. This allows for almost all of the advantages to persist, with some minimal drawbacks.
2023-04-05 18:58:44 +02:00
Michael Fabian 'Xaymar' Dirks
e3d0cabb09 cmake: Always show templates for all architectures 2023-04-05 18:58:43 +02:00
Michael Fabian 'Xaymar' Dirks
c750fa9a5c cmake: Use @rpath on MacOS
This removes the additional patch steps after building, and are more stable across architectures.
2023-04-05 18:58:43 +02:00
Michael Fabian 'Xaymar' Dirks
9adc49b164 templates: Move MacOS-only files into dedicated folder 2023-04-05 18:58:43 +02:00
Michael Fabian 'Xaymar' Dirks
4382ad469f templates: Move Windows-only files into dedicated folder 2023-04-05 18:58:42 +02:00
Michael Fabian 'Xaymar' Dirks
7f1ae7f9f1 cmake: Require MacOSX 10.15 or newer 2023-04-05 18:58:42 +02:00
Michael Fabian 'Xaymar' Dirks
f40c7a9906 cmake: Automatically discover data files
Prevents missing data due to it not being in the PROJECT_DATA variable. Bit of a hacky solution, but you gotta do what you gotta do to fix it.
2023-04-05 18:58:42 +02:00
Michael Fabian 'Xaymar' Dirks
a66b46965e cmake: Add media files to IDE projects
These files should be ignored as they have the HEADER_FILE_ONLY flag set.
2023-04-05 18:58:42 +02:00
Xaymar
630600fd96 locale: New Crowdin updates (#907)
* New translations en-US.ini (Portuguese)

* New translations en-US.ini (Portuguese)

* New translations en-US.ini (Italian)

* New translations en-US.ini (Chinese Simplified)

* New translations en-US.ini (Swedish)

* New translations en-US.ini (Turkish)

* New translations en-US.ini (Indonesian)

* New translations en-US.ini (Portuguese)

* New translations en-US.ini (Estonian)

* New translations en-US.ini (Polish)

* New translations en-US.ini (Portuguese, Brazilian)

* New translations en-US.ini (Greek)

* New translations en-US.ini (Romanian)

* New translations en-US.ini (French)

* New translations en-US.ini (Spanish)

* New translations en-US.ini (Bulgarian)

* New translations en-US.ini (Czech)

* New translations en-US.ini (Danish)

* New translations en-US.ini (German)

* New translations en-US.ini (Finnish)

* New translations en-US.ini (Hungarian)

* New translations en-US.ini (Japanese)

* New translations en-US.ini (Dutch)
2023-04-05 18:58:41 +02:00
Xaymar
e59660a18f locale: New Crowdin updates (#897)
* New translations en-US.ini (Chinese Simplified)

* New translations en-US.ini (Chinese Simplified)

* New translations en-US.ini (Japanese)
2023-04-05 18:58:41 +02:00
Michael Fabian 'Xaymar' Dirks
78e5c10a74 code: Fix GCC warning diagnostic pragmas 2023-04-05 18:58:41 +02:00
Michael Fabian 'Xaymar' Dirks
6c8578e555 third-party: Update obs-studio to 28.0.0 2023-04-05 18:58:40 +02:00
Michael Fabian 'Xaymar' Dirks
f1c91f1671 ci: Install GLES, EGL and OpenGL development files (Linux) 2023-04-05 18:58:40 +02:00
Michael Fabian 'Xaymar' Dirks
15bf5b8e64 cmake: Remove pointless floating math contract option 2023-04-05 18:58:40 +02:00
Michael Fabian 'Xaymar' Dirks
1c7350edf7 code: Fix initialization order for constructors
Prevents some out-of-order events from occurring.
2023-04-05 18:58:40 +02:00
Michael Fabian 'Xaymar' Dirks
08544b4116 cmake, code: Abuse pre-processor to disable/enable warnings 2023-04-05 18:58:39 +02:00
Michael Fabian 'Xaymar' Dirks
8e52bbf88b code: Ignore warnings from external code
May need to find a better solution such as disabling all warnings on third party code.
2023-04-05 18:58:38 +02:00
Michael Fabian 'Xaymar' Dirks
4e41c5cf24 code: Revert #836
The compiler will choose the optimal way automatically, and forcing std::move here actually results in two objects existing side by side, before being "moved" into one.
2023-04-05 18:58:38 +02:00
Michael Fabian 'Xaymar' Dirks
b9d8583d58 code: (sn)printf automatically zero-terminates strings 2023-04-05 18:58:38 +02:00
Michael Fabian 'Xaymar' Dirks
24a19c2ed3 ffmpeg/tools: Revert #836
It is not valid to pass std::string_view to snprintf's %s.
2023-04-05 18:58:38 +02:00
Michael Fabian 'Xaymar' Dirks
0aca1fc132 code: Always provide a default case for enumerations 2023-04-05 18:58:37 +02:00
Michael Fabian 'Xaymar' Dirks
badca28a08 updater: Don't pass unused variables into lambda captures 2023-04-05 18:58:37 +02:00
Michael Fabian 'Xaymar' Dirks
4fa26dd2d6 code: Always initialize or cast to correct type 2023-04-05 18:58:37 +02:00
Michael Fabian 'Xaymar' Dirks
de703867e6 encoder/ffmpeg: Drop support for broken FFmpeg versions
This removes the Matroska fix for ProRes content, and upgrades from av_init_packet to av_packet_alloc.
2023-04-05 18:58:37 +02:00
Michael Fabian 'Xaymar' Dirks
0fe5c7e654 code: Don't use try-catch as function definition
This breaks MSVC and results in leaked exceptions.
2023-04-05 18:58:37 +02:00
Michael Fabian 'Xaymar' Dirks
678399ce81 cmake: Ignore not-so-useful warnings
These warnings are mostly hints or complete nonsense based on broken parsing. It is easier to disable them than to find a common solution that works on all compilers.
2023-04-05 18:58:36 +02:00
Michael Fabian 'Xaymar' Dirks
bb79b574b5 cmake: Enable all warnings 2023-04-05 18:58:36 +02:00
Michael Fabian 'Xaymar' Dirks
398a58ec64 project: Updating contributing guidelines 2023-04-05 18:58:36 +02:00
Xaymar
5d76a3865a locale: New Crowdin updates (#890)
* New translations en-US.ini (Russian)

* New translations en-US.ini (Czech)

* New translations en-US.ini (Italian)

* New translations en-US.ini (Spanish)

* New translations en-US.ini (Polish)

* New translations en-US.ini (Danish)

* New translations en-US.ini (Danish)

* New translations en-US.ini (Danish)

* New translations en-US.ini (Danish)

* New translations en-US.ini (Danish)

* New translations en-US.ini (French)
2023-04-05 18:58:36 +02:00
Michael Fabian 'Xaymar' Dirks
ed88c4a4d2 project: Updating contributing guidelines 2023-04-05 18:58:36 +02:00
Michael Fabian 'Xaymar' Dirks
c1b832c03a cmake: Fix bad version strings
PROJECT_VERSION is defined by CMake, and can't be relied on.
2023-04-05 18:58:35 +02:00
Xaymar
584ee995be locale: New Crowdin updates (#867)
* New translations en-US.ini (Portuguese, Brazilian)

* New translations en-US.ini (Portuguese, Brazilian)

* New translations en-US.ini (Chinese Simplified)

* New translations en-US.ini (Chinese Simplified)

* New translations en-US.ini (Romanian)

* New translations en-US.ini (Spanish)

* New translations en-US.ini (Russian)

* New translations en-US.ini (Italian)

* New translations en-US.ini (Czech)
2023-04-05 18:58:35 +02:00
Michael Fabian 'Xaymar' Dirks
b5195c580c filter/displacement: Add missing deprecation notice 2023-04-05 18:58:35 +02:00
Michael Fabian 'Xaymar' Dirks
5ea8aa2acc encoders/handlers/amf: Add missing deprecation notice 2023-04-05 18:58:35 +02:00
Michael Fabian 'Xaymar' Dirks
c150a1b0d7 encoders/aom-av1: Deprecate encoder 2023-04-05 18:58:35 +02:00
Michael Fabian 'Xaymar' Dirks
3883c4759c encoders/handlers/amf: Deprecate encoder 2023-04-05 18:58:34 +02:00
Michael Fabian 'Xaymar' Dirks
fb09e98a5f gfx/shader/param-texture: Use obs::weak_source instead of obs::source 2023-04-05 18:58:33 +02:00
Michael Fabian 'Xaymar' Dirks
8f8b8839e5 obs/weak-source: Further optimization and modernization 2023-04-05 18:58:33 +02:00
Michael Fabian 'Xaymar' Dirks
9fbed3a319 cmake: Workaround for missing INTERFACE_INCLUDE_DIRECTORIES (MacOS)
This work-around adds the necessary include directories, as the 'libobs' target does not export any include directories visible without BUILD_INTERFACE evaluating to TRUE. Hopefully the true cause for this problem can be identified and fixed later.
2023-04-05 18:58:33 +02:00
Michael Fabian 'Xaymar' Dirks
1d066caed3 cmake: Set correct path for Qt6 binaries (MacOS) 2023-04-05 18:58:33 +02:00
Michael Fabian 'Xaymar' Dirks
e97f1c2a3f ci: Fix definition of CMAKE_OSX_ARCHITECTURES (MacOS) 2023-04-05 18:58:33 +02:00
Michael Fabian 'Xaymar' Dirks
c92be933d9 third-party/obs-studio: 28.0.0-rc1 2023-04-05 18:58:32 +02:00
Michael Fabian 'Xaymar' Dirks
808f5c63fb obs/gs/effect: Revert #836
The use of const references breaks '#include' for relative paths.
2023-04-05 18:58:32 +02:00
lainon
6e1566386e project: Apply more C++ paradigms to the code
- Use auto in places where code clarity is improved or identical.
- Replace trivial constructors and destructors with default.
- Use true random for random generation.
- Use std::string_view where it is valid to do so.
- Apply const where it is valid to do so.
- Use references where it is valid to do so.
- Manually optimize memory usage with std::move and std::copy.
- Opt for memory efficient containers where the size is known ahead of time.

Signed-off-by: lainon <GermanAizek@yandex.ru>
2023-04-05 18:58:32 +02:00