Commit graph

2036 commits

Author SHA1 Message Date
Wim Taymans f05b0e222f Update for new seeking variable name
When seeking, the start value and type are now called start and start_type.
2012-07-27 15:24:52 +02:00
Wim Taymans dbb6d68999 tests: improve segment tests 2012-07-27 12:24:03 +02:00
Wim Taymans a2027b5e9b allocator: remove user_data from alloc vmethod
Remove the user_data from the alloc vmethod. Subclasses that implement a new
alloc function can also implement their own vmethod to pass extra arguments. We
can then also require that custom allocators implement an alloc function so that
gst_allocator_alloc() always works.
2012-07-27 12:17:29 +02:00
Wim Taymans 60382cd994 tests: remove segment accumulation checks
Remove the checks because there is no more segment accumulation.
2012-07-27 12:17:28 +02:00
Tim-Philipp Müller 3231ea6204 taglist: gst_tag_list_get_buffer*() => gst_tag_list_get_sample*()
Image tags and other tags are now of GstSample type.
2012-07-26 15:51:10 +01:00
Mark Nauwelaerts 9166014007 tests: gstbuffer: add tests for some mulitple map combinations 2012-07-19 13:51:52 +02:00
Mark Nauwelaerts 8620352efc tests: gstbuffer: extend buffer copy test 2012-07-19 13:13:33 +02:00
Edward Hervey 028b9a8dbb check: Avoid deadlock
Queries will be sent when pipeline goes down to NULL, which would
result in the probe being called ... but can't take the lock.
2012-07-18 12:07:26 +02:00
Stefan Sauer 840f905c2c bin: aggregate durations like in adder
Stop querying the duration once an element return unknown and return unknown
as a final result. This avoid eventually cutting off a stream too early.
Add a tests to docuement the behavior.
2012-07-16 20:54:17 +02:00
Tim-Philipp Müller 94f6ba9c0b base: make GstQueueArray private to coreelements for now
Keep it private until we have a reason to make it public.
2012-07-14 19:36:02 +01:00
Wim Taymans 02eebca16b pad: fix test raciness
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=679506
2012-07-13 09:43:59 +02:00
Tim-Philipp Müller 443075e5a4 tests: fix toc unit tests
Meant to check subsubentry, not subentry.
2012-07-09 20:11:32 +01:00
Tim-Philipp Müller 5b133bbdcf tests: minor toc test clean-up 2012-07-09 20:11:32 +01:00
Tim-Philipp Müller c427d8caa8 tests: turn toc check macros into proper functions
So we can see the line number of the check that fails.
2012-07-09 20:11:32 +01:00
Edward Hervey e219ede527 check: Update tests for new STREAM_START message 2012-07-09 20:31:45 +02:00
Edward Hervey e2326ac506 check: Ensure STREAM_START message is posted
A STREAM_START message is posted if and only if all sinks in the
bin/pipeline received the STREAM_START event
2012-07-09 20:31:45 +02:00
Edward Hervey d14f523d4a check: Unit test for EOS message
Make sure we get the aggregated message if and only if all sinks
received an EOS event
2012-07-09 20:31:45 +02:00
Wim Taymans f362f643ac memory: Make GstAllocator a GstObject
Make GstAllocator a GstObject instead of a GstMiniObject, like bufferpool.
Make a new gstallocator.c file. Make a GstAllocator subclass for the default
allocator.
2012-07-09 16:28:22 +02:00
Wim Taymans 10f3adfd9d clock: make abstract
Make the GstClock type abstract.
Fix a horrible hack in the clock unit test.
2012-07-09 16:28:22 +02:00
Tim-Philipp Müller 1ba0d6f6f6 toc: add gst_toc_dump() function for debugging
API: gst_toc_dump()
2012-07-09 13:12:27 +01:00
Tim-Philipp Müller c0c79188ca bus, clock: make sure these never have a floating ref
Clear the initial floating ref in the init function for
busses and clocks. These objects can be set on multiple
elements, so there's no clear parent-child relationship
here. Ideally we'd just not make them derive from
GInitiallyUnowned at all, but since we want to keep
using GstObject features for debugging, we'll just do
it like this.

This should also fix some problems with bindings, which
seem to get confused when they get floating refs from
non-constructor functions (or functions annotated to
have a 'transfer full' return type). This works now:

from gi.repository import GObject, Gst

GObject.threads_init()
Gst.init(None)

pipeline=Gst.Pipeline()
bus = pipeline.get_bus()
pipeline.set_state(Gst.State.NULL)
del pipeline;

https://bugzilla.gnome.org/show_bug.cgi?id=679286
https://bugzilla.gnome.org/show_bug.cgi?id=657202
2012-07-09 13:09:45 +01:00
Tim-Philipp Müller 52c0e856f7 tests: add more tests for datetime value serialisation/deserialisation
Esp. of partial datetimes.
2012-07-07 23:13:20 +01:00
Tim-Philipp Müller 93a2b6e9b3 value: use datetime serialise/deserialise functions for datetimes
This re-uses existing code and makes sure we properly serialise
and deserialise datetimes where not all fields are set (thus
fixing some warnings when serialising such datetimes).
2012-07-07 22:46:00 +01:00
Tim-Philipp Müller 1c43e3628d examples: fix debug log print formats in memory examples 2012-07-07 15:44:57 +01:00
Wim Taymans 408df31a48 memory: expose the GstAllocation structure
Expose the GstAllocation structure and provide an _init function. This makes it
easier to make 'subclasses' of the allocator that contain more info.
It also allows us to expose the flags on the allocator miniobject.
Make a flag to note that the allocator uses a custom alloc function.
2012-07-06 17:24:32 +02:00
Edward Hervey d3744d05dc check: gstcontroller.h doesn't exist anymore 2012-07-06 12:48:44 +02:00
Edward Hervey 0efc42aac7 check: Use consistencycheck on basesrc 2012-07-06 12:48:44 +02:00
Wim Taymans a39b13ff9f tests: remove unused includes 2012-07-06 09:11:48 +02:00
Wim Taymans 968de7b725 memory: add more examples
Add an example of a custom allocator with a custom API.
2012-07-05 18:07:52 +02:00
Wim Taymans 50cf7f6a08 memory: add gst_memory_init()
Add a method that memory implementations can call to initialize the standard
GstMemory structure.
Move the parent handling in the _free handler.
Rearrange some internal function parameters so that the order is consistent.
Add more memory examples
2012-07-05 17:11:01 +02:00
Wim Taymans b2b934a928 tests: add memory example 2012-07-05 16:17:20 +02:00
Tim-Philipp Müller 8ac900a515 tests: fix toc unit test build by removing toc query stuff there too 2012-07-05 12:27:14 +01:00
Sebastian Dröge dfd9b60221 toc: Make structures opaque and clean up function names and fields a bit 2012-07-05 12:29:02 +02:00
Wim Taymans 3b16efa1d1 miniobject: add lock functionality to GstMiniObject
Move the locking methods from GstMemory to GstMiniObject.
Add a miniobject flag to enable LOCKABLE objects. LOCKABLE objects can
use the lock/unlock API to control the access to the object.
Add a minobject flag that allows you to lock an object in readonly mode.
Modify the _is_writable() method to check the shared counter for LOCKABLE
objects. This allows us to control writability separately from the refcount for
LOCKABLE objects.
2012-07-05 11:19:16 +02:00
Mark Nauwelaerts 0f69f9e44a tests: gstbuffer: extend buffer copy test
... to check for independence of copied buffer.
2012-07-05 11:19:15 +02:00
Tim-Philipp Müller 3329f3f4e4 uri: there are valid URI protocols with only two letters, like fd://
We added a minimum length of three letters originally so we would
fail to recognise DOS/Windows-style filenames as valid URIs (as we
should). Two should be just fine as well.
2012-07-04 17:39:52 +01:00
Edward Hervey 041787ac82 check: New unit test for GstQueueArray 2012-07-04 17:46:54 +02:00
Tim-Philipp Müller 0bbeab52cc tests: make checks for from/to_g_date_time() actually work properly 2012-07-04 10:23:06 +01:00
Joshua M. Doe ba6fad9302 datetime: add conversion to/from GDateTime
Exposes existing constructor.

API: gst_date_time_to_g_date_time()
API: gst_date_time_new_from_g_date_time()

https://bugzilla.gnome.org/show_bug.cgi?id=679080
2012-07-04 10:22:41 +01:00
Tim-Philipp Müller 08c2c446a5 tests: add unit test for element re-use using fakesrc 2012-07-03 19:15:25 +01:00
Raimo Järvi 40e68e7760 tests: fix build of datetime unit test in Windows
Also include config.h for all the #ifdef HAVE_XYZ.

https://bugzilla.gnome.org/show_bug.cgi?id=676935
2012-07-02 11:44:31 +01:00
Tim-Philipp Müller 2506dc5fe2 tests: test datetime deserialisation a bit more 2012-06-27 23:01:13 +01:00
Tim-Philipp Müller d6e6391518 tests: fix bus leak in GstBin test_state_change_skip test
Still not valgrind clean though.
2012-06-27 20:52:52 +01:00
Tim-Philipp Müller f95996d97f tests: add some datetime serialisation/deserialisation tests
https://bugzilla.gnome.org/show_bug.cgi?id=678031
2012-06-27 13:51:42 +01:00
Lionel Landwerlin 8b3708ea8c configure: add --disable-tools and --disable-benchmarks options
Add option to avoid build binaries. When building for platforms like
android, you might want to not link any "final" binary, mostly because
it requires special link flags or other parts of code that aren't
in the C library.

https://bugzilla.gnome.org/show_bug.cgi?id=677621
2012-06-26 23:12:56 +01:00
Tim-Philipp Müller 2c532aa821 toc: put toc directly into event/message/query structure
Now that TOCs are refcounted and have a GType, we can just
stuff a ref of the TOC directly into the various toc
event/message/query structures and get rid of lots of
cracktastic GstStructure <-> GstToc serialisation and
deserialisation code. We lose some TOC sanity checking
in the process, but that should really be done when
it's being created anyway.
2012-06-26 20:43:50 +01:00
Tim-Philipp Müller 03ac16c1d8 tocsetter: clean up and update API for refcounted TOCs
Let's keep it simple for now:

gst_toc_setter_reset_toc() -> gst_toc_setter_reset()
gst_toc_setter_get_toc_copy() -> removed
gst_toc_setter_get_toc() -> returns a ref now
gst_toc_setter_get_toc_entry_copy() -> removed,
    use TOC functions instead
gst_toc_setter_get_toc_entry() -> removed,
    use TOC functions instead
gst_toc_setter_add_toc_entry() -> removed,
    to avoid problems with (refcount-dependent)
    writability of TOC; use TOC functions instead
2012-06-25 20:18:32 +01:00
Tim-Philipp Müller 8590be2861 tocsetter, gst-launch, tests: update for GstToc API changes 2012-06-24 20:15:19 +01:00
Tim-Philipp Müller bc28ebf08d sample: add compare function for GstSample
Should make gst_tag_list_is_equal() work properly with image tags.

https://bugzilla.gnome.org/show_bug.cgi?id=672637
2012-06-23 16:59:10 +01:00
Tim-Philipp Müller e4b6bcb7b9 tests: add unit test for gst_element_make_from_uri()
https://bugzilla.gnome.org/show_bug.cgi?id=645467
2012-06-23 14:43:26 +01:00