Call macGlutInit just when GL context is requested. This slightly
improves a commit 887da0882. This causes that when macOS is headless
(eg. no logged user), glutInit (that will unconditionally fail) is
called no only if needed, not always.
The code taken from SDK samples was not correct in UltraGrid - we cannot
declare framebuffer as not RGB provided that it is in a RGB (we do not
convert by ourselves). Thus the output is set to the same codec as the
framebuffer.
Removed assertion to check standard pitch - non-standard ones should be
already supported. This allows decoding to framebuffers, where pitch
is not equal to line width, i. e. also for tiled video assembled to one
buffer.
Do not rename main thread since it renames a process as well and then it
doesn't respond to eg. killall as expected.
+ name the display thread (run if display worker doesn't require to be
run in main thread)
This is a re-implementation of commit 57f215b554 to support the case that you
have a single device but multiple tiles, using 3D mode, as well as the case
where you have multiple non-3D devices and multiple tiles.
Call glutInit for macOS. This is rather a workaround to fix a problem
when running 'uv --capabilities' with RTDXT and Syphon. Initialization
of GLUT in Syphon then fails because glutInit is skipped since NSApp is
a non-NULL (from initialization of GL context). Further GLUT call then
fail.
Do not run the display worker in the main thread if not needed.
This would allow to run a custom mainloop (eg. from Syphon) while being able
to run a display that doesn't need to be run in the main thread.
Some modules on some hardware need considerable time to finish
(SVT HEVC ~8s, AV1 >30s) so do not force quit after fixed amount
of time. Instead display only a warning and let use kill UG manually
if needed. Since previous commit, SIGINT causes usual termination.
The HEVC/AV1 SVT encoders default to open GOP which is unsuitable for
UltraGrid - unable to refresh from the middle of the stream. Even
playback from the start won't work (because the first frame is
"consumed" by color space probe).