Projects
Multimedia
obs-studio
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 62
View file
obs-studio.changes
Changed
@@ -1,4 +1,22 @@ ------------------------------------------------------------------- +Wed Feb 27 21:36:03 UTC 2019 - jimmy@boombatower.com + +- Update to version 23.0.1: + * obs-browser: Fix widgets being initially blank on high-DPI + * libobs: Update version to 23.0.1 + * libobs-d3d11: Disable NV12 textures if NVENC unavailable + * UI: Don't show "What's New" for new users + * UI: Don't delete auto-remux file (just in case) + * libobs-d3d11: Blacklist certain adapters from NV12 + * UI: Do not allow post-GPU rescaling on gpu encoders + * libobs: Add func to get encoder caps by encoder pointer + * obs-ffmpeg: Fix bitrate being set on NVENC CQP/lossless + * UI: Fix Mixer allowing endless login retries + * UI: Make workaround for Logitech plugin hard lock + * UI: Check CEF available when loading auth + * libobs-d3d11: Improve check for NV12 texture support + +------------------------------------------------------------------- Tue Feb 26 00:11:02 UTC 2019 - Jimmy Berry <jimmy@boombatower.com> - Include pkg-config (.pc) file in devel subpackage.
View file
obs-studio.spec
Changed
@@ -1,5 +1,5 @@ Name: obs-studio -Version: 23.0.0 +Version: 23.0.1 Release: 0 Summary: A recording/broadcasting program Group: Productivity/Multimedia/Video/Editors and Convertors
View file
_service
Changed
@@ -1,7 +1,7 @@ <services> <service name="tar_scm" mode="disabled"> <param name="versionformat">@PARENT_TAG@</param> - <param name="revision">refs/tags/23.0.0</param> + <param name="revision">refs/tags/23.0.1</param> <param name="url">git://github.com/jp9000/obs-studio.git</param> <param name="scm">git</param> <param name="changesgenerate">enable</param>
View file
_servicedata
Changed
@@ -1,6 +1,6 @@ <servicedata> <service name="tar_scm"> <param name="url">git://github.com/jp9000/obs-studio.git</param> - <param name="changesrevision">8181f776093bde3d078709e4b5d50cba50cad92c</param> + <param name="changesrevision">f2d7f5b2e713266138df656121da35ff89407991</param> </service> </servicedata>
View file
obs-studio-23.0.0.tar.xz/UI/api-interface.cpp -> obs-studio-23.0.1.tar.xz/UI/api-interface.cpp
Changed
@@ -20,6 +20,10 @@ void EnumProfiles(function<bool (const char *, const char *)> &&cb); void EnumSceneCollections(function<bool (const char *, const char *)> &&cb); +extern volatile bool streaming_active; +extern volatile bool recording_active; +extern volatile bool replaybuf_active; + /* ------------------------------------------------------------------------- */ template<typename T> struct OBSStudioCallback { @@ -232,12 +236,7 @@ bool obs_frontend_streaming_active(void) override { - bool active; - QMetaObject::invokeMethod(main, - "StreamingActive", - WaitConnection(), - Q_RETURN_ARG(bool, active)); - return active; + return os_atomic_load_bool(&streaming_active); } void obs_frontend_recording_start(void) override @@ -252,12 +251,7 @@ bool obs_frontend_recording_active(void) override { - bool active; - QMetaObject::invokeMethod(main, - "RecordingActive", - WaitConnection(), - Q_RETURN_ARG(bool, active)); - return active; + return os_atomic_load_bool(&recording_active); } void obs_frontend_replay_buffer_start(void) override @@ -277,12 +271,7 @@ bool obs_frontend_replay_buffer_active(void) override { - bool active; - QMetaObject::invokeMethod(main, - "ReplayBufferActive", - WaitConnection(), - Q_RETURN_ARG(bool, active)); - return active; + return os_atomic_load_bool(&replaybuf_active); } void *obs_frontend_add_tools_menu_qaction(const char *name) override
View file
obs-studio-23.0.0.tar.xz/UI/auth-mixer.cpp -> obs-studio-23.0.1.tar.xz/UI/auth-mixer.cpp
Changed
@@ -44,7 +44,7 @@ { } -bool MixerAuth::GetChannelInfo() +bool MixerAuth::GetChannelInfo(bool allow_retry) try { std::string client_id = MIXER_CLIENTID; deobfuscate_str(&client_id[0], MIXER_HASH); @@ -148,8 +148,8 @@ * it'll be an empty stream key usually. So treat empty stream key as * an error. */ if (key_suffix.empty()) { - if (RetryLogin()) { - return GetChannelInfo(); + if (allow_retry && RetryLogin()) { + return GetChannelInfo(false); } throw ErrorInfo("Auth Failure", "Could not get channel data"); } @@ -213,6 +213,8 @@ void MixerAuth::LoadUI() { + if (!cef) + return; if (uiLoaded) return; if (!GetChannelInfo()) @@ -261,6 +263,9 @@ bool MixerAuth::RetryLogin() { + if (!cef) + return false; + OAuthLogin login(OBSBasic::Get(), MIXER_AUTH_URL, false); cef->add_popup_whitelist_url("about:blank", &login); @@ -278,6 +283,10 @@ std::shared_ptr<Auth> MixerAuth::Login(QWidget *parent) { + if (!cef) { + return nullptr; + } + OAuthLogin login(parent, MIXER_AUTH_URL, false); cef->add_popup_whitelist_url("about:blank", &login); @@ -296,7 +305,7 @@ } std::string error; - if (auth->GetChannelInfo()) { + if (auth->GetChannelInfo(false)) { return auth; }
View file
obs-studio-23.0.0.tar.xz/UI/auth-mixer.hpp -> obs-studio-23.0.1.tar.xz/UI/auth-mixer.hpp
Changed
@@ -19,7 +19,7 @@ virtual void SaveInternal() override; virtual bool LoadInternal() override; - bool GetChannelInfo(); + bool GetChannelInfo(bool allow_retry = true); virtual void LoadUI() override;
View file
obs-studio-23.0.0.tar.xz/UI/auth-oauth.cpp -> obs-studio-23.0.1.tar.xz/UI/auth-oauth.cpp
Changed
@@ -26,6 +26,10 @@ : QDialog (parent), get_token (token) { + if (!cef) { + return; + } + setWindowTitle("Auth"); setMinimumSize(400, 400); resize(700, 700); @@ -66,6 +70,15 @@ delete cefWidget; } +int OAuthLogin::exec() +{ + if (cefWidget) { + return QDialog::exec(); + } + + return QDialog::Rejected; +} + void OAuthLogin::urlChanged(const QString &url) { std::string uri = get_token ? "access_token=" : "code=";
View file
obs-studio-23.0.0.tar.xz/UI/auth-oauth.hpp -> obs-studio-23.0.1.tar.xz/UI/auth-oauth.hpp
Changed
@@ -23,6 +23,8 @@ inline QString GetCode() const {return code;} inline bool LoadFail() const {return fail;} + virtual int exec() override; + public slots: void urlChanged(const QString &url); };
View file
obs-studio-23.0.0.tar.xz/UI/auth-twitch.cpp -> obs-studio-23.0.1.tar.xz/UI/auth-twitch.cpp
Changed
@@ -42,6 +42,9 @@ TwitchAuth::TwitchAuth(const Def &d) : OAuthStreamKey(d) { + if (!cef) + return; + cef->add_popup_whitelist_url( "https://twitch.tv/popout/frankerfacez/chat?ffz-settings", this); @@ -194,6 +197,8 @@ void TwitchAuth::LoadUI() { + if (!cef) + return; if (uiLoaded) return; if (!GetChannelInfo())
View file
obs-studio-23.0.0.tar.xz/UI/window-basic-main-outputs.cpp -> obs-studio-23.0.1.tar.xz/UI/window-basic-main-outputs.cpp
Changed
@@ -10,6 +10,10 @@ extern bool EncoderAvailable(const char *encoder); +volatile bool streaming_active = false; +volatile bool recording_active = false; +volatile bool replaybuf_active = false; + static void OBSStreamStarting(void *data, calldata_t *params) { BasicOutputHandler *output = static_cast<BasicOutputHandler*>(data); @@ -41,6 +45,7 @@ { BasicOutputHandler *output = static_cast<BasicOutputHandler*>(data); output->streamingActive = true; + os_atomic_set_bool(&streaming_active, true); QMetaObject::invokeMethod(output->main, "StreamingStart"); UNUSED_PARAMETER(params); @@ -56,6 +61,7 @@ output->streamingActive = false; output->delayActive = false; + os_atomic_set_bool(&streaming_active, false); QMetaObject::invokeMethod(output->main, "StreamingStop", Q_ARG(int, code), Q_ARG(QString, arg_last_error)); } @@ -65,6 +71,7 @@ BasicOutputHandler *output = static_cast<BasicOutputHandler*>(data); output->recordingActive = true; + os_atomic_set_bool(&recording_active, true); QMetaObject::invokeMethod(output->main, "RecordingStart"); UNUSED_PARAMETER(params); @@ -76,6 +83,7 @@ int code = (int)calldata_int(params, "code"); output->recordingActive = false; + os_atomic_set_bool(&recording_active, false); QMetaObject::invokeMethod(output->main, "RecordingStop", Q_ARG(int, code)); @@ -95,6 +103,7 @@ BasicOutputHandler *output = static_cast<BasicOutputHandler*>(data); output->replayBufferActive = true; + os_atomic_set_bool(&replaybuf_active, true); QMetaObject::invokeMethod(output->main, "ReplayBufferStart"); UNUSED_PARAMETER(params); @@ -106,6 +115,7 @@ int code = (int)calldata_int(params, "code"); output->replayBufferActive = false; + os_atomic_set_bool(&replaybuf_active, false); QMetaObject::invokeMethod(output->main, "ReplayBufferStop", Q_ARG(int, code)); @@ -1226,9 +1236,14 @@ "Rescale"); const char *rescaleRes = config_get_string(main->Config(), "AdvOut", "RescaleRes"); + uint32_t caps = obs_encoder_get_caps(h264Streaming); unsigned int cx = 0; unsigned int cy = 0; + if ((caps & OBS_ENCODER_CAP_PASS_TEXTURE) != 0) { + rescale = false; + } + if (rescale && rescaleRes && *rescaleRes) { if (sscanf(rescaleRes, "%ux%u", &cx, &cy) != 2) { cx = 0; @@ -1262,6 +1277,11 @@ obs_output_set_video_encoder(replayBuffer, h264Streaming); } else { + uint32_t caps = obs_encoder_get_caps(h264Recording); + if ((caps & OBS_ENCODER_CAP_PASS_TEXTURE) != 0) { + rescale = false; + } + if (rescale && rescaleRes && *rescaleRes) { if (sscanf(rescaleRes, "%ux%u", &cx, &cy) != 2) { cx = 0;
View file
obs-studio-23.0.0.tar.xz/UI/window-basic-main.cpp -> obs-studio-23.0.1.tar.xz/UI/window-basic-main.cpp
Changed
@@ -1919,12 +1919,18 @@ return; } - cef->init_browser(); - ExecuteFuncSafeBlock([] {cef->wait_for_browser_init();}); - config_set_int(App()->GlobalConfig(), "General", "InfoIncrement", info_increment); + /* Don't show What's New dialog for new users */ +#if !defined(OBS_RELEASE_CANDIDATE) || OBS_RELEASE_CANDIDATE == 0 + if (!lastVersion) { + return; + } +#endif + cef->init_browser(); + ExecuteFuncSafeBlock([] {cef->wait_for_browser_init();}); + QDialog *dlg = new QDialog(this); dlg->setAttribute(Qt::WA_DeleteOnClose, true); dlg->setWindowTitle("What's New");
View file
obs-studio-23.0.0.tar.xz/UI/window-remux.cpp -> obs-studio-23.0.1.tar.xz/UI/window-remux.cpp
Changed
@@ -946,7 +946,6 @@ queueModel->finishEntry(success); if (autoRemux && autoRemuxFile != "") { - QFile::remove(autoRemuxFile); QTimer::singleShot(3000, this, SLOT(close())); }
View file
obs-studio-23.0.0.tar.xz/libobs-d3d11/d3d11-subsystem.cpp -> obs-studio-23.0.1.tar.xz/libobs-d3d11/d3d11-subsystem.cpp
Changed
@@ -18,6 +18,8 @@ #include <cinttypes> #include <util/base.h> #include <util/platform.h> +#include <util/dstr.h> +#include <util/util.hpp> #include <graphics/matrix3.h> #include "d3d11-subsystem.hpp" @@ -227,6 +229,21 @@ D3D_FEATURE_LEVEL_9_3, }; +static const char *blacklisted_nv12_geforce_gpus[] = { + "8100", + "8200", + "8300", + "8400", + "8500", + "8600", + "8800", + "9300", + "9400", + "9500", + "9600", + "9800" +}; + void gs_device::InitDevice(uint32_t adapterIdx) { wstring adapterName; @@ -244,11 +261,10 @@ adapterName = (adapter->GetDesc(&desc) == S_OK) ? desc.Description : L"<unknown>"; - char *adapterNameUTF8; + BPtr<char> adapterNameUTF8; os_wcs_to_utf8_ptr(adapterName.c_str(), 0, &adapterNameUTF8); blog(LOG_INFO, "Loading up D3D11 on adapter %s (%" PRIu32 ")", - adapterNameUTF8, adapterIdx); - bfree(adapterNameUTF8); + adapterNameUTF8.Get(), adapterIdx); hr = D3D11CreateDevice(adapter, D3D_DRIVER_TYPE_UNKNOWN, NULL, createFlags, featureLevels, @@ -258,19 +274,69 @@ if (FAILED(hr)) throw UnsupportedHWError("Failed to create device", hr); - ComQIPtr<ID3D11Device1> d3d11_1(device); - if (!!d3d11_1) { - D3D11_FEATURE_DATA_D3D11_OPTIONS opts = {}; - hr = d3d11_1->CheckFeatureSupport( - D3D11_FEATURE_D3D11_OPTIONS, - &opts, sizeof(opts)); - if (SUCCEEDED(hr)) { - nv12Supported = !!opts.ExtendedResourceSharing; + blog(LOG_INFO, "D3D11 loaded successfully, feature level used: %u", + (unsigned int)levelUsed); + + /* ---------------------------------------- */ + /* check for nv12 texture output support */ + + nv12Supported = false; + bool geforce = astrstri(adapterNameUTF8, "geforce") != nullptr; + bool nvidia = astrstri(adapterNameUTF8, "nvidia") != nullptr; + + /* don't use on blacklisted adapters */ + if (geforce) { + for (const char *old_gpu : blacklisted_nv12_geforce_gpus) { + if (astrstri(adapterNameUTF8, old_gpu) != nullptr) { + return; + } } } - blog(LOG_INFO, "D3D11 loaded successfully, feature level used: %u", - (unsigned int)levelUsed); + /* Disable NV12 textures if NVENC not available, just as a safety + * measure */ + if (nvidia) { + HMODULE nvenc = LoadLibraryW((sizeof(void*) == 8) + ? L"nvEncodeAPI64.dll" + : L"nvEncodeAPI.dll"); + if (!nvenc) { + return; + } + } + + ComQIPtr<ID3D11Device1> d3d11_1(device); + if (!d3d11_1) { + return; + } + + /* needs to support extended resource sharing */ + D3D11_FEATURE_DATA_D3D11_OPTIONS opts = {}; + hr = d3d11_1->CheckFeatureSupport( + D3D11_FEATURE_D3D11_OPTIONS, + &opts, sizeof(opts)); + if (FAILED(hr) || !opts.ExtendedResourceSharing) { + return; + } + + /* needs to support the actual format */ + UINT support = 0; + hr = device->CheckFormatSupport( + DXGI_FORMAT_NV12, + &support); + if (FAILED(hr)) { + return; + } + + if ((support & D3D11_FORMAT_SUPPORT_TEXTURE2D) == 0) { + return; + } + + /* must be usable as a render target */ + if ((support & D3D11_FORMAT_SUPPORT_RENDER_TARGET) == 0) { + return; + } + + nv12Supported = true; } static inline void ConvertStencilSide(D3D11_DEPTH_STENCILOP_DESC &desc,
View file
obs-studio-23.0.0.tar.xz/libobs/obs-config.h -> obs-studio-23.0.1.tar.xz/libobs/obs-config.h
Changed
@@ -41,7 +41,7 @@ * * Reset to zero each major or minor version */ -#define LIBOBS_API_PATCH_VER 0 +#define LIBOBS_API_PATCH_VER 1 #define MAKE_SEMANTIC_VERSION(major, minor, patch) \ ((major << 24) | \
View file
obs-studio-23.0.0.tar.xz/libobs/obs-encoder.c -> obs-studio-23.0.1.tar.xz/libobs/obs-encoder.c
Changed
@@ -1269,3 +1269,9 @@ struct obs_encoder_info *info = find_encoder(encoder_id); return info ? info->caps : 0; } + +uint32_t obs_encoder_get_caps(const obs_encoder_t *encoder) +{ + return obs_encoder_valid(encoder, "obs_encoder_get_caps") + ? encoder->orig_info.caps : 0; +}
View file
obs-studio-23.0.0.tar.xz/libobs/obs.h -> obs-studio-23.0.1.tar.xz/libobs/obs.h
Changed
@@ -1921,6 +1921,7 @@ EXPORT const char *obs_encoder_get_id(const obs_encoder_t *encoder); EXPORT uint32_t obs_get_encoder_caps(const char *encoder_id); +EXPORT uint32_t obs_encoder_get_caps(const obs_encoder_t *encoder); #ifndef SWIG /** Duplicates an encoder packet */
View file
obs-studio-23.0.0.tar.xz/plugins/obs-browser/panel/browser-panel-internal.hpp -> obs-studio-23.0.1.tar.xz/plugins/obs-browser/panel/browser-panel-internal.hpp
Changed
@@ -64,6 +64,8 @@ virtual void setURL(const std::string &url) override; virtual void setStartupScript(const std::string &script) override; + void Resize(); + public slots: void Init(); };
View file
obs-studio-23.0.0.tar.xz/plugins/obs-browser/panel/browser-panel.cpp -> obs-studio-23.0.1.tar.xz/plugins/obs-browser/panel/browser-panel.cpp
Changed
@@ -210,6 +210,9 @@ url, cefBrowserSettings, rqc); +#ifdef _WIN32 + Resize(); +#endif }); if (success) @@ -219,7 +222,11 @@ void QCefWidgetInternal::resizeEvent(QResizeEvent *event) { QWidget::resizeEvent(event); + Resize(); +} +void QCefWidgetInternal::Resize() +{ QSize size = this->size() * devicePixelRatio(); QueueCEFTask([this, size] () @@ -230,6 +237,8 @@ HWND hwnd = cefBrowser->GetHost()->GetWindowHandle(); SetWindowPos(hwnd, nullptr, 0, 0, size.width(), size.height(), SWP_NOMOVE | SWP_NOOWNERZORDER | SWP_NOZORDER); + SendMessage(hwnd, WM_SIZE, 0, + MAKELPARAM(size.width(), size.height())); #endif }); }
View file
obs-studio-23.0.0.tar.xz/plugins/obs-ffmpeg/jim-nvenc.c -> obs-studio-23.0.1.tar.xz/plugins/obs-ffmpeg/jim-nvenc.c
Changed
@@ -409,8 +409,6 @@ params->encodeConfig = &enc->config; params->maxEncodeWidth = voi->width; params->maxEncodeHeight = voi->height; - config->rcParams.averageBitRate = bitrate * 1000; - config->rcParams.maxBitRate = vbr ? max_bitrate * 1000 : bitrate * 1000; config->gopLength = gop_size; config->frameIntervalP = 1 + bf; h264_config->idrPeriod = gop_size; @@ -455,6 +453,9 @@ config->rcParams.constQP.qpIntra = cqp; enc->can_change_bitrate = false; + bitrate = 0; + max_bitrate = 0; + } else if (astrcmpi(rc, "vbr") != 0) { /* CBR by default */ h264_config->outputBufferingPeriodSEI = 1; h264_config->outputPictureTimingSEI = 1; @@ -463,6 +464,9 @@ : NV_ENC_PARAMS_RC_CBR; } + config->rcParams.averageBitRate = bitrate * 1000; + config->rcParams.maxBitRate = vbr ? max_bitrate * 1000 : bitrate * 1000; + /* -------------------------- */ /* profile */
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.