Commit graph

3130 commits

Author SHA1 Message Date
Thibault Saunier
2c08770cf0 python: Add a better asset __repr__ 2019-07-26 13:48:51 -04:00
Thibault Saunier
a5fa2c35aa ges: Implement subprojects
Subprojects simply consist of adding the GESProject
to the main project asset list. Then those are recursively
serialized in the main project in the <asset> not, when deserializing,
temporary files are created and those will be used in clips
as necessary
2019-07-26 13:48:48 -04:00
Thibault Saunier
5f3adbc1a3 project: Fix our asset cache
It was not talking into account the fact that you can have
several assets with a same ID but different exactractable types.
2019-07-24 10:49:38 -04:00
Thibault Saunier
b8c897308d asset: Handle trying to proxy an asset to itself
And avoid infinite recursion
2019-07-15 10:30:44 -04:00
Thibault Saunier
902b8ad98e gesdemux: Detect recursively loading the same project file
And error out when it is the case.
2019-07-05 18:30:41 -04:00
Thibault Saunier
e9e24a23ba gesdemux: Create proper stream-ids 2019-07-05 18:30:41 -04:00
Thibault Saunier
b3bac67f58 nle: Check seeking on deeply nested composition 2019-07-05 18:30:41 -04:00
Thibault Saunier
bb10b9faa6 track: Disable last gap by default
And let the GESPipeline logic handle that
2019-07-05 18:30:41 -04:00
Thibault Saunier
91ff8a8110 nlecomposition: Drop all group-done but the last one 2019-07-05 18:30:41 -04:00
Thibault Saunier
99c45d42cf validate: Allow scenarios to set track types 2019-07-05 18:30:41 -04:00
Swayamjeet
147cbcd6e1 tests: Add ges-sample-path-recurse with projects location
So that project files are found when using nested timelines
2019-07-05 18:30:41 -04:00
Thibault Saunier
8bf3256ddf validate: Add a way to use validate configs with scenarios
Config files should have the-scenario-name.scenario.config to be picked automatically
2019-07-05 18:30:41 -04:00
Thibault Saunier
b8b9441adb validate: Use proper sink and give them good names 2019-07-05 18:30:41 -04:00
Thibault Saunier
5e4555c6b3 validate: Create folders as needed when serializing timelines 2019-07-05 18:30:41 -04:00
Thibault Saunier
e5045b33d5 nlesource: Wait for the seek to actualy happen before removing the probe
Make sure that an event resulting from the seek happens before removing
the pad probe, dropping anything while it is not the case.

This guarantees that the seek happens before `nlesource` outputs
anything. This was not necessary as with decodebin or usual source
flushing seeks lead to synchronous flush_start/flush_stop and we could
safely assume that once the seek is sent, it was happenning.
With nested `nlecomposition` this assumption is simply not true as
in the composition seeks are basically cached and happen later in
the composition updating thread.

This fixes races where we ended up removing the blocking probe before
the seek actually started to be executed in the nlecomposition
nested inside an nlesource which leaded to data from *before* the seek
to be outputed which means we could display wrong frames,
and it was leading to interesting deadlocks.
2019-07-05 18:30:41 -04:00
Thibault Saunier
e97c90fa40 nlecomposition: Minor debugging enhancements 2019-07-05 18:11:04 -04:00
Thibault Saunier
564505e16f uri-asset: Fix retrieving a relocated asset sync twice
Add a simple test for that.
2019-07-05 18:11:04 -04:00
Thibault Saunier
a2b0dd3859 timeline: Make adding/removing track MT safe
It was almost the case already so make it happen fully
2019-07-05 18:11:04 -04:00
Thibault Saunier
1eb05b0b71 nlecomposition: Ensure flushes after seek have the right seqnum
Seeks that lead to a stack change lead to deactivating the current
stack. At that point we explicitely flush downstream as a reaction to
the flushing seek. Until now those flushes had a random seqnum, this
fails if we are a nested compostion as the parent composition will end
up dropping that flush which in turns might lead to deadlocks. For
example, the flush goes through a `compositor` which wants to flush
downstream to stop its srcpad task, but that flush wouldn't have
"released" its srcpad thread if the composition srcpad drops it, meaning
it won't be able to stop the task ever.
2019-07-05 18:11:04 -04:00
Thibault Saunier
e903f15380 nlecomposition: Shutdown children when setting state to NULL
Otherwise if we shutdown a composition whith an nested composition
(inside a source in the test) and leak it, we end up with the nested
composition task still running (in READY) which is bad.

Add a test for that which leaks the pipeline on purpose.
2019-07-05 18:01:51 -04:00
Thibault Saunier
351182ba2a nle: Parent the GstTask to ourself
This allows accessing the nlecomposition in gdb when a task is
'dangling' making debugging easier.
2019-07-05 18:01:07 -04:00
Swayamjeet
ad6d1964af tests: Implement nested timelines tests 2019-07-05 18:00:33 -04:00
Thibault Saunier
c1206df0bb nlecomposition: Properly set seqnum on flush events 2019-07-05 18:00:09 -04:00
Thibault Saunier
eb53e62c6d timeline: Drop ASYNC_/START/DONE messages
When we have nested timelines, we do not want those messages to pop
to the parent timelines as we handle the sequence ourself in the
timeline.
2019-07-05 17:58:13 -04:00
Thibault Saunier
6d895ea111 demux: Create timeline from the streaming thread
First marshilling it to the main thread is dangerous as it is a blocking
operation and it should never happen there.

The asset cache is MT safe now so it is possible to load the timeline
from that thread directly
2019-07-05 17:57:04 -04:00
Thibault Saunier
61c952c714 uri-asset: Implement multi threading support
Making sure to have 1 GstDiscoverer per thread.

Use that new feature in gesdemux by loading the timeline directly from
the streaming thread. Modifying the timeline is not supported allowed
anyway.
2019-07-05 17:56:03 -04:00
Thibault Saunier
3d11893fd7 nle: Add a seeking test for nested composition 2019-07-05 17:54:40 -04:00
Thibault Saunier
cb96d0287e Use the new GstDiscoverer caching feature 2019-07-05 17:54:29 -04:00
Thibault Saunier
31ccb3106f timeline: Do not post upstream translated composition update messages
In the case of nested timeline in the toplevel timeline we ended up
with CompositionUpdate for seeks sent by our own composition to
granchildren composition. This was not causing essential issues
if all tracks where containing nested timelines but in cases
where one of the tracks only had a nested timelines, then we
were waiting forever for a `CompositionUpdateDone`.

CompositionUpdate translated into ASYNC_START/ASYNC_DONE should
be kept inside the GESTimeline and not travel up (possibly to some
parent GESTimeline).
2019-07-05 17:53:57 -04:00
Thibault Saunier
1e23799a24 structured-interface: Handle track-types in clip addition
The field was already expected in the launcher
2019-07-05 17:53:41 -04:00
Thibault Saunier
5ea4667be6 Implement and use the GstStream API 2019-07-05 17:53:15 -04:00
Thibault Saunier
5be359cf7f timeline: Create stable stream IDs 2019-07-05 17:52:55 -04:00
Thibault Saunier
63a49edf1f docs: Generate ges plugin doc 2019-07-05 17:52:50 -04:00
Thibault Saunier
aca18a29b5 plugins:ges: Factor out a GESBaseBin class
And use it in both gesdemux and gessrc
2019-07-05 17:50:57 -04:00
Thibault Saunier
db97b2c921 gesdemux: Emit no-more-pad as required 2019-07-05 17:50:52 -04:00
Thibault Saunier
d07fe11c5f nlecomposition: Respect seek seqnum in output EOS/SEGMENT
Allowing a proper seek EOS handling with nested compositions
2019-07-05 17:50:22 -04:00
Thibault Saunier
93289ac406 gesdemux: Properly combine flows 2019-07-05 17:49:07 -04:00
Thibault Saunier
cf43d9b6d4 plugin: Make use of G_DECLARE
And remove useless .h files
2019-07-05 17:48:23 -04:00
Thibault Saunier
032200577a xml-formatter: Plug some leaks 2019-07-05 17:47:53 -04:00
Thibault Saunier
90943667ce xml-formatter: Refactor the way we handle loading state 2019-07-05 17:47:39 -04:00
Thibault Saunier
33bac10cc8 xml-formatter: Cleanup removing all now useless pending fields 2019-07-05 17:45:20 -04:00
Thibault Saunier
14d1f558b1 xml-formatter: Load assets before their proxies
Paving the way to removing pending fields to make the code
simpler to follow.
2019-07-05 17:44:31 -04:00
Thibault Saunier
5774d5256a assets: Recurse in the chain of proxies
When linking loaded proxies and trying to setup their targets
2019-06-16 23:20:12 -04:00
Thibault Saunier
d0b4b87b1e docs: Add gstges plugin 2019-06-06 09:48:39 -04:00
Thibault Saunier
7b1cb7a1d7 validate: Add action type to copy/paste clips 2019-06-05 00:43:48 +00:00
Thibault Saunier
b3e449fd4f container: Handle children pasting failures 2019-06-05 00:43:48 +00:00
Thibault Saunier
3b95bec095 clip: Fix layer managament when copying a clip that was pasted 2019-06-05 00:43:48 +00:00
Thibault Saunier
ded3a5fb2f element: Properly handle the fact that pasting can return NULL
And fix paste annotation
2019-06-05 00:43:48 +00:00
Niels De Graef
0f238144bf meson: Bump minimal GLib version to 2.44
This means we can use some newer features and get rid of some
boilerplate code using the G_DECLARE_* macros.

As discussed on IRC, 2.44 is old enough by now to start depending on it.
2019-06-02 21:35:25 +02:00
Mathieu Duponchelle
4c77b04fa1 doc: remove xml from comments 2019-05-29 23:12:11 +02:00