Commit graph

66 commits

Author SHA1 Message Date
Wim Taymans 6efb5c9b6b bus: add GDestroyNotify to set_sync_handler() 2012-06-20 12:29:35 +02:00
Tim-Philipp Müller ed80a5cd4b registry: rename gst_registry_get_default() to gst_registry_get()
It's not really a default if there is only one that can't be changed.

Should we return a ref like e.g. g_volume_monitor_get() does?
2012-01-02 02:22:51 +00:00
Wim Taymans ba3028aeeb pad: Add GstPadProbeInfo
Make a new GstPadProbeInfo structure and pass this in the probe callback. This
allows us to add more things later and also allow the callback to replace or
modify the passed object.
2011-11-08 11:04:19 +01:00
Wim Taymans 24e596a1fb pad: rework pad probes
Make a separate cookie to detect chancges in the list of probes and keeping
track of what hooks have been invoked yet.
Remove the requirement to have probes on srcpads in push mode and sinkpads in
pull mode.
Add some more debug.
Keep track of what callbacks got executed. If no callback is called and we are a
blocking pad, let the item pass. This allows you to block pads on selected
items only.
Explicitly have an UPSTREAM and DOWNSTREAM PadProbeType. This allows you to only
block the pad on upstream or downstream items.
Add convenience macros to only block on downstream/upstream items.
2011-11-07 17:15:17 +01:00
Wim Taymans a8cc106ba8 tests: fix tests
Since blocks are not on both directions, we need to check in the block callback
if we are not blocking on an upstream event and let it pass.
2011-11-04 18:47:10 +01:00
Tim-Philipp Müller bffc9207b5 pad: rename GstProbeType and GstProbeReturn to GstPadProbe{Type,Return}
Better now than later in the cycle. These might come in handy:

sed -i -e 's/GstProbeReturn/GstPadProbeReturn/g'   `git grep GstProbeReturn  | sed -e 's/:.*//' | sort -u`
sed -i -e 's/GST_PROBE_/GST_PAD_PROBE_/g'          `git grep GST_PROBE_      | sed -e 's/:.*//' | sort -u`
sed -i -e 's/GstProbeType/GstPadProbeType/g'       `git grep GstProbeType    | sed -e 's/:.*//' | sort -u`
2011-11-01 00:15:17 +00:00
René Stadler 5800757369 Revert gst_plugin_feature_get_name to const string return
Returning a newly allocated string makes no sense. It's unexpected for a
getter, and also this behaves differently in 0.10, so it would make future
merges harder.

Except for these two places here in core which were updated for the new
semantic, the return value is getting leaked all over the place.
2011-10-19 23:40:10 +02:00
Edward Hervey e60fa7cb48 tests: Fix more leaks 2011-10-11 13:54:45 +02:00
Tim-Philipp Müller 26b1496b15 tests: fix compiler warnings in sinks test 2011-10-07 13:55:18 +01:00
Sebastian Dröge 43538e2e75 Merge branch 'master' into 0.11
Conflicts:
	docs/design/draft-buffer2.txt
	docs/design/part-TODO.txt
	docs/design/part-block.txt
	docs/design/part-bufferlist.txt
	docs/design/part-caps.txt
	docs/design/part-element-transform.txt
	docs/design/part-events.txt
	docs/design/part-negotiation.txt
	gst/gstcaps.c
	gst/gstevent.h
	gst/gstghostpad.c
	gst/gstinterface.c
	gst/gstpad.c
	gst/gstpad.h
	gst/gstutils.c
	libs/gst/base/gstbasesink.c
	libs/gst/base/gstbasesrc.c
	libs/gst/base/gstbasetransform.c
	libs/gst/base/gsttypefindhelper.c
	plugins/elements/gstcapsfilter.c
	plugins/elements/gsttee.c
	tests/check/generic/sinks.c
	tools/gst-launch.1.in
2011-09-08 14:28:23 +02:00
Piotr Fusik 14f5518f3d docs, gst: typo fixes
https://bugzilla.gnome.org/show_bug.cgi?id=658449
2011-09-07 18:03:17 +01:00
Wim Taymans d8d7c62789 basesink: remove preroll-queue-len property
Remove the preroll-queue-len property and move its variables to a private
section so that we can remove them later.
2011-08-25 12:38:58 +02:00
Tim-Philipp Müller 6248fefaa5 tests: update for query API changes 2011-07-28 11:24:19 +01:00
Wim Taymans 3f51563319 pad: further improve probes and pad blocking
Keep track of installed number of probes to shortcut emission.
Allow NULL callbacks, this is useful for blocking probes.
Improve probe selection based on the mask, an empty mask for the data or the
scheduling flags equals that all probes match.
Add some more debug info.
Don't check the flushing flag in the probe callback handler, this needs to be
done before calling the handler.
Fix blocking probes.
Fix unit tests
2011-06-01 19:39:20 +02:00
Wim Taymans fce85f75ff pad: Rework pad blocking, another attempt
Make the PadBlock callback take a GstBlockType parameter to handle the different
kind of stages in the pad block. This provides for more backwards compatibility
in the pad block API.
Separate blocking and unblocking into different methods, only blocking can do a
callback, unblock is always immediately. Also removed synchronous blocking, it
can always be implemented with a callback.
2011-05-30 18:29:06 +02:00
Wim Taymans 565f492af2 Revert "pad: rework pad blocking, first part"
This reverts commit 415da89f3c.

Conflicts:

	gst/gstpad.c
2011-05-30 13:40:04 +02:00
Wim Taymans 415da89f3c pad: rework pad blocking, first part
Make pad block call the callback as soon as the pad is not in use. This makes it
possible to make sure that when the callback is called, no activity is happening
on the pad and that no activity will ever happen until the pad is unblocked
again. This makes pad blocking work when there is no dataflow or after EOS and
greatly helps dynamic pipelines.
Move the probe handling right where we wait on the pad block. The two are
related but not the same and the probe can eventually influence the pad
blocking as we'll se later.
Fix up some broken unit tests or tests that fail with the new behaviour.
2011-05-27 17:37:20 +02:00
Wim Taymans f4f4fa5e8f pad: remove old gst_pad_set_blocked methods 2011-05-26 16:17:31 +02:00
Wim Taymans bdbc069348 Rework GstSegment handling
Improve GstSegment, rename some fields. The idea is to have the GstSegment
structure represent the timing structure of the buffers as they are generated by
the source or demuxer element.
gst_segment_set_seek() -> gst_segment_do_seek()
Rename the NEWSEGMENT event to SEGMENT.
Make parsing of the SEGMENT event into a GstSegment structure.
Pass a GstSegment structure when making a new SEGMENT event. This allows us to
pass the timing info directly to the next element. No accumulation is needed in
the receiving element, all the info is inside the element.
Remove gst_segment_set_newsegment(): This function as used to accumulate
segments received from upstream, which is now not needed anymore because the
segment event contains the complete timing information.
2011-05-16 11:37:52 +02:00
Wim Taymans c07b57fc05 segment: remove _full version
Rename the _full versions of the functions to the normal function names.
2011-05-09 17:51:07 +02:00
Wim Taymans 17bb26b529 check: add more sink unit tests 2010-12-28 16:40:28 +01:00
Wim Taymans a813aad0ac basesink: rework position reporting code
Unify the different position reporting code paths to make it more
understandable.
Use start_time to get more accurate position reporting in paused.
Fix unit tests for more accurate reporting.
2010-12-02 19:10:46 +01:00
Wim Taymans 9076d5688f basesink: also preroll after a flush with async=false
Make sure to preroll after a flush even when we are async=false.
Add unit test.

Fixes #634965
2010-12-02 19:10:45 +01:00
Wim Taymans 6c47a2e69d check: lock src state to avoid error cases
Lock the state of the src element or else the pipeline might go into the error
state when we set it to PAUSED later.
2010-12-02 19:10:44 +01:00
Stefan Kost d2aa01c2de checks: and check the right env-var (fixup last commit) 2010-09-09 21:59:29 +03:00
Stefan Kost 6a3e15373c tests: allow running state tests for all elements
Now one can use GST_NO_STATE_IGNORE_ELEMENTS=1 make generic/states.check
to try elements that would normaly be skipped.
2010-09-09 21:56:28 +03:00
Wim Taymans e93b94afdf libs/gst/base/gstbasesink.c: Improve position reporting in the flushing state.
Original commit message from CVS:
* libs/gst/base/gstbasesink.c: (gst_base_sink_render_object),
(gst_base_sink_event), (gst_base_sink_chain_unlocked),
(gst_base_sink_negotiate_pull), (gst_base_sink_pad_activate_pull),
(gst_base_sink_get_position), (gst_base_sink_change_state):
Improve position reporting in the flushing state.
Also report the position when we are not yet prerolled but we
have a newsegment event. Fixes #543444.
Improve the pull-based negotiation code.
* tests/check/elements/fakesink.c: (GST_START_TEST),
(fakesink_suite):
Add testcase for position reporting while flushing in PAUSED and
PLAYING.
* tests/check/generic/sinks.c: (GST_START_TEST):
Update unit-test, we can now query the position as soon as we receive a
NEWSEGMENT event.
2008-08-19 16:47:07 +00:00
Wim Taymans cc8334905c Don't use gst_element_get_pad().
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_load_and_link):
* gst/gstutils.c: (gst_element_link_pads),
(gst_element_unlink_pads):
* libs/gst/check/gstcheck.c: (gst_check_setup_src_pad),
(gst_check_teardown_src_pad), (gst_check_setup_sink_pad),
(gst_check_teardown_sink_pad),
(gst_check_element_push_buffer_list):
* tests/check/elements/fakesink.c: (GST_START_TEST):
* tests/check/elements/filesink.c:
* tests/check/elements/filesrc.c: (GST_START_TEST):
* tests/check/elements/multiqueue.c: (setup_multiqueue),
(mq_sinkpad_to_srcpad):
* tests/check/elements/tee.c: (GST_START_TEST):
* tests/check/generic/sinks.c: (GST_START_TEST):
* tests/check/gst/gstbin.c: (GST_START_TEST):
* tests/check/gst/gstevent.c: (GST_START_TEST):
* tests/check/gst/gstghostpad.c: (GST_START_TEST):
* tests/check/gst/gstpipeline.c: (GST_START_TEST):
* tests/check/gst/gstquery.c: (GST_START_TEST):
* tests/check/gst/gstutils.c: (GST_START_TEST):
* tests/check/libs/basesrc.c: (GST_START_TEST):
* tests/check/pipelines/parse-launch.c: (run_delayed_test),
(gst_parse_test_element_change_state):
Don't use gst_element_get_pad().
2008-05-21 15:57:52 +00:00
Sebastian Dröge 58cc2ede0a And correct even more valid sparse warnings.
Original commit message from CVS:
* gst/gstelementfactory.h:
* tests/check/elements/fakesink.c:
* tests/check/elements/fakesrc.c: (setup_fakesrc):
* tests/check/elements/fdsrc.c: (setup_fdsrc):
* tests/check/elements/filesink.c: (setup_filesink):
* tests/check/elements/filesrc.c: (setup_filesrc):
* tests/check/elements/identity.c: (setup_identity):
* tests/check/elements/tee.c:
* tests/check/generic/sinks.c:
* tests/check/generic/states.c: (setup), (teardown):
* tests/check/gst/gst.c:
* tests/check/gst/gstabi.c:
* tests/check/gst/gstbin.c:
* tests/check/gst/gstbus.c: (pull_messages):
* tests/check/gst/gstcaps.c:
* tests/check/gst/gstelement.c:
* tests/check/gst/gstevent.c:
* tests/check/gst/gstghostpad.c:
* tests/check/gst/gstiterator.c:
* tests/check/gst/gstmessage.c:
* tests/check/gst/gstminiobject.c: (my_foo_init):
* tests/check/gst/gstobject.c: (thread_name_object),
(gst_object_suite):
* tests/check/gst/gstpad.c:
* tests/check/gst/gstplugin.c:
* tests/check/gst/gstpoll.c:
* tests/check/gst/gstquery.c:
* tests/check/gst/gstsegment.c:
* tests/check/gst/gststructure.c:
* tests/check/gst/gstsystemclock.c:
* tests/check/gst/gsttask.c:
* tests/check/gst/gstutils.c:
* tests/check/gst/gstvalue.c:
* tests/check/gst/struct_hppa.h:
* tests/check/gst/struct_i386.h:
* tests/check/gst/struct_ppc32.h:
* tests/check/gst/struct_ppc64.h:
* tests/check/gst/struct_x86_64.h:
* tests/check/libs/adapter.c: (create_and_fill_adapter):
* tests/check/libs/basesrc.c:
* tests/check/libs/controller.c: (GST_START_TEST):
* tests/check/libs/gdp.c:
* tests/check/libs/gstnetclientclock.c:
* tests/check/libs/gstnettimeprovider.c:
* tests/check/libs/libsabi.c:
* tests/check/libs/struct_hppa.h:
* tests/check/libs/struct_i386.h:
* tests/check/libs/struct_ppc32.h:
* tests/check/libs/struct_ppc64.h:
* tests/check/libs/struct_x86_64.h:
* tests/check/pipelines/cleanup.c:
* tests/check/pipelines/simple-launch-lines.c:
* tests/check/pipelines/stress.c:
And correct even more valid sparse warnings.
* win32/common/libgstreamer.def:
Add gst_poll_fd_init to the list of symbols.
2008-02-29 13:59:24 +00:00
Jan Schmidt f2c36159ef gst/gst.c: _gst_trace_on is already provided by gsttrace.h, no need to declare it ourselves.
Original commit message from CVS:
* gst/gst.c:
_gst_trace_on is already provided by gsttrace.h, no need to declare
it ourselves.
* docs/libs/gstreamer-libs-sections.txt:
Add 'buffers', 'check_cond' and 'check_mutex' from libgstcheck
and remove strange tcase_add_test which is outputting a warning.
* libs/gst/check/gstcheck.c:
* libs/gst/check/gstcheck.h:
Properly declare 'buffers', 'check_cond', 'check_mutex' extern
and define them in gstcheck.c instead of having every .c file whcih
includes gstcheck.h be defining its own copy and relying on symbol
interposing to marry them all, which doesn't work on Solaris.
* tests/check/elements/identity.c: (GST_START_TEST):
Don't define 'buffers' locally, it comes from libgstcheck.
* tests/check/generic/sinks.c: (send_buffer):
Fix type of variable (GstFlowReturn, not GstStateChangeReturn)
* tests/check/gst/gststructure.c: (GST_START_TEST):
* tests/check/gst/gstsystemclock.c: (GST_START_TEST):
* tests/check/gst/gstutils.c: (GST_START_TEST):
* tests/check/gst/gstvalue.c: (GST_START_TEST):
Add a bunch of casts to make various constants fit the types
they're being assigned to.
2008-01-12 20:22:30 +00:00
Tim-Philipp Müller 34cdb9b9d2 tests/check/generic/sinks.c: Put back the tcase_set_timeout(), apparently it's needed after all; fix it up in a way t...
Original commit message from CVS:
* tests/check/generic/sinks.c: (gst_sinks_suite):
Put back the tcase_set_timeout(), apparently it's needed after
all; fix it up in a way that makes things work with valgrind too.
2007-12-30 13:31:17 +00:00
Tim-Philipp Müller dd739adfa7 tests/check/generic/sinks.c: Fix leak in unit test (bus sync handler must unref the message if it returns GST_BUS_DRO...
Original commit message from CVS:
* tests/check/generic/sinks.c: (async_done_func),
(async_done_eos_func):
Fix leak in unit test (bus sync handler must unref the message
if it returns GST_BUS_DROP). Don't fiddle with the default test
timeout, this is smaller than the current preconfigured value
via CK_DEFAULT_TIMEOUT, and also breaks things with valgrind
because it overrides the value specified in CK_DEFAULT_TIMEOUT.
2007-12-28 13:57:05 +00:00
Wim Taymans 9e50fa303e libs/gst/base/gstbasesink.c: Don't try to report a 0 position when we don't know, return -1 and FALSE instead. This m...
Original commit message from CVS:
* libs/gst/base/gstbasesink.c: (gst_base_sink_get_sync_times),
(gst_base_sink_do_sync), (gst_base_sink_preroll_object),
(gst_base_sink_event), (gst_base_sink_get_position_last),
(gst_base_sink_get_position_paused), (gst_base_sink_get_position),
(gst_base_sink_change_state):
Don't try to report a 0 position when we don't know, return -1 and FALSE
instead. This mostly happens when we are prerolling.
Make sure we can report the right position before we post the ASYNC_DONE
message so that a message handler can query position without races.
* tests/check/generic/sinks.c: (send_eos), (GST_START_TEST),
(async_done_handoff), (async_done_func), (send_buffer),
(async_done_eos_func), (gst_sinks_suite):
Add two tests for the above.
2007-11-06 10:33:22 +00:00
Wim Taymans de5d9793d7 libs/gst/base/gstbasesink.c: When we received EOS and are waiting for when to post the EOS message, our state is prer...
Original commit message from CVS:
* libs/gst/base/gstbasesink.c: (gst_base_sink_preroll_queue_flush),
(gst_base_sink_queue_object_unlocked),
(gst_base_sink_queue_object), (gst_base_sink_event),
(gst_base_sink_needs_preroll), (gst_base_sink_chain_unlocked):
When we received EOS and are waiting for when to post the EOS message,
our state is prerolled and we should not return ASYNC.
Reorganize some code paths to implement this behavior.
* tests/check/generic/sinks.c: (send_eos), (GST_START_TEST),
(gst_sinks_suite):
Add unit test to verify above EOS fix.
2007-10-08 17:05:06 +00:00
Stefan Kost 1120543704 tests/check/generic/states.c: Improved state change unit test.
Original commit message from CVS:
* tests/check/generic/states.c:
Improved state change unit test.
2007-09-20 10:36:23 +00:00
Wim Taymans 9b24336ce5 gst/gstbin.c: Always change the state of a NO_PREROLL element even if it has ASYNC elements inside (in case of a bin).
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_element_set_state):
Always change the state of a NO_PREROLL element even if it has ASYNC
elements inside (in case of a bin).
* tests/check/generic/sinks.c: (GST_START_TEST), (gst_sinks_suite):
Unit test for this case.
2007-08-14 13:37:16 +00:00
Wim Taymans 0b3153873b gst/gstbin.*: Immediatly commit the toplevel bin state when receiving an async-done message. This enables us to avoid...
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_init), (gst_bin_add_func),
(gst_bin_remove_func), (gst_bin_get_state_func),
(gst_bin_element_set_state), (gst_bin_continue_func),
(bin_push_state_continue), (bin_handle_async_start),
(bin_handle_async_done), (gst_bin_handle_message_func):
* gst/gstbin.h:
Immediatly commit the toplevel bin state when receiving an async-done
message. This enables us to avoid spawning a thread to commit the state
in some common cases and it also avoids some races.
Avoid spawning a state thread when adding/removing async elements to a
toplevel bin. Instead we immediatly update the bin state.
Get rid of iterating all the children when getting the state in the bin
because it is now always up-to-date.
Fix bug where locked elements would always return _SUCCESS even it they
returned NO_PREROLL before being locked.
Fix the order of the state_change, async-start/done messages that was
sometimes incorrect.
Mark the state_dirty field as deprecated, we don't need it anymore as we
are always up-to-date.
* gst/gstelement.c: (gst_element_get_state_func),
(gst_element_continue_state):
Small debug inprovements.
Return the previous element state return when nothing is pending instead
of blindly returning SUCCESS.
* tests/check/generic/sinks.c: (GST_START_TEST), (pad_blocked_cb),
(gst_sinks_suite):
Add a whole bunch of new testcases.
2007-06-18 15:12:28 +00:00
Wim Taymans d14c4c4a67 docs/gst/gstreamer-sections.txt: Add new element field and method.
Original commit message from CVS:
* docs/gst/gstreamer-sections.txt:
Add new element field and method.
* gst/gstbin.c: (gst_bin_class_init), (gst_bin_init),
(bin_remove_messages), (gst_bin_add_func), (gst_bin_remove_func),
(gst_bin_recalc_state), (gst_bin_get_state_func),
(gst_bin_element_set_state), (gst_bin_change_state_func),
(gst_bin_continue_func), (bin_bus_handler),
(bin_push_state_continue), (bin_handle_async_start),
(bin_handle_async_done), (gst_bin_handle_message_func):
Make async state changes a bit smarter by using new ASYNC_START and
ASYNC_DONE messages. This reduces the number of times we run the state
recalculation thread.
Don't change state of element with a pending ASYNC_START message.
Deprecate STATE_DIRTY messages.
* gst/gstelement.c: (gst_element_init), (gst_element_send_event),
(gst_element_get_state_func), (gst_element_continue_state),
(gst_element_lost_state), (gst_element_set_state_func),
(gst_element_change_state):
* gst/gstelement.h:
Keep the state that was last set by the app in a new element field.
Don't allow state changes when handling an element event.
Post ASYNC_START and ASYNC_DONE messages.
Change lost_state so that we go to PAUSED and wait for the parent to set
us to PLAYING again (so latency calculation can be performed)
Export gst_element_change_state() method so that subclasses can use it.
API: gst_element_change_state()
API: GST_STATE_TARGET
* gst/gstpipeline.c: (gst_pipeline_class_init),
(reset_stream_time), (gst_pipeline_change_state),
(gst_pipeline_handle_message), (gst_pipeline_set_new_stream_time):
Using the new ASYNC_START message we can reset the base_time when
needed. This can then be used to implement base_time redistribution in
flushing seeks so that we can remove the explicit seek handling.
Perform latency query and configuration when going to PLAYING.
* libs/gst/base/gstbasesink.c: (gst_base_sink_commit_state),
(gst_base_sink_query), (gst_base_sink_change_state):
Post new ASYNC_START/ASYNC_DONE messages.
* tests/check/generic/sinks.c: (GST_START_TEST):
Fix test because the bin will not set the async element to PLAYING right
away.
* tests/check/gst/gstbin.c: (pop_async_done), (GST_START_TEST):
Make the message check a little stronger.
Handle ASYNC messages.
* tests/check/pipelines/cleanup.c: (GST_START_TEST):
* tests/check/pipelines/simple-launch-lines.c: (GST_START_TEST):
Expect ASYNC_DONE messages.
2007-03-19 10:47:56 +00:00
Thomas Vander Stichele 7d42056b8e plug test leak
Original commit message from CVS:
plug test leak
2007-02-28 12:57:42 +00:00
Thomas Vander Stichele 155fa0066d tests/check/generic/states.c: Copy the current generic/states example from -base and adapt so we can use the exact sa...
Original commit message from CVS:
* tests/check/generic/states.c: (GST_START_TEST), (states_suite):
Copy the current generic/states example from -base and adapt so
we can use the exact same code everywhere.
Check a STATES_IGNORE_ELEMENTS env var which can be used
to ignore certain element factories for this test, which is
what is being done in -base
* tests/check/Makefile.am:
Mention this environment variable.
2007-02-28 12:40:45 +00:00
Thomas Vander Stichele cb65f3e99f moap ignore
Original commit message from CVS:
moap ignore
2006-07-02 22:20:20 +00:00
Thomas Vander Stichele 64086e2970 tests/check/: use the new macro
Original commit message from CVS:
* tests/check/elements/fakesink.c:
* tests/check/elements/fakesrc.c:
* tests/check/elements/fdsrc.c:
* tests/check/elements/identity.c:
* tests/check/generic/sinks.c: (gst_sinks_suite):
* tests/check/generic/states.c:
* tests/check/gst/gst.c:
* tests/check/gst/gstabi.c:
* tests/check/gst/gstbin.c:
* tests/check/gst/gstbuffer.c: (gst_buffer_suite):
* tests/check/gst/gstbus.c: (gst_bus_suite):
* tests/check/gst/gstcaps.c: (GST_START_TEST):
* tests/check/gst/gstelement.c:
* tests/check/gst/gstevent.c: (gst_event_suite):
* tests/check/gst/gstghostpad.c:
* tests/check/gst/gstiterator.c: (gst_iterator_suite):
* tests/check/gst/gstmessage.c: (gst_message_suite):
* tests/check/gst/gstminiobject.c:
* tests/check/gst/gstobject.c:
* tests/check/gst/gstpad.c:
* tests/check/gst/gstpipeline.c:
* tests/check/gst/gstplugin.c:
* tests/check/gst/gstquery.c: (gst_query_suite):
* tests/check/gst/gstsegment.c: (gst_segment_suite):
* tests/check/gst/gststructure.c:
* tests/check/gst/gstsystemclock.c:
* tests/check/gst/gsttag.c:
* tests/check/gst/gsttask.c: (gst_task_suite):
* tests/check/gst/gstutils.c:
* tests/check/gst/gstvalue.c:
* tests/check/libs/adapter.c:
* tests/check/libs/basesrc.c:
* tests/check/libs/collectpads.c:
* tests/check/libs/controller.c:
* tests/check/libs/gdp.c: (gst_dp_suite):
* tests/check/libs/gstnetclientclock.c:
* tests/check/libs/gstnettimeprovider.c:
* tests/check/libs/libsabi.c: (libsabi_suite):
* tests/check/libs/typefindhelper.c:
* tests/check/pipelines/cleanup.c:
* tests/check/pipelines/parse-launch.c:
* tests/check/pipelines/simple-launch-lines.c:
* tests/check/pipelines/stress.c: (stress_suite):
use the new macro
2006-07-01 20:56:56 +00:00
Michael Smith 26bb3efc1a tests/check/generic/sinks.c: Fix a variety of memleaks in sinks check, which are only sometimes shown by running the ...
Original commit message from CVS:
* tests/check/generic/sinks.c: (GST_START_TEST):
Fix a variety of memleaks in sinks check, which are only sometimes
shown by running the tests under valgrind (weird?).
2006-04-05 12:11:20 +00:00
Jan Schmidt 1559c57a8e gst/gstutils.c: Don't leak pad references.
Original commit message from CVS:
* gst/gstutils.c: (gst_element_unlink_pads):
Don't leak pad references.

* tests/check/elements/fakesink.c: (GST_START_TEST):
* tests/check/generic/sinks.c: (GST_START_TEST):
* tests/check/generic/states.c: (GST_START_TEST):
* tests/check/gst/gstbin.c: (GST_START_TEST):
* tests/check/gst/gstcaps.c: (GST_START_TEST):
* tests/check/gst/gstelement.c: (GST_START_TEST):
* tests/check/gst/gstghostpad.c: (GST_START_TEST):
* tests/check/gst/gstiterator.c: (GST_START_TEST):
* tests/check/gst/gstvalue.c: (GST_START_TEST):
Fix a bunch of leaks. Make generic/sinks.c
use a bit less cpu by slowing the buffer rate
between fakesrc and fakesink.
2006-01-28 00:59:37 +00:00
Thomas Vander Stichele 4344994d69 ignore more
Original commit message from CVS:
ignore more
2005-11-30 16:32:22 +00:00
Wim Taymans 82a38aff77 check/states/sinks.c: Uncomment fixed check.
Original commit message from CVS:
* check/states/sinks.c: (GST_START_TEST):
Uncomment fixed check.

* docs/design/part-TODO.txt:
Updated TODO.

* gst/base/gstbasesink.c: (gst_base_sink_commit_state),
(gst_base_sink_handle_object), (gst_base_sink_do_sync),
(gst_base_sink_get_position):
If we are going to PLAYING, post the right pending state
when we post the intermediate paused message.

* gst/gstelement.c: (gst_element_continue_state),
(gst_element_set_state_func), (gst_element_change_state):
Don't post state changes that were between the same state
and were not ASYNC.
2005-11-03 20:14:24 +00:00
Andy Wingo e2200c1f82 check/states/sinks.c (test_livesrc_sink): Add checks that the state-changed messages actually have the right order an...
Original commit message from CVS:
2005-11-03  Andy Wingo  <wingo@pobox.com>

* check/states/sinks.c (test_livesrc_sink): Add checks that the
state-changed messages actually have the right order and the right
values.
2005-11-03 17:53:27 +00:00
Wim Taymans 43fe0b06e9 check/states/sinks.c: Added some more checks. Specifically the case where NO_PREROLL elements are in the pipeline.
Original commit message from CVS:
* check/states/sinks.c: (GST_START_TEST), (gst_object_suite):
Added some more checks. Specifically the case where NO_PREROLL
elements are in the pipeline.

* gst/base/gstbasesink.c: (gst_base_sink_commit_state),
(gst_base_sink_handle_object), (gst_base_sink_do_sync),
(gst_base_sink_get_position):
Post READY->PAUSED state change messages too.
Fix bug where VOID was posted as pending state...

* gst/gstbin.c: (gst_bin_recalc_state):
use _element_continue_state() to continue the state change.

* gst/gstelement.c: (gst_element_continue_state),
(gst_element_commit_state), (gst_element_set_state_func),
(gst_element_change_state), (gst_element_change_state_func):
Lots of state change cleanups, assign the STATE_RETURN in
a new continue_state() function that also propagates the
last return value from a state change to the app.
Update some debug statements with proper category.
2005-11-03 17:12:00 +00:00
Wim Taymans 6d0be74351 Use GstClockTime in _get_state() instead of GTimeVal.
Original commit message from CVS:
* check/gst/gstbin.c: (GST_START_TEST):
* check/gst/gstelement.c: (GST_START_TEST):
* check/gst/gstevent.c: (GST_START_TEST), (test_event):
* check/gst/gstghostpad.c: (GST_START_TEST):
* check/gst/gstpipeline.c: (GST_START_TEST):
* check/pipelines/simple_launch_lines.c: (run_pipeline):
* check/states/sinks.c: (GST_START_TEST):
* gst/elements/gsttypefindelement.c: (stop_typefinding):
* gst/gstbin.c: (gst_bin_provide_clock_func), (gst_bin_add_func),
(gst_bin_remove_func), (gst_bin_get_state_func),
(gst_bin_recalc_state), (gst_bin_change_state_func),
(bin_bus_handler):
* gst/gstelement.c: (gst_element_get_state_func),
(gst_element_get_state), (gst_element_abort_state),
(gst_element_commit_state), (gst_element_set_state),
(gst_element_change_state), (gst_element_change_state_func):
* gst/gstelement.h:
* gst/gstpipeline.c: (gst_pipeline_class_init), (do_pipeline_seek),
(gst_pipeline_provide_clock_func):
* gst/gstutils.c: (gst_element_link_pads_filtered):
* tools/gst-launch.c: (main):
* tools/gst-typefind.c: (main):
Use GstClockTime in _get_state() instead of GTimeVal.
Remove old code in gstutils.c
2005-10-12 12:18:48 +00:00
Wim Taymans cc28efc239 check/: Moved sinks2 testcode in sinks check.
Original commit message from CVS:
* check/Makefile.am:
* check/states/sinks.c: (GST_START_TEST), (gst_object_suite):
* check/states/sinks2.c:
Moved sinks2 testcode in sinks check.

* gst/gstbin.c: (gst_bin_provide_clock_func), (gst_bin_add_func),
(gst_bin_remove_func), (gst_bin_recalc_state),
(gst_bin_change_state_func), (bin_bus_handler):
Fix potential race condition when _get_state() iterated over an
ASYNC element right before it posted a state completion.

* gst/gstclock.h:
Do proper cast here.

* gst/gstevent.c: (gst_event_new_newsegment),
(gst_event_parse_newsegment):
A playback rate of 0.0 is not allowed.
2005-10-12 08:38:06 +00:00