mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-09-20 04:42:18 +02:00
UI: Use GDI+ text for multiview on windows
Fixes an issue where text would not have language glyph fallback if another language would used. This problem still needs a solution on linux/mac (and preferably a fix for language glyph fallbacks when using freetype 2 in general).
This commit is contained in:
parent
65f81105f5
commit
0389ecf9f0
@ -116,7 +116,13 @@ static OBSSource CreateLabel(const char *name, size_t h)
|
||||
obs_data_set_string(settings, "text", text.c_str());
|
||||
obs_data_set_bool(settings, "outline", true);
|
||||
|
||||
OBSSource txtSource = obs_source_create_private("text_ft2_source", name,
|
||||
#ifdef _WIN32
|
||||
const char *text_source_id = "text_gdiplus";
|
||||
#else
|
||||
const char *text_source_id = "text_ft2_source";
|
||||
#endif
|
||||
|
||||
OBSSource txtSource = obs_source_create_private(text_source_id, name,
|
||||
settings);
|
||||
obs_source_release(txtSource);
|
||||
|
||||
@ -835,9 +841,6 @@ void OBSProjector::UpdateMultiview()
|
||||
name += " - ";
|
||||
name += obs_source_get_name(src);
|
||||
|
||||
if (name.size() > 15)
|
||||
name.resize(15);
|
||||
|
||||
multiviewLabels[curIdx + 2] = CreateLabel(name.c_str(), h / 4);
|
||||
|
||||
curIdx++;
|
||||
|
Loading…
Reference in New Issue
Block a user