Commit Graph

9126 Commits

Author SHA1 Message Date
Martin Pulec
d0bbce5af9 vcomp/lavc version: print ver from run-time linked
Do print the runtime lavc version instead the one from headers, that
may differ (minor and patch only).
2025-05-05 11:17:32 +02:00
Martin Pulec
28bb5609d6 configure.ac: pcp has changed pkg-config name 2025-05-05 10:56:05 +02:00
Martin Pulec
1fbd3bf7b6 CI: fix XIMEA URL 2025-05-05 10:52:14 +02:00
Martin Pulec
21319bbe48 vulkan_sdl2: vulkan_display_log: fix log_level
fixed log_level shadowing

The vulkan_sdl mapped log_level shadows the global log_level variable,
so that automatic variable log_level is compared to itself (always true).
2025-04-02 12:56:41 +02:00
Martin Pulec
5e9fc00864 fix macOS 15.4 beta crashes due to LC_RPATH dups
Fixes the UG crashes caused by the multiplication of
"@executable_path/../libs/" caused by replacing multiple (originally
distinct) LC_RPATH values with this one.

+ removed invalid comment from Makefile (actually was related to
"bundle-nolib" target that is no longer present)

closes GH-436
2025-04-02 12:54:18 +02:00
Martin Pulec
26ba0bc6d8 AppImage Firejail: suppress private-tmp in config
Upstream Firejail (0.9.75) has now private-tmp enabld by default in
default.profile, which breaks run from the nounted AppImage.
2025-03-28 09:34:00 +01:00
Martin Pulec
8035b2f5f1 UltraGrid 1.9.9 v1.9.9 2025-03-21 14:52:23 +01:00
Martin Pulec
76dcda887d CI PCP: fix another breakage [Win]
The development in PCP seem to be very turbulent these days and it breaks
Win builds often so pin a commit in Windows CI until the situation calms
down a bit.
2025-03-21 14:52:23 +01:00
Martin Pulec
55eb31a840 CI PCP Win: most of incompat is now fixed upstream
Most of the incompatibilities, which were patched, have already been
fixed in upstream.

just forward decl of struct timezone/timeval is still needed
2025-03-21 12:58:51 +01:00
Martin Pulec
c248e53752 MTU size check: improved
Do not use positional references to printf format string, which is a
POSIX extension and not supported by Windows C library.

+ write the optarg string (in case that is only partionally parsed -
atoi stopped at first non-number)

refers to GH-437
2025-03-21 12:58:51 +01:00
Martin Pulec
e4248fe559 aplay/portaudio: add dev default sample rate
This complements the previous commit - add the device default rate to
list of rates, that are tested if work (obviously this one should work
by definition so that now testing the remaining sample rates shouldn't
take place).
2025-03-21 12:58:50 +01:00
Martin Pulec
8f5b0ce2b3 acap/portaudio: set device default rate
instead of hard coding 48 kHz, which may also fail as for VB-Matrix set
to 44100 Hz using ASIO

refers to GH-430
2025-03-21 12:58:50 +01:00
Martin Pulec
4af2584093 vcomp/lavc: prefer libvpx-vp9 if AVX2 !present
For VP9, libsvt_vp9 is preferrd (if built-in, which is in Linux builds),
but it compiles with AVX2 by default, so prefer libvpx if CPU doesn't
support that.
2025-03-21 12:58:50 +01:00
Martin Pulec
2db22adefb vcomp/lavc: preferred encoder updates
- typo (prefered->preferrred)
- if callback defined but returned nullptr, ignore that
2025-03-21 12:58:50 +01:00
Martin Pulec
c7aad836a1 AppRun Firejail fix
Omit adding --read-only=/tmp fixed - now paths are "-enclosed, handle
eventual mutliplied leading / and evental trailing one and don't assume
space after (not needed now, " delimits that).
2025-03-21 12:58:50 +01:00
Martin Pulec
66f2375723 CoInitializeEx: use COINIT_APARTMENTTHREADED
PortAudio/ASIO drivers seem refuse initialization if
CoInitilizeEx initialized as COINIT_MULTITHREADED but they do for
COINIT_APARTMENTTHREADED.

Windows devices that could be affected by this change tested and seem
to work, namely:
- DeckLink
- DirectShow
- WASAPI

refer to GH-430
2025-03-21 12:58:49 +01:00
Martin Pulec
e6cf35ca0b CI Linux: switch to ubuntu-22.04
ubuntu-20.04 GH image is being deprecated and will be eventually removed
from GH
2025-03-21 12:58:49 +01:00
Martin Pulec
265228cad0 wasapi: fix setting dev by UUID
The mutibyte to wide character conversion was (perhaps since the
beginning) wrong - mbtowc converts just one character - it should have
beem mbstowcs but using rather mbsrttowcs (thread-safe).
2025-03-21 12:58:49 +01:00
Martin Pulec
c3bc5a6ef9 AppImage Firajail: drop --ipc-namespace
breaks display vulkan_sdl2 with x11 driver (but not wayland!)
2025-03-21 12:58:49 +01:00
Martin Pulec
d286b59f3d vdisp/sdl2: fixed I420 (IYUV)
The pitch for planar pixel formats is the pitch of the first plane,
most likely =width. This yield wrong data_len for I420 if just multiplied
by the height.

this fixes the change made by 107e3e30 (2024-09-02)
2025-03-21 12:58:49 +01:00
Martin Pulec
e8763663c2 CI GPUJPEG Win: upstream file name has changed 2025-03-21 12:58:49 +01:00
Martin Pulec
56673146ec GPUJPEG: adjust verbosity
v0.26 is slightly more chatty even in GPUJPEG_LL_STATUS mode (new between
INFO and VERBOSE) while the status/verbose mode maps more to debug than
UG verbose so adjust the modes as such.
2025-03-21 12:58:48 +01:00
Martin Pulec
ec8467dabe CI Linux FFmpeg: libsvtav1 API change patch 2025-03-21 12:58:48 +01:00
Martin Piatka
0956c6a8d3 disp/vulkan: Don't crash when image acquire fails multiple times
It is not uncommon for swapchain image acquire to fail multiple times in
a row e.g. when the user is continuously resizing the windown with the
mouse cursor. There is really no need to raise an exception and crash
the whole process.
2025-03-20 14:11:39 +01:00
Martin Piatka
9eeede3954 disp/vulkan: Fix suboptimal swapchain handling
When vkAcquireNextImage() returns VK_SUBOPTIMAL_KHR it means that a valid
usable image was still acquired and that means that the
acquire_samaphore is pending and signalled as normal.

This means we cannot just recreate the swapchain and reuse it to acquire
an image from the new swapchain as VulkanDisplay::display_queued_image()
was doing, because the spec states that the semaphore must be unsignaled
and not pending.

The fix here is to render and display the suboptimal image as normal and
set a flag to immediately return swapchain_image_out_of_date to trigger
a swapchain recreation on the next frame.
2025-03-20 14:11:38 +01:00
Martin Pulec
c78eef3b15 UltraGrid 1.9.8 v1.9.8 2024-11-20 13:50:17 +01:00
Martin Pulec
07a61c53ff Vulkan >=301 compat 2024-11-20 13:31:02 +01:00
Martin Pulec
4868103be3 CI FFmpeg SVT-VP9 patch
SVT-HEVC and SVT-VP9 patches now interfere (neighbor of SVT-VP9 is not
libspeex but libsvthevc now).
2024-11-20 13:30:30 +01:00
Martin Pulec
908165c83b CI mac: add /Library/Framework to rpath
needed for DELTACAST, otherwise manpage generation fails with:
```
 dyld[40232]: Library not loaded: @rpath/VideoMasterHD.framework/Versions/A/VideoMasterHD
  Referenced from: <3D8A8CBA-1094-3538-9770-331DE9A2D6D2> /Users/runner/work/UltraGrid/UltraGrid/bin/uv
  Reason: tried: '/usr/local/lib/VideoMasterHD.framework/Versions/A/VideoMasterHD' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/usr/local/lib/VideoMasterHD.framework/Versions/A/VideoMasterHD' (no such file), '/usr/local/lib/VideoMasterHD.framework/Versions/A/VideoMasterHD' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/usr/local/lib/VideoMasterHD.framework/Versions/A/VideoMasterHD' (no such file)
Could not obtain data from UG/reflector output!
```
2024-10-25 09:26:07 +02:00
Martin Pulec
4bf16b87ee CI macos: fail if DELTA not found
Fail if DELTACAST SDK was not found (actually remove check for its
presence) if $SDK_URL is set.
2024-10-24 16:19:00 +02:00
Martin Pulec
09ff92219f CI macos: re-enable DELTACAST
The file name has changed and --enable-deltacast was used just if the
download succeeded (which didn't).

Fixes the commit 98d4969b (2024-05-24) that disabled deltacast, because
the archive was not downloaded due to wrong name.
2024-10-24 16:18:37 +02:00
Martin Pulec
b3ec13a2ce UltraGrid 1.9.7 v1.9.7 2024-10-21 15:04:56 +02:00
Martin Pulec
480c95c0d4 updated FIXES for 1.9.7 2024-10-21 15:04:56 +02:00
Martin Pulec
8881d22150 Revert "CI Linux FFmpeg: patch VP9 FFmpeg patch"
This reverts commit c8b1e6859d.

the upstream SVT-VP9 patch has been updated
2024-10-21 15:04:56 +02:00
Martin Pulec
a6ed0cbcdb CI FFmpeg Linux: updated libde265 patch
remove FFCodec.init_static_data - dropped from upstream but not used by
libde265 plugin anyways
2024-10-21 15:04:55 +02:00
Martin Pulec
82cfa8caf8 CI Linux FFmpeg: compat vaapi patch update 2024-10-21 15:04:55 +02:00
Martin Pulec
cb3089d589 vdisp/ndi: set stride explicitly
The documentation in header for
NDIlib_video_frame_v2_t.line_stride_in_bytes says that if set to 0,
default value (size of pixel * bpp) will be used.

However, this doesn't seem to work for P216 and PA16 in Windows. It does
in Linux, also 8-bit formats do not require that. However in Windows,
it causes "No data received.".

see also GH-148
2024-10-21 15:04:55 +02:00
Martin Pulec
cc617d7f9f vcap/ndi: handle source disconnect 2024-10-21 15:04:55 +02:00
Martin Pulec
8e0504bce6 debug.h: MSG: allow MOD_NAME to be a varible
Allow the MOD_NAME to be a variable (like (constexpr const char *)). Using
non-standard extension, the standard one would be __VA_OPT__. Although
it is supported with MSVC 2019/2022, it requires the compiler flag
/Zc:preprocessor.

This version doesn't require that so use it for now. The MSVC is used to
compile the CUDA code and AJA wrapper so not to complicate the things now.

This syntax is supported for both GNU and MSVC:
1. https://stackoverflow.com/a/78185169
2. https://gcc.gnu.org/onlinedocs/cpp/Variadic-Macros.html

refer to GH-375
2024-10-21 15:04:55 +02:00
Martin Pulec
60592ffbf7 vcap/ndi: ndi_disp_convert_Y416_to_PA16 fix 2024-10-21 15:04:54 +02:00
Martin Pulec
6eb681070f fix vc_copylineRG48toY216
incorrectly braced

Actually not obvious until 2f450060  (2024-09-24) in master because the
chroma x1.5 was used but clamped, which has somehow hidden that.
2024-10-21 15:04:54 +02:00
Martin Pulec
7c6681c016 macOS build: fixed crashing build
the build fails after switch to macos-13 on manual page generation:
```
dyld[39415]: Symbol not found: _glfwCreateWindow
  Referenced from: <2CA04B35-6318-3824-91FA-664E963F3C86> /Users/runner/work/UltraGrid/UltraGrid/bin/uv
  Expected in:     <no uuid> unknown
Could not obtain data from UG/reflector output!
```

Please note that the corresponding error in master (from which was this
commit cherry-picked) was the following, which seems to be the same issue:
```
dyld[41003]: Symbol not found: __Z11IsRGBFormat21NTV2FrameBufferFormat
  Referenced from: <2945C378-5453-3610-9AA4-63E2723BBA5D> /Users/runner/work/UltraGrid/UltraGrid/bin/uv
  Expected in:     <no uuid> unknown
Could not obtain data from UG/reflector output!
make: *** [uv.1] Error 3
make: *** Waiting for unfinished jobs....
```

which tries to run bin/uv with --fullhelp.

(this fails only if run within the script data/make_man.sh, not when run directly)
2024-10-21 15:04:54 +02:00
Martin Pulec
b6a540c552 CI mac: use macos-13
macOS 12 is no longer supported and as Homebrew has a policy, that it
compiles packages from sources on unsupported macOSes, it is needed to
switch to newer macOS to keep reasonable build times.
2024-10-21 15:04:54 +02:00
Martin Pulec
9cc7de395b configure.ac: pkgconf compat improved
pkg.m4 macro from pkgconf since 2.3.0 aborts by default if PKG_CONFIG
is not found, which check implicitly for pkg-config. Thus set
ACTION-IF-NOT-FOUND to allow fallback check for pkgconf.
2024-10-21 15:04:54 +02:00
Martin Pulec
e0f844918f tx audio: warn if Reed-Solomon is inadequate
refer to GH-408
2024-10-21 15:04:53 +02:00
Martin Pulec
068079833c aplay/alsa: warn if buffer is too short 2024-10-21 15:04:53 +02:00
Martin Pulec
6db0a9c9de vdisp/dump: fix alloc size
MIN was used by mistake, should be MAX
2024-10-21 15:04:53 +02:00
Martin Pulec
ccdf0afd10 vc_copylineR12LtoRG48: do not override output buf
In non-native R12L lengths (width%8!=0). do not override the output
last block.
2024-10-21 15:04:53 +02:00
Martin Pulec
4db099d202 video_pattern_generator/interlaced: check width 2024-10-21 15:04:53 +02:00
Martin Pulec
b5a2138ac6 video_pattern_generator/interlaced: alloc inc MAX_PADDING 2024-10-21 15:04:52 +02:00