![]() |
Open Broadcaster Software
Free, open source software for live streaming and recording
|
header for modules implementing sources. More...
Go to the source code of this file.
Data Structures | |
struct | obs_source_audio_mix |
struct | obs_source_info |
Macros | |
#define | obs_register_source(info) obs_register_source_s(info, sizeof(struct obs_source_info)) |
Source output flags | |
These flags determine what type of data the source outputs and expects. | |
#define | OBS_SOURCE_VIDEO (1<<0) |
#define | OBS_SOURCE_AUDIO (1<<1) |
#define | OBS_SOURCE_ASYNC (1<<2) |
#define | OBS_SOURCE_ASYNC_VIDEO (OBS_SOURCE_ASYNC | OBS_SOURCE_VIDEO) |
#define | OBS_SOURCE_CUSTOM_DRAW (1<<3) |
#define | OBS_SOURCE_INTERACTION (1<<5) |
#define | OBS_SOURCE_COMPOSITE (1<<6) |
#define | OBS_SOURCE_DO_NOT_DUPLICATE (1<<7) |
#define | OBS_SOURCE_DEPRECATED (1<<8) |
#define | OBS_SOURCE_DO_NOT_MONITOR (1<<9) |
Typedefs | |
typedef void(* | obs_source_enum_proc_t) (obs_source_t *parent, obs_source_t *child, void *param) |
Enumerations | |
enum | obs_source_type { OBS_SOURCE_TYPE_INPUT, OBS_SOURCE_TYPE_FILTER, OBS_SOURCE_TYPE_TRANSITION, OBS_SOURCE_TYPE_SCENE } |
Functions | |
EXPORT void | obs_register_source_s (const struct obs_source_info *info, size_t size) |
header for modules implementing sources.
Sources are modules that either feed data to libobs or modify it.
#define obs_register_source | ( | info | ) | obs_register_source_s(info, sizeof(struct obs_source_info)) |
Regsiters a source definition to the current obs context. This should be used in obs_module_load.
info | Pointer to the source definition structure |
#define OBS_SOURCE_ASYNC (1<<2) |
Async video flag (use OBS_SOURCE_ASYNC_VIDEO)
#define OBS_SOURCE_ASYNC_VIDEO (OBS_SOURCE_ASYNC | OBS_SOURCE_VIDEO) |
Source passes raw video data via RAM.
Use the obs_source_output_video function to pass raw video data, which will be automatically uploaded at the specified timestamp.
If this flag is specified, it is not necessary to include the video_render callback. However, if you wish to use that function as well, you must call obs_source_getframe to get the current frame data, and obs_source_releaseframe to release the data when complete.
#define OBS_SOURCE_AUDIO (1<<1) |
Source has audio.
Use the obs_source_output_audio function to pass raw audio data, which will be automatically converted and uploaded. If used with SOURCE_ASYNC_VIDEO, audio will automatically be synced up to the video output.
#define OBS_SOURCE_COMPOSITE (1<<6) |
Source composites sub-sources
When used specifies that the source composites one or more sub-sources. Sources that render sub-sources must implement the audio_render callback in order to perform custom mixing of sub-sources.
This capability flag is always set for transitions.
#define OBS_SOURCE_CUSTOM_DRAW (1<<3) |
Source uses custom drawing, rather than a default effect.
If this flag is specified, the video_render callback will pass a NULL effect, and effect-based filters will not use direct rendering.
#define OBS_SOURCE_DEPRECATED (1<<8) |
Source is deprecated and should not be used
#define OBS_SOURCE_DO_NOT_DUPLICATE (1<<7) |
Source should not be fully duplicated
When this is used, specifies that the source should not be fully duplicated, and should prefer to duplicate via holding references rather than full duplication.
#define OBS_SOURCE_DO_NOT_MONITOR (1<<9) |
Source cannot have its audio monitored
Specifies that this source may cause a feedback loop if audio is monitored. This is used primarily with desktop audio capture sources.
#define OBS_SOURCE_INTERACTION (1<<5) |
Source supports interaction.
When this is used, the source will receive interaction events if they provide the necessary callbacks in the source definition structure.
#define OBS_SOURCE_VIDEO (1<<0) |
Source has video.
Unless SOURCE_ASYNC_VIDEO is specified, the source must include the video_render callback in the source definition structure.
typedef void(* obs_source_enum_proc_t) (obs_source_t *parent, obs_source_t *child, void *param) |
enum obs_source_type |
EXPORT void obs_register_source_s | ( | const struct obs_source_info * | info, |
size_t | size | ||
) |