mirror of
https://github.com/Palakis/obs-websocket.git
synced 2024-08-30 18:12:16 +00:00
Utils: Add includeDisabled in GetInputKindList
This commit is contained in:
parent
d0e05ae45c
commit
7081824bbe
@ -208,6 +208,7 @@ RequestResult RequestHandler::SetStreamServiceSettings(const Request& request)
|
||||
if (streamServiceType == requestedStreamServiceType) {
|
||||
OBSDataAutoRelease currentStreamServiceSettings = obs_service_get_settings(currentStreamService);
|
||||
|
||||
// TODO: Add `overlay` field
|
||||
OBSDataAutoRelease newStreamServiceSettings = obs_data_create();
|
||||
obs_data_apply(newStreamServiceSettings, currentStreamServiceSettings);
|
||||
obs_data_apply(newStreamServiceSettings, requestedStreamServiceSettings);
|
||||
|
@ -316,7 +316,7 @@ std::vector<json> Utils::Obs::ListHelper::GetInputList(std::string inputKind)
|
||||
return inputInfo.inputs;
|
||||
}
|
||||
|
||||
std::vector<std::string> Utils::Obs::ListHelper::GetInputKindList(bool unversioned)
|
||||
std::vector<std::string> Utils::Obs::ListHelper::GetInputKindList(bool unversioned, bool includeDisabled)
|
||||
{
|
||||
std::vector<std::string> ret;
|
||||
|
||||
@ -326,7 +326,7 @@ std::vector<std::string> Utils::Obs::ListHelper::GetInputKindList(bool unversion
|
||||
while (obs_enum_input_types2(idx++, &kind, &unversioned_kind)) {
|
||||
uint32_t caps = obs_get_source_output_flags(kind);
|
||||
|
||||
if ((caps & OBS_SOURCE_CAP_DISABLED) != 0)
|
||||
if (!includeDisabled && (caps & OBS_SOURCE_CAP_DISABLED) != 0)
|
||||
continue;
|
||||
|
||||
if (unversioned)
|
||||
|
@ -54,7 +54,7 @@ namespace Utils {
|
||||
std::vector<json> GetSceneItemList(obs_scene_t *scene, bool basic = false);
|
||||
std::vector<json> GetTransitionList();
|
||||
std::vector<json> GetInputList(std::string inputKind = "");
|
||||
std::vector<std::string> GetInputKindList(bool unversioned = false);
|
||||
std::vector<std::string> GetInputKindList(bool unversioned = false, bool includeDisabled = false);
|
||||
}
|
||||
|
||||
namespace SearchHelper {
|
||||
|
Loading…
Reference in New Issue
Block a user