Commit graph

839 commits

Author SHA1 Message Date
Nicolas Dufresne
194db480e0 bufferpool: Add an helper to validate config
When we call gst_buffer_pool_set_config() the pool may return FALSE and
slightly change the parameters. This helper is useful to do the minial required
validation before accepting the modified configuration.

https://bugzilla.gnome.org/show_bug.cgi?id=727916
2014-05-08 13:11:14 -04:00
Nicolas Dufresne
6079666a71 bufferpool: Add support for reconfiguring a pool
If a pool config is being configured again, check if the configuration have changed.
If not, skip that step. Finally, if the pool is active, try deactivating it.

https://bugzilla.gnome.org/show_bug.cgi?id=728268
2014-05-08 13:08:21 -04:00
Nicolas Dufresne
64aa64cb80 value: Add support for GstAllocationParams comparision
This is useful to compare buffer pool configuaration.

https://bugzilla.gnome.org/show_bug.cgi?id=728268
2014-05-08 13:08:21 -04:00
Nicolas Dufresne
00614e2c2b value: Add support for GObject comparising in structures
This is useful to allow comparing pool configuration where a GstAllocator
is set.

https://bugzilla.gnome.org/show_bug.cgi?id=728268
2014-05-08 13:08:21 -04:00
Jan Schmidt
4d7d3a1c02 Fix extended message handling with gst_bus_pop_timed_filtered()
Make sure extended message types don't get accidentally matched
when not asked for in the mask
2014-03-17 06:29:27 +11:00
Tim-Philipp Müller
1b7c5c4d64 tests: add test for extended message types and gst_bus_timed_pop_filtered 2014-03-16 14:38:07 +00:00
Wim Taymans
7691150c45 bufferpool: only release buffers with writable memory
Check if the memory is writable before releasing the buffer into the
pool again.
Add unit test for this scenario.
2014-02-27 16:40:34 +01:00
Wim Taymans
f22d8f08e0 bufferpool: Use TAG_MEMORY to check memory before releasing
Tag allocated buffers with TAG_MEMORY. When they are released later,
only add them back to the pool if the tag is still there and the memory
has not been changed, otherwise throw the buffer away.
Add unit test to check various scenarios.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=724481
2014-02-27 15:43:13 +01:00
Sebastian Dröge
ab9fdf13a0 structure: Add getters for int64 and uint64 values 2014-02-25 15:41:45 +01:00
Tim-Philipp Müller
7644c8a3c5 tests: fix leak in systemclock test 2014-02-08 23:39:03 +00:00
Matthieu Bouron
97103c90b0 tests: add caps features unit tests
https://bugzilla.gnome.org/show_bug.cgi?id=723236
2014-02-04 18:47:23 +01:00
Stefan Sauer
c42780db66 bufferpool: more tests and small doc fixes 2014-01-31 08:36:55 +01:00
Stefan Sauer
f9a5a24211 bufferpool: add a new testsuite or the pool
Start with some basic tests.
2014-01-30 12:43:45 +01:00
Sebastian Dröge
af84535569 iterator: Add unit tests for filtering, recursive filtering and locking
https://bugzilla.gnome.org/show_bug.cgi?id=711138
2014-01-18 14:48:54 +01:00
Wim Taymans
6c95262447 tests: improve check, also check stream-time 2014-01-08 15:47:10 +01:00
Wim Taymans
b5e4e24e75 tests: add unit test for segment _offset_running_time()
Add a unit test to check that positive and negative offsets are applied
correctly in various cases.
2014-01-08 15:31:28 +01:00
Sebastian Dröge
9e125e7bab pad: Add unit test for adding/removing blocking probes while a pad is blocked
And make sure that these new probes are actually called if they should
instead of silently blocking the pad forever.

https://bugzilla.gnome.org/show_bug.cgi?id=721289
2014-01-02 13:34:52 +01:00
Edward Hervey
3ea6b04c10 gstvalue: Fix comparision of double range
Checking twice the lower bound is great (you never know, it might change
between the two calls by someone using emacs butterfly-mode), but it's a bit
more useful to check the higher bound are also identical.

Detected by Coverity
2013-12-10 18:01:52 -05:00
Tim-Philipp Müller
9a62f007fc tests: add unit test for registering the same category twice 2013-12-07 19:04:16 +00:00
Sebastian Rasmussen
e8ecf3c407 Fix some typos in code comments and debug messages
https://bugzilla.gnome.org/show_bug.cgi?id=720029
2013-12-07 17:09:39 +00:00
Tim-Philipp Müller
47679cf2f8 tests: fix GstBus unit test with latest GLib
g_source_remove() works on the default main context, and
we're doing things with a custom context. Fixes warning
with newer GLib versions.
2013-11-18 15:28:32 +00:00
Sebastian Dröge
5286479467 value: Lists with all equal elements are equal to a single value
Otherwise caps containing f={X, X} are not compatible with f=X

https://bugzilla.gnome.org/show_bug.cgi?id=709253
2013-11-13 19:57:23 +01:00
Wim Taymans
02b64ee03b systemclock: Add gst_system_clock_set_default
Used for setting the default system clock that is obtained through
gst_system_clock_obtain(), which is sometimes needed for unit
testing.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=711269
2013-11-11 12:25:14 +01:00
Sebastian Dröge
4429ea53c4 caps: Skip test_subset_duplication until the bug is fixed
https://bugzilla.gnome.org/show_bug.cgi?id=709253
2013-10-10 13:19:09 +02:00
Sebastian Dröge
eb0d978e1e caps: Add a testcase for subset checks on lists with duplicated items
https://bugzilla.gnome.org/show_bug.cgi?id=709253
2013-10-10 12:42:52 +02:00
Thiago Santos
007c0e5fe1 value: fix caps serialization when there are caps inside caps
Wrap caps strings so that it can handle serialization and deserialization
of caps inside caps. Otherwise the values from the internal caps are parsed
as if they were from the upper one

https://bugzilla.gnome.org/show_bug.cgi?id=708772
2013-09-30 16:20:48 -03:00
Sebastian Dröge
8f0c9c7055 context: Add test for the context caching in GstBin
https://bugzilla.gnome.org/show_bug.cgi?id=708668
2013-09-24 13:11:47 +02:00
Sebastian Dröge
921ab73340 context: Fix unit test for GstContext changes 2013-09-18 21:42:42 +02:00
Olivier Crête
f90f3cde5f buffer: Fix gst_buffer_memcmp() where the buffer is smaller than size
Also add unit tests for gst_buffer_memcmp

https://bugzilla.gnome.org/show_bug.cgi?id=706162
2013-08-20 14:41:27 -04:00
Sebastian Dröge
0b3bd4b954 tests: Remove other interface structs from the ABI tests too 2013-07-24 10:31:02 +02:00
Thiago Santos
6da1778dad tests: Remove GstTagSetter from ABI checks
Interfaces can have new members added without breaking ABI, so
remove it from the check.

https://bugzilla.gnome.org/show_bug.cgi?id=623799
2013-07-24 10:31:02 +02:00
Sebastian Dröge
4fc1ba1e60 buffer: Add unit test for map_range()
https://bugzilla.gnome.org/show_bug.cgi?id=702617
2013-06-19 10:45:45 +02:00
Sebastian Dröge
2253f8fa6f pad: Fix memory leak in the unit test 2013-05-29 11:36:38 +02:00
Sebastian Dröge
114f9584d4 tests: Fix event order warnings and dataflow before stream-start/segment event 2013-05-09 13:32:07 +02:00
Tim-Philipp Müller
913b1e6f20 tests: add some basic checks for gst_buffer_fill() 2013-05-08 10:26:15 +01:00
Alessandro Decina
ef0e9b6840 tests: add check for FLUSH pad probes 2013-04-25 07:26:29 +02:00
Tim-Philipp Müller
c7a8318452 tests: ignore new test binary 2013-04-18 10:14:09 +01:00
Sebastian Dröge
03c3738b67 context: Add gst_context_writable_structure() and let get_structure() return const again 2013-04-18 10:18:22 +02:00
Tim-Philipp Müller
e8a9f7acdf printf: fix handling of old printf extension specifiers for ABI compatibility
Fixes abort when the old specifiers are used. Fix up the conversion
specifier, it would get overwritten with 'c' below to the extension
format char, which then later is unhandled, leading to the abort.
Also fix up and enable unit test for this.

https://bugzilla.gnome.org/process_bug.cgi
2013-04-18 00:46:58 +01:00
Tim-Philipp Müller
c398c842f5 tests: add unit test for old printf extension specifiers
To make sure we maintain binary compatibility with the old
specifiers.

https://bugzilla.gnome.org/show_bug.cgi?id=698242
2013-04-18 00:28:00 +01:00
Sebastian Dröge
f5f0dd50c8 context: Add unit test for GstContext 2013-04-17 12:44:29 +02:00
Tim-Philipp Müller
637e8b5e1c tests: skip all GstPoll tests on Windows
As they don't work there, and it's non-trivial to fix.

https://bugzilla.gnome.org/show_bug.cgi?id=697609
2013-04-13 12:20:06 +01:00
Руслан Ижбулатов
ff62f3f1e0 libsabi: Special struct size values for W32
These account for both possible type size mismatch AND -mms-bitfields
packing. Sizes are taken from an i686-w64-mingw32-built GStreamer,
gcc 4.8.0, mingw-w64 svn-r5685.

Fixes #697551
2013-04-09 20:10:46 +02:00
Руслан Ижбулатов
54aaba5f21 tests: fix GstPad test on windows and in CK_FORK=no mode
Need to clear buffer lists at the end of each test.

https://bugzilla.gnome.org/show_bug.cgi?id=697610
2013-04-09 09:56:57 +01:00
Sebastian Dröge
1de3b0f9e8 caps: Add test for operations on caps with ANY features 2013-04-06 21:21:39 +02:00
Tim-Philipp Müller
24cac0afa3 docs: more since markers and other docs fixes 2013-04-02 23:51:06 +01:00
Sebastian Dröge
65c650d7d4 capsfeatures: Add GST_CAPS_FEATURES_ANY
This is equal to any other caps features but results in unfixed caps. It
would be used by elements that only look at the buffer metadata or are
currently working in passthrough mode, and as such don't care about any
specific features.
2013-04-02 22:17:22 +02:00
Sebastian Dröge
7477b25df5 caps: Add new data type for handling caps features to the caps
These are meant to specify features in caps that are required
for a specific structure, for example a specific memory type
or meta.

Semantically they could be though of as an extension of the media
type name of the structures and are handled exactly like that.
2013-03-31 18:15:52 +02:00
Tim-Philipp Müller
0e5c1dcf64 event: add stream flags to stream-start event
API: gst_event_set_stream_flags()
API: gst_event_parse_stream_flags()
API: GST_STREAM_FLAG_NONE
API: GST_STREAM_FLAG_SPARSE

https://bugzilla.gnome.org/show_bug.cgi?id=600648
2013-03-31 11:47:40 +01:00
Sebastian Dröge
7b00fd3701 caps: Add unit test for GST_CAPS_{ANY,NONE} and GST_STATIC_CAPS_{ANY,NONE}
https://bugzilla.gnome.org/show_bug.cgi?id=696435
2013-03-25 09:22:50 +01:00