mirror of
https://github.com/outbackdingo/UltraGrid.git
synced 2026-03-21 02:40:14 +00:00
GUI: fix passing options for other capturers
This commit is contained in:
@@ -214,7 +214,14 @@ const static struct{
|
||||
{"preview", Option::BoolOpt, "", "t", true, "", ""},
|
||||
{"vuMeter", Option::BoolOpt, "", "t", true, "", ""},
|
||||
{"errors_fatal", Option::BoolOpt, " --param errors-fatal", "t", true, "", ""},
|
||||
{"aja.device", Option::StringOpt, ":device=", "", false, "video.source", "aja"},
|
||||
{"bluefish444.device", Option::StringOpt, ":device=", "", false, "video.source", "bluefish444"},
|
||||
{"deltacast.device", Option::StringOpt, ":device=", "", false, "video.source", "deltacast"},
|
||||
{"deltacast-dv.device", Option::StringOpt, ":device=", "", false, "video.source", "deltacast-dv"},
|
||||
{"dvs.device", Option::StringOpt, ":", "", false, "video.source", "dvs"},
|
||||
{"ndi.device", Option::StringOpt, ":url=", "", false, "video.source", "ndi"},
|
||||
{"syphon.device", Option::StringOpt, ":app=", "", false, "video.source", "syphon"},
|
||||
{"ximea.device", Option::StringOpt, ":device=", "", false, "video.source", "ximea"},
|
||||
};
|
||||
|
||||
const struct {
|
||||
|
||||
@@ -1131,7 +1131,7 @@ LINK_SPEC struct vidcap_type *vidcap_aja_probe(bool verbose, void (**deleter)(vo
|
||||
realloc(vt->cards, vt->card_count * sizeof(struct device_info));
|
||||
memset(&vt->cards[vt->card_count - 1], 0, sizeof(struct device_info));
|
||||
snprintf(vt->cards[vt->card_count - 1].id, sizeof vt->cards[vt->card_count - 1].id,
|
||||
"device=%d", i);
|
||||
"%d", i);
|
||||
snprintf(vt->cards[vt->card_count - 1].name, sizeof vt->cards[vt->card_count - 1].name,
|
||||
"AJA %s", info.deviceIdentifier.c_str());
|
||||
}
|
||||
|
||||
@@ -133,7 +133,7 @@ vidcap_deltacast_probe(bool verbose, void (**deleter)(void *))
|
||||
vt->cards = (struct device_info *) calloc(NbBoards, sizeof(struct device_info));
|
||||
vt->card_count = NbBoards;
|
||||
for (ULONG i = 0; i < NbBoards; ++i) {
|
||||
snprintf(vt->cards[i].id, sizeof vt->cards[i].id, "device=%" PRIu32, i);
|
||||
snprintf(vt->cards[i].id, sizeof vt->cards[i].id, "%" PRIu32, i);
|
||||
snprintf(vt->cards[i].name, sizeof vt->cards[i].name, "DELTACAST SDI board %" PRIu32, i);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -99,7 +99,6 @@ static struct vidcap_type * vidcap_screen_win_probe(bool verbose, void (**delete
|
||||
vt->card_count = 1;
|
||||
vt->cards = calloc(vt->card_count, sizeof(struct device_info));
|
||||
// vt->cards[0].id can be "" since screen cap. doesn't require parameters
|
||||
snprintf(vt->cards[0].id, sizeof vt->cards[0].id, "screen");
|
||||
snprintf(vt->cards[0].name, sizeof vt->cards[0].name, "Screen capture");
|
||||
|
||||
return vt;
|
||||
|
||||
@@ -474,7 +474,7 @@ static void probe_devices_callback(state_vidcap_syphon *s)
|
||||
s->probed_devices = (struct device_info *) realloc(s->probed_devices, s->probed_devices_count * sizeof(struct device_info));
|
||||
memset(&s->probed_devices[s->probed_devices_count - 1], 0, sizeof(struct device_info));
|
||||
snprintf(s->probed_devices[s->probed_devices_count - 1].id, sizeof s->probed_devices[s->probed_devices_count - 1].id,
|
||||
"app=%s", [[item objectForKey:@"SyphonServerDescriptionAppNameKey"] UTF8String]);
|
||||
"%s", [[item objectForKey:@"SyphonServerDescriptionAppNameKey"] UTF8String]);
|
||||
snprintf(s->probed_devices[s->probed_devices_count - 1].name, sizeof s->probed_devices[s->probed_devices_count - 1].name,
|
||||
"Syphon %s", [[item objectForKey:@"SyphonServerDescriptionAppNameKey"] UTF8String]);
|
||||
}
|
||||
|
||||
@@ -351,9 +351,8 @@ static struct vidcap_type *vidcap_ximea_probe(bool verbose, void (**deleter)(voi
|
||||
|
||||
vt->cards = calloc(count, sizeof(struct device_info));
|
||||
for (DWORD i = 0; i < count; ++i) {
|
||||
snprintf(vt->cards[i].id, sizeof vt->cards[i].id, "ximea:device=%d", (int) i);
|
||||
snprintf(vt->cards[i].id, sizeof vt->cards[i].id, "%d", (int) i);
|
||||
char name[256];
|
||||
color_out(COLOR_OUT_BOLD, "%d) ", (int) i);
|
||||
if (funcs.xiGetDeviceInfoString(i, XI_PRM_DEVICE_NAME, name, sizeof name) == XI_OK) {
|
||||
strncpy(vt->cards[i].name, name, sizeof vt->cards[i].name);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user