After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 341435 - [GnlComposition]] Implement default sources
[GnlComposition]] Implement default sources
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gnonlin
git master
Other All
: Normal normal
: 0.10.5
Assigned To: GStreamer Maintainers
Edward Hervey
Depends on:
Blocks:
 
 
Reported: 2006-05-11 16:06 UTC by Jono Bacon
Modified: 2006-08-18 11:04 UTC
See Also:
GNOME target: ---
GNOME version: 2.13/2.14



Description Jono Bacon 2006-05-11 16:06:42 UTC
Please describe the problem:
I have written a script that plays three bits of audio with a couple of seconds
gap between them. With the current gnonlin HEAD, the gaps are not played and
instead the three clips are played one after the other without the gap.

These are my gnlfilesource properties:

		self.ins1 = Instrument(self, 1)
		self.event1 = Event("/home/jono/media/audioforjokosher/spheres.mp3", 1)
		self.event1.audio.set_property("start", 0 * gst.SECOND)
		self.event1.audio.set_property("duration", 2 * gst.SECOND)
		self.event1.audio.set_property("media-start", 80 * gst.SECOND)
		self.event1.audio.set_property("media-duration", 2 * gst.SECOND)
		self.ins1.addEvent(self.event1)

		self.event2 = Event("/home/jono/media/audioforjokosher/alive.mp3", 2)
		self.event2.audio.set_property("start", 7 * gst.SECOND)
		self.event2.audio.set_property("duration", 2 * gst.SECOND)
		self.event2.audio.set_property("media-start", 130 * gst.SECOND)
		self.event2.audio.set_property("media-duration", 2 * gst.SECOND)
		self.ins1.addEvent(self.event2)

		self.event3 = Event("/home/jono/media/audioforjokosher/seed.mp3", 3)
		self.event3.audio.set_property("start", 12 * gst.SECOND)
		self.event3.audio.set_property("duration", 2 * gst.SECOND)
		self.event3.audio.set_property("media-start", 10 * gst.SECOND)
		self.event3.audio.set_property("media-duration", 2 * gst.SECOND)
		self.ins1.addEvent(self.event3)

Steps to reproduce:
1. Specify a time gap between gnlfilesources.
2. 
3. 


Actual results:
The audio is played one after other, with no gap.

Expected results:
The time between two elements where no audio is playing should be silent - at
the moment it is ignored.

Does this happen every time?
Yes.

Other information:
Comment 1 Edward Hervey 2006-05-21 10:41:24 UTC
It shouldn't play gaps. The problem previously what the the gnlcomposition would stop after the first source (seeing nothing else to play at THAT position), which is now fixed (it will look for the next source, if any).

The composition will now emit the proper segments (with correct new segments).

To achieve what you want, you have to put 'blank' sources (producing silent audio) under your tracks.

Something we had in gnonlin 0.8 was default sources (which had a priority of G_MAXUINT). Those sources will be played when there's nothing else to be played, apply to the whole length of the composition, but will not be taken into account for the composition start/stop calculation.

I will look into hacking those back in shortly.
Comment 2 Edward Hervey 2006-05-21 10:41:59 UTC
Changing title accordingly.
Comment 3 Edward Hervey 2006-08-18 11:04:36 UTC
whoops, forgot to close this bug :) Already fixed in 0.10.5

2006-07-19  Edward Hervey  <edward@fluendo.com>

	* gnl/gnlcomposition.c: (gnl_composition_class_init),
	(hash_value_destroy), (gnl_composition_init), (get_stack_list),
	(update_start_stop_duration), (object_start_changed),
	(object_stop_changed), (object_priority_changed),
	(object_active_changed), (gnl_composition_add_object),
	(gnl_composition_remove_object):
	Add default sources properly (sources with prioriy of G_MAXUINT32).
	Update pipeline when:
	_ object is added/removed within current playing segment
	_ object within current playing segment whose start/stop/priority/active
	property changes.
	* tests/check/complex.c: (GST_START_TEST):
	* tests/check/gnlsource.c: (GST_START_TEST):
	Fixed tests to test more behaviours, including new ones.