Overview
Request 2901 (accepted)
- Update to version 0.16.2:
* obs-ffmpeg: Fix possible NVENC crash
* UI: Use rect intersection test for validating position
* enc-amf: Update submodule to 1.3.1.0
* obs-text: Add gradient feature
* enc-amf: Fix warnings caused by warnings( push/pop )
* libobs: Update to 0.16.2
- Created by boombatower over 8 years ago
- In state accepted
- Package maintainers: boombatower and frispete
obs-studio.changes
Changed
-------------------------------------------------------------------
+Thu Sep 29 20:07:16 UTC 2016 - jimmy@boombatower.com
+
+- Update to version 0.16.2:
+ * obs-ffmpeg: Fix possible NVENC crash
+ * UI: Use rect intersection test for validating position
+ * enc-amf: Update submodule to 1.3.1.0
+ * obs-text: Add gradient feature
+ * enc-amf: Fix warnings caused by warnings( push/pop )
+ * libobs: Update to 0.16.2
+
+-------------------------------------------------------------------
Thu Sep 29 02:35:16 UTC 2016 - jimmy@boombatower.com
- Update to version 0.16.1:
obs-studio.spec
Changed
Name: obs-studio
-Version: 0.16.1
+Version: 0.16.2
Release: 0
Summary: A recording/broadcasting program
_service
Changed
<services>
<service name="tar_scm" mode="disabled">
<param name="versionformat">@PARENT_TAG@</param>
- <param name="revision">refs/tags/0.16.1</param>
+ <param name="revision">refs/tags/0.16.2</param>
<param name="url">git://github.com/jp9000/obs-studio.git</param>
<param name="scm">git</param>
<param name="changesgenerate">enable</param>
_servicedata
Changed
<servicedata>
<service name="tar_scm">
<param name="url">git://github.com/jp9000/obs-studio.git</param>
- <param name="changesrevision">6d16c51cd117a1da04d64f63562b112c38d3fd47</param>
+ <param name="changesrevision">580cfc1a95a6bb2b4ea6f002c95c630ae4542ed7</param>
</service>
</servicedata>
obs-studio-0.16.1.tar.xz/UI/obs-app.cpp -> obs-studio-0.16.2.tar.xz/UI/obs-app.cpp
Changed
return true;
}
-bool WindowPositionValid(int x, int y)
+bool WindowPositionValid(QRect rect)
{
vector<MonitorInfo> monitors;
GetMonitors(monitors);
for (auto &monitor : monitors) {
- int br_x = monitor.x + monitor.cx;
- int br_y = monitor.y + monitor.cy;
+ int left = int(monitor.x);
+ int top = int(monitor.y);
+ int right = left + int(monitor.cx);
+ int bottom = top + int(monitor.cy);
- if (x >= monitor.x && x < br_x &&
- y >= monitor.y && y < br_y)
+ if ((rect.left() - right) < 0 && (left - rect.right()) < 0 &&
+ (rect.top() - bottom) < 0 && (top - rect.bottom()) < 0)
return true;
}
obs-studio-0.16.1.tar.xz/UI/obs-app.hpp -> obs-studio-0.16.2.tar.xz/UI/obs-app.hpp
Changed
bool GetFileSafeName(const char *name, std::string &file);
bool GetClosestUnusedFileName(std::string &path, const char *extension);
-bool WindowPositionValid(int x, int y);
+bool WindowPositionValid(QRect rect);
static inline int GetProfilePath(char *path, size_t size, const char *file)
{
obs-studio-0.16.1.tar.xz/UI/window-basic-main.cpp -> obs-studio-0.16.2.tar.xz/UI/window-basic-main.cpp
Changed
restoreGeometry(byteArray);
QRect windowGeometry = normalGeometry();
- int posx = windowGeometry.x();
- int posy = windowGeometry.y();
- if (!WindowPositionValid(posx, posy)) {
+ if (!WindowPositionValid(windowGeometry)) {
QRect rect = App()->desktop()->availableGeometry();
setGeometry(QStyle::alignedRect(
Qt::LeftToRight,
obs-studio-0.16.1.tar.xz/libobs/obs-config.h -> obs-studio-0.16.2.tar.xz/libobs/obs-config.h
Changed
*
* Reset to zero each major or minor version
*/
-#define LIBOBS_API_PATCH_VER 1
+#define LIBOBS_API_PATCH_VER 2
#define MAKE_SEMANTIC_VERSION(major, minor, patch) \
((major << 24) | \
obs-studio-0.16.1.tar.xz/plugins/enc-amf/#Resources/PatchNotes.txt -> obs-studio-0.16.2.tar.xz/plugins/enc-amf/#Resources/PatchNotes.txt
Changed
*1.3.0.3*
-* Changed: Translations have been updated from CrowdIn.
\ No newline at end of file
+* Changed: Translations have been updated from CrowdIn.
+
+*1.3.1.0*
+
+* Fixed: Simple Interface will now permanently apply Presets.
+* Fixed: 'Indistinguishable' had Maximum QP at 21.
+* Changed: 'Recording' preset enables 'Frame Skipping' by default.
+* Changed: 'High Quality' Preset now uses CQP 16/19/21.
+* Changed: 'Indistinguishable' Preset now uses CQP 11/14/16.
obs-studio-0.16.1.tar.xz/plugins/enc-amf/enc-amf/Include/amd-amf.h -> obs-studio-0.16.2.tar.xz/plugins/enc-amf/enc-amf/Include/amd-amf.h
Changed
// Plugin
#include "plugin.h"
-// AMD AMF SDK
+// AMD AMF SDK
+#pragma warning( push )
+#pragma warning( disable: 4458 )
#include "core\Factory.h"
#include "components\Component.h"
#include "components\ComponentCaps.h"
#include "components\VideoEncoderVCE.h"
+#pragma warning( pop )
//////////////////////////////////////////////////////////////////////////
// Code
obs-studio-0.16.1.tar.xz/plugins/enc-amf/enc-amf/Include/enc-h264-simple.h -> obs-studio-0.16.2.tar.xz/plugins/enc-amf/enc-amf/Include/enc-h264-simple.h
Changed
#include <stdint.h>
#include <inttypes.h>
-// OBS
-#include "libobs/obs-module.h"
-#include "libobs/obs-encoder.h"
-
// Plugin
#include "plugin.h"
#include "amd-amf.h"
obs-studio-0.16.1.tar.xz/plugins/enc-amf/enc-amf/Include/plugin.h -> obs-studio-0.16.2.tar.xz/plugins/enc-amf/enc-amf/Include/plugin.h
Changed
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
*/
+
#pragma once
//////////////////////////////////////////////////////////////////////////
// Includes
#include <thread>
// Open Broadcaster Software
+#pragma warning( disable: 4201 )
#include "libobs/obs-module.h"
#include "libobs/obs-encoder.h"
#define PLUGIN_VERSION_MAJOR 1
#define PLUGIN_VERSION_MINOR 3
-#define PLUGIN_VERSION_PATCH 0
-#define PLUGIN_VERSION_BUILD 3
+#define PLUGIN_VERSION_PATCH 1
+#define PLUGIN_VERSION_BUILD 0
#define PLUGIN_VERSION_FULL (((uint64_t)PLUGIN_VERSION_MAJOR << 48ull) | ((uint64_t)PLUGIN_VERSION_MINOR << 32ull) | ((uint64_t)PLUGIN_VERSION_PATCH) | ((uint64_t)PLUGIN_VERSION_BUILD))
#define PLUGIN_VERSION_TEXT vstr(PLUGIN_VERSION_MAJOR) "." vstr(PLUGIN_VERSION_MINOR) "." vstr(PLUGIN_VERSION_PATCH) "." vstr(PLUGIN_VERSION_BUILD) "-" vstr(AMF_VERSION_MAJOR) "." vstr(AMF_VERSION_MINOR) "." vstr(AMF_VERSION_RELEASE) "." vstr(AMF_VERSION_BUILD_NUM)
#define ThrowExceptionWithAMFError(format, res, ...) {\
std::vector<char> _throwexceptionwithamferror_buf(8192);\
- sprintf(_throwexceptionwithamferror_buf.data(), format, ##__VA_ARGS__, Plugin::AMD::AMF::GetInstance()->GetTrace()->GetResultText(res), res);\
+ sprintf_s(_throwexceptionwithamferror_buf.data(), _throwexceptionwithamferror_buf.size(), format, ##__VA_ARGS__, Plugin::AMD::AMF::GetInstance()->GetTrace()->GetResultText(res), res);\
AMF_LOG_ERROR("%s", _throwexceptionwithamferror_buf.data()); \
throw new std::exception(_throwexceptionwithamferror_buf.data(), res); \
}
obs-studio-0.16.1.tar.xz/plugins/enc-amf/enc-amf/Source/amd-amf-vce-capabilities.cpp -> obs-studio-0.16.2.tar.xz/plugins/enc-amf/enc-amf/Source/amd-amf-vce-capabilities.cpp
Changed
*/
#pragma once
+
//////////////////////////////////////////////////////////////////////////
// Includes
//////////////////////////////////////////////////////////////////////////
}
// Print to log
- sprintf(msgBuf.data(),
+ sprintf_s(msgBuf.data(), msgBuf.size(),
" %4s | %8s | %11d | %8d | %11d | %9d | %7s | %4d - %4d | %7d | %3s | %10d ",
(i == 0 ? "AVC" : (i == 1 ? "SVC" : "HEVC")),
accelType,
}
// Print to log
- sprintf(msgBuf.data(),
+ sprintf_s(msgBuf.data(), msgBuf.size(),
" %4s | %6s | %4dx%4d | %4dx%4d | %3s | %5d | %7s | %12s",
(i == 0 ? "AVC" : (i == 1 ? "SVC" : "HEVC")),
(j == 0 ? "Input" : "Output"),
obs-studio-0.16.1.tar.xz/plugins/enc-amf/enc-amf/Source/amd-amf-vce.cpp -> obs-studio-0.16.2.tar.xz/plugins/enc-amf/enc-amf/Source/amd-amf-vce.cpp
Changed
static const char* computeTypeToString[] = {
"None",
"OpenCL",
- "DirectCompute",
};
static const char* surfaceFormatToString[] = {
"NV12",
obs-studio-0.16.1.tar.xz/plugins/enc-amf/enc-amf/Source/enc-h264-simple.cpp -> obs-studio-0.16.2.tar.xz/plugins/enc-amf/enc-amf/Source/enc-h264-simple.cpp
Changed
/// Preset
list = obs_properties_add_list(props, AMF_H264SIMPLE_PRESET, obs_module_text(AMF_H264SIMPLE_PRESET), OBS_COMBO_TYPE_LIST, OBS_COMBO_FORMAT_INT);
obs_property_list_add_int(list, "", -1);
- obs_property_list_add_int(list, obs_module_text(AMF_H264SIMPLE_PRESET_RECORDING), Preset_Recording);
obs_property_list_add_int(list, obs_module_text(AMF_H264SIMPLE_PRESET_TWITCH), Preset_Twitch);
obs_property_list_add_int(list, obs_module_text(AMF_H264SIMPLE_PRESET_YOUTUBE), Preset_YouTube);
+ obs_property_list_add_int(list, obs_module_text(AMF_H264SIMPLE_PRESET_RECORDING), Preset_Recording);
obs_property_list_add_int(list, obs_module_text(AMF_H264SIMPLE_PRESET_HIGHQUALTIY), Preset_HighQuality);
obs_property_list_add_int(list, obs_module_text(AMF_H264SIMPLE_PRESET_INDISTINGUISHABLE), Preset_Indistinguishable);
obs_property_list_add_int(list, obs_module_text(AMF_H264SIMPLE_PRESET_LOSSLESS), Preset_Lossless);
bool Plugin::Interface::H264SimpleInterface::ui_modified(obs_properties_t *props, obs_property_t *, obs_data_t *data) {
if (obs_data_get_int(data, AMF_H264SIMPLE_PRESET) != -1) {
switch (obs_data_get_int(data, AMF_H264SIMPLE_PRESET)) {
- case Preset_Recording: // Recording
- obs_data_set_int(data, AMF_H264SIMPLE_KEYFRAME_INTERVAL, 1);
+ case Preset_Twitch: // Twitch
+ obs_data_set_int(data, AMF_H264SIMPLE_KEYFRAME_INTERVAL, 2);
obs_data_set_int(data, AMF_H264_QUALITY_PRESET, VCEQualityPreset_Quality);
obs_data_set_int(data, AMF_H264_PROFILE, VCEProfile_High);
- obs_data_set_int(data, AMF_H264_PROFILELEVEL, VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->maxProfileLevel);
- obs_data_set_int(data, AMF_H264_RATECONTROLMETHOD, VCERateControlMethod_VariableBitrate_LatencyConstrained);
- obs_data_set_int(data, AMF_H264_QP_MINIMUM, 0);
+ obs_data_set_int(data, AMF_H264_PROFILELEVEL, VCEProfileLevel_41);
+ obs_data_set_int(data, AMF_H264_RATECONTROLMETHOD, VCERateControlMethod_ConstantBitrate);
+ obs_data_set_int(data, AMF_H264_QP_MINIMUM, 18);
obs_data_set_int(data, AMF_H264_QP_MAXIMUM, 51);
- obs_data_set_int(data, AMF_H264_BITRATE_TARGET, 10000);
- obs_data_set_int(data, AMF_H264_BITRATE_PEAK, VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->maxBitrate / 1000);
+ obs_data_set_int(data, AMF_H264_BITRATE_TARGET, 3000);
obs_data_set_bool(data, AMF_H264SIMPLE_USE_CUSTOM_BUFFER_SIZE, false);
- obs_data_set_int(data, AMF_H264_FILLERDATA, 0);
+ obs_data_set_int(data, AMF_H264_FILLERDATA, 1);
obs_data_set_int(data, AMF_H264_FRAMESKIPPING, 0);
// Advanced Properties
- obs_data_set_int(data, AMF_H264_BPICTURE_PATTERN, (VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->supportsBFrames ? 3 : 0));
- obs_data_set_int(data, AMF_H264_BPICTURE_REFERENCE, (VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->supportsBFrames ? 1 : 0));
+ obs_data_set_int(data, AMF_H264_BPICTURE_PATTERN, 0);
+ obs_data_set_int(data, AMF_H264_BPICTURE_REFERENCE, 0);
obs_data_set_int(data, AMF_H264_QP_BPICTURE_DELTA, 0);
obs_data_set_int(data, AMF_H264_QP_REFERENCE_BPICTURE_DELTA, 0);
obs_data_set_int(data, AMF_H264_DEBLOCKINGFILTER, 1);
obs_data_set_bool(data, AMF_H264SIMPLE_USE_CUSTOM_GOP_SIZE, false);
obs_data_set_int(data, AMF_H264_CABAC, -1);
break;
- case Preset_Twitch: // Twitch
+ case Preset_YouTube: // YouTube
+ // Basic Properties
obs_data_set_int(data, AMF_H264SIMPLE_KEYFRAME_INTERVAL, 2);
obs_data_set_int(data, AMF_H264_QUALITY_PRESET, VCEQualityPreset_Quality);
obs_data_set_int(data, AMF_H264_PROFILE, VCEProfile_High);
obs_data_set_int(data, AMF_H264_RATECONTROLMETHOD, VCERateControlMethod_ConstantBitrate);
obs_data_set_int(data, AMF_H264_QP_MINIMUM, 18);
obs_data_set_int(data, AMF_H264_QP_MAXIMUM, 51);
- obs_data_set_int(data, AMF_H264_BITRATE_TARGET, 3000);
+ obs_data_set_int(data, AMF_H264_BITRATE_TARGET, 6000);
obs_data_set_bool(data, AMF_H264SIMPLE_USE_CUSTOM_BUFFER_SIZE, false);
obs_data_set_int(data, AMF_H264_FILLERDATA, 1);
obs_data_set_int(data, AMF_H264_FRAMESKIPPING, 0);
obs_data_set_bool(data, AMF_H264SIMPLE_USE_CUSTOM_GOP_SIZE, false);
obs_data_set_int(data, AMF_H264_CABAC, -1);
break;
- case Preset_YouTube: // YouTube
- // Basic Properties
- obs_data_set_int(data, AMF_H264SIMPLE_KEYFRAME_INTERVAL, 2);
+ case Preset_Recording: // Recording
+ obs_data_set_int(data, AMF_H264SIMPLE_KEYFRAME_INTERVAL, 1);
obs_data_set_int(data, AMF_H264_QUALITY_PRESET, VCEQualityPreset_Quality);
obs_data_set_int(data, AMF_H264_PROFILE, VCEProfile_High);
- obs_data_set_int(data, AMF_H264_PROFILELEVEL, VCEProfileLevel_41);
- obs_data_set_int(data, AMF_H264_RATECONTROLMETHOD, VCERateControlMethod_ConstantBitrate);
- obs_data_set_int(data, AMF_H264_QP_MINIMUM, 18);
+ obs_data_set_int(data, AMF_H264_PROFILELEVEL, VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->maxProfileLevel);
+ obs_data_set_int(data, AMF_H264_RATECONTROLMETHOD, VCERateControlMethod_VariableBitrate_LatencyConstrained);
+ obs_data_set_int(data, AMF_H264_QP_MINIMUM, 0);
obs_data_set_int(data, AMF_H264_QP_MAXIMUM, 51);
- obs_data_set_int(data, AMF_H264_BITRATE_TARGET, 6000);
+ obs_data_set_int(data, AMF_H264_BITRATE_TARGET, 10000);
+ obs_data_set_int(data, AMF_H264_BITRATE_PEAK, VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->maxBitrate / 1000);
obs_data_set_bool(data, AMF_H264SIMPLE_USE_CUSTOM_BUFFER_SIZE, false);
- obs_data_set_int(data, AMF_H264_FILLERDATA, 1);
- obs_data_set_int(data, AMF_H264_FRAMESKIPPING, 0);
+ obs_data_set_int(data, AMF_H264_FILLERDATA, 0);
+ obs_data_set_int(data, AMF_H264_FRAMESKIPPING, 1);
// Advanced Properties
- obs_data_set_int(data, AMF_H264_BPICTURE_PATTERN, 0);
- obs_data_set_int(data, AMF_H264_BPICTURE_REFERENCE, 0);
+ obs_data_set_int(data, AMF_H264_BPICTURE_PATTERN, (VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->supportsBFrames ? 3 : 0));
+ obs_data_set_int(data, AMF_H264_BPICTURE_REFERENCE, (VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->supportsBFrames ? 1 : 0));
obs_data_set_int(data, AMF_H264_QP_BPICTURE_DELTA, 0);
obs_data_set_int(data, AMF_H264_QP_REFERENCE_BPICTURE_DELTA, 0);
obs_data_set_int(data, AMF_H264_DEBLOCKINGFILTER, 1);
obs_data_set_int(data, AMF_H264_QUALITY_PRESET, VCEQualityPreset_Quality);
obs_data_set_int(data, AMF_H264_PROFILE, VCEProfile_High);
obs_data_set_int(data, AMF_H264_PROFILELEVEL, VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->maxProfileLevel);
- obs_data_set_int(data, AMF_H264_RATECONTROLMETHOD, VCERateControlMethod_VariableBitrate_LatencyConstrained);
+ obs_data_set_int(data, AMF_H264_RATECONTROLMETHOD, VCERateControlMethod_ConstantQP);
obs_data_set_int(data, AMF_H264_QP_MINIMUM, 0);
obs_data_set_int(data, AMF_H264_QP_MAXIMUM, 51);
+ obs_data_set_int(data, AMF_H264_QP_IFRAME, 16);
+ obs_data_set_int(data, AMF_H264_QP_PFRAME, 19);
+ obs_data_set_int(data, AMF_H264_QP_BFRAME, 21);
obs_data_set_int(data, AMF_H264_BITRATE_TARGET, 10000);
- obs_data_set_int(data, AMF_H264_BITRATE_PEAK, 20000);
+ obs_data_set_int(data, AMF_H264_BITRATE_PEAK, VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->maxBitrate / 1000);
obs_data_set_bool(data, AMF_H264SIMPLE_USE_CUSTOM_BUFFER_SIZE, false);
obs_data_set_int(data, AMF_H264_FILLERDATA, 0);
obs_data_set_int(data, AMF_H264_FRAMESKIPPING, 0);
obs_data_set_int(data, AMF_H264_QUALITY_PRESET, VCEQualityPreset_Quality);
obs_data_set_int(data, AMF_H264_PROFILE, VCEProfile_High);
obs_data_set_int(data, AMF_H264_PROFILELEVEL, VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->maxProfileLevel);
- obs_data_set_int(data, AMF_H264_RATECONTROLMETHOD, VCERateControlMethod_VariableBitrate_LatencyConstrained);
+ obs_data_set_int(data, AMF_H264_RATECONTROLMETHOD, VCERateControlMethod_ConstantQP);
obs_data_set_int(data, AMF_H264_QP_MINIMUM, 0);
- obs_data_set_int(data, AMF_H264_QP_MAXIMUM, 21);
+ obs_data_set_int(data, AMF_H264_QP_MAXIMUM, 51);
+ obs_data_set_int(data, AMF_H264_QP_IFRAME, 11);
+ obs_data_set_int(data, AMF_H264_QP_PFRAME, 14);
+ obs_data_set_int(data, AMF_H264_QP_BFRAME, 16);
obs_data_set_int(data, AMF_H264_BITRATE_TARGET, 10000);
- obs_data_set_int(data, AMF_H264_BITRATE_PEAK, 50000);
+ obs_data_set_int(data, AMF_H264_BITRATE_PEAK, VCECapabilities::GetInstance()->GetEncoderCaps(VCEEncoderType_AVC)->maxBitrate / 1000);
obs_data_set_bool(data, AMF_H264SIMPLE_USE_CUSTOM_BUFFER_SIZE, false);
obs_data_set_int(data, AMF_H264_FILLERDATA, 0);
obs_data_set_int(data, AMF_H264_FRAMESKIPPING, 0);
obs_data_set_int(data, AMF_H264_CABAC, -1);
break;
}
- obs_data_set_int(data, AMF_H264SIMPLE_PRESET, -1);
+ //obs_data_set_int(data, AMF_H264SIMPLE_PRESET, -1);
}
{ // Rate Control Settings
}
}
+#pragma warning( push )
+#pragma warning( disable: 4702 )
void Plugin::Interface::H264SimpleInterface::destroy(void* data) {
try {
delete (static_cast<Plugin::Interface::H264SimpleInterface*>(data));
AMF_LOG_ERROR("Unable to destroy Encoder, see log for more information.");
}
}
+#pragma warning( pop )
+#pragma warning( push )
+#pragma warning( disable: 4702 )
bool Plugin::Interface::H264SimpleInterface::update(void *data, obs_data_t *settings) {
try {
return static_cast<Plugin::Interface::H264SimpleInterface*>(data)->update(settings);
} catch (...) {
AMF_LOG_ERROR("Unable to update Encoder, see log for more information.");
+ return false;
}
}
+#pragma warning( pop )
bool Plugin::Interface::H264SimpleInterface::encode(void *data, struct encoder_frame * frame, struct encoder_packet * packet, bool * received_packet) {
try {
AMF_LOG_INFO("<AMFEncoder::H264SimpleInterface::~H264SimpleInterface> Complete.");
}
+#pragma warning( push )
+#pragma warning( disable: 4100 )
bool Plugin::Interface::H264SimpleInterface::update(obs_data_t* settings) {
// settings is not flagged as a unused here, since a future update may add support for this.
return false;
}
+#pragma warning( pop )
bool Plugin::Interface::H264SimpleInterface::encode(struct encoder_frame * frame, struct encoder_packet * packet, bool * received_packet) {
bool retVal = true;
obs-studio-0.16.1.tar.xz/plugins/enc-amf/enc-amf/Source/enc-h264.cpp -> obs-studio-0.16.2.tar.xz/plugins/enc-amf/enc-amf/Source/enc-h264.cpp
Changed
}
}
+#pragma warning( push )
+#pragma warning( disable: 4702 )
void Plugin::Interface::H264Interface::destroy(void* data) {
try {
Plugin::Interface::H264Interface* enc = static_cast<Plugin::Interface::H264Interface*>(data);
AMF_LOG_ERROR("Unable to destroy Encoder, see log for more information.");
}
}
+#pragma warning( pop )
bool Plugin::Interface::H264Interface::encode(void *data, struct encoder_frame *frame, struct encoder_packet *packet, bool *received_packet) {
try {
return static_cast<Plugin::Interface::H264Interface*>(data)->update(settings);
} catch (...) {
AMF_LOG_ERROR("Unable to update Encoder, see log for more information.");
+ return false;
}
}
obs-studio-0.16.1.tar.xz/plugins/enc-amf/enc-amf/enc-amf.vcxproj -> obs-studio-0.16.2.tar.xz/plugins/enc-amf/enc-amf/enc-amf.vcxproj
Changed
<WarningLevel>Level4</WarningLevel>
<Optimization>Disabled</Optimization>
<SDLCheck>true</SDLCheck>
- <PreprocessorDefinitions>DEBUG;_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;DEBUG;_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
<Link>
<EnableCOMDATFolding>false</EnableCOMDATFolding>
<WarningLevel>Level4</WarningLevel>
<Optimization>Disabled</Optimization>
<SDLCheck>true</SDLCheck>
- <PreprocessorDefinitions>DEBUG;_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;DEBUG;_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
<Link>
<EnableCOMDATFolding>false</EnableCOMDATFolding>
<IntrinsicFunctions>true</IntrinsicFunctions>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
<FloatingPointModel>Fast</FloatingPointModel>
- <PreprocessorDefinitions>_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<InlineFunctionExpansion>AnySuitable</InlineFunctionExpansion>
<FunctionLevelLinking>false</FunctionLevelLinking>
<FloatingPointExceptions>false</FloatingPointExceptions>
<IntrinsicFunctions>true</IntrinsicFunctions>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
<FloatingPointModel>Fast</FloatingPointModel>
- <PreprocessorDefinitions>_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+ <PreprocessorDefinitions>_CRT_SECURE_NO_WARNINGS;_WINDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<InlineFunctionExpansion>AnySuitable</InlineFunctionExpansion>
<FunctionLevelLinking>false</FunctionLevelLinking>
<FloatingPointExceptions>false</FloatingPointExceptions>
obs-studio-0.16.1.tar.xz/plugins/obs-ffmpeg/obs-ffmpeg-nvenc.c -> obs-studio-0.16.2.tar.xz/plugins/obs-ffmpeg/obs-ffmpeg-nvenc.c
Changed
int height;
bool first_packet;
+ bool initialized;
};
static const char *nvenc_getname(void *unused)
return false;
}
+ enc->initialized = true;
+
*((AVPicture*)enc->vframe) = enc->dst_picture;
return true;
}
static void nvenc_destroy(void *data)
{
struct nvenc_encoder *enc = data;
- AVPacket pkt = {0};
- int r_pkt = 1;
- while (r_pkt) {
- if (avcodec_encode_video2(enc->context, &pkt, NULL, &r_pkt) < 0)
- break;
+ if (enc->initialized) {
+ AVPacket pkt = {0};
+ int r_pkt = 1;
+
+ while (r_pkt) {
+ if (avcodec_encode_video2(enc->context, &pkt, NULL,
+ &r_pkt) < 0)
+ break;
- if (r_pkt)
- av_free_packet(&pkt);
+ if (r_pkt)
+ av_free_packet(&pkt);
+ }
}
avcodec_close(enc->context);
obs-studio-0.16.1.tar.xz/plugins/obs-text/data/locale/en-US.ini -> obs-studio-0.16.2.tar.xz/plugins/obs-text/data/locale/en-US.ini
Changed
Filter.AllFiles="All Files"
Color="Color"
Opacity="Opacity"
+Gradient="Gradient"
+Gradient.Color="Gradient Color"
+Gradient.Opacity="Gradient Opacity"
+Gradient.Direction="Gradient Direction"
BkColor="Background Color"
BkOpacity="Background Opacity"
Alignment="Alignment"
obs-studio-0.16.1.tar.xz/plugins/obs-text/gdiplus/obs-text.cpp -> obs-studio-0.16.2.tar.xz/plugins/obs-text/gdiplus/obs-text.cpp
Changed
#define S_FILE "file"
#define S_TEXT "text"
#define S_COLOR "color"
+#define S_GRADIENT "gradient"
+#define S_GRADIENT_COLOR "gradient_color"
+#define S_GRADIENT_DIR "gradient_dir"
+#define S_GRADIENT_OPACITY "gradient_opacity"
#define S_ALIGN "align"
#define S_VALIGN "valign"
#define S_OPACITY "opacity"
#define T_FILE T_("TextFile")
#define T_TEXT T_("Text")
#define T_COLOR T_("Color")
+#define T_GRADIENT T_("Gradient")
+#define T_GRADIENT_COLOR T_("Gradient.Color")
+#define T_GRADIENT_DIR T_("Gradient.Direction")
+#define T_GRADIENT_OPACITY T_("Gradient.Opacity")
#define T_ALIGN T_("Alignment")
#define T_VALIGN T_("VerticalAlignment")
#define T_OPACITY T_("Opacity")
wstring face;
int face_size = 0;
uint32_t color = 0xFFFFFF;
+ uint32_t color2 = 0xFFFFFF;
+ float gradient_dir = 0;
uint32_t opacity = 100;
+ uint32_t opacity2 = 100;
uint32_t bk_color = 0;
uint32_t bk_opacity = 0;
Align align = Align::Left;
VAlign valign = VAlign::Top;
+ bool gradient = false;
bool bold = false;
bool italic = false;
bool underline = false;
bits.get());
Graphics graphics_bitmap(&bitmap);
- SolidBrush brush(Color(get_alpha_val(opacity) | (color & 0xFFFFFF)));
+ LinearGradientBrush brush(RectF(0, 0, (float)size.cx, (float)size.cy),
+ Color(calc_color(color, opacity)),
+ Color(calc_color(color2, opacity2)),
+ gradient_dir, 1);
DWORD full_bk_color = bk_color & 0xFFFFFF;
if (!text.empty() || use_extents)
const char *valign_str = obs_data_get_string(s, S_VALIGN);
uint32_t new_color = obs_data_get_uint32(s, S_COLOR);
uint32_t new_opacity = obs_data_get_uint32(s, S_OPACITY);
+ bool gradient = obs_data_get_bool(s, S_GRADIENT);
+ uint32_t new_color2 = obs_data_get_uint32(s, S_GRADIENT_COLOR);
+ uint32_t new_opacity2 = obs_data_get_uint32(s, S_GRADIENT_OPACITY);
+ float new_grad_dir = (float)obs_data_get_double(s, S_GRADIENT_DIR);
bool new_vertical = obs_data_get_bool(s, S_VERTICAL);
bool new_outline = obs_data_get_bool(s, S_OUTLINE);
uint32_t new_o_color = obs_data_get_uint32(s, S_OUTLINE_COLOR);
/* ----------------------------- */
new_color = rgb_to_bgr(new_color);
+ new_color2 = rgb_to_bgr(new_color2);
new_o_color = rgb_to_bgr(new_o_color);
new_bk_color = rgb_to_bgr(new_bk_color);
color = new_color;
opacity = new_opacity;
+ color2 = new_color2;
+ opacity2 = new_opacity2;
+ gradient_dir = new_grad_dir;
vertical = new_vertical;
bk_color = new_bk_color;
extents_cx = n_extents_cx;
extents_cy = n_extents_cy;
+ if (!gradient) {
+ color2 = color;
+ opacity2 = opacity;
+ }
+
read_from_file = new_use_file;
chatlog_mode = new_chat_mode;
return true;
}
+static bool gradient_changed(obs_properties_t *props, obs_property_t *p,
+ obs_data_t *s)
+{
+ bool gradient = obs_data_get_bool(s, S_GRADIENT);
+
+ set_vis(gradient, S_GRADIENT_COLOR, true);
+ set_vis(gradient, S_GRADIENT_OPACITY, true);
+ set_vis(gradient, S_GRADIENT_DIR, true);
+ return true;
+}
+
static bool extents_modified(obs_properties_t *props, obs_property_t *p,
obs_data_t *s)
{
obs_properties_add_bool(props, S_VERTICAL, T_VERTICAL);
obs_properties_add_color(props, S_COLOR, T_COLOR);
-
obs_properties_add_int_slider(props, S_OPACITY, T_OPACITY, 0, 100, 1);
+
+ p = obs_properties_add_bool(props, S_GRADIENT, T_GRADIENT);
+ obs_property_set_modified_callback(p, gradient_changed);
+
+ obs_properties_add_color(props, S_GRADIENT_COLOR, T_GRADIENT_COLOR);
+ obs_properties_add_int_slider(props, S_GRADIENT_OPACITY,
+ T_GRADIENT_OPACITY, 0, 100, 1);
+ obs_properties_add_float_slider(props, S_GRADIENT_DIR,
+ T_GRADIENT_DIR, 0, 360, 0.1);
obs_properties_add_color(props, S_BKCOLOR, T_BKCOLOR);
obs_properties_add_int_slider(props, S_BKOPACITY, T_BKOPACITY,
obs_data_set_default_string(settings, S_VALIGN, S_VALIGN_TOP);
obs_data_set_default_int(settings, S_COLOR, 0xFFFFFF);
obs_data_set_default_int(settings, S_OPACITY, 100);
+ obs_data_set_default_int(settings, S_GRADIENT_COLOR, 0xFFFFFF);
+ obs_data_set_default_int(settings, S_GRADIENT_OPACITY, 100);
+ obs_data_set_default_double(settings, S_GRADIENT_DIR, 90.0);
obs_data_set_default_int(settings, S_BKCOLOR, 0x000000);
obs_data_set_default_int(settings, S_BKOPACITY, 0);
obs_data_set_default_int(settings, S_OUTLINE_SIZE, 2);
No rpmlint results available
Request History
boombatower created request over 8 years ago
- Update to version 0.16.2:
* obs-ffmpeg: Fix possible NVENC crash
* UI: Use rect intersection test for validating position
* enc-amf: Update submodule to 1.3.1.0
* obs-text: Add gradient feature
* enc-amf: Fix warnings caused by warnings( push/pop )
* libobs: Update to 0.16.2
boombatower accepted request over 8 years ago
Ok