Commit graph

350 commits

Author SHA1 Message Date
Stefan Kost 05287354e3 gst/gstbin.c: Fix build with --gst-disable-gst-debug
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_element_set_state),
(iterator_activate_fold_with_resync), (gst_bin_continue_func),
(bin_handle_async_done), (gst_bin_handle_message_func):
Fix build with --gst-disable-gst-debug
2007-04-23 07:30:38 +00:00
Wim Taymans 9f3b0b8f3a gst/gstbin.c: Prepare for release where we warn against possible app breakage in the case of live pipelines along wit...
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_get_type), (gst_bin_element_set_state):
Prepare for release where we warn against possible app breakage in the
case of live pipelines along with an env var to enable/disable live
preroll mode (GST_COMPAT=[no-]live-preroll).
2007-03-21 11:52:04 +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
Sébastien Moutte 25b5fc7a7a gst/gstbin.c: Use GST_STR_NULL to prevent NULL pointer to be passed to GST_CAT_DEBUG.
Original commit message from CVS:
* gst/gstbin.c:(gst_bin_add):
Use GST_STR_NULL to prevent NULL pointer to be passed to GST_CAT_DEBUG.
* win32/common/libgstbase.def:
* win32/common/libgstreamer.def:
Add new exported functions.
2007-03-10 15:44:44 +00:00
Wim Taymans 05cf4d83c3 gst/gstbin.c: Also report the live parameter of a latency query.
Original commit message from CVS:
* gst/gstbin.c: (bin_query_min_max_init), (bin_query_latency_fold),
(bin_query_latency_done):
Also report the live parameter of a latency query.
2007-02-28 16:35:48 +00:00
Wim Taymans e561ce761b gst/gstbin.c: Improve debug info.
Original commit message from CVS:
* gst/gstbin.c: (bin_replace_message), (gst_bin_add_func),
(gst_bin_change_state_func), (bin_query_min_max_init),
(bin_query_latency_fold), (bin_query_latency_done),
(gst_bin_query):
Improve debug info.
Implement latency query.
2007-02-20 10:45:13 +00:00
Stefan Kost 85c81ea952 docs/libs/Makefile.am: Fix path to core docs.
Original commit message from CVS:
* docs/libs/Makefile.am:
Fix path to core docs.
* gst/gstbin.c: (gst_bin_get_by_interface),
(gst_bin_iterate_all_by_interface):
Refix docs by also renaming 'interface' to 'iface' in implementation.
* docs/gst/gstreamer-sections.txt:
* gst/gstcaps.c:
* gst/gstchildproxy.c: (gst_child_proxy_base_init):
* gst/gstchildproxy.h:
* gst/gstelementfactory.c:
* gst/gstpadtemplate.h:
* libs/gst/controller/gstcontroller.c:
(gst_controlled_property_new):
Document more.
2007-02-11 19:59:12 +00:00
Stefan Kost ea55e1357e configure.ac: comment about refining the xml deps
Original commit message from CVS:
* configure.ac:
comment about refining the xml deps
* docs/manuals.mak:
comments about moving away from jade for docs
* gst/gst.c:
recommit the ifdefs to use the binary registry
* gst/gstbin.c: (gst_bin_change_state_func):
this break is obsolete
* gst/gstelementfactory.h:
better GST_ELEMENT_DETAILS docs, add comment about translation
* gst/gstinfo.h:
remove eol slash
* gst/gstobject.c: (gst_signal_object_get_type):
add G_UNLIKELY as usual
* gst/gstpad.c: (gst_pad_event_default):
add fall trhu comment
* gst/gstregistrybinary.c: (gst_registry_binary_write),
(gst_registry_binary_initialize_magic),
(gst_registry_binary_save_string),
(gst_registry_binary_save_pad_template),
(gst_registry_binary_save_feature),
(gst_registry_binary_save_plugin),
(gst_registry_binary_write_cache),
(gst_registry_binary_check_magic),
(gst_registry_binary_load_pad_template),
(gst_registry_binary_load_feature),
(gst_registry_binary_load_plugin),
(gst_registry_binary_read_cache):
comment typo and formatting
* gst/gstutils.c: (gst_element_state_get_name),
(gst_element_state_change_return_get_name):
remove obsolete breaks
* gst/gstvalue.c: (gst_date_get_type), (_gst_value_initialize):
add FIXME 0.11 and remove cpp comment
2007-01-29 15:54:09 +00:00
Wim Taymans 57667ddd07 gst/gstbin.c: Add some more docs about the POSITION query.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_query):
Add some more docs about the POSITION query.
2006-12-07 10:02:19 +00:00
Stefan Kost 894b7f9f4a docs/gst/gstreamer-sections.txt: add new API and fix the build
Original commit message from CVS:
* docs/gst/gstreamer-sections.txt:
add new API and fix the build
* gst/gstbin.c: (gst_bin_recalc_state):
* gst/gstelement.c: (gst_element_message_full),
(gst_element_get_state_func), (gst_element_set_state_func):
use new API and improve logging
* gst/gstutils.c: (gst_element_state_change_return_get_name):
* gst/gstutils.h:
API: add function to get StateChangereturn names to improve logs
2006-11-06 15:14:46 +00:00
Josep Torre Valles fcb5023fa4 gst/gst.c: Fix empty declaration and type mismatch.
Original commit message from CVS:
2006-10-06  Zaheer Abbas Merali  <zaheerabbas at merali dot org>

Patch by: Josep Torre Valles <josep@fluendo.com>

* gst/gst.c: (gst_init_get_option_group):
Fix empty declaration and type mismatch.
* gst/gstbin.c: (gst_bin_change_state_func):
Fix type mismatch.
* gst/gstelement.c: (gst_element_continue_state),
(gst_element_set_state_func), (gst_element_change_state),
(gst_element_change_state_func):
Fix type mismatches.
* gst/gstinfo.c: (gst_debug_compare_log_function_by_func),
(gst_debug_remove_log_function), (_gst_debug_nameof_funcptr):
Cast as appropriate.
* gst/gstobject.c: (gst_class_signal_connect):
Cast as appropriate.  The function pointer parameter really
has the wrong type but would break API if we change it.
* gst/gstquery.c:
Fix redefinition of _FILE_OFFSET_BITS caused on Solaris wrt
order of including string.h.
* gst/gstutils.c: (gst_element_state_get_name):
Remove unreachable line.
* gst/gstxml.c: (gst_xml_parse_doc):
Fix type mismatch.
All these caught by Forte.
2006-10-06 14:46:04 +00:00
Wim Taymans 84fc21c3c1 gst/gstbin.c: Update documentation.
Original commit message from CVS:
* gst/gstbin.c:
Update documentation.
* gst/gstelement.c: (gst_element_class_init),
(gst_element_release_request_pad), (gst_element_set_clock),
(gst_element_get_index), (gst_element_add_pad),
(gst_element_remove_pad), (gst_element_get_random_pad),
(gst_element_send_event), (gst_element_get_query_types),
(gst_element_query), (gst_element_post_message),
(gst_element_message_full), (gst_element_continue_state),
(gst_element_lost_state), (gst_element_save_thyself),
(gst_element_restore_thyself):
Documentation updates.
Rename last bit of the new-pad -> pad-added signal rename.
Fix the case where an element query would only work if the source
pad was linked.
Avoid some useless type checking in message handling.
* gst/gstevent.c:
* gst/gstevent.h:
* gst/gstutils.c:
Documentation updates.
2006-09-15 08:32:57 +00:00
Wim Taymans 6072def8ed gst/gstbin.c: Fix bogus docs.
Original commit message from CVS:
* gst/gstbin.c:
Fix bogus docs.
2006-08-16 08:54:56 +00:00
Edward Hervey 4f9d5adb40 gst/gstbin.c: (de)activate src pads before calling state_change on the childs.
Original commit message from CVS:
* gst/gstbin.c: (activate_pads),
(iterator_activate_fold_with_resync), (gst_bin_src_pads_activate),
(gst_bin_change_state_func):
(de)activate src pads before calling state_change on the childs.
This is to avoid the case where a src ghostpad is blocked (holding the
stream lock), which would block the deactivation of the ghostpad's
target pad.
* gst/gstghostpad.c: (gst_proxy_pad_do_query_type),
(gst_proxy_pad_do_event), (gst_proxy_pad_do_query),
(gst_proxy_pad_do_internal_link), (gst_proxy_pad_do_bufferalloc),
(gst_proxy_pad_do_chain), (gst_proxy_pad_do_getrange),
(gst_proxy_pad_do_checkgetrange), (gst_proxy_pad_do_getcaps),
(gst_proxy_pad_do_acceptcaps), (gst_proxy_pad_do_fixatecaps),
(gst_proxy_pad_do_setcaps), (gst_proxy_pad_set_target_unlocked),
(gst_proxy_pad_set_target), (gst_proxy_pad_get_internal),
(gst_proxy_pad_dispose), (gst_proxy_pad_init),
(gst_ghost_pad_parent_set), (gst_ghost_pad_parent_unset),
(gst_ghost_pad_class_init),
(gst_ghost_pad_internal_do_activate_push),
(gst_ghost_pad_internal_do_activate_pull),
(gst_ghost_pad_do_activate_push), (gst_ghost_pad_do_activate_pull),
(gst_ghost_pad_do_link), (gst_ghost_pad_do_unlink),
(gst_ghost_pad_dispose), (gst_ghost_pad_new_no_target),
(gst_ghost_pad_new), (gst_ghost_pad_set_target):
GhostPads now create their internal GstProxyPad at creation (and not
when they're linked, as it was being done previously).
The internal and target pads are linked straight away.
The data will also travel through the other pad in order to make
pad blocking and probes non-hackish (the probe/block now really happens
on the GhostPad and not on the target).
* gst/gstpad.c: (gst_pad_set_blocked_async),
(gst_pad_link_prepare), (gst_pad_push_event):
Remove previous ghostpad cruft.
* gst/gstutils.c: (gst_pad_add_data_probe),
(gst_pad_add_event_probe), (gst_pad_add_buffer_probe),
(gst_pad_remove_data_probe), (gst_pad_remove_event_probe),
(gst_pad_remove_buffer_probe):
Remove previous ghost pad cruft.
Added more detailed debug statements.
* tests/check/gst/gstghostpad.c: (GST_START_TEST):
Fix the testsuite for refcounting changes.
The comments about who has references were correct, but the refcount
being checked wasn't the same (!?!).
2006-07-11 16:20:09 +00:00
Tim-Philipp Müller 99f16655f4 gst/gstbin.c: Can't use GPOINTER_TO_INT and GINT_TO_POINTER with GTypes.
Original commit message from CVS:
* gst/gstbin.c: (compare_interface), (gst_bin_get_by_interface),
(gst_bin_iterate_all_by_interface):
Can't use GPOINTER_TO_INT and GINT_TO_POINTER with GTypes.
GTypes are gulongs and thus the top 4 bytes might be cut
off on some platforms when doing GPOINTER_TO_INT, leading
to invalid GTypes and bad things happening.
Also add a check to make sure the type passed in is really
an interface type.
2006-07-07 15:42:08 +00:00
Tim-Philipp Müller 565199efa8 gst/: Fix deserialisation from XML. Set parent manually instead of using gst_bin_add(), since gst_bin_add() will unli...
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_restore_thyself):
* gst/gstxml.c: (gst_xml_make_element):
Fix deserialisation from XML. Set parent manually
instead of using gst_bin_add(), since gst_bin_add()
will unlink all pads of the element being added.
Fixes #341667.
2006-06-30 13:17:46 +00:00
Wim Taymans 44547817c6 gst/gstbin.c: Make it clear with a FIXME and a real define what the #if 0 previously disabled.
Original commit message from CVS:
* gst/gstbin.c: (bin_query_duration_done), (gst_bin_query):
Make it clear with a FIXME and a real define what the #if 0
previously disabled.
2006-06-14 10:34:14 +00:00
Stefan Kost e90fcdbc80 make GstElementDetails const
Original commit message from CVS:
* gst/gstbin.c:
* gst/gstpipeline.c:
* plugins/elements/gstcapsfilter.c:
* plugins/elements/gstfakesink.c:
* plugins/elements/gstfakesrc.c:
* plugins/elements/gstfdsink.c:
* plugins/elements/gstfdsrc.c:
* plugins/elements/gstfilesink.c:
* plugins/elements/gstfilesrc.c:
* plugins/elements/gstidentity.c:
* plugins/elements/gstqueue.c:
* plugins/elements/gsttee.c:
* plugins/elements/gsttypefindelement.c:
(gst_type_find_element_handle_event):
make GstElementDetails const
2006-04-28 18:55:17 +00:00
Stefan Kost 185188ab13 gst/gstbin.c: Update docs.
Original commit message from CVS:
Patch by: Stefan Kost <ensonic at sonicpulse dot de>
* gst/gstbin.c: (gst_bin_handle_message_func):
Update docs.
Don't leak bin refcount when a state recalc is
in progress and we delay another one #339808.
2006-04-28 13:04:07 +00:00
Edward Hervey ac377b0cdc Series of fixes for dereferenced pointers that gcc 4.1 complains about.
Original commit message from CVS:
reviewed by: <delete if not using a buddy>
* gst/gstbin.c: (gst_bin_dispose), (gst_bin_provide_clock_func),
(gst_bin_handle_message_func):
* gst/gstclock.c: (gst_clock_dispose), (gst_clock_set_master):
* gst/gstelement.c: (gst_element_set_clock), (gst_element_dispose),
(gst_element_set_bus_func):
* gst/gstghostpad.c: (gst_proxy_pad_dispose):
* gst/gstminiobject.c: (gst_value_set_mini_object),
(gst_value_take_mini_object):
* gst/gstpad.c: (gst_pad_set_pad_template):
* gst/gstpipeline.c: (gst_pipeline_dispose),
(gst_pipeline_use_clock), (gst_pipeline_auto_clock):
* libs/gst/base/gstcollectpads.c: (gst_collect_pads_pop),
(gst_collect_pads_chain):
* libs/gst/net/gstnettimeprovider.c:
(gst_net_time_provider_set_property):
Series of fixes for dereferenced pointers that gcc 4.1 complains about.
It's in fact all issues with gst_*object_replace().
2006-03-21 14:14:49 +00:00
Wim Taymans f35fc7a902 gst/gstbin.c: Position query should also take max of all streams.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_handle_message_func),
(bin_query_max_init), (bin_query_position_fold),
(bin_query_position_done), (gst_bin_query):
Position query should also take max of all streams.
2006-03-20 10:56:08 +00:00
Wim Taymans 429ebfff2c Documentation updates.
Original commit message from CVS:
* docs/gst/gstreamer-sections.txt:
* gst/gstbin.c: (bin_bus_handler), (gst_bin_handle_message_func):
* gst/gstbin.h:
* gst/gstbus.c: (gst_bus_class_init):
* gst/gstbus.h:
* gst/gstclock.c:
* gst/gstelement.c: (gst_element_set_locked_state):
* gst/gstsegment.c:
Documentation updates.
* gst/gstpipeline.c: (gst_pipeline_get_type),
(gst_pipeline_class_init), (gst_pipeline_init),
(gst_pipeline_dispose), (gst_pipeline_set_property),
(gst_pipeline_get_property), (do_pipeline_seek),
(gst_pipeline_send_event), (gst_pipeline_change_state),
(gst_pipeline_provide_clock_func), (gst_pipeline_set_delay),
(gst_pipeline_get_delay):
* gst/gstpipeline.h:
Added methods for setting the delay.
API: gst_pipeline_set_delay
API: gst_pipeline_get_delay
Add pipeline debug category
Various cleanups.
Updated docs.
Don't reset stream time when seek failed.
2006-03-13 11:04:38 +00:00
Wim Taymans a19398105c gst/gstbin.c: Help the compiler a bit with type registration.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_get_type), (gst_bin_handle_message_func):
Help the compiler a bit with type registration.
Use existing forward cod path instead of duplicating it when
handling a message.

* gst/gstbus.c: (gst_bus_get_type):
* gst/gstcaps.c: (gst_caps_get_type), (gst_static_caps_get_type):
* gst/gstchildproxy.c: (gst_child_proxy_get_type):
* gst/gstclock.c: (gst_clock_get_type):
* gst/gstelement.c: (gst_element_get_type),
* gst/gstelementfactory.c: (gst_element_factory_get_type):
* gst/gstindexfactory.c: (gst_index_factory_get_type):
* gst/gstminiobject.c: (gst_mini_object_get_type):
* gst/gstpad.c: (gst_pad_get_type):
* gst/gstsegment.c: (gst_segment_get_type):
* gst/gststructure.c: (gst_structure_get_type):
* gst/gstsystemclock.c: (gst_system_clock_get_type):
* gst/gsttask.c: (gst_task_get_type), (gst_task_join):
* gst/gstvalue.c:
Help compiler with type registration.

* plugins/elements/gstqueue.c: (gst_queue_handle_sink_event):
Small doc update.
2006-02-28 10:52:02 +00:00
Jan Schmidt a54323429c docs/random/release: Move the current documentation of how to do a release to the top of the file.
Original commit message from CVS:
* docs/random/release:
Move the current documentation of how to do a release to the top
of the file.

* gst/gstbin.c: (gst_bin_class_init),
(gst_bin_handle_message_func):
Allow multiple state-recalculation threads. (Closes #328873)
2006-02-20 12:26:50 +00:00
Wim Taymans b37766658e docs/design/part-TODO.txt: Updated TODO list, basesrc supports seeking to non-bytes formats.
Original commit message from CVS:
* docs/design/part-TODO.txt:
Updated TODO list, basesrc supports seeking to non-bytes
formats.

* docs/design/part-element-sink.txt:
Update docs.

* gst/gstbin.c: (bin_replace_message),
(gst_bin_handle_message_func):
* gst/gstbus.c: (gst_bus_post), (gst_bus_pop):
* gst/gstevent.c: (gst_event_finalize):
* gst/gstpad.c: (gst_pad_event_default_dispatch),
(gst_pad_send_event):
Use shiny new _TYPE_NAME macros.

* libs/gst/base/gstbasesrc.c: (gst_base_src_get_range):
Move debug statement up.

* gst/gstelement.c: (gst_element_set_locked_state):
Add some debugging.
2006-02-13 11:52:43 +00:00
Wim Taymans b6192a81bd gst/gstbin.c: Don't cache duration messages if we're not going to use or free them.
Original commit message from CVS:
* gst/gstbin.c: (bin_remove_messages), (bin_query_duration_done):
Don't cache duration messages if we're not going to use or
free them.
2006-01-31 18:46:15 +00:00
Jan Schmidt 6ef1fd2c53 gst/gstbin.c: Clean up references to the clock provider when disposed or when handling a clock-lost message from it.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_dispose), (gst_bin_provide_clock_func),
(gst_bin_remove_func), (gst_bin_handle_message_func),
(bin_query_duration_fold), (bin_query_generic_fold):
Clean up references to the clock provider when disposed or when
handling a clock-lost message from it.

Unref sinks when performing a query via gst_iterator_fold, as the
gst_bin_iterate_sinks iterator refs each item. (Fixes #323874)

* gst/gstclock.c: (gst_clock_class_init), (gst_clock_dispose),
(gst_clock_set_master):
Drop our reference to the master clock, if any, when we are disposed.

* gst/gsttypefindfactory.c: (gst_type_find_factory_dispose):
Chain up in dispose.
2006-01-27 01:48:37 +00:00
Stefan Kost b352cee4f7 added code for downstream events, reviewed docs in gstevent.c
Original commit message from CVS:
* docs/gst/gstreamer-sections.txt:
* gst/gstbin.c: (bin_element_is_src), (src_iterator_filter),
(gst_bin_iterate_sources), (gst_bin_send_event):
* gst/gstbin.h:
* gst/gstelement.c: (gst_element_send_event):
* gst/gstevent.c:
* gst/gstpad.c: (gst_pad_send_event):
added code for downstream events, reviewed docs in gstevent.c
2006-01-26 06:57:14 +00:00
Thomas Vander Stichele 0e08e35ec2 docs/random/release: update notes
Original commit message from CVS:

* docs/random/release:
update notes
* gst/gstbin.c: (gst_bin_init):
* gst/gstbus.c: (gst_bus_new):
* gst/gstbus.h:
* gst/gstpipeline.c: (gst_pipeline_init):
use gst_bus_new(), improve logging, fix docs
* win32/common/config.h:
update for cvs build
2006-01-20 19:01:59 +00:00
Tim-Philipp Müller da80e6167e gst/gstbin.c: Guard gst_object_unref call against a NULL object (dispose can theoretically be called multiple times).
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_dispose):
Guard gst_object_unref call against a NULL object (dispose
can theoretically be called multiple times).
2006-01-18 18:56:44 +00:00
Wim Taymans c33121174b gst/: Added some more debug info.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_element_set_state):
* gst/gstclock.c: (gst_clock_id_wait):
Added some more debug info.

* libs/gst/base/gstadapter.c:
Added more docs.

* libs/gst/base/gstbasesink.c: (gst_base_sink_handle_object),
(gst_base_sink_do_sync), (gst_base_sink_chain):
Added some comments.
2006-01-18 18:01:54 +00:00
Tim-Philipp Müller f3b5a1952c gst/gstbin.c: Disable duration query caching in bins until it gets fixed (see #324807).
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_query):
Disable duration query caching in bins until it gets
fixed (see #324807).
2005-12-29 16:47:27 +00:00
Wim Taymans 0a12d6a308 gst/gstbin.c: Small doc updates.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_recalc_state):
Small doc updates.
2005-12-16 18:20:58 +00:00
Jan Schmidt 4b3455b7a8 gst/gstbin.c: Don't leak clock messages.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_handle_message_func):
Don't leak clock messages.
2005-11-25 17:06:36 +00:00
Wim Taymans a9f7f7b7b6 Doc fixes.
Original commit message from CVS:
Doc fixes.
2005-11-24 09:44:07 +00:00
Wim Taymans cf925ebb6f gst/base/gstbasesink.*: No need to store the clock, the parent element class already has it.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_base_sink_class_init),
(gst_base_sink_wait), (gst_base_sink_do_sync),
(gst_base_sink_handle_event):
* gst/base/gstbasesink.h:
No need to store the clock, the parent element class already
has it.

* gst/gstbin.c: (gst_bin_set_clock_func), (gst_bin_add_func):
Updates for clock_set returning a gboolean

* gst/gstclock.c: (gst_clock_entry_new), (gst_clock_id_wait),
(gst_clock_id_wait_async), (gst_clock_class_init),
(gst_clock_init), (gst_clock_finalize),
(gst_clock_get_internal_time), (gst_clock_get_time),
(gst_clock_slave_callback), (gst_clock_set_master),
(gst_clock_get_master), (do_linear_regression),
(gst_clock_add_observation), (gst_clock_set_property),
(gst_clock_get_property):
* gst/gstclock.h:
Implement master/slave. When setting a clock as a slave, a
periodic timeout is scheduled to sample master and slave times.
Then the slave clock is recalibrated to match offset and rate
of the master clock.
Update logging a bit.
Add flag so that a clock can state that is cannot be slaved to
another clock.

* gst/gstelement.c: (gst_element_set_clock):
* gst/gstelement.h:
The set_clock returns a gboolean for when an element cannot
deal with the selected clock in the pipeline.

* gst/gstpipeline.c: (gst_pipeline_change_state),
(gst_pipeline_set_clock):
* gst/gstpipeline.h:
Handle the case where the selected clock cannot be set on
the pipeline.

* gst/net/gstnetclientclock.c: (gst_net_client_clock_class_init),
(gst_net_client_clock_init), (gst_net_client_clock_finalize),
(gst_net_client_clock_set_property),
(gst_net_client_clock_get_property),
(gst_net_client_clock_observe_times):
* gst/net/gstnetclientclock.h:
Use regression code in GstClock parent, remove duplicated
functionality.
2005-11-22 18:28:44 +00:00
Wim Taymans 5252cefbed gst/gstbin.c: Fix for #321595
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_change_state_func):
Fix for #321595
2005-11-21 19:13:13 +00:00
Andy Wingo 44c548b205 *.*: Ran scripts/update-macros. Oh yes. gst/gstobject.h (GST_OBJECT_GET_LOCK, GST_OBJECT_LOCK)
Original commit message from CVS:
2005-11-21  Andy Wingo  <wingo@pobox.com>

* *.h:
* *.c: Ran scripts/update-macros. Oh yes.

* gst/gstobject.h (GST_OBJECT_GET_LOCK, GST_OBJECT_LOCK)
(GST_OBJECT_TRYLOCK, GST_OBJECT_UNLOCK): Renamed from
GST_GET_LOCK, etc.

* scripts/update-macros: New script. Run it on your files to
change GST_LOCK to GST_OBJECT_LOCK, and the same for UNLOCK as
well.
2005-11-21 16:34:26 +00:00
Andy Wingo eb8cc5ab32 gst/gstbin.c (gst_bin_remove_func): Wim claims I can remove this state_broadcast call.
Original commit message from CVS:
2005-11-21  Andy Wingo  <wingo@pobox.com>

* gst/gstbin.c (gst_bin_remove_func): Wim claims I can remove this
state_broadcast call.
2005-11-21 15:01:48 +00:00
Wim Taymans 5209b1b0a2 Make message handling overridable.
Original commit message from CVS:
* docs/design/part-TODO.txt:
* gst/gstbin.c: (gst_bin_class_init), (gst_bin_provide_clock_func),
(gst_bin_add_func), (gst_bin_remove_func), (bin_bus_handler),
(gst_bin_handle_message_func):
* gst/gstbin.h:
Make message handling overridable.
2005-11-19 18:28:40 +00:00
Andy Wingo 5748aa1156 gst/gstutils.h: gst/gstutils.c (g_static_rec_cond_wait)
Original commit message from CVS:
2005-11-19  Andy Wingo  <wingo@pobox.com>

* gst/gstutils.h:
* gst/gstutils.c (g_static_rec_cond_wait)
(g_static_rec_cond_timed_wait): Removed, no longer needed.

* gst/gstbin.c: Remove terrible continue_state prototype.

* gst/gstelement.h (gst_element_continue_state): Make public.

* gst/gstelement.h:
* gst/gstelement.c (gst_element_commit_state): Removed, replaced
by continue_state. Fixes #319389.
2005-11-19 17:50:52 +00:00
Wim Taymans 02253f5807 gst/gstbin.*: Removing a clock provider from a bin, triggers a clock lost message so that a new clock will be selected.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_provide_clock_func), (gst_bin_add_func),
(gst_bin_remove_func), (bin_bus_handler):
* gst/gstbin.h:
Removing a clock provider from a bin, triggers a clock lost message
so that a new clock will be selected.
Adding a clock to a bin triggers a clock provider message.
Make sure we reselect a clock when we received a clock lost message.
Keep a reference to the element that provided the clock.
2005-11-18 11:03:10 +00:00
Wim Taymans 40e4311d94 gst/gstbin.c: And unref the child too..
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_provide_clock_func),
(gst_bin_sort_iterator_new):
And unref the child too..
2005-11-17 16:02:48 +00:00
Wim Taymans a1aa83c759 gst/gstbin.c: Refactor the sort iterator so it can be used while holding the
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_dispose), (gst_bin_provide_clock_func),
(gst_bin_sort_iterator_new), (gst_bin_iterate_sorted):
Refactor the sort iterator so it can be used while holding the
LOCK too.
Make clock selection select a clock closest to the source.
2005-11-17 14:51:11 +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 563477a64e gst/gstbin.c: Fix typo in docs.
Original commit message from CVS:
* gst/gstbin.c:
Fix typo in docs.

* gst/gstelement.c: (gst_element_commit_state):
Remove unused value.

* gst/gstiterator.c:
Mention that the returned element is reffed in the docs.
2005-11-02 18:44:20 +00:00
Thomas Vander Stichele d581d5c976 doc updates
Original commit message from CVS:

* docs/README:
* docs/gst/gstreamer-sections.txt:
* gst/gstbin.c:
doc updates
* gst/gstregistry.c: (gst_registry_scan_path_level):
fix for a nasty little missed situation where an installed plug-in
which was in the cache did not get overridden by an uninstalled one
which was earlier in the plugin path because the newly created plugin
for the uninstalled one (not in the registry) didn't get its
->registered set to TRUE
2005-11-02 15:34:23 +00:00
Thomas Vander Stichele 4652cba829 more doc updates
Original commit message from CVS:
more doc updates
2005-11-01 19:16:58 +00:00
Thomas Vander Stichele 4a8451a360 Documentation updates.
Original commit message from CVS:
Documentation updates.
2005-10-28 17:35:43 +00:00
Wim Taymans 7f22710f65 gst/base/gstbasesink.c: Some more debug.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_base_sink_handle_object),
(gst_base_sink_get_position):
Some more debug.

* gst/gstbin.c: (message_check), (bin_replace_message),
(bin_remove_messages), (is_eos), (gst_bin_add_func),
(update_degree), (gst_bin_sort_iterator_next), (bin_bus_handler),
(bin_query_duration_init), (bin_query_duration_fold),
(bin_query_duration_done), (bin_query_generic_fold),
(gst_bin_query):
* tools/gst-launch.c: (main):
Remove old option.
2005-10-27 08:55:44 +00:00