Commit graph

2133 commits

Author SHA1 Message Date
Thibault Saunier
903f30cb32 tools:launch: Properly terminate when we get a SIGINT signal 2014-11-10 16:22:41 +01:00
Thibault Saunier
20f76fe86f trackelement: Add a lookup_child vmethod
This method can be used for subclass to override the default behaviour
for child lookup. This vmethod can be used for example in the case where
you want the name of a child property to be 'overridden'.

As an example in the GESTitleSource where we have a videotestsrc
which has a 'foreground-color' property that is used in the TitleSource
to set the background color of the title, this vmethod is now used to
tweak the name passed as parameter to rename "background" to
"foreground-backend" making our API understandable.

API:
  GESTrackElement::lookup_child

https://bugzilla.gnome.org/show_bug.cgi?id=727880
2014-11-10 16:22:41 +01:00
Thibault Saunier
190643508f title: Deprecate all method related to child properties
The standard way setting children properties is by using the
GESTrackElement::set_child_propery and friend methods

https://bugzilla.gnome.org/show_bug.cgi?id=727880
2014-11-10 16:22:41 +01:00
Mathieu Duponchelle
0192c0e237 ges-validate: inform of clip removal. 2014-11-10 16:22:41 +01:00
Mathieu Duponchelle
3035bcb405 timeline: connect_after to layer.object_added.
We want the user provided signal handlers to be called before
we add track elements.
2014-11-10 16:22:41 +01:00
Mathieu Duponchelle
3f97397b4f nle: Downgrade some INFO to DEBUG.
+ makes it more pleasant to read logs in info.
2014-11-10 16:22:40 +01:00
Thibault Saunier
79230eef1f nle: Handle sending SEEK event recursively to our children
Instead of relying on it being implemented in core (as it is currently
not!)
2014-11-10 16:22:40 +01:00
Thibault Saunier
d3d1f85373 tests: Use audiomixer as an audio mixing element
Adder is the past!
2014-11-10 16:22:40 +01:00
Thibault Saunier
ca0ce859de validate: Implement validate Action type to handle KeyFrames
New action types:
  * set-control-binding
  * add-keyframe
  * remove-keyframe
2014-11-10 16:22:40 +01:00
Thibault Saunier
c4f43c88f2 track-element: Add a signal about added control bindings
API:
  GESTrackElement::control-binding-added
2014-11-10 16:22:40 +01:00
Thibault Saunier
24e2c88180 track-element: Add an API to list all set ControlBinding
API:
    ges_track_element_get_all_control_bindings
2014-11-10 16:22:40 +01:00
Thibault Saunier
a022b4b394 title-source: Properly expose children properties
+ Make sure that the TitleClip properties are not serialized anymore as
  they are serialized through children properties now.

+ Enhance debugging for not serialized properties in GESXmlFormatter.
2014-11-10 16:22:40 +01:00
Mathieu Duponchelle
19ee23cdcc nlecomposition: update base time before seeking current stack.
There could be a race where the new segments were pushed after
a seek on some / all pads before the operation had had its basetime
updated, and thus incoming segments were tweaked wrongly.

Reproducible with 3 clips composited and multiple seeks,
FIXME hard to validate.
2014-11-10 16:22:39 +01:00
Joris Valette
84610050ae formatter: save and load source's children properties 2014-11-10 16:22:39 +01:00
Joris Valette
b89ffaea82 tests: project: Add children properties check
Rename test_project_add_keyframes into test_project_add_properties
2014-11-10 16:22:39 +01:00
Thibault Saunier
e8fd816e33 project: Do not concider adding am already tracked asset as failure
It is not really a failure, just a special case.
2014-11-10 16:22:39 +01:00
Thibault Saunier
6d8f744f7f ges-validate: Add actions to add/remove object from container
+ Add an action to set an asset on a GESTimelineElement
2014-11-10 16:22:39 +01:00
Thibault Saunier
c0a0c1f582 ges-validate: Fix edit_container return code
It used to always return FALSE.

+ Fix minor leaks
+ Do not seek ourself, it is users responsability to seek and
commit these days.
2014-11-10 16:22:39 +01:00
Thibault Saunier
bc7a465fcd extractable: Make extractable_set_asset return a boolean
WARNING: This is a minor API breakage, it should be harmless
and allows us to let users know whether changing setting the
asset worked or no.
2014-11-10 16:22:39 +01:00
Thibault Saunier
0cdec2c2d0 ges-validate: Add an action type to set restriction caps on track 2014-11-10 16:22:38 +01:00
Thibault Saunier
92cb5811e7 tools: Handle asset relocation for assets from scenario
Allowing us to share scenario and media file!
2014-11-10 16:22:38 +01:00
Thibault Saunier
4691210030 ges-validate: Add support for Layer.auto-transition
+ Fix a bug where the mandatory field name for the name of the clip to
remove in remove-clip did not correspond to what we used in the action
(clip-name vs name).
2014-11-10 16:22:38 +01:00
Thibault Saunier
f362e81a29 ges-validate: Add commit and split-clip action types
And stop commit at the end of other action types, this now
has to be done in the scenario itself.
2014-11-10 16:22:38 +01:00
Thibault Saunier
8a6892ba0a ges-validate: Add start/inpoint/duration params to the add-clip action 2014-11-10 16:22:38 +01:00
Thibault Saunier
f4faa487ba tools:ges-launch: Save the project at the end of execution
So that changes from scenarios are taken into account
2014-11-10 16:22:38 +01:00
Thibault Saunier
6a371b308b nlecomposition: Fix the get_current_position method 2014-11-10 16:22:38 +01:00
Thibault Saunier
d419bccf4f nlecomposition: Wait for a buffer from the new segment to restart task
Avoiding races where we would launch a seek right after a FLUSH_STOP and
before we get a Buffer which would possibly lead to ERROR message when upstream
elements try to push a buffer and check_sticky fails because downstream
is flushing.
2014-11-10 16:22:37 +01:00
Thibault Saunier
578364ce41 nlecomposition: Do useless thing so that the compiler doesn't warn us!
Otherwize we get a gcc warning about useless statements.
2014-11-10 16:22:37 +01:00
Thibault Saunier
2d3769f079 tools:ges-launch: Do not set pipeline state before the timeline is ready
When we are loading a project
2014-11-10 16:22:37 +01:00
Thibault Saunier
2fb33d69f8 nlecomposition: Update start stop and duration on initialization
So that the composition is usable right after the initialization
2014-10-31 11:58:12 +01:00
Thibault Saunier
0d54d796de ges: Avoid to always commit when a project is loaded
In case we are not in a PLAYING state and the project is loaded, the
only thing that should be done is to fill the gaps and this way when the
composition get to PLAYING, their initialization will be enough to get
everything on track.
2014-10-31 11:58:12 +01:00
Thibault Saunier
57eef236b5 tests: Use the new gst_check_objects_destroyed_on_unref function 2014-10-31 11:58:12 +01:00
Thibault Saunier
95223fd46b Start taking advantage of the fact that NLE is in the same three as GES! 2014-10-31 11:58:12 +01:00
Thibault Saunier
50cf1fb5fe nlecomposition: Fix several leaks
* In the action closure invokation we were alway leaking the composition.
* gst_bin_add will actually take an extra ref since we already  gst_object_ref_sink so we
own the object, other call to that method will increase the refcount which means we do
not need to pass an extra ref to the bin.
* We want to ref_sink right when the object is added to the composition, making things
cleaner and simpler to follow in the tests.
2014-10-31 11:58:12 +01:00
Thibault Saunier
3e79e28213 nlecomposition: Activate the composition ghostpad to flush downstream
Since commit 060b16ac75
"pad: don't accept flush-stop on inactive pads" in -core, the flush_stop event will not be
fowarded downstream in case the pad is not activated. In our case the element is in
READY state, so pads are deactivated. In that commit we simply make sure that the
event can be fowarded downstream
2014-10-31 11:58:12 +01:00
Thibault Saunier
02665dae91 nlecomposition: Restart the main task on FLUSH_STOP
It means stop using a dedicated probe to restart task so that the main probe does not
drop the FLUSH_STOP event before we have a chance to restart the task. (and this is
for sure cleaner/and simpler to read).
2014-10-31 11:58:12 +01:00
Thibault Saunier
37f50193fd nle:source: Protect the probeid field with the GST_OBJECT_LOCK
Avoiding races where we try to remove a probe on an already destroyed pad.
2014-10-31 11:58:12 +01:00
Thibault Saunier
03c284abb6 framepositionner: Add a weak pointer to the track_source
Avoiding assertions when the object is destroyed.
2014-10-31 11:58:12 +01:00
Mathieu Duponchelle
e31d0554c8 nle: Seek gnlsource when prerolled only
Instead of implementing seek on ready all around GStreamer, just
seek in PAUSED, when the source gets 'prerolled'.
2014-10-31 11:58:12 +01:00
Thibault Saunier
6bd27667eb ges-track: Do not set removed object state
It is the composition to handle
2014-10-31 11:58:12 +01:00
Thibault Saunier
8913c14c58 nle: Stop using a MainContext avoiding needing one iter per source dispach
Using GClosure to handle the source handling and handle our action
ordering ourselves

https://bugzilla.gnome.org/show_bug.cgi?id=733342
2014-10-31 11:58:12 +01:00
Thibault Saunier
aa69de7514 ges: Use audiomixer instead of adder by default 2014-10-31 11:58:12 +01:00
Thibault Saunier
b3336fe26e Port to the new NLE API
Port the timeline, track and pipeline to the new NLE API where
all objects have static src pads.
2014-10-31 11:58:12 +01:00
Thibault Saunier
11f9c6e108 Cleanup import of GNL and rename gnl to nle for Non Linear Engine
Conflicts:
	ges/ges-track-element.c
	gnl/Makefile.am
	gnl/common

Conflicts:
	ges/ges-internal.h
	ges/ges-track.c
	ges/ges-utils.c
	ges/nle/.gitignore
	ges/nle/gnlmarshal.list
	ges/nle/nle.h
	ges/nle/nlecomposition.c
	ges/nle/nlecomposition.h
	ges/nle/nleghostpad.c
	ges/nle/nleghostpad.h
	ges/nle/nleobject.c
	ges/nle/nleoperation.c
	ges/nle/nleoperation.h
	ges/nle/nlesource.c
	ges/nle/nlesource.h
	ges/nle/nletypes.h
	ges/nle/nleurisource.c
	ges/nle/nleurisource.h
	gnl/Makefile.am
	gnl/gnl.c
	gnl/gnl.h
	gnl/gnl/gnl.h
	gnl/gnl/gnlcomposition.c
	gnl/gnl/gnlcomposition.h
	gnl/gnl/gnlghostpad.c
	gnl/gnl/gnlghostpad.h
	gnl/gnl/gnlmarshal.list
	gnl/gnl/gnlobject.c
	gnl/gnl/gnloperation.c
	gnl/gnl/gnloperation.h
	gnl/gnl/gnlsource.c
	gnl/gnl/gnlsource.h
	gnl/gnl/gnltypes.h
	gnl/gnl/gnlurisource.c
	gnl/gnl/gnlurisource.h
	gnl/gnlcomposition.c
	gnl/gnlcomposition.h
	gnl/gnlghostpad.c
	gnl/gnlghostpad.h
	gnl/gnlmarshal.list
	gnl/gnlobject.c
	gnl/gnlobject.h
	gnl/gnloperation.c
	gnl/gnloperation.h
	gnl/gnlsource.c
	gnl/gnlsource.h
	gnl/gnltypes.h
	gnl/gnlurisource.c
	gnl/gnlurisource.h
	gnl/tests/check/gnl/common.c
	gnl/tests/check/gnl/common.h
	gnl/tests/check/gnl/complex.c
	gnl/tests/check/gnl/gnlcomposition.c
	gnl/tests/check/gnl/gnloperation.c
	gnl/tests/check/gnl/gnlsource.c
	gnl/tests/check/gnl/seek.c
	gnl/tests/check/gnl/simple.c
	tests/check/gnl/common.c
	tests/check/gnl/common.h
	tests/check/gnl/complex.c
	tests/check/gnl/gnlcomposition.c
	tests/check/gnl/gnloperation.c
	tests/check/gnl/gnlsource.c
	tests/check/gnl/seek.c
	tests/check/gnl/simple.c
	tests/check/nle/common.c
	tests/check/nle/common.h
	tests/check/nle/complex.c
	tests/check/nle/nlecomposition.c
	tests/check/nle/nleoperation.c
	tests/check/nle/nlesource.c
	tests/check/nle/seek.c
	tests/check/nle/simple.c
2014-10-31 11:58:12 +01:00
Thibault Saunier
aa1ba05895 composition: Commit all values before initializing the pipeline 2014-10-31 11:58:12 +01:00
Mathieu Duponchelle
f5073e4e58 composition: Prevent update sources from being added after seek. 2014-10-31 11:58:12 +01:00
Mathieu Duponchelle
4dd0b6fe14 composition: only flush stop after seek was set to READY. 2014-10-31 11:58:12 +01:00
Thibault Saunier
ee54d98fe2 composition: Also ignore all messages from children tearing them to READY
At that stage elements should not be taken into account anymore. In some
spacial cases they can post ERROR messages (when trying to push sticky
events on flushing pads) on the bus. We actually do not care about those
issues at that exact point.
2014-10-31 11:58:12 +01:00
Thibault Saunier
8154a2c96f composition: Do not try to paused the task that could have been stopped
There was a race where we ended up trying to update the pipeline and
stop our children task at the exact moment where we were actually
setting its state to PAUSED. Take the composition lock and make sure
that can't happen
2014-10-31 11:58:11 +01:00
Thibault Saunier
463626ceae composition: Post messages on the bus when it updates itself
And properly set the seqnums of those messages so that the application,
parents have the exact information about what is going on and why.
2014-10-31 11:58:11 +01:00