Commit Graph

7080 Commits (04d1f04bd3bea27f3e60f5ce8a4cb9af394d9a90)

Author SHA1 Message Date
Cole c7e77024ea UI: Remove Twitch from MultichannelWarning message 2019-08-03 14:08:15 -07:00
SCG82 5bc1b3bc76 libobs: Add missing pixel format to format_is_yuv and get_video_format_name 2019-08-03 05:42:30 -07:00
jp9000 deaeb5e632 win-dshow: Use unbuffered by default for MJPEG
Due to the recent change of using FFmpeg to decode MJPEG, MJPEG was
getting included in the delayed device check.  This fixes that so that
it doesn't.  MJPEG can decode in real time.
2019-07-29 20:34:13 -07:00
jp9000 cd6e9e34b8 win-dshow: Clarify function name/purpose
IsEncoded is meant to be used to indicated delayed devices, such as
older Elgato devices, or Hauppauge device.  Devices that use H264 and
have a 800+ millisecond latency.  This changes the function name to
better indicate that.
2019-07-29 20:34:13 -07:00
jp9000 68a5a40df9 libobs, obs-ffmpeg, win-dshow: Fix FFmpeg 4.0 deprecation
Fixes FFmpeg 4.0 deprecation warnings.
2019-07-29 20:34:13 -07:00
jp9000 a3fface27f win-dshow, obs-ffmpeg: Add hardware decoding support
Fixes hardware decoding support and updates it to FFmpeg 4.0.
2019-07-29 20:34:13 -07:00
jpark37 0e12d8189c libobs: Add GPU timestamp query support
This change only wraps the functionality. I have rough code to exercise
the the query functionality, but that part is not really clean enough to
submit.
2019-07-27 13:31:07 -07:00
Michael Fabian 'Xaymar' Dirks bd8ead2d4b UI: Partially revert PR #1979
This broke support for various filters, sources and encoders and should not
have been merged as it is.
2019-07-27 19:21:46 +02:00
jpark37 30979a54fe UI: Fix Lanczos label with correct sample count 2019-07-27 08:39:00 -07:00
jpark37 9aacc99b3e libobs: Separate textures for YUV output, fix chroma
The shaders to pack YUV information into the same texture were rather
complicated and suffering precision issues. Breaking them up into
separate textures makes the shaders much simpler and avoids having to
compute large integer offsets. Unfortunately, the code to handle
multiple textures is not as pleasant, but at least the NV12 rendering
path is no longer separate.

In addition, write chroma samples to "standard" offsets. For I444,
there's no difference, but I420/NV12 formats now have chroma shifted to
the left as 4:2:0 is shown in the H.264 specification.

Intel GPA, SetStablePowerState, Intel HD Graphics 530

Expect speed incrase:
I420: 844 us -> 493 us (254 us + 190 us + 274 us)
I444: 837 us -> 747 us (258 us + 276 us + 272 us)
NV12: 450 us -> 368 us (319 us + 168 us)

Expect no change:
NV12 (HW): 580 (481 us + 166 us) us -> 588 us (468 us + 247 us)
RGB: 359 us -> 387 us

Fixes https://obsproject.com/mantis/view.php?id=624
Fixes https://obsproject.com/mantis/view.php?id=1512
2019-07-26 23:21:41 -07:00
Gol-D-Ace baddca2536 CI: Only download Qt if it doesn't exist already 2019-07-27 06:52:47 +02:00
jpark37 f27ece50c9 libobs: Optimize lanczos shader, remove scaling
Use bilinear filtering to reduce 36 taps to 25 for the regular path.
This works because the middle weights are always between 0 and 1,
allowing texture coordinates to be placed strategically to sample
correct ratios. I'm not sure about the undistort path, so I've left that
alone.

Also remove scaling added in #526, after which weight normalization is
unnecessary. If we want to use or invent an algorithm with alternate
downscaling properties, that's fine, but I don't think we should change
Lanczos scaling to mean something it's not. The scale implementation was
also seen not working when applied directly to scene items because of
assumptions made about the projection matrix.

Intel GPA, SetStablePowerState, Intel HD Graphics 530, D3D11
644x478 -> 1323x1080: 3890 us -> 3401 us
1920x1080 -> 1280x720: 2555 us -> 2261 us
2019-07-26 20:45:33 -07:00
Jim 62c7e00d16
Merge pull request #1993 from jpark37/faster-bicubic
Optimize bicubic shader
2019-07-26 00:36:19 -07:00
jp9000 363d28815f obs-browser: Update to 2.5.0 (audio capture support) 2019-07-26 00:14:09 -07:00
jp9000 aee84cc743 libobs: Add "monitoring by default" source cap
(This also modifies the UI module)

Adds the ability for a source to monitor by default.  This is mainly
aimed at browser sources, so that they do not stop outputting audio by
default like they used to.
2019-07-26 00:05:14 -07:00
Jim 916d89a73b
Merge pull request #1930 from jpark37/ffmpeg-mjpeg
Add planar 4:2:2 video support; Use FFmpeg MJPEG decoder instead of DirectShow
2019-07-25 23:22:18 -07:00
jpark37 2721ac4a85 libobs: Optimize bicubic shader
Use bilinear filtering to reduce 16 taps to 9 for the regular path. This
works because the middle weights are always between 0 and 1, allowing
texture coordinates to be placed strategically to sample correct ratios.
I'm not sure about the undistort path, so I've left that alone.

Also remove weight normalization. I'm not seeing that make even a small
difference.

Intel HD Graphics 530, D3D11
644x478 -> 1323x1080: 1790 us -> 1279 us
1920x1080 -> 1280x720: 1301 us -> 918 us

References:
https://entropymine.com/imageworsener/bicubic/
http://vec3.ca/bicubic-filtering-in-fewer-taps/
http://developer.download.nvidia.com/books/HTML/gpugems/gpugems_ch24.html
2019-07-25 22:21:11 -07:00
jpark37 2f286b81d9 libobs: Default sampler sometimes unset for GL
When mixing sampling with raw loads in a shader, ending a shader with a
load would case the default sampler to become unset for OpenGL. Instead,
initialize with no sampler, and only set if there is a sampler.
2019-07-25 21:54:23 -07:00
jpark37 2c6aac32c8 libobs: Fix benign typo 2019-07-25 21:54:23 -07:00
Jim e153dc3777
Merge pull request #1943 from glikely/master
UI: Add option to warn on stop recording
2019-07-25 21:47:15 -07:00
James Park 0e7eec8f2d win-dshow: Use FFmpeg for MJPEG decompression
Measured lower CPU usage and latency than default DirectShow filter.
Tested with Logitech BRIO camera at 4K, 30 FPS.
2019-07-25 20:11:44 -07:00
James Park 37f663a789 libobs: obs-ffmpeg: win-dshow: Planar 4:2:2 video
This format has been seen when using FFmpeg MJPEG decompression.
2019-07-25 20:11:37 -07:00
Jim f54fda4678
Merge pull request #1991 from jpark37/gl-improvements
GL support improvements
2019-07-25 16:22:01 -07:00
Jim 173eec0d6e
Merge pull request #1978 from jpark37/defer-yuv-multiply
libobs: Rework RGB to YUV conversion
2019-07-25 16:20:48 -07:00
Michael Fabian 'Xaymar' Dirks dc150ce0eb UI: Pass QColor as reference 2019-07-24 18:49:03 +02:00
Michael Fabian 'Xaymar' Dirks c5928bff4a win-capture: Don't leak dynamic library references 2019-07-24 18:26:45 +02:00
Michael Fabian 'Xaymar' Dirks 4159477e43 libobs: Don't leak dynamic library references 2019-07-24 18:26:44 +02:00
Michael Fabian 'Xaymar' Dirks 005921c67d libobs: Return NULL if there is no get_properties callback
If there's no get_properties function, return NULL instead of uninitialized memory.
2019-07-24 18:26:44 +02:00
Michael Fabian 'Xaymar' Dirks 00298fd4f1 win-wasapi: Catch by reference 2019-07-24 18:26:44 +02:00
Michael Fabian 'Xaymar' Dirks 3b0238fc11 UI: Catch by reference 2019-07-24 18:26:44 +02:00
Michael Fabian 'Xaymar' Dirks 1154c01266 libobs-d3d11: Catch be reference 2019-07-24 18:26:43 +02:00
Michael Fabian 'Xaymar' Dirks b31e93d59e libobs: Supress clang-tidy warning clang-tidy-cert-flp30-c 2019-07-24 18:26:43 +02:00
Clayton Groeneveld d9a4842604 UI: Stop recording when disk space is low
This stops the recording when disk space is low. It is currently
set to stop when disk space is below 500 MB.
2019-07-23 15:28:29 -05:00
jpark37 a7ac33488c libobs-opengl: Remove unused VERTEXID code
I think this was leftover from an abandoned approach.
2019-07-23 08:33:49 -07:00
jpark37 df59046050 libobs-opengl: Support gl_FragCoord and cull unused interpolants 2019-07-23 08:31:57 -07:00
jpark37 ce9e4dd4d2 libobs-opengl: Fix GS_R8G8 values 2019-07-23 08:29:54 -07:00
Richard Stanway 1684b9bddb
UI: Add links for Facebook stream key 2019-07-23 00:47:18 +02:00
Clayton Groeneveld ae7887704a obs-transitions: Fix suffix with stinger transition 2019-07-22 15:24:30 -05:00
Jim d396b2ec15
Merge pull request #1977 from cg2121/adv-audio-styling
UI: Improve look of adv audio control dialog
2019-07-22 02:59:58 -07:00
Jim 37072e6c97
Merge pull request #1932 from Chiitoo/libdir
cmake: Install 'libobs.pc' under the correct 'libdir'
2019-07-22 02:45:22 -07:00
Jim c36a86bb46
Merge pull request #1973 from restreamio/master
UI: Add Restream integration: stream info widget, channels widget
2019-07-22 01:33:59 -07:00
Jonathan Baecker 19464e6552 UI: Add ability to disable hotkeys when not in focus 2019-07-22 01:20:12 -07:00
jp9000 985772d915 UI: Fix param logic of ResetHotkeyState calls
The parameter "inFocus" was being given the opposite of what the name
implies: it was being set to false when in focus, and true when not in
focus.  This fixes that confusion.
2019-07-22 01:17:29 -07:00
jpark37 2656bf0a90 libobs: Rework RGB to YUV conversion
RGB to YUV converison was previously baked into every scale shader, but
this work has been moved to the YUV packing shaders. The scale shaders
now write RGBA instead. In the case where base and output resolutions
are identical, the render texture is forwarded directly to the YUV pack
step, skipping an entire fullscreen pass.

Intel GPA, SetStablePowerState, Intel HD Graphics 530, NV12

1920x1080, Before:
RGBA -> UYVX: ~321 us
UYVX -> Y: ~480 us
UYVX -> UV: ~127 us

1920x1080, After:
[forward render texture]
RGBA -> Y: ~487 us
RGBA -> UV: ~131 us

1920x1080 -> 1280x720, Before:
RGBA -> UYVX: ~268 us
UYVX -> Y: ~209 us
UYVX -> UV: ~57 us

1920x1080 -> 1280x720, After:
RGBA -> RGBA (rescale): ~268 us
RGBA -> Y: ~210 us
RGBA -> UV: ~58 us
2019-07-22 01:12:35 -07:00
jpark37 e5b004fd48 libobs: Remove YUV transformation on CPU
This code path does not appear to be used. Breakpoint-inspected all four
output formats I420/I444/NV12/RGB, and they are all behaving as they
should.
2019-07-22 01:12:01 -07:00
jp9000 9ca1e85f7d UI: Fix hotkeys working even when disabled in focus
Fixes a bug where the hotkey inject would trigger hotkeys despite
hotkeys being disabled when in focus.
2019-07-22 01:11:34 -07:00
Grant Likely 4e3ce938f2 UI: Add option to warn on stop recording
OBS has an option to warn before stopping a stream, but it doesn't have
a similar warning for recording. This can result in a recording being
unintentionally stopped.

Add an option to warn when the "Stop Recording" button is pressed.

Note: While OBS also has an option to warn on stream start, this
patch purposefully does not add similar warn on recording start option.
This is because accidentally starting to record isn't risky in the same
way that accidentally starting to stream is.
2019-07-21 22:57:31 -07:00
Jim 887857b71d
Merge pull request #1976 from cg2121/output-timer-pause
frontend-tools: Add option to pause output timer when rec is paused
2019-07-21 22:48:13 -07:00
Jim 1831165c5e
Merge pull request #1969 from cg2121/simplify-code
UI: Simplify resize output code
2019-07-21 22:33:46 -07:00
Jim 8ff87ef9e1
Merge pull request #1968 from redcrazyheart/addstripchatsources
rtmp-services: Add Stripchat streaming service
2019-07-21 22:32:58 -07:00