mirror of
https://github.com/obsproject/obs-studio.git
synced 2024-09-20 13:08:50 +02:00
libobs: Add function to get libobs object data
This commit is contained in:
parent
07c22cb885
commit
a2829643f4
@ -2149,6 +2149,15 @@ bool obs_obj_invalid(void *obj)
|
||||
return !context->data;
|
||||
}
|
||||
|
||||
void *obs_obj_get_data(void *obj)
|
||||
{
|
||||
struct obs_context_data *context = obj;
|
||||
if (!context)
|
||||
return NULL;
|
||||
|
||||
return context->data;
|
||||
}
|
||||
|
||||
bool obs_set_audio_monitoring_device(const char *name, const char *id)
|
||||
{
|
||||
if (!obs || !name || !id || !*name || !*id)
|
||||
|
@ -674,6 +674,7 @@ enum obs_obj_type {
|
||||
EXPORT enum obs_obj_type obs_obj_get_type(void *obj);
|
||||
EXPORT const char *obs_obj_get_id(void *obj);
|
||||
EXPORT bool obs_obj_invalid(void *obj);
|
||||
EXPORT void *obs_obj_get_data(void *obj);
|
||||
|
||||
typedef bool (*obs_enum_audio_device_cb)(void *data, const char *name,
|
||||
const char *id);
|
||||
|
Loading…
Reference in New Issue
Block a user