Commit Graph

5 Commits

Author SHA1 Message Date
cg2121
750c016161 frontend, libobs: Add OBSProperties OBSPtr type
We no longer have to manually destroy obs_properties_t.
2026-05-06 17:27:36 -04:00
Sebastian Beckmann
649beed45c frontend: Don't store QT_TO_UTF8 to std::string
QT_TO_UTF8 returns a const char * that, in general, shouldn't be stored.
This is because QT_TO_UTF8(str) expands to str.toUtf8().constData():
toUtf8() returns a QByteArray, and constData() the pointer to its data
which is only valid until the QByteArray goes out of scope, which is
immediately after the call.
The original code that is changed here only works because in all of the
situations, the object that is stored to is actually a std::string that
gets constructed implicitly, so the constData() pointer is valid long
enough for the std::string constructor to copy the data.

The issue is that any "... = QT_TO_UTF8" code *looks* unsafe, and may
lead new or unfamiliar contributors to assume that they can also use it,
only to do "const char *... = QT_TO_UTF8(...)" which is dangerous.
Additionally, it introduces an unnecessary round of implicit conversions
and copies when QString.toStdString() already exists and copies into the
string buffer directly.
2026-05-06 14:15:44 -04:00
Sean DuBois
cd4d624ec3 obs-webrtc: Add Simulcast Support 2025-12-17 13:41:59 -05:00
Dennis Sädtler
0552062390 frontend: Allow selecting additional canvases for multitrack 2025-05-05 17:17:20 -04:00
PatTheMav
7f6bee603b frontend: Add renamed Qt Settings UI implementation 2025-01-08 15:36:55 +01:00