Commit Graph

6715 Commits

Author SHA1 Message Date
Martin Pulec
069869efcb screen_win: use generic FPS indicator
doesn't have own
2022-10-19 16:00:34 +02:00
Martin Pulec
db75326b32 screen_win: opt to filter unregister 2022-10-19 16:00:34 +02:00
Martin Pulec
f2a4de3dd8 indent_paragraph fix
Fixed not counting the start of the line after the wrap, as it can be
clearly seen on this string:

"X yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy zzzzzzzzzzzzzzz"

where should be every ' ' replaced by '\n' but the second wasn't.
2022-10-19 16:00:34 +02:00
Martin Pulec
055194c6d5 screen_win: request registration of DShow module
Try to install the DShow module with elevated privileges (doesn't work
with normal on most Windows instances, perhaps given by settings).

If the elevated registration succeeds, do not unregister that (otherwise
next time user would need to confirm that again).
2022-10-19 16:00:34 +02:00
Martin Pulec
24647eeffc screen_win: refactor
+ free loaded library in case of error
+ report also different errors than E_ACCESSDENIED (and print that the
  error was access denied if so)
2022-10-19 16:00:34 +02:00
Martin Pulec
507b48c061 screen_win: use system screen-capture-recorder
Use system-registered screen-capture-recorder if available.

THe current way (if screen-capture-recorder is not installed) relies on
pushing a DLL into system but in current W10 (21H2) version, this is
prohibited to a normal user.
2022-10-19 16:00:34 +02:00
Martin Pulec
49e4de595d DShow probe: set card_id early to vidcap_type
To avoid having blank device ID if device name read fails.
2022-10-19 16:00:34 +02:00
Martin Pulec
3bee13fdb5 replaced unqualified move with std::move
to avoid this clang warning: https://reviews.llvm.org/D119670
2022-10-19 16:00:31 +02:00
Martin Piatka
95b9157134 holepunch: simplify config parsing
Now it doesn't modify argv
2022-10-19 14:55:40 +02:00
Martin Piatka
9f3b891309 holepunch: pass addresses as buffers in config 2022-10-19 14:06:26 +02:00
Martin Piatka
d7495d070d holepunch: Add log messages
see GH-260
2022-10-19 12:25:51 +02:00
Martin Piatka
8d6b17522d tools/ipc_frame_unix: Initialize winsock 2022-10-18 14:15:06 +02:00
Martin Piatka
f5c69aa486 GUI: control socket: reset socket before new connection 2022-10-18 13:15:12 +02:00
Martin Piatka
1378bad9ff GUI: Remove now unused random port helper 2022-10-18 13:00:57 +02:00
Martin Piatka
894dbdcc65 GUI: Use "0" for a random port 2022-10-18 13:00:57 +02:00
Martin Piatka
ba7c40a4be GUI: Use controlPort class 2022-10-18 13:00:56 +02:00
Martin Piatka
6dea418cb1 GUI: vuMeter: Use the controlPort class for ug communication
Should make the meter much quikcer to start reporiting volumes after
start
2022-10-18 13:00:56 +02:00
Martin Piatka
f3ce37a188 tools/astat: Standalone parsing func 2022-10-18 12:11:14 +02:00
Martin Piatka
97cba4d2d3 GUI: Control port class 2022-10-18 12:11:13 +02:00
Martin Piatka
3acc296291 control_socket: Print listening port
This is useful when binding to a random port (--control-port 0)
2022-10-18 12:11:10 +02:00
Martin Piatka
85019bbec0 GUI: Factor log line processing into function 2022-10-18 12:06:04 +02:00
Martin Piatka
27bd5f9148 GUI: func for reading preview process output 2022-10-18 12:06:03 +02:00
Martin Pulec
1e50d51e11 replaced unqualified move with std::move
to avoid this clang warning: https://reviews.llvm.org/D119670
2022-10-18 09:21:50 +02:00
Martin Pulec
5dda4c3778 host: documented --capabilities vidcap 2022-10-18 08:24:17 +02:00
Martin Pulec
7d47e27a02 main.cpp: print UG summary first again
This partially reverts b1537dd7c by checking whether help should or
should not be shown.
2022-10-18 08:23:20 +02:00
Martin Pulec
5be4e17880 main: start audio later
moved audio initialization after printing summary and printing
capabilities:
- messages from audio don't interleaved with the UG summary
- when printing capabilities, it is not needed to start audio (which
  would do nothing)
2022-10-18 08:23:19 +02:00
Martin Pulec
b1020bd77b added --param audio-dec-format
Forces decoded audio format.

Mainly for testing but can be used also in case of problems (some format
doesn't work correctly although device claims to support that).
2022-10-18 08:23:19 +02:00
Martin Pulec
762216f579 split setting audio capture format from parsing
Since it was seting global variables, the advantage is also that
set_audio_capture_format is now simplier.
2022-10-18 08:23:19 +02:00
Martin Pulec
b07ce59da7 don't return failure on '--audio-capture-format help' 2022-10-18 08:23:19 +02:00
Martin Pulec
aeadbe0b62 main parse options: return 0 on success
follow common pattern: 0 - success; >1 also success (but something
different); -1 error (here (-error) that should be returned from main)
2022-10-18 08:23:19 +02:00
Martin Pulec
04acaf7d69 removed needlessly added sys/time.h include
this is already included via tv.h
2022-10-18 08:23:06 +02:00
Martin Pulec
2d69e343ac added vc_copylineV210toY416
+ fixed description of v210 codec in types.h
2022-10-17 15:11:08 +02:00
Martin Pulec
2b8ab0f82b vc_copylineV210toY216: fixes
- fixed wrong conversion to (Y416 instead of Y216)
- bad mask (0x3FU instead of 0x3FFU)
+ simplified
2022-10-17 15:11:07 +02:00
Martin Pulec
c132fcc9fe removed gettimeofday win32 replacement
The replacement was recently (since 6dfd098d) used even despite the
built-in has been implemented. The replacement was there because it
has supposedly better precision than the built-in. But since it is
no longer true (if it ever was), it is removed.

Note: there is also timespec_get (or UG wrapper get_time_in_ns) that can
be used in recent code instead of POSIX gettimeofday.
2022-10-13 12:15:40 +02:00
Martin Pulec
97d365af28 tv.h: replaced wrong ifdef
struct timeval definition is needed for the original functions
regardless timespec_get is present or not

On the other hand, do not include it with files compiled by MSVC
(prominently AJA).
2022-10-13 12:15:38 +02:00
Martin Pulec
344e49ff15 dshow: use generic FPS indicator 2022-10-13 11:31:04 +02:00
Martin Pulec
eae114cf6d color_out.cpp: missing include <memory> 2022-10-13 10:34:41 +02:00
Martin Pulec
e94edb767b CI: updated actions/{cache,checkout} to latest ver
https://github.blog/changelog/2022-09-22-github-actions-all-actions-will-begin-running-on-node16-instead-of-node12/
2022-10-13 09:36:47 +02:00
Martin Pulec
05aea72a3c moved some functions from misc to text
moved text-related functions from utils/misc to utils/text
2022-10-13 09:16:16 +02:00
Martin Pulec
17056959f6 dummy: documentation
+ added indent_paragraph function
2022-10-13 09:16:07 +02:00
Martin Pulec
d254b22b1b main: parsing options simplified
moved some huge branches to function
2022-10-12 13:11:27 +02:00
Martin Pulec
e6f7af5b1b main: option parsing - simplify '-c'
Do not handle help, already handled in module and UG summary is no
longer displayed prior to it (see 9e39ce04).
2022-10-12 13:11:27 +02:00
Martin Pulec
b1537dd7c0 main.cpp: print configuration summary later
This allows showing modules help without the summary being needlessly shown.
2022-10-12 13:11:27 +02:00
Martin Pulec
0ccfba3f39 turn some initialization messages to debug
Those messages have nearly no information value (RTP session ID) or are
redundant (display/vidcap name; perhaps only to notice initialization
success). May be perhaps removed in future.
2022-10-12 13:11:26 +02:00
Martin Pulec
ef5d050b09 dummy: rewritten to C 2022-10-12 13:11:18 +02:00
Martin Pulec
7d62474c77 print_module_usage: align key to right
It perhaps looks better to avoid potentially huge spaces between option
and description.
2022-10-12 12:05:24 +02:00
Martin Pulec
3370489e50 dummy: use print_module_usage 2022-10-12 12:05:24 +02:00
Martin Pulec
42b3fc1558 common handling of modules printing usage
Return a macro ((void *) 1) from modules returning pointer to signalize
that help was printed (for correct UG return value). This replaces the
old behavior when module class specific value (eg. &display_init_noerr)
was returned.
2022-10-12 12:05:19 +02:00
Martin Pulec
e687bd35ac AppRun: added libva-wayland to preload
currently will not be used by CI because U18.04 doesn't link that
library
2022-10-11 16:22:54 +02:00
Martin Pulec
387276b304 GLFW: print error if init fails
register error calback prior to glfwInit
2022-10-11 15:04:45 +02:00