0
0
mirror of https://github.com/obsproject/obs-studio.git synced 2024-09-20 13:08:50 +02:00
Commit Graph

351 Commits

Author SHA1 Message Date
jp9000
9819cb2924 libobs: Add obs_weak_source_expired() 2021-10-15 22:10:33 -07:00
jpark37
7c72fd1d4c libobs: Plumb texcoord hint to reduce GPU cost
In order to do linear-correct filtering cheaply when scale filtering is
disabled, we need to know whether or not texture coordinates will always
sample from texel centers. This can be computed at the scene item level
relatively easily, and passed along to sources when rendering. Scene
items will use obs_source_set_texcoords_centered to set hint status, and
sources will use obs_source_get_texcoords_centered to retrieve it.
2021-07-11 08:26:29 -07:00
tt2468
53a8a326da libobs: Add obs_enum_all_sources()
There is currently no way to enumerate *all* sources in OBS. Only
inputs and scenes have a way to be enumerated. Some applications
like obs-websocket have features that need to take advantage
of enumerating all sources in order to function properly.
2021-07-09 17:33:17 +12:00
jpark37
c021338ceb libobs,deps/media-playback: Avoid bitfields
Use unused padding of obs_source_frame/obs_source_frame2 instead.
2021-06-11 07:02:37 -07:00
jpark37
1fa152092c libobs: Plumb linear alpha flag
Use union for backwards compatibility.
2021-06-04 19:04:08 -07:00
jp9000
6b2c3f4845 libobs: Add obs_group_or_scene_from_source()
Makes it a little bit easier to get a scene from either a source or
group.
2021-05-17 16:34:09 -07:00
jpark37
ae7718a765 libobs, obs-filters: SRGB backwards compatibility
Add OBS_SOURCE_SRGB to indicate sources that support SRGB rendering. We
can use this flag to know which sources do not know how to handle SRGB,
and disable accordingly inside obs_source_main_render().

We can also use this flag to clean up the filter interface and remove
the SRGB-specific functions. We also need to disable direct rendering if
the filter source wants to render SRGB, but the parent source does not
support it.

Scenes and groups are marked as having SRGB support, and those are
internal sources that we control.
2021-05-03 01:19:56 -07:00
jp9000
60447872c0 libobs: Add obs_source_reset_settings()
Allows the ability to reset (erase) a source's existing settings and
replace them with new settings. This is useful for things such as
reverting to older settings.
2021-04-30 18:37:38 -07:00
jp9000
0fd1238d45 libobs: Add functions to backup/restore filters
Adds functions to backup and restore filters (along with their order) on
a specified source. Useful for undo/redo operations.
2021-04-30 00:11:52 -07:00
jp9000
09ffab6f90 libobs: Add helper func to find a scene by name 2021-04-16 20:28:14 -07:00
Exeldro
b9a2fe7851 libobs: Add transition save/load functions
Moves the transition saving/loading to functions, and refactors existing
code to use those functions instead.
2021-04-11 10:10:54 -07:00
jp9000
d332a8ea76 libobs: Add obs_source_is_scene() 2021-04-09 04:30:30 -07:00
jp9000
33c5563c1e libobs: Add obs_obj_is_private()
Returns true if an obs object is considered private. (Author's note: the
concept of "private" objects is not ideal, but we're stuck with it for
now)
2021-04-09 04:30:30 -07:00
jp9000
ca08df9fb2 libobs: Add obs_source_load2()
Allows loading a source and all of its filters automatically.
Previously, the original obs_source_load would not load filters.
2021-04-09 04:30:29 -07:00
jp9000
0ecf24d0ed libobs: Add obs_source_enum_full_tree()
Allows the ability to enumerate all sources and subsources in a source's
hierarchy, regardless of whether they're active or not.
2021-04-09 04:30:29 -07:00
jpark37
9220316700 libobs: Add filter functions for SRGB support
This way, legacy filters can use the original functions without
triggering SRGB support.
2021-04-04 00:58:38 -07:00
Jim
5d87f3c00b
Merge pull request #3426 from Programatic/undo_redo
UI: Implement Undo/Redo System
2021-03-30 03:16:24 -07:00
Ford Smith
3a620c485e UI: Undo/Redo Transformations
Implements undo/redo for transformations of sources, both through
preview and the transformations properties.
2021-03-29 03:06:26 -04:00
Ford Smith
60d95cb5bd UI/libobs: Undo/Redo Sources and Scenes
Implements the Undo/Redo for scenes and sources, ranging from renaming,
deletion, addition. It also adds several elements to libobs that were
designed to facilitate undo/redo, and should not affect the rest of
libobs.
2021-03-29 03:06:26 -04:00
Exeldro
32e7ba1abe UI: Add visibility transitions
This also modifies libobs.

This adds the ability for scene items to have transitions
when their visibility is toggled.
2021-03-16 22:15:16 -07:00
Anton Bershanskiy
54cbd98d91 libobs: add helper for source filter count
Add function size_t obs_source_get_filter_count(obs_source_t *source)
which returns the number of filters a source has. Update docs for it.
2021-03-16 21:38:06 -07:00
Jim
2eca4d80b6
Merge pull request #2233 from VodBox/missing-files-dialog
libobs + UI: Add Missing Files API & Dialog
2021-01-31 08:02:16 -08:00
Clayton Groeneveld
99d10c2607 libobs: Add function to get module lib
This adds a function find module library.

Co-authored-by: Stéphane Lepin <stephane.lepin@gmail.com>
2021-01-26 03:31:31 -08:00
VodBox
fb95e1d1e9 libobs: Add missing file API to sources 2021-01-17 10:31:58 +13:00
jp9000
ebbe8d1bf9 libobs: Change service max res. to res. list
(This commit also modifies rtmp-services and UI)

Changes the maximum resolution size to a resolution list, and splits the
maximum FPS to its own function.

(Note: ABI has not been modified because the last changes still haven't
been released yet, so it's safe to modify this as long as the changes
haven't been officially released)
2020-11-13 18:22:53 -08:00
jp9000
fb7747c56e libobs: Implement obs_service func to get max bitrates
(This commit also modifies rtmp-services)

Implements obs_service_get_max_bitrate, which allows retrieving the
maximum audio/video bitrates directly rather than being forced to use
the apply method. Makes it a bit easier to get the bitrate values.
2020-11-11 09:42:26 -08:00
Colin Edwards
7b0d7c6357 Remove BUILD_CAPTIONS build flag 2020-11-02 22:46:55 -06:00
Colin Edwards
923f06bfa6 decklink: Add ability to ingest/embed cea 708 captions
(This commit also modifies libobs, UI)
2020-11-01 22:28:49 -08:00
jp9000
e4c6b59852 libobs: Add ability to get max cx/cy/fps from service
This obs_service_t object callback was implemented specifically for
services which may have a maximum recommended width, height, and
framerate that needs to be enforced.
2020-10-30 00:28:44 -07:00
Clayton Groeneveld
2b50263d5c UI, libobs: Add ability to copy/paste single filter 2020-10-15 10:14:22 -07:00
jp9000
d45017370b libobs: Add functions to get locale text from modules
Useful for sharing translated text from modules with the frontend.  This
is technically already done via properties, but it would be nice to just
be able to explicitly look up locale text directly rather than have to
go through properties.
2020-08-10 12:24:01 -07:00
jp9000
de2e89d972 libobs: Add function to get module pointer
Useful for getting getting locale text associated with a specific module
2020-08-10 12:24:01 -07:00
jp9000
d117908440 libobs: Add func to set async video frame immediately
Allows the ability to directly override the current async frame
immediately.
2020-07-29 13:59:49 -07:00
Richard Stanway
5e3e9c1f13 obs-ffmpeg: Use new encoder error handling functions 2020-04-12 17:05:19 +02:00
Richard Stanway
5dc9f989d6 libobs: Add support functions for encoder error handling
Similar to how outputs can pass errors, add the same functionality for
encoders so that if an output encoder has an error, it is made available
to the output and eventually the UI / user.
2020-04-12 17:05:19 +02:00
jp9000
8de20ab3be libobs: Add task scheduling features
(This commit also modifies the UI)

Adds the ability to schedule tasks for certain threads
2020-03-14 10:54:37 -07:00
jp9000
b2302902a3 libobs: Fix source type versioning system
(This also modifies image-source, obs-text, text-freetype2, and UI)

This improves source definition versioning.  To do this, it now stores
two identifier names.  One "unversioned" which is the original name, and
one "versioned" with the version number appended.

This fixes both backward compatibility with older OBS versions, and
fixes the inability to use "add existing" in OBS itself on sources
created from older version definitions.
2020-03-09 06:12:22 -07:00
jp9000
b9d6675e2c libobs: Add ability to rotate async sources 2020-03-01 03:39:54 -08:00
jp9000
de363d3e09 libobs: Add obs_encoder_scaling_enabled()
Returns whether rescaling is enabled for an encoder.  This will be used
with texture-based encoders to determine whether to fall back to
RAM-based encoding instead.
2020-02-18 20:58:58 -08:00
jp9000
99e639015f libobs: Add group functions that can signal refresh
Adds API:
obs_scene_add_group2
obs_scene_insert_group2
obs_sceneitem_group_ungroup2

These functions should be used by plugins if they need to use these
functions and need to send a refresh signal.  If a major API rework ever
happens the old functions should be removed.  The old functions should
eventually be deprecated.

The reason why specifying a 'signal' parameter is useful is because it's
a bit more seamless for the user interface to be able to have custom
handling of these specific cases.  It looks better and doesn't require
completely erasing/recreating the entire list, which is visually
unappealing.
2020-02-07 16:45:04 -08:00
Clayton Groeneveld
f9ccea5235 libobs: Add media control support to backend 2020-01-30 21:40:20 -08:00
jp9000
3aa08c4e0f libobs: Add obs_scene_find_source_recursive
Same as obs_scene_find_source but also searches groups within the scene.
2020-01-27 14:36:53 -08:00
jpark37
00f280ff9d libobs: Rename DEPRECATED to OBS_DEPRECATED
Avoid collisions with other libraries that define DEPRECATED.
2020-01-20 21:44:50 -08:00
jp9000
2d35f863da libobs: Add manual transition "torque" support
Allows the ability for manual transitioning to smoothly flow
(interpolate) to the intended transition point over a short period of
time rather than simply setting a hard transition point number.  Doing
this allows manual transitioning to occur more smoothly, and in a more
visually pleasant way.
2019-12-27 16:38:20 -08:00
Clayton Groeneveld
a97039db64 libobs: Add manual transitioning support (T-bar)
Allows the ability to manually specify the transitioning point so the
user can transition at a custom rate, usually done by a device that can
be used as a T-bar

Co-authored-by: Jim <obs.jim@gmail.com>
2019-12-27 16:38:20 -08:00
Clayton Groeneveld
82ffcdc827 UI: Add source icons 2019-11-24 20:50:42 -08:00
Exeldro
e5ae662e7a libobs: Export obs_group_from_source
Export obs_group_from_source to allow it to be used externally
2019-10-15 09:21:21 -07:00
luz.paz
d124e6402c docs/sphinx: Fix various typos
(This modifies UI, libobs, deps/obs-scripting, various cmake files)

Found using:
`codespell -q 3 -S *.ini,./UI/data/locale,./deps/w32-pthreads -L aci,dur,iff,mut,numer,uint`
2019-10-14 17:19:38 -07:00
jp9000
65c7e2d19d libobs: Add API to get last OBS version of a source
Allows the ability to change the behavior of a source depending on the
previous OBS version.
2019-09-20 00:13:51 -07:00
jp9000
33c09d91c2 libobs: Add funcs to determine whether audio active
Adds functions to allow sources to inform the UI whether the audio is
currently active or not.  Allows the ability to turn on/off the items in
the mixer.
2019-09-19 23:37:29 -07:00