New upstream version 25.0.3+dfsg1

This commit is contained in:
Sebastian Ramacher 2020-03-25 09:07:22 +01:00
parent 04fe0efc67
commit 8b2e5f2130
569 changed files with 62491 additions and 5875 deletions

View file

@ -98,7 +98,7 @@ save/load individual sources manually by using
:c:func:`obs_save_source()` and :c:func:`obs_load_source()`.
*(Author's note: I should not have written those helper functions; the
downside is I had to add "private" sources that aren't savable via the*
downside is I had to add "private" sources that aren't saveable via the*
:c:func:`obs_source_create_private()` *function. Just one of the many
minor design flaws that can occur during long-term development.)*

View file

@ -228,6 +228,19 @@ Libobs Objects
---------------------
.. function:: void obs_enum_scenes(bool (*enum_proc)(void*, obs_source_t*), void *param)
Enumerates all scenes.
Callback function returns true to continue enumeration, or false to end
enumeration.
Use :c:func:`obs_source_get_ref()` or
:c:func:`obs_source_get_weak_source()` if you want to retain a
reference after obs_enum_scenes finishes.
---------------------
.. function:: void obs_enum_outputs(bool (*enum_proc)(void*, obs_output_t*), void *param)
Enumerates outputs.

View file

@ -380,6 +380,13 @@ General Encoder Functions
---------------------
.. function:: bool obs_encoder_scaling_enabled(const obs_encoder_t *encoder)
:return: *true* if pre-encode (CPU) scaling enabled, *false*
otherwise.
---------------------
.. function:: uint32_t obs_encoder_get_width(const obs_encoder_t *encoder)
uint32_t obs_encoder_get_height(const obs_encoder_t *encoder)

View file

@ -826,7 +826,7 @@ Draw Functions
Gets the current viewport
:param rect: Pointer to recieve viewport rectangle
:param rect: Pointer to receive viewport rectangle
---------------------

View file

@ -249,5 +249,5 @@
Normalizes a vector
:param dst: Desination
:param dst: Destination
:param v: Vector to normalize

View file

@ -273,7 +273,7 @@
Normalizes a vector
:param dst: Desination
:param dst: Destination
:param v: Vector to normalize
---------------------

View file

@ -268,7 +268,7 @@
Normalizes a vector
:param dst: Desination
:param dst: Destination
:param v: Vector to normalize
---------------------

View file

@ -95,7 +95,7 @@ dynamic array value with a reference (&) operator. For example:
.. function:: void da_copy(da_dst, da_src)
Makes a copy of a dyanmic array.
Makes a copy of a dynamic array.
:param da_dst: The dynamic array to copy to
:param da_src: The dynamic array to copy from

View file

@ -188,7 +188,7 @@ Dynamic String Functions
Copies a specific number of characters from another dynamic string.
:param dst: Dynamic string
:param src: Dynamic tring to copy
:param src: Dynamic string to copy
:param len: Number of characters to copy
----------------------
@ -234,7 +234,7 @@ Dynamic String Functions
.. function:: void dstr_cat_dstr(struct dstr *dst, const struct dstr *str)
Concatenates a dyanmic string with another dynamic string.
Concatenates a dynamic string with another dynamic string.
:param dst: Dynamic string to concatenate to
:param str: Dynamic string to concatenate with
@ -308,7 +308,7 @@ Dynamic String Functions
Removes a specific number of characters starting from a specific
index.
:param dst: Dyanmic string
:param dst: Dynamic string
:param idx: Index to start removing characters at
:param count: Number of characters to remove

View file

@ -355,7 +355,7 @@ Other Path/File Functions
.. function:: int os_copyfile(const char *file_in, const char *file_out)
Copys a file.
Copies a file.
---------------------

View file

@ -159,7 +159,7 @@ Profiler Data Access Functions
:param snap: A profiler snapshot
:param filename: The path to the CSV file to save
:return: *true* if successfuly written, *false* otherwise
:return: *true* if successfully written, *false* otherwise
----------------------
@ -169,7 +169,7 @@ Profiler Data Access Functions
:param snap: A profiler snapshot
:param filename: The path to the gzipped CSV file to save
:return: *true* if successfuly written, *false* otherwise
:return: *true* if successfully written, *false* otherwise
----------------------

View file

@ -73,7 +73,7 @@ Event Functions
- 0 - successful
- ETIMEDOUT - Timed out
- EINVAL - An unexpected error occured
- EINVAL - An unexpected error occurred
----------------------
@ -86,7 +86,7 @@ Event Functions
- 0 - successful
- EAGAIN - The event is not signaled
- EINVAL - An unexpected error occured
- EINVAL - An unexpected error occurred
----------------------
@ -123,7 +123,7 @@ Semaphore Functions
.. function:: void os_sem_destroy(os_sem_t *sem)
Destroys a sempahore object.
Destroys a semaphore object.
:param sem: Semaphore object
@ -140,7 +140,7 @@ Semaphore Functions
.. function:: int os_sem_wait(os_sem_t *sem)
Decrements the semphore or waits until the semaphore has been
Decrements the semaphore or waits until the semaphore has been
incremented.
:param sem: Semaphore object

View file

@ -98,7 +98,7 @@ to communicate with libobs and front-ends.
Module Externs
--------------
These functions are externs that are useable throughout the module.
These functions are externs that are usable throughout the module.
.. function:: const char *obs_module_text(const char *lookup_string)

View file

@ -122,7 +122,7 @@ Output Definition Structure (obs_output_info)
.. member:: void (*obs_output_info.raw_audio)(void *data, struct audio_data *frames)
This is called when the output recieves raw audio data. Only applies
This is called when the output receives raw audio data. Only applies
to outputs that are not encoded.
**This callback must be used with single-track raw outputs.**
@ -131,7 +131,7 @@ Output Definition Structure (obs_output_info)
.. member:: void (*obs_output_info.raw_audio2)(void *data, size_t idx, struct audio_data *frames)
This is called when the output recieves raw audio data. Only applies
This is called when the output receives raw audio data. Only applies
to outputs that are not encoded.
**This callback must be used with multi-track raw outputs.**
@ -251,7 +251,7 @@ Output Signals
:Parameters: - **code** - Can be one of the following values:
| OBS_OUTPUT_SUCCESS - Successfuly stopped
| OBS_OUTPUT_SUCCESS - Successfully stopped
| OBS_OUTPUT_BAD_PATH - The specified path was invalid
| OBS_OUTPUT_CONNECT_FAILED - Failed to connect to a server
| OBS_OUTPUT_INVALID_STREAM - Invalid stream path
@ -368,7 +368,7 @@ General Output Functions
Starts the output.
:return: *true* if output successfuly started, *false* otherwise. If
:return: *true* if output successfully started, *false* otherwise. If
the output failed to start,
:c:func:`obs_output_get_last_error()` may contain a specific
error string related to the reason
@ -460,7 +460,7 @@ General Output Functions
Pause an output (if supported by the output).
:return: *true* if the output was paused successfuly, *false*
:return: *true* if the output was paused successfully, *false*
otherwise
---------------------
@ -818,7 +818,7 @@ Functions used by outputs
to the user
:param code: | Can be one of the following values:
| OBS_OUTPUT_SUCCESS - Successfuly stopped
| OBS_OUTPUT_SUCCESS - Successfully stopped
| OBS_OUTPUT_BAD_PATH - The specified path was invalid
| OBS_OUTPUT_CONNECT_FAILED - Failed to connect to a server
| OBS_OUTPUT_INVALID_STREAM - Invalid stream path

View file

@ -182,7 +182,7 @@ Property Object Functions
- **OBS_COMBO_TYPE_EDITABLE** - Can be edited.
Only used with string lists.
- **OBS_COMBO_TYPE_LIST** - Not ediable.
- **OBS_COMBO_TYPE_LIST** - Not editable.
:param format: Can be one of the following values:
@ -562,7 +562,7 @@ Property Modification Functions
---------------------
.. function:: void obs_property_list_item_disable(obs_property_t *p, size_t idx,
.. function:: void obs_property_list_item_disable(obs_property_t *p, size_t idx, bool disabled)
---------------------

View file

@ -135,6 +135,11 @@ Scene Signals
Called when scene items have been reoredered in the scene.
**refresh** (ptr scene)
Called when the entire scene item list needs to be refreshed.
Usually this is only used when groups have changed.
**item_visible** (ptr scene, ptr item, bool visible)
Called when a scene item's visibility state changes.
@ -225,6 +230,16 @@ General Scene Functions
---------------------
.. function:: obs_sceneitem_t *obs_scene_find_source_recursive(obs_scene_t *scene, const char *name)
Same as obs_scene_find_source, but also searches groups within the
scene.
:param name: The name of the source to find
:return: The scene item if found, otherwise *NULL* if not found
---------------------
.. function:: obs_sceneitem_t *obs_scene_find_sceneitem_by_id(obs_scene_t *scene, int64_t id)
:param id: The unique numeric identifier of the scene item
@ -398,7 +413,7 @@ Scene Item Functions
.. function:: void obs_sceneitem_get_box_transform(const obs_sceneitem_t *item, struct matrix4 *transform)
Gets the transform matrix of the scene item used for the bouding box
Gets the transform matrix of the scene item used for the bounding box
or edges of the scene item.
---------------------
@ -463,7 +478,8 @@ Scene Item Group Functions
.. function:: obs_sceneitem_t *obs_scene_add_group(obs_scene_t *scene, const char *name)
Adds a group with the specified name.
Adds a group with the specified name. Does not signal the scene with
the *refresh* signal.
:param scene: Scene to add the group to
:param name: Name of the group
@ -471,10 +487,23 @@ Scene Item Group Functions
---------------------
.. function:: obs_sceneitem_t *obs_scene_add_group2(obs_scene_t *scene, const char *name, bool signal)
Adds a group with the specified name.
:param scene: Scene to add the group to
:param name: Name of the group
:param signal: If *true*, signals the scene with the *refresh*
signal
:return: The new group's scene item
---------------------
.. function:: obs_sceneitem_t *obs_scene_insert_group(obs_scene_t *scene, const char *name, obs_sceneitem_t **items, size_t count)
Creates a group out of the specified scene items. The group will be
inserted at the top scene item.
inserted at the top scene item. Does not signal the scene with the
*refresh* signal.
:param scene: Scene to add the group to
:param name: Name of the group
@ -484,6 +513,21 @@ Scene Item Group Functions
---------------------
.. function:: obs_sceneitem_t *obs_scene_insert_group2(obs_scene_t *scene, const char *name, obs_sceneitem_t **items, size_t count, bool signal)
Creates a group out of the specified scene items. The group will be
inserted at the top scene item. Does not signal a refresh.
:param scene: Scene to add the group to
:param name: Name of the group
:param items: Array of scene items to put in a group
:param count: Number of scene items in the array
:param signal: If *true*, signals the scene with the *refresh*
signal
:return: The new group's scene item
---------------------
.. function:: obs_sceneitem_t *obs_scene_get_group(obs_scene_t *scene, const char *name)
Finds a group within a scene by its name.
@ -494,6 +538,13 @@ Scene Item Group Functions
---------------------
.. function:: obs_scene_t *obs_group_from_source(const obs_source_t *source)
:return: The group context, or *NULL* if not a group. Does not
increase the reference
---------------------
.. function:: bool obs_sceneitem_is_group(obs_sceneitem_t *item)
:param item: Scene item
@ -510,9 +561,21 @@ Scene Item Group Functions
.. function:: void obs_sceneitem_group_ungroup(obs_sceneitem_t *group)
Ungroups the specified group. Scene items within the group will be
placed where the group was. Does not signal the scene with the
*refresh* signal.
---------------------
.. function:: void obs_sceneitem_group_ungroup2(obs_sceneitem_t *group, bool signal)
Ungroups the specified group. Scene items within the group will be
placed where the group was.
:param group: Group scene item
:param signal: If *true*, signals the scene with the *refresh*
signal
---------------------
.. function:: void obs_sceneitem_group_add_item(obs_sceneitem_t *group, obs_sceneitem_t *item)
@ -523,8 +586,8 @@ Scene Item Group Functions
.. function:: void obs_sceneitem_group_remove_item(obs_sceneitem_t *item)
Rmoves a scene item from a group. The item will be placed before the
group in the main scene.
Removes a scene item from a group. The item will be placed before
the group in the main scene.
---------------------

View file

@ -96,7 +96,7 @@ Source Definition Structure (obs_source_info)
user.
When this is used, the source will receive interaction events if
theese callbacks are provided:
these callbacks are provided:
:c:member:`obs_source_info.mouse_click`,
:c:member:`obs_source_info.mouse_move`,
:c:member:`obs_source_info.mouse_wheel`,
@ -142,6 +142,20 @@ Source Definition Structure (obs_source_info)
from creating an audio feedback loop. This is primarily only used
with desktop audio capture sources.
- **OBS_SOURCE_CAP_DISABLED** - This source type has been disabled
and should not be shown as a type of source the user can add.
- **OBS_SOURCE_CAP_OBSOLETE** - This source type is obsolete and
should not be shown as a type of source the user can add.
Identical to *OBS_SOURCE_CAP_DISABLED*. Meant to be used when a
source has changed in some way (mostly defaults/properties), but
you want to avoid breaking older configurations. Basically solves
the problem of "I want to change the defaults of a source but I
don't want to break people's configurations"
- **OBS_SOURCE_CONTROLLABLE_MEDIA** - This source has media that can
be controlled
.. member:: const char *(*obs_source_info.get_name)(void *type_data)
Get the translated name of the source type.
@ -286,7 +300,7 @@ Source Definition Structure (obs_source_info)
Called to enumerate all active sources being used within this
source. If the source has children that render audio/video it must
implement this callback. Only used with sources that have tha
implement this callback. Only used with sources that have the
OBS_SOURCE_COMPOSITE output capability flag.
:param enum_callback: Enumeration callback
@ -391,14 +405,14 @@ Source Definition Structure (obs_source_info)
.. member:: bool (*obs_source_info.audio_render)(void *data, uint64_t *ts_out, struct obs_source_audio_mix *audio_output, uint32_t mixers, size_t channels, size_t sample_rate)
Called to render audio of composite sources. Only used with sources
that have tha OBS_SOURCE_COMPOSITE output capability flag.
that have the OBS_SOURCE_COMPOSITE output capability flag.
.. member:: void (*obs_source_info.enum_all_sources)(void *data, obs_source_enum_proc_t enum_callback, void *param)
Called to enumerate all active and inactive sources being used
within this source. If this callback isn't implemented,
enum_active_sources will be called instead. Only used with sources
that have tha OBS_SOURCE_COMPOSITE output capability flag.
that have the OBS_SOURCE_COMPOSITE output capability flag.
This is typically used if a source can have inactive child sources.
@ -412,6 +426,70 @@ Source Definition Structure (obs_source_info)
(Optional)
.. member:: enum obs_icon_type obs_source_info.icon_type
Icon used for the source.
- **OBS_ICON_TYPE_UNKNOWN** - Unknown
- **OBS_ICON_TYPE_IMAGE** - Image
- **OBS_ICON_TYPE_COLOR** - Color
- **OBS_ICON_TYPE_SLIDESHOW** - Slideshow
- **OBS_ICON_TYPE_AUDIO_INPUT** - Audio Input
- **OBS_ICON_TYPE_AUDIO_OUTPUT** - Audio Output
- **OBS_ICON_TYPE_DESKTOP_CAPTURE** - Desktop Capture
- **OBS_ICON_TYPE_WINDOW_CAPTURE** - Window Capture
- **OBS_ICON_TYPE_GAME_CAPTURE** - Game Capture
- **OBS_ICON_TYPE_CAMERA** - Camera
- **OBS_ICON_TYPE_TEXT** - Text
- **OBS_ICON_TYPE_MEDIA** - Media
- **OBS_ICON_TYPE_BROWSER** - Browser
- **OBS_ICON_TYPE_CUSTOM** - Custom (not implemented yet)
.. member:: void (*obs_source_info.media_play_pause)(void *data, bool pause)
Called to pause or play media.
.. member:: void (*obs_source_info.media_restart)(void *data)
Called to restart the media.
.. member:: void (*obs_source_info.media_stop)(void *data)
Called to stop the media.
.. member:: void (*obs_source_info.media_next)(void *data)
Called to go to the next media.
.. member:: void (*obs_source_info.media_previous)(void *data)
Called to go to the previous media.
.. member:: int64_t (*obs_source_info.media_get_duration)(void *data)
Called to get the media duration.
.. member:: int64_t (*obs_source_info.media_get_time)(void *data)
Called to get the current time of the media.
.. member:: void (*obs_source_info.media_set_time)(void *data, int64_t miliseconds)
Called to set the media time.
.. member:: enum obs_media_state (*obs_source_info.media_get_state)(void *data)
Called to get the state of the media.
- **OBS_MEDIA_STATE_NONE** - None
- **OBS_MEDIA_STATE_PLAYING** - Playing
- **OBS_MEDIA_STATE_OPENING** - Opening
- **OBS_MEDIA_STATE_BUFFERING** - Buffering
- **OBS_MEDIA_STATE_PAUSED** - Paused
- **OBS_MEDIA_STATE_STOPPED** - Stopped
- **OBS_MEDIA_STATE_ENDED** - Ended
- **OBS_MEDIA_STATE_ERROR** - Error
.. _source_signal_handler_reference:
@ -528,6 +606,37 @@ Source Signals
Called when a transition has stopped.
**media_started**
Called when media has started.
**media_ended**
Called when media has ended.
**media_pause**
Called when media has been paused.
**media_play**
Called when media starts playing.
**media_restart**
Called when the playing of media has been restarted.
**media_stopped**
Called when the playing of media has been stopped.
**media_next**
Called when the media source switches to the next media.
**media_previous**
Called when the media source switches to the previous media.
General Source Functions
------------------------
@ -836,7 +945,7 @@ General Source Functions
.. function:: bool obs_source_active(const obs_source_t *source)
:return: *true* if active, *false* if not. A source is only
consdiered active if it's being shown on the final mix
considered active if it's being shown on the final mix
---------------------
@ -1077,6 +1186,14 @@ Functions used by sources
---------------------
.. function:: void obs_source_set_async_rotation(obs_source_t *source, long rotation)
Allows the ability to set rotation (0, 90, 180, -90, 270) for an
async video source. The rotation will be automatically applied to
the source.
---------------------
.. function:: void obs_source_preload_video(obs_source_t *source, const struct obs_source_frame *frame)
Preloads a video frame to ensure a frame is ready for playback as
@ -1268,8 +1385,8 @@ Transitions
Sets/gets the scale type for sources within the transition.
:param type: | OBS_TRANSITION_SCALE_MAX_ONLY - Scale to aspect ratio, but only to the maximum size of each source
| OBS_TRANSITION_SCALE_ASPECT - Alwasy scale the sources, but keep aspect ratio
| OBS_TRANSITION_SCALE_STRETCH - Scale and stretch the sources to the size of the transision
| OBS_TRANSITION_SCALE_ASPECT - Always scale the sources, but keep aspect ratio
| OBS_TRANSITION_SCALE_STRETCH - Scale and stretch the sources to the size of the transition
---------------------