Commit graph

2898 commits

Author SHA1 Message Date
Tim-Philipp Müller 96e954852f configure.ac: Use AC_SYS_LARGEFILE, which will set _FILE_OFFSET_BITS=64 and _LARGEFILE_SOURCE in config.h as required...
Original commit message from CVS:
* configure.ac:
Use AC_SYS_LARGEFILE, which will set _FILE_OFFSET_BITS=64
and _LARGEFILE_SOURCE in config.h as required. Do not
export those flags in our .pc files any longer (#142209).
Remove unused GST_DISABLE_OMEGA_COTHREADS stuff.
* gst/elements/gstfilesink.c: (gst_file_sink_class_init),
(gst_file_sink_do_seek), (gst_file_sink_event),
(gst_file_sink_get_current_offset), (gst_file_sink_render):
Redo seek/tell calls with large file support in mind; add some
debugging messages; add log message that tells us when large
file support is unavailable or not enabled for some reason.
* gst/elements/gstfilesrc.c: (gst_file_src_class_init):
Add log message that tells us when large file support
is unavailable or not enabled for some reason.
2005-07-30 15:00:07 +00:00
Wim Taymans afbe734024 check/gst/gstghostpad.c: Added test for removing an element with ghostpad from a bin.
Original commit message from CVS:
* check/gst/gstghostpad.c: (GST_START_TEST), (gst_ghost_pad_suite):
Added test for removing an element with ghostpad from a bin.
Fixed test as current implementation does the right thing.

* gst/gstghostpad.c: (gst_proxy_pad_class_init),
(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_activate),
(gst_proxy_pad_do_activatepull), (gst_proxy_pad_do_activatepush),
(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),
(gst_proxy_pad_get_target), (gst_proxy_pad_init),
(gst_proxy_pad_dispose), (gst_proxy_pad_finalize),
(gst_ghost_pad_class_init), (gst_ghost_pad_do_activate_push),
(gst_ghost_pad_do_link), (gst_ghost_pad_do_unlink),
(gst_ghost_pad_set_internal), (gst_ghost_pad_dispose),
(gst_ghost_pad_new_notarget), (gst_ghost_pad_new),
(gst_ghost_pad_get_target), (gst_ghost_pad_set_target):
* gst/gstghostpad.h:
Clean up ghostpads, remove properties for internal stuff.
Make threadsafe.
Fix refcounting.
Prepare for switching targets, not all use cases work yet.
2005-07-29 19:22:28 +00:00
Wim Taymans 49de56dd1f docs/design/part-gstghostpad.txt: Small update.
Original commit message from CVS:
* docs/design/part-gstghostpad.txt:
Small update.

* gst/gstbin.c: (unlink_pads), (gst_bin_add_func),
(gst_bin_remove_func):
Unlinking pads while holding the bin LOCK is not a good
idea.

* gst/gstpad.c: (gst_pad_class_init),
(gst_pad_link_check_hierarchy), (gst_pad_get_caps_unlocked),
(gst_pad_accept_caps), (gst_pad_set_caps), (gst_pad_send_event):
No prob setting template after creating the pad.
2005-07-29 19:19:29 +00:00
Jan Schmidt 9b1b3593e0 gst/gstbus.c: gst_bus_poll may be called from other threads. Handle this nicely by not making poll_data disappear off...
Original commit message from CVS:
* gst/gstbus.c: (gst_bus_set_flushing), (gst_bus_pop),
(gst_bus_peek), (gst_bus_source_dispatch),
(gst_bus_add_watch_full), (poll_handler), (poll_timeout),
(poll_destroy), (poll_destroy_timeout), (gst_bus_poll):
gst_bus_poll may be called from other threads. Handle
this nicely by not making poll_data disappear off the
stack once gst_bus_poll returns.
gst_bus_peek now increments the refcount on the returned
message.
2005-07-29 15:34:52 +00:00
Wim Taymans a62db7f1ba check/gst/gstbin.c: Added checks for hierarchy consistency whan adding linked elements to bins.
Original commit message from CVS:
* check/gst/gstbin.c: (GST_START_TEST), (gst_bin_suite):
Added checks for hierarchy consistency whan adding linked
elements to bins.

* check/gst/gstelement.c: (GST_START_TEST), (gst_element_suite):
Added check to test element scheduling without bin/pipeline.

* check/pipelines/simple_launch_lines.c: (GST_START_TEST):
First add elements to bin, then link.

* gst/gstbin.c: (unlink_pads), (gst_bin_add_func),
(gst_bin_remove_func):
Unlink pads from elements added/removed from bin to maintain
hierarchy consistency.
2005-07-28 15:38:46 +00:00
Ronald S. Bultje cd76217ce5 gst/base/gstbasetransform.*: Remove broken delay_configure (fixes renegotiation of software scaling pipelines); remov...
Original commit message from CVS:
* gst/base/gstbasetransform.c: (gst_base_transform_setcaps),
(gst_base_transform_handle_buffer):
* gst/base/gstbasetransform.h:
Remove broken delay_configure (fixes renegotiation of software
scaling pipelines); remove some leftover printf()s.
2005-07-28 11:49:56 +00:00
Wim Taymans 7c7a4b68a1 check/gst/gstghostpad.c: Added some more tests for wrong hierarchy
Original commit message from CVS:
* check/gst/gstghostpad.c: (GST_START_TEST), (gst_ghost_pad_suite):
Added some more tests for wrong hierarchy

* docs/design/part-overview.txt:
Some updates.

* gst/gstbin.c: (gst_bin_remove_func), (gst_bin_dispose):
Cleanups.

* gst/gstelement.c: (gst_element_remove_pad), (gst_element_seek),
(gst_element_dispose):
Some more cleanups.

* gst/gstpad.c: (gst_pad_link_check_compatible_unlocked),
(gst_pad_link_check_hierarchy), (gst_pad_link_prepare),
(gst_pad_get_caps_unlocked), (gst_pad_accept_caps),
(gst_pad_set_caps), (gst_pad_send_event):
Check for correct hierarchy when linking pads. Moving to
strict requirement for ghostpads when linking elements in
different bins.

* gst/gstpad.h:
Clean ups. Added WRONG_HIERARCHY return value.
2005-07-28 11:24:33 +00:00
Ronald S. Bultje f6195ba59a gst/base/gstbasetransform.c: Better debug if no transform is possible.
Original commit message from CVS:
* gst/base/gstbasetransform.c: (gst_base_transform_setcaps):
Better debug if no transform is possible.
2005-07-28 10:38:02 +00:00
Wim Taymans 7b1c29b05e Fix compilation and fix event serialization.
Original commit message from CVS:
* check/gst-libs/gdp.c: (GST_START_TEST):
* gst/elements/gstfakesink.c: (gst_fake_sink_event):
Fix compilation and fix event serialization.
2005-07-27 18:47:48 +00:00
Wim Taymans 66d7070ef1 Some docs updates
Original commit message from CVS:
* CHANGES-0.9:
* docs/design/part-TODO.txt:
* docs/design/part-events.txt:
Some docs updates

* gst/base/gstbasesink.c: (gst_base_sink_handle_object),
(gst_base_sink_event), (gst_base_sink_do_sync),
(gst_base_sink_activate_push), (gst_base_sink_activate_pull):
* gst/base/gstbasesrc.c: (gst_base_src_send_discont),
(gst_base_src_do_seek), (gst_base_src_event_handler),
(gst_base_src_loop):
* gst/base/gstbasetransform.c: (gst_base_transform_transform_caps),
(gst_base_transform_configure_caps), (gst_base_transform_setcaps),
(gst_base_transform_get_size), (gst_base_transform_buffer_alloc),
(gst_base_transform_event), (gst_base_transform_handle_buffer),
(gst_base_transform_set_passthrough),
(gst_base_transform_is_passthrough):
* gst/elements/gstfakesink.c: (gst_fake_sink_event):
* gst/elements/gstfilesink.c: (gst_file_sink_event):
Event updates.

* gst/gstbuffer.h:
Use faster casts.

* gst/gstelement.c: (gst_element_seek):
* gst/gstelement.h:
Update gst_element_seek.

* gst/gstevent.c: (gst_event_finalize), (_gst_event_copy),
(gst_event_new), (gst_event_new_custom), (gst_event_get_structure),
(gst_event_new_flush_start), (gst_event_new_flush_stop),
(gst_event_new_eos), (gst_event_new_newsegment),
(gst_event_parse_newsegment), (gst_event_new_tag),
(gst_event_parse_tag), (gst_event_new_filler), (gst_event_new_qos),
(gst_event_parse_qos), (gst_event_new_seek),
(gst_event_parse_seek), (gst_event_new_navigation):
* gst/gstevent.h:
Make GstEvent use GstStructure. Add parsing code, make sure the
API is sufficiently generic.
Mark possible directions of events and serialization.

* gst/gstmessage.c: (gst_message_init), (gst_message_finalize),
(_gst_message_copy), (gst_message_new_segment_start),
(gst_message_new_segment_done), (gst_message_new_custom),
(gst_message_parse_segment_start),
(gst_message_parse_segment_done):
Small cleanups.

* gst/gstpad.c: (gst_pad_get_caps_unlocked), (gst_pad_accept_caps),
(gst_pad_set_caps), (gst_pad_send_event):
Update for new events.
Catch events sent in wrong directions.

* gst/gstqueue.c: (gst_queue_link_src),
(gst_queue_handle_sink_event), (gst_queue_chain), (gst_queue_loop),
(gst_queue_handle_src_query):
Event updates.

* gst/gsttag.c:
* gst/gsttag.h:
Remove event code from this file.

* libs/gst/dataprotocol/dataprotocol.c: (gst_dp_packet_from_event),
(gst_dp_event_from_packet):
Event updates.
2005-07-27 18:33:03 +00:00
Ronald S. Bultje 4795d25721 gst/base/gstbasetransform.c: Make debugging actually useful.
Original commit message from CVS:
* gst/base/gstbasetransform.c: (gst_base_transform_getcaps),
(gst_base_transform_configure_caps), (gst_base_transform_setcaps),
(gst_base_transform_get_size), (gst_base_transform_handle_buffer):
Make debugging actually useful.
2005-07-27 15:05:45 +00:00
Ronald S. Bultje 8de129adc4 gst/gstpad.c: Implement default fixation once again, so that gst_pad_fixate() actually does anything at all. This pro...
Original commit message from CVS:
* gst/gstpad.c: (fixate_value), (gst_pad_default_fixate),
(gst_pad_fixate_caps):
Implement default fixation once again, so that gst_pad_fixate()
actually does anything at all. This probably needs to be some
sort of a last resort, and use profile-based fixation first, but
since that doesn't exist yet, this is the best we have. Fixes
visualization in Totem.
2005-07-25 12:31:08 +00:00
Wim Taymans 9f06376bab docs/design/part-events.txt: Small update.
Original commit message from CVS:
* docs/design/part-events.txt:
Small update.

* gst/base/gstbasesink.c: (gst_base_sink_handle_object),
(gst_base_sink_do_sync), (gst_base_sink_activate_push),
(gst_base_sink_activate_pull):
Some more comments.

* gst/elements/gstfakesrc.c: (gst_fake_src_class_init),
(gst_fake_src_create):
Fix handoff marshall.

* gst/elements/gstidentity.c: (gst_identity_class_init),
(gst_identity_transform_ip):
We're a real inplace element.

* gst/gstbus.c: (gst_bus_post):
Added some comments.

* tests/lat.c: (fakesrc), (fakesink), (simple), (queue), (main):
* tests/muxing/case1.c: (main):
* tests/sched/dynamic-pipeline.c: (main):
* tests/sched/interrupt1.c: (main):
* tests/sched/interrupt2.c: (main):
* tests/sched/interrupt3.c: (main):
* tests/sched/runxml.c: (main):
* tests/sched/sched-stress.c: (main):
* tests/seeking/seeking1.c: (event_received), (main):
* tests/threadstate/threadstate2.c: (bus_handler), (timeout_func),
(main):
* tests/threadstate/threadstate3.c: (main):
* tests/threadstate/threadstate4.c: (main):
* tests/threadstate/threadstate5.c: (main):
Fix the tests.
2005-07-22 11:47:10 +00:00
Wim Taymans 030ff93e82 docs/design/part-seeking.txt: Some small additions.
Original commit message from CVS:
* docs/design/part-seeking.txt:
Some small additions.

* gst/base/gstbasesink.c: (gst_base_sink_handle_object),
(gst_base_sink_get_times), (gst_base_sink_do_sync),
(gst_base_sink_activate_push), (gst_base_sink_activate_pull):
* gst/base/gstbasesink.h:
discont values are gint64, handle the math correctly.

* gst/base/gstbasesrc.c: (gst_base_src_loop):
Make the basesrc report error if the source pad is not linked.

* gst/gstqueue.c: (gst_queue_link_src), (gst_queue_chain),
(gst_queue_loop), (gst_queue_handle_src_query),
(gst_queue_src_activate_push):
Make queue collect data even if the srcpad is not linked.
Start pushing out data as soon as it is linked.

* gst/gstutils.c: (gst_element_unlink), (gst_flow_get_name):
* gst/gstutils.h:
Added gst_flow_get_name() to ease error reporting.
2005-07-21 17:22:13 +00:00
Wim Taymans e261956ca6 gst/gstmessage.*: Added a bunch of messages for advanced seeking.
Original commit message from CVS:
* gst/gstmessage.c: (gst_message_new_segment_start),
(gst_message_new_segment_done), (gst_message_parse_segment_start),
(gst_message_parse_segment_done):
* gst/gstmessage.h:
Added a bunch of messages for advanced seeking.

* gst/parse/grammar.y:
* libs/gst/control/dparammanager.c: (gst_dpman_set_parent),
(gst_dpman_state_changed):
Fix some new-pad -> pad-added signals
2005-07-20 18:02:13 +00:00
Ronald S. Bultje 3f62c7db23 GstElement::new-pad -> pad-added, GstElement::state-change -> state-changed, GstValueFixedList -> GstValueArray, add ...
Original commit message from CVS:
* docs/manual/advanced-autoplugging.xml:
* docs/manual/basics-helloworld.xml:
* docs/manual/basics-pads.xml:
* docs/random/ds/0.9-suggested-changes:
* gst/gstelement.c: (gst_element_class_init), (gst_element_seek):
* gst/gstelement.h:
* gst/gstevent.h:
* gst/gstformat.h:
* gst/gstquery.h:
* gst/gststructure.c: (gst_structure_value_get_generic_type),
(gst_structure_parse_array), (gst_structure_parse_value):
* gst/gstvalue.c: (gst_type_is_fixed),
(gst_value_list_prepend_value), (gst_value_list_append_value),
(gst_value_list_get_size), (gst_value_list_get_value),
(gst_value_transform_array_string), (gst_value_serialize_array),
(gst_value_deserialize_array), (gst_value_intersect_array),
(gst_value_is_fixed), (_gst_value_initialize):
* gst/gstvalue.h:
GstElement::new-pad -> pad-added, GstElement::state-change ->
state-changed, GstValueFixedList -> GstValueArray, add format and
flags as their own arguments in gst_element_seek() (should improve
"bindeability"), remove function generators since they don't work
under a whole bunch of compilers (they were deprecated already
anyway).
2005-07-20 17:16:44 +00:00
Ronald S. Bultje e333ec54c0 gst/gstinfo.*: Fix illegal cast on some platforms (#309253).
Original commit message from CVS:
* gst/gstinfo.c: (_gst_debug_nameof_funcptr),
(_gst_debug_register_funcptr):
* gst/gstinfo.h:
Fix illegal cast on some platforms (#309253).
2005-07-20 16:20:39 +00:00
Ronald S. Bultje 3b19336fcc gst/gstmessage.*: Add _new_custom, make _new_application a macro to _new_custom.
Original commit message from CVS:
* gst/gstmessage.c: (gst_message_new_custom):
* gst/gstmessage.h:
Add _new_custom, make _new_application a macro to _new_custom.
2005-07-20 11:35:18 +00:00
Wim Taymans f73fb55d1e gst/base/gstbasesrc.*: Add a gboolean to decide when to push out a discont.
Original commit message from CVS:
* gst/base/gstbasesrc.c: (gst_base_src_init),
(gst_base_src_do_seek), (gst_base_src_loop), (gst_base_src_start):
* gst/base/gstbasesrc.h:
Add a gboolean to decide when to push out a discont.

* gst/gstqueue.c: (gst_queue_handle_sink_event), (gst_queue_chain),
(gst_queue_loop), (gst_queue_handle_src_query),
(gst_queue_sink_activate_push), (gst_queue_src_activate_push),
(gst_queue_set_property), (gst_queue_get_property):
Some cleanups.

* tests/threadstate/threadstate1.c: (main):
Make a thread test compile and run... very silly..
2005-07-20 10:58:10 +00:00
Wim Taymans f529a0bafc gst/gstqueue.*: Propagate GstFlowReturn more intelligently upstream and output an ERROR/EOS when streaming stopped du...
Original commit message from CVS:
* gst/gstqueue.c: (gst_queue_init), (gst_queue_handle_sink_event),
(gst_queue_chain), (gst_queue_loop), (gst_queue_handle_src_event),
(gst_queue_handle_src_query), (gst_queue_sink_activate_push),
(gst_queue_src_activate_push), (gst_queue_change_state),
(gst_queue_get_property):
* gst/gstqueue.h:
Propagate GstFlowReturn more intelligently upstream and output
an ERROR/EOS when streaming stopped due to fatal error.
2005-07-19 17:46:37 +00:00
Wim Taymans 737969ce5b gst/base/gstbasesrc.c: Make sure we never call the create function is we got deactivated.
Original commit message from CVS:
* gst/base/gstbasesrc.c: (gst_base_src_get_range):
Make sure we never call the create function is we
got deactivated.
2005-07-19 13:43:50 +00:00
Andy Wingo 1d2f26f522 gst/parse/parse.l: Attempt to solve bug #172815.
Original commit message from CVS:
2005-07-19  Andy Wingo  <wingo@pobox.com>

* gst/parse/parse.l: Attempt to solve bug #172815.
2005-07-19 10:40:49 +00:00
Wim Taymans 99a3a0a6c0 Small docs updates.
Original commit message from CVS:
* docs/design/part-clocks.txt:
* docs/design/part-events.txt:
* gst/base/gstbasesrc.c: (gst_base_src_do_seek):
Small docs updates.
Only update the seeking values when we are not
busy streaming.
2005-07-19 09:19:06 +00:00
Jan Schmidt 690e87b1fd Oops, ignore the result of gst_pad_push_event here.
Original commit message from CVS:
Oops, ignore the result of gst_pad_push_event here.
2005-07-18 17:43:52 +00:00
Jan Schmidt 518e590f8b gst/base/gstbasesrc.c: Send discont event from the loop function, as pads aren't activated yet in the activate_push h...
Original commit message from CVS:
* gst/base/gstbasesrc.c: (gst_base_src_loop),
(gst_base_src_activate_push):
Send discont event from the loop function, as pads
aren't activated yet in the activate_push handler.

* gst/gstbin.c: (bin_bus_handler):
Don't leak element name.
2005-07-18 17:12:36 +00:00
Wim Taymans e1aeec6d77 Removed plugable schedulers.
Original commit message from CVS:
Removed plugable schedulers.
Removed Scheduler/Manager from elements.
Removed gsttypes.h, rearranged includes.
Removed dependency pad<->element, element<>pipeline, and
various others,  fix includes.
implement gst_pad_get_parent() with gst_object_get_parent()
Make GstTask sefcontained.
Fix _get_state() on GstBin, it did not return ASYNC with a 0
timeout.
Fix endless loop in iterator_fold_with_resync.
2005-07-18 12:49:53 +00:00
Wim Taymans fba0bf771b gst/: Remove old file.
Original commit message from CVS:
* gst/Makefile.am:
* gst/gstarch.h:
Remove old file.
2005-07-18 09:22:55 +00:00
Wim Taymans 5ebba480f0 gst/Makefile.am: No more cothreads.h
Original commit message from CVS:
* gst/Makefile.am:
No more cothreads.h
2005-07-18 08:51:31 +00:00
Wim Taymans d454303dfe gst/cothreads.*: Let's remove these.
Original commit message from CVS:
* gst/cothreads.c:
* gst/cothreads.h:
Let's remove these.
2005-07-18 08:43:27 +00:00
Wim Taymans 2b1ce5f29e docs/design/: Some more docs in the works.
Original commit message from CVS:
* docs/design/part-dynamic.txt:
* docs/design/part-events.txt:
* docs/design/part-seeking.txt:
Some more docs in the works.

* gst/base/gstbasetransform.c: (gst_base_transform_transform_caps),
(gst_base_transform_getcaps), (gst_base_transform_configure_caps),
(gst_base_transform_setcaps), (gst_base_transform_get_size),
(gst_base_transform_buffer_alloc), (gst_base_transform_event),
(gst_base_transform_handle_buffer),
(gst_base_transform_sink_activate_push),
(gst_base_transform_src_activate_pull),
(gst_base_transform_set_passthrough),
(gst_base_transform_is_passthrough):
Refcounting fixes.

* gst/gstbus.c: (gst_bus_source_dispatch), (gst_bus_poll):
Cleanups.

* gst/gstevent.c: (gst_event_finalize):
Set SRC to NULL.

* gst/gstutils.c: (gst_element_unlink),
(gst_pad_get_parent_element), (gst_pad_proxy_getcaps),
(gst_pad_proxy_setcaps):
* gst/gstutils.h:
Add _get_parent_element() to get a pads parent as an element.
2005-07-18 08:28:48 +00:00
Wim Taymans 56453e01b9 gst/base/gstbasesink.c: Refcounting fixes.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_base_sink_pad_getcaps),
(gst_base_sink_pad_setcaps), (gst_base_sink_pad_buffer_alloc),
(gst_base_sink_preroll_queue_flush), (gst_base_sink_handle_object),
(gst_base_sink_event), (gst_base_sink_do_sync),
(gst_base_sink_chain), (gst_base_sink_loop),
(gst_base_sink_deactivate), (gst_base_sink_activate_push),
(gst_base_sink_activate_pull), (gst_base_sink_change_state):
Refcounting fixes.
Fix logic for returning ASYNC when not prerolled.
2005-07-17 22:26:02 +00:00
Wim Taymans e5c9ef1341 gst/gstqueue.c: Fix nasty refcount bug.
Original commit message from CVS:
* gst/gstqueue.c: (gst_queue_handle_sink_event):
Fix nasty refcount bug.
2005-07-17 22:22:52 +00:00
Philippe Kalaf cb5b884215 Moved fdsrc to gst-plugins.
Original commit message from CVS:
Moved fdsrc to gst-plugins.
2005-07-16 19:25:41 +00:00
Philippe Kalaf 4b888578a0 gst/elements/gstfdsrc.c gst/elements/gstfdsrc.h gst/elements/gstelements.c gst/elements/Makefile.am
Original commit message from CVS:
2005-07-16 Philippe Khalaf <burger@speedy.org>
* gst/elements/gstfdsrc.c
* gst/elements/gstfdsrc.h
* gst/elements/gstelements.c
* gst/elements/Makefile.am
Ported fdsrc to 0.9.
2005-07-16 15:41:04 +00:00
Wim Taymans 11bc479656 gst/base/gstbasesink.c: Fix compile error.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_base_sink_handle_object),
(gst_base_sink_do_sync):
Fix compile error.
2005-07-16 14:52:15 +00:00
Wim Taymans d5be929bf8 gst/base/gstbasesink.*: Store and use discont values when syncing buffers as described in design docs.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_base_sink_handle_object),
(gst_base_sink_event), (gst_base_sink_get_times),
(gst_base_sink_do_sync), (gst_base_sink_change_state):
* gst/base/gstbasesink.h:
Store and use discont values when syncing buffers as described
in design docs.

* gst/base/gstbasesrc.c: (gst_base_src_send_discont),
(gst_base_src_do_seek), (gst_base_src_loop), (gst_base_src_start),
(gst_base_src_activate_push):
Push discont event when starting.

* gst/elements/gstidentity.c: (gst_identity_transform):
Small cleanups.

* gst/gstbin.c: (gst_bin_change_state):
Small cleanups in base_time  distribution.

* gst/gstelement.c: (gst_element_set_base_time),
(gst_element_get_base_time), (gst_element_change_state):
* gst/gstelement.h:
Added methods for the base_time of the element.
Some MT fixes.

* gst/gstpipeline.c: (gst_pipeline_send_event),
(gst_pipeline_change_state), (gst_pipeline_set_new_stream_time),
(gst_pipeline_get_last_stream_time):
* gst/gstpipeline.h:
MT fixes.
Handle seeking as described in design doc, remove stream_time
hack.
Cleanups clock and stream_time selection code. Added accessors
for the stream_time.
2005-07-16 14:41:25 +00:00
Andy Wingo d3ffeea70a gst/gsterror.c (_gst_core_errors_init): Use the magic word..
Original commit message from CVS:
2005-07-16  Andy Wingo  <wingo@pobox.com>

* gst/gsterror.c (_gst_core_errors_init): Use the magic word..
2005-07-16 14:06:21 +00:00
Wim Taymans f89689b7e6 check/gst/gstbin.c: Make elements silent as the deep_notify refs the parent, which might make the test fail.
Original commit message from CVS:
* check/gst/gstbin.c: (GST_START_TEST):
Make elements silent as the deep_notify refs the
parent, which might make the test fail.

* gst/gstghostpad.c: (gst_ghost_pad_do_activate_push):
Don't hold the lock for too long.
2005-07-16 13:50:37 +00:00
Tim-Philipp Müller d34751b8c2 gst/base/gstbasesrc.c: Don't unref the caps we passed to gst_caps_make_writable() after passing them. gst_caps_make_w...
Original commit message from CVS:
* gst/base/gstbasesrc.c: (gst_base_src_default_negotiate):
Don't unref the caps we passed to gst_caps_make_writable() after
passing them. gst_caps_make_writable() will do that for us.
2005-07-16 12:33:13 +00:00
Andy Wingo 1ac0654d11 gst/gstcaps.h (gst_caps_is_simple): Removed deprecated macro (#157311).
Original commit message from CVS:
2005-07-15  Andy Wingo  <wingo@pobox.com>

* gst/gstcaps.h (gst_caps_is_simple): Removed deprecated macro
(#157311).
2005-07-15 16:10:41 +00:00
Andy Wingo 096d369bb3 gst/elements/gstidentity.c (marshal_VOID__MINIOBJECT): Write our own marshalling function for the handoff signal. Pro...
Original commit message from CVS:
2005-07-15  Andy Wingo  <wingo@pobox.com>

* gst/elements/gstidentity.c (marshal_VOID__MINIOBJECT): Write our
own marshalling function for the handoff signal. Properly type the
buffer as a buffer. Fixes some warnings. Should do a more general
solution.
(gst_identity_class_init): Plug into the right marshaller.
2005-07-15 14:59:22 +00:00
Andy Wingo ad1970eae2 tools/gst-typefind.c: Update, add copyright block.
Original commit message from CVS:
2005-07-15  Andy Wingo  <wingo@pobox.com>

* tools/gst-typefind.c: Update, add copyright block.

* gst/base/gstbasesrc.c (gst_base_src_default_negotiate):
Normalize and truncate caps before fixation.

* gst/gstcaps.h:
* gst/gstcaps.c (gst_caps_truncate): New function, destructively
discards all but the first structure from its argument.
2005-07-15 11:04:18 +00:00
Wim Taymans 7f4581d977 gst/base/gstbasetransform.*: Make passthrough work using the bufferpools.
Original commit message from CVS:
* gst/base/gstbasetransform.c: (gst_base_transform_init),
(gst_base_transform_transform_caps), (gst_base_transform_getcaps),
(gst_base_transform_configure_caps), (gst_base_transform_setcaps),
(gst_base_transform_get_size), (gst_base_transform_buffer_alloc),
(gst_base_transform_handle_buffer), (gst_base_transform_getrange),
(gst_base_transform_chain), (gst_base_transform_change_state),
(gst_base_transform_set_passthrough),
(gst_base_transform_is_passthrough):
* gst/base/gstbasetransform.h:
Make passthrough work using the bufferpools.
Changed API a bit, subclasses have to write into a buffer
provided by the base class.
More debug info in nego functions.

* gst/elements/gstidentity.c: (gst_identity_init),
(gst_identity_transform):
Port to new base class.
2005-07-15 10:41:32 +00:00
Wim Taymans a8d8310819 Totally dump messages in -launch with the -m option.
Original commit message from CVS:
* gst/gstmessage.c: (gst_message_new_state_changed):
* tools/gst-launch.c: (event_loop), (main):
Totally dump messages in -launch with the -m option.
Fix message name for State messages,
2005-07-15 10:30:49 +00:00
Wim Taymans 40a158fa44 gst/base/gstbasesrc.c: Post error messages on errors.
Original commit message from CVS:
* gst/base/gstbasesrc.c: (gst_base_src_loop):
Post error messages on errors.
2005-07-14 18:45:51 +00:00
Wim Taymans 9ace74670e gst/gstcaps.c: Remove debug info.
Original commit message from CVS:
* gst/gstcaps.c: (gst_caps_do_simplify):
Remove debug info.

* gst/gsterror.h:
Define error for stream stopped.

* gst/gstghostpad.c: (gst_proxy_pad_do_bufferalloc),
(gst_proxy_pad_do_chain), (gst_proxy_pad_do_getrange):
Do proper return values.

* gst/gstpad.c: (gst_pad_get_caps_unlocked), (gst_pad_accept_caps),
(gst_pad_set_caps), (gst_pad_chain), (gst_pad_push),
(gst_pad_get_range):
Better return values.

* gst/gstpad.h:
Reorganise return values, add macro to check for fatal errors.

* gst/gstqueue.c: (gst_queue_chain):
Return proper GstFlowReturn values,
2005-07-14 18:10:04 +00:00
Thomas Vander Stichele 259dec97fd more autistic cleanliness in functions/names/defines
Original commit message from CVS:
more autistic cleanliness in functions/names/defines
2005-07-14 09:35:12 +00:00
Thomas Vander Stichele 2ad8bc5a02 fix debug ifdef
Original commit message from CVS:
fix debug ifdef
2005-07-13 18:29:41 +00:00
Andy Wingo 9cb62f69e3 gst/base/gstbasesrc.c (gst_base_src_start): Post an error if the source couldn't negotiate.
Original commit message from CVS:
2005-07-13  Andy Wingo  <wingo@pobox.com>

* gst/base/gstbasesrc.c (gst_base_src_start): Post an error if the
source couldn't negotiate.
2005-07-13 16:26:07 +00:00
Wim Taymans f7c0c25d58 gst/base/gstbasetransform.c: Added more debug info in the negotiate process.
Original commit message from CVS:
* gst/base/gstbasetransform.c: (gst_base_transform_setcaps):
Added more debug info in the negotiate process.

* gst/gstmessage.h:
Prepare for segment playback.

* gst/gstpad.c: (gst_pad_accept_caps), (gst_pad_set_caps):
Better debugging.

* gst/gstutils.c:
Some more docs.

* tools/gst-launch.c: (main):
NULL pipeline on errors.
2005-07-12 17:17:34 +00:00
Andy Wingo c09555552a gst/gstbuffer.c (_gst_buffer_copy): Copy the buffer whether or not it comes from a malloc region. Make sure our copy ...
Original commit message from CVS:
2005-07-12  Andy Wingo  <wingo@pobox.com>

* gst/gstbuffer.c (_gst_buffer_copy): Copy the buffer whether or
not it comes from a malloc region. Make sure our copy gets freed.
2005-07-12 17:04:41 +00:00
Thomas Vander Stichele 232b0ba690 fix refcounting of warning and error messages
Original commit message from CVS:
fix refcounting of warning and error messages
2005-07-12 16:28:36 +00:00
Thomas Vander Stichele b7e7148a4c check/Makefile.am: instate more valgrindable tests
Original commit message from CVS:
2005-07-12  Thomas Vander Stichele  <thomas at apestaart dot org>

* check/Makefile.am:
instate more valgrindable tests
* check/elements/gstfakesrc.c: (chain_func), (event_func),
(GST_START_TEST), (fakesrc_suite):
* check/gst/gstpad.c: (GST_START_TEST):
* check/gst/gststructure.c: (GST_START_TEST):
fix test leaks
* docs/gst/tmpl/gstminiobject.sgml:
* gst/gstpad.c: (gst_pad_finalize):
fix the static mutex leak
2005-07-12 09:41:00 +00:00
Thomas Vander Stichele 0794b693d9 check/Makefile.am: add two more tests for valgrinding
Original commit message from CVS:
* check/Makefile.am:
add two more tests for valgrinding
* check/gst/gstvalue.c: (GST_START_TEST):
test refcount of deserialized buffer, found a leak
* docs/gst/gstreamer-docs.sgml:
* docs/gst/gstreamer-sections.txt:
* docs/gst/gstreamer.types:
* docs/gst/tmpl/gstminiobject.sgml:
add miniobject to docs
* gst/gstminiobject.c:
add some docs
* gst/gstvalue.c: (gst_value_deserialize_buffer),
(gst_string_unwrap):
fix a hard-to-find invalid write for one of the tests
fix a leak for deserialized buffers
2005-07-11 18:41:49 +00:00
Thomas Vander Stichele a59215bb4e valgrind unit tests as check-local; add gst_deinit
Original commit message from CVS:
valgrind unit tests as check-local; add gst_deinit
2005-07-11 15:10:40 +00:00
Thomas Vander Stichele aff85422dc add num-buffers property to basesrc
Original commit message from CVS:
add num-buffers property to basesrc
2005-07-11 15:06:27 +00:00
Thomas Vander Stichele 82596fea62 more macro splitting
Original commit message from CVS:
more macro splitting
2005-07-10 12:03:13 +00:00
Thomas Vander Stichele 3127459e22 gst/gstelement.c: add debug
Original commit message from CVS:

* gst/gstelement.c: (gst_element_get_bus):
add debug
* tools/gst-launch.c: (check_intr), (event_loop):
fix bus leaks
2005-07-10 00:07:51 +00:00
Thomas Vander Stichele 7d8c811095 fix caps leak in both cases
Original commit message from CVS:
fix caps leak in both cases
2005-07-09 23:52:07 +00:00
Thomas Vander Stichele 351230b554 duh, remove unused var
Original commit message from CVS:
duh, remove unused var
2005-07-09 23:48:45 +00:00
Thomas Vander Stichele 84caeeb557 fix a caps leak
Original commit message from CVS:
fix a caps leak
2005-07-09 23:47:23 +00:00
Thomas Vander Stichele 51bfa5c30b gst/base/gstbasesrc.c: add finalize method and clean up properly
Original commit message from CVS:

* gst/base/gstbasesrc.c: (gst_base_src_class_init),
(gst_base_src_finalize):
add finalize method and clean up properly
* gst/gstpipeline.c: (gst_pipeline_dispose):
add debug
2005-07-09 23:33:24 +00:00
Thomas Vander Stichele 3f768e81e7 don't get src for all messages; only for eos
Original commit message from CVS:
don't get src for all messages; only for eos
2005-07-09 23:15:27 +00:00
Thomas Vander Stichele fe31300609 check/gst/gstbin.c: add more things to check
Original commit message from CVS:

* check/gst/gstbin.c: (pop_messages), (GST_START_TEST),
(gst_bin_suite):
add more things to check
* gst/gstbin.c: (gst_bin_change_state), (bin_bus_handler):
* gst/gstelement.c:
more debug
2005-07-09 22:54:28 +00:00
Thomas Vander Stichele 48464956ca check/gst/gstbin.c: add test for state change message on a bin
Original commit message from CVS:

* check/gst/gstbin.c: (START_TEST), (gst_bin_suite):
add test for state change message on a bin
* check/gst/gstelement.c: (START_TEST), (gst_element_suite):
add another test
* gst/gstbin.c: (gst_bin_init):
* gst/gstbus.c: (gst_bus_init), (gst_bus_post):
* gst/gstelement.c: (gst_element_post_message),
(gst_element_set_state):
* gst/gstelementfactory.c: (gst_element_factory_create):
* gst/gstmessage.c: (gst_message_new):
* gst/gstscheduler.c:
various debugging additions and cleanups
2005-07-09 15:18:53 +00:00
Thomas Vander Stichele 240c8e10cf adding tests for elements
Original commit message from CVS:
adding tests for elements
2005-07-08 16:41:45 +00:00
Thomas Vander Stichele f3d8a28662 gst/registries/gstlibxmlregistry.c: plug more leaks. A simple gst_init() now is leakfree, yay.
Original commit message from CVS:

* gst/registries/gstlibxmlregistry.c: (load_feature):
plug more leaks.  A simple gst_init() now is leakfree, yay.
2005-07-08 16:16:29 +00:00
Thomas Vander Stichele c527fd8dad plug another memleak in registry loading - I have NO idea why this was returning a GstPlugin
Original commit message from CVS:
plug another memleak in registry loading - I have NO idea why this was returning a GstPlugin
2005-07-08 16:08:16 +00:00
Thomas Vander Stichele 34445bec34 I need to learn to stop doing this
Original commit message from CVS:
I need to learn to stop doing this
2005-07-08 14:50:44 +00:00
Thomas Vander Stichele f627c78fa6 configure.ac: make GST_ERROR_CFLAGS overridable and re-enable Werror
Original commit message from CVS:
* configure.ac:
make GST_ERROR_CFLAGS overridable and re-enable Werror
* docs/faq/cvs.xml:
add a note about error CFLAGS
* docs/gst/tmpl/gstfakesrc.sgml:
* gst/elements/gstfakesrc.c:
comment out some unused code
* gst/gst.c: (split_and_iterate):
* gst/registries/gstlibxmlregistry.c: (load_pad_template),
(load_feature):
plug some memleaks
2005-07-08 14:01:31 +00:00
Wim Taymans adf701a8cc gst/schedulers/threadscheduler.c: Unlock the STREAM_LOCK completely.
Original commit message from CVS:
* gst/schedulers/threadscheduler.c: (gst_thread_scheduler_func),
(gst_thread_scheduler_dispose):
Unlock the STREAM_LOCK completely.
2005-07-07 14:01:47 +00:00
Thomas Vander Stichele 48cef19743 adding an element test
Original commit message from CVS:
adding an element test
2005-07-07 11:59:37 +00:00
Andy Wingo a1457cff29 gst/gstbus.c (gst_bus_have_pending): Remove intensely irritating debug message.
Original commit message from CVS:
2005-07-07  Andy Wingo  <wingo@pobox.com>

* gst/gstbus.c (gst_bus_have_pending): Remove intensely irritating
debug message.
2005-07-07 11:09:32 +00:00
Wim Taymans b9880f8a26 gst/gstquery.*: Remove old types
Original commit message from CVS:
* gst/gstquery.c:
* gst/gstquery.h:
Remove old types
2005-07-07 08:43:17 +00:00
Wim Taymans c985c341ab gst/base/gstbasesrc.c: Allow subclasses to implement their own negotiation.
Original commit message from CVS:
* gst/base/gstbasesrc.c: (gst_base_src_get_range),
(gst_base_src_default_negotiate), (gst_base_src_negotiate):
Allow subclasses to implement their own negotiation.
2005-07-07 08:16:54 +00:00
Jan Schmidt ba5cecf321 examples/: Update a couple of the examples to work again.
Original commit message from CVS:
* examples/Makefile.am:
* examples/helloworld/helloworld.c: (event_loop), (main):
* examples/queue/queue.c: (event_loop), (main):
* examples/queue2/queue2.c: (main):
Update a couple of the examples to work again.

* gst/base/gstbasesink.c: (gst_base_sink_preroll_queue_empty),
(gst_base_sink_preroll_queue_flush), (gst_base_sink_handle_event):
Spelling corrections and extra debug.

* gst/gstbin.c: (gst_bin_class_init), (gst_bin_init), (is_eos),
(gst_bin_add_func), (bin_element_is_sink), (gst_bin_get_state),
(gst_bin_change_state), (gst_bin_dispose), (bin_bus_handler):
* gst/gstbin.h:
* gst/gstpipeline.c: (gst_pipeline_init), (gst_pipeline_dispose),
(gst_pipeline_change_state):
* gst/gstpipeline.h:
Move the bus handler for children to the GstBin, and create a
separate bus for receiving messages from children to the one the
bus sends 'upwards' on.
2005-07-06 16:22:47 +00:00
Wim Taymans 03aa950f7d gst/base/: Make basesrc negotiate.
Original commit message from CVS:
* gst/base/README:
* gst/base/gstbasesink.c: (gst_base_sink_preroll_queue_empty),
(gst_base_sink_handle_object), (gst_base_sink_loop),
(gst_base_sink_change_state):
* gst/base/gstbasesink.h:
* gst/base/gstbasesrc.c: (gst_base_src_class_init),
(gst_base_src_init), (gst_base_src_setcaps),
(gst_base_src_getcaps), (gst_base_src_loop),
(gst_base_src_default_negotiate), (gst_base_src_negotiate),
(gst_base_src_start), (gst_base_src_change_state):
* gst/base/gstbasesrc.h:
Make basesrc negotiate.
Handle the case where preroll fails in basesink.
Update README.
2005-07-06 13:25:26 +00:00
Wim Taymans 7ce828ba3a gst/gstpad.c: Implement the fixate function.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_fixate_caps), (gst_pad_accept_caps):
Implement the fixate function.
Clean up acceptcaps.
2005-07-06 13:20:47 +00:00
Thomas Vander Stichele b9f6a4d4ee if pad has no parent, return NULL as list of internal links
Original commit message from CVS:

* check/gst/gstpad.c:
* check/gstcheck.c:
* gst/gstpad.c: (gst_pad_get_internal_links_default):
if pad has no parent, return NULL as list of internal links
2005-07-06 11:31:57 +00:00
Andy Wingo 0675bff0fc gst/: s/BASESRC/BASE_SRC/g.
Original commit message from CVS:
2005-07-05  Andy Wingo  <wingo@pobox.com>

* gst/elements/gstfilesrc.c:
* gst/elements/gstfakesrc.c:
* gst/base/gstpushsrc.c:
* gst/base/gstbasesrc.h:
* gst/base/gstbasesrc.c: s/BASESRC/BASE_SRC/g.
2005-07-05 16:38:13 +00:00
Andy Wingo 82a5239bfe gst/elements, testsuite: Null if we got it...
Original commit message from CVS:
2005-07-05  Andy Wingo  <wingo@pobox.com>

* gst/elements, testsuite: Null if we got it...
2005-07-05 10:58:21 +00:00
Andy Wingo fd980b9f72 gst/base/gstbasetransform.c (gst_base_transform_setcaps): Default to returning TRUE for the case when tranform_caps r...
Original commit message from CVS:
2005-07-05  Andy Wingo  <wingo@pobox.com>

* gst/base/gstbasetransform.c (gst_base_transform_setcaps):
Default to returning TRUE for the case when tranform_caps returns
a fixed caps, like for identity or volume.
2005-07-05 09:35:22 +00:00
Andy Wingo 83a7075f8a check/: Application message API change.
Original commit message from CVS:
2005-07-05  Andy Wingo  <wingo@pobox.com>

* check/gst/gstbus.c (pound_bus_with_messages):
* check/gst/gstmessage.c (START_TEST):
* check/pipelines/simple_launch_lines.c (got_handoff): Application
message API change.

* gst/base/gstbasetransform.c (gst_base_transform_setcaps): More
logic weaks here: always run transform_caps, trying passthrough
operation only if the original caps intersects with the transform.

* gst/gstpad.c (gst_pad_link_check_compatible_unlocked): Debug
source and sink caps.

* gst/base/gstbasetransform.c (gst_base_transform_getcaps):
Intersect the peer caps with the pad template before going into
transform_caps.
(gst_base_transform_transform_caps): More debugging.

* gst/gstmessage.h (gst_message_new_application): Take a GstObject
src argument.
2005-07-05 08:47:40 +00:00
Edward Hervey e3141fc8f5 gst/gstutils.*: now returns the signal id for better wrapping in bindings.
Original commit message from CVS:
* gst/gstutils.c:
* gst/gstutils.h:
(gst_pad_add_*_probe): now returns the signal id for better wrapping
in bindings.
2005-07-04 15:08:30 +00:00
Andy Wingo c1d34b8acf tests/network-clock.scm: Commentary update.
Original commit message from CVS:
2005-07-01  Andy Wingo  <wingo@pobox.com>

* tests/network-clock.scm: Commentary update.

* gst/elements/gstidentity.c (PROP_DUPLICATE): Gone daddy gone.
Didn't really make sense, not implementable with basetransform,
etc.
(gst_identity_transform): Unref inbuf via make_writable. Feeble
attempt at implementing the sync property, needs an unlock method.

* gst/base/gstbasetransform.c (gst_base_transform_transform_caps):
New func, by default returns the same caps (the identity
transformation).
(gst_base_transform_getcaps): Uses transform_caps to return
something sensible.
(gst_base_transform_setcaps): Complicated logic to get caps on
both pads, even if they are different, and to call set_caps once
for every time both pads get their caps set.
(gst_base_transform_handle_buffer): Give the ref to the transform
function. Allows in-place modification of the buffer.

* gst/base/gstbasetransform.h (transform_caps): New class method.
Given caps on one side, what can I do on the other.
(set_caps): Take two caps, one for each side of the element.

* gst/gstpad.h:
* gst/gstpad.c (gst_pad_fixate_caps): Change prototype to modify
caps in place. This is safe because we can check the mutability of
the caps, and a good idea because fixate functions are just called
as a matter of last resort. (Not actually implemented.)
(gst_pad_set_caps): If the caps we're setting is actually the same
as the existing pad caps, just update the pointer without calling
setcaps. Assert that caps is either NULL or fixed, as per the
docs.

* gst/gstghostpad.c: Update for fixate changes.
2005-07-01 16:46:59 +00:00
Jan Schmidt e762446852 gst/gstpad.c: Put the mini_object into GValue as a mini_object, not a gpointer.
Original commit message from CVS:
2005-07-02  Jan Schmidt  <thaytan@mad.scientist.com>

* gst/gstpad.c: (gst_pad_emit_have_data_signal):
Put the mini_object into GValue as a mini_object,
not a gpointer.
2005-07-01 14:36:12 +00:00
Thomas Vander Stichele 4507397788 debug disable fixes
Original commit message from CVS:
debug disable fixes
2005-06-30 12:26:26 +00:00
Wim Taymans 4dd878f93b Added CHANGES-0.9 doc, updated status of other docs.
Original commit message from CVS:
* CHANGES-0.9:
* docs/design/draft-ghostpads.txt:
* docs/design/draft-push-pull.txt:
* docs/design/draft-query.txt:
* docs/design/part-TODO.txt:
* docs/design/part-query.txt:
Added CHANGES-0.9 doc, updated status of other docs.

* gst/gstquery.h:
Remove "hmm" macro
2005-06-30 12:18:19 +00:00
Wim Taymans 6a6a717235 gst/base/gstbasesink.*: Some tweaks, only EOS and a buffer complete a preroll.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_base_sink_preroll_queue_empty),
(gst_base_sink_preroll_queue_flush), (gst_base_sink_handle_object),
(gst_base_sink_change_state):
* gst/base/gstbasesink.h:
Some tweaks, only EOS and a buffer complete a preroll.
2005-06-30 12:14:47 +00:00
Andy Wingo 6da6bc4530 gst/gstghostpad.c (gst_ghost_pad_do_activate_push): Proxy activate_push down to the internal pad as well.
Original commit message from CVS:
2005-06-30  Andy Wingo  <wingo@pobox.com>

* gst/gstghostpad.c (gst_ghost_pad_do_activate_push): Proxy
activate_push down to the internal pad as well.
2005-06-30 11:39:34 +00:00
Ronald S. Bultje 6c8dc39ee4 gst/gsttaginterface.c: Some documentation fixes (#307394 and #307397).
Original commit message from CVS:
Reviewed by:  Ronald S. Bultje  <rbultje@ronald.bitfreak.net>
* gst/gsttaginterface.c:
Some documentation fixes (#307394 and #307397).
2005-06-30 10:59:34 +00:00
Ronald S. Bultje f05cd57bf2 gst/gstvalue.c: Fix memleak (#309125).
Original commit message from CVS:
Reviewed by:  Ronald S. Bultje  <rbultje@ronald.bitfreak.net>
* gst/gstvalue.c: (gst_value_intersect_list):
Fix memleak (#309125).
2005-06-30 10:10:00 +00:00
Wim Taymans a578cfd009 gst/gstbin.c: Lame attempt at making the state change function a bit more readable.
Original commit message from CVS:
* gst/gstbin.c: (clear_queue), (remove_all_from_queue),
(gst_bin_change_state):
Lame attempt at making the state change function a bit
more readable.
2005-06-30 09:41:15 +00:00
Wim Taymans 092745b46d gst/: Removed atomic operations, use existing LOCK.
Original commit message from CVS:
* gst/gstpad.c: (_gst_do_pass_data_accumulator),
(default_have_data), (gst_pad_class_init), (gst_pad_init),
(gst_pad_emit_have_data_signal), (gst_pad_chain), (gst_pad_push),
(gst_pad_check_pull_range), (gst_pad_get_range),
(gst_pad_pull_range), (gst_pad_push_event), (gst_pad_send_event):
* gst/gstpad.h:
* gst/gstutils.c: (gst_atomic_int_set), (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):
Removed atomic operations, use existing LOCK.
Move exception handling out of main code path.
2005-06-30 09:23:54 +00:00
Ronald S. Bultje a220106c57 gst/gstpad.c: Fix accumulator, add default value by using _emitv() instead of _emit() for signal emission.
Original commit message from CVS:
* gst/gstpad.c: (_gst_do_pass_data_accumulator),
(silly_return_true_function), (gst_pad_class_init),
(gst_pad_emit_have_data_signal), (gst_pad_chain), (gst_pad_push),
(gst_pad_get_range), (gst_pad_pull_range), (gst_pad_push_event),
(gst_pad_send_event):
Fix accumulator, add default value by using _emitv() instead
of _emit() for signal emission.
2005-06-29 19:20:07 +00:00
Ronald S. Bultje af3acddad9 Add probe example.
Original commit message from CVS:
* docs/manual/advanced-dataaccess.xml:
* examples/manual/Makefile.am:
Add probe example.
* gst/gstpad.c: (_gst_do_pass_data_accumulator):
Make work (??).
2005-06-29 16:57:59 +00:00
Thomas Vander Stichele faf3c9d652 fix for ppc, hopefully
Original commit message from CVS:
fix for ppc, hopefully
2005-06-29 16:45:58 +00:00
Tim-Philipp Müller 38565eafdb gst/elements/gstfilesink.c: Simplify code so that we don't have to handle short writes and return GST_FLOW_ERROR if a...
Original commit message from CVS:
* gst/elements/gstfilesink.c: (gst_filesink_render):
Simplify code so that we don't have to handle short
writes and return GST_FLOW_ERROR if an error occured.
2005-06-29 16:11:12 +00:00
Ronald S. Bultje d13478b357 Remove old probes, add new g-signal-based probes and some utility functions.
Original commit message from CVS:
* docs/gst/gstreamer-sections.txt:
* docs/gst/tmpl/gstpad.sgml:
* docs/gst/tmpl/gstprobe.sgml:
* gst/Makefile.am:
* gst/gstpad.c: (_gst_do_pass_data_accumulator),
(gst_pad_class_init), (gst_pad_init), (gst_pad_chain),
(gst_pad_push), (gst_pad_get_range), (gst_pad_pull_range),
(gst_pad_push_event), (gst_pad_send_event):
* gst/gstpad.h:
* 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):
* gst/gstutils.h:
Remove old probes, add new g-signal-based probes and some utility
functions.
2005-06-29 15:51:25 +00:00
Edward Hervey 6aa149a930 gst/: Moved gst_element_factory_can_[sink|src]_caps() to gstutils and added the definition to the header file.
Original commit message from CVS:
* gst/gstelementfactory.c:
* gst/gstutils.h:
* gst/gstutils.c:
Moved gst_element_factory_can_[sink|src]_caps() to gstutils and added
the definition to the header file.
2005-06-29 15:17:25 +00:00
Thomas Vander Stichele 80717cb5d1 logic was reversed, duh
Original commit message from CVS:
logic was reversed, duh
2005-06-29 12:40:39 +00:00
Thomas Vander Stichele a30e9069d1 add A GST_PLUGIN_PATH_ONLY env var; if it is set, it will only scan the GST_PLUGIN_PATH locations, and not add system...
Original commit message from CVS:

* check/Makefile.am:
* gst/gst.c: (add_path_func), (init_pre):
* gst/gstregistry.c: (gst_registry_add_path):
add A GST_PLUGIN_PATH_ONLY env var; if it is set, it will
only scan the GST_PLUGIN_PATH locations, and not add
system locations
2005-06-29 12:25:05 +00:00
Thomas Vander Stichele bd728f0b2c doc fixes
Original commit message from CVS:
doc fixes
2005-06-29 12:23:35 +00:00
Wim Taymans 06ab4b7831 gst/base/gstbasesink.c: Small debug line.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_base_sink_handle_object),
(gst_base_sink_change_state):
Small debug line.

* gst/gstclock.h:
map SIGNAL and BROADCAST to the right function.

* gst/gstobject.h:
Remove redundant braces.

* gst/gstpad.c: (gst_pad_set_caps):
Don't call setcaps function when reseting caps to NULL.

* gst/gstsystemclock.c: (gst_system_clock_dispose),
(gst_system_clock_async_thread), (gst_system_clock_id_wait_async),
(gst_system_clock_id_unschedule):
Use BROADCAST as this is what we do.
2005-06-29 11:10:44 +00:00
Wim Taymans a34bc0bd60 gst/base/gstbasesink.c: We are actually prerolling before commiting the state change.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_base_sink_handle_object):
We are actually prerolling before commiting the state
change.
2005-06-29 10:24:08 +00:00
Wim Taymans bd72354e9a gst/gstbus.c: Add debugging messages.
Original commit message from CVS:
* gst/gstbus.c: (gst_bus_post), (gst_bus_have_pending),
(gst_bus_set_flushing), (gst_bus_pop), (gst_bus_peek),
(gst_bus_source_dispatch):
Add debugging messages.
Make internal methods static.
Handle the case where the bus is flushed in the handler.

* gst/gstelement.c: (gst_element_get_bus):
Fix refcount in _get_bus();

* gst/gstpipeline.c: (gst_pipeline_change_state),
(gst_pipeline_get_clock_func):
Clock refcounting fixes.
Handle the case where preroll timed out more gracefully.

* gst/gstsystemclock.c: (gst_system_clock_dispose):
Clean up the internal thread in dispose. This is needed
for subclasses that actually get disposed.

* gst/schedulers/threadscheduler.c:
(gst_thread_scheduler_class_init), (gst_thread_scheduler_func),
(gst_thread_scheduler_dispose):
Free thread pool in dispose.
2005-06-28 19:45:26 +00:00
Wim Taymans d0616cd459 gst/gstghostpad.c: Correctly proxy the check_pull_range function.
Original commit message from CVS:
* gst/gstghostpad.c: (gst_proxy_pad_do_bufferalloc),
(gst_proxy_pad_do_checkgetrange), (gst_proxy_pad_do_acceptcaps),
(gst_proxy_pad_do_fixatecaps):
Correctly proxy the check_pull_range function.
2005-06-28 13:40:12 +00:00
Thomas Vander Stichele e65ae0c3c8 fix fake elements too
Original commit message from CVS:
fix fake elements too
2005-06-28 12:45:21 +00:00
Thomas Vander Stichele f0e5bb0a33 did s/bases(rc/ink)_/base_s(rc/ink)_/; wim wants to remove base completely, but that's for later
Original commit message from CVS:
did s/bases(rc/ink)_/base_s(rc/ink)_/; wim wants to remove base completely, but that's for later
2005-06-28 12:01:49 +00:00
Wim Taymans de3be844ec gst/: The deprecated pad loop function is removed now.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_set_pad_functions),
(gst_basesink_preroll_queue_flush):
* gst/base/gstbasesrc.c: (gst_basesrc_set_dataflow_funcs):
* gst/elements/gsttee.c: (gst_tee_update_pad_functions):
* gst/gstghostpad.c: (gst_proxy_pad_do_bufferalloc),
(gst_proxy_pad_do_acceptcaps), (gst_proxy_pad_do_fixatecaps),
(gst_proxy_pad_set_property):
* gst/gstpad.c:
* gst/gstpad.h:
* gst/gstqueue.c: (gst_queue_init):
The deprecated pad loop function is removed now.
2005-06-28 11:36:43 +00:00
Wim Taymans 7dc174d140 gst/base/gstbasesink.c: Flushing the preroll queue always needs to unlock the waiters.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_preroll_queue_flush),
(gst_basesink_event), (gst_basesink_deactivate):
Flushing the preroll queue always needs to unlock the waiters.
2005-06-28 11:02:18 +00:00
Edward Hervey 2e75d2ae7e gst/gstpipeline.c: Wheen a seek was successful on a pipeline, set the stream_time to the seek offset in order to have...
Original commit message from CVS:
* gst/gstpipeline.c: (gst_pipeline_send_event):
Wheen a seek was successful on a pipeline, set the stream_time to the
seek offset in order to have a synchronized stream_time.
2005-06-28 10:45:48 +00:00
Wim Taymans 57d529de3a gst/gstghostpad.c: Call wrapper function instead of just calling the function pointers. This takes care of any lockin...
Original commit message from CVS:
* gst/gstghostpad.c: (gst_proxy_pad_do_bufferalloc),
(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):
Call wrapper function instead of just calling the function
pointers. This takes care of any locking and whatmore.
2005-06-28 10:37:24 +00:00
Wim Taymans 9a6500143f gst/gstpad.*: CONNECTED -> LINKED.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_alloc_buffer), (gst_pad_push),
(gst_pad_pull_range):
* gst/gstpad.h:
CONNECTED -> LINKED.
2005-06-28 10:28:31 +00:00
Andy Wingo f8e79bdf86 *.c: Don't cast to GST_OBJECT when reffing or unreffing. Large source-munging commit!!!
Original commit message from CVS:
2005-06-28  Andy Wingo  <wingo@pobox.com>

* *.c: Don't cast to GST_OBJECT when reffing or unreffing. Large
source-munging commit!!!
2005-06-28 09:59:01 +00:00
Andy Wingo 5016035bc6 gst/gstobject.c (gst_object_unref, gst_object_ref)
Original commit message from CVS:
2005-06-28  Andy Wingo  <wingo@pobox.com>

* gst/gstobject.c (gst_object_unref, gst_object_ref)
(gst_object_sink): Take gpointer arguments, not GstObject --
avoids casts. Like GLib.
2005-06-28 09:17:14 +00:00
Andy Wingo 1b02b1d741 gst/gstghostpad.c (gst_proxy_pad_do_activate): Don't proxy activate.
Original commit message from CVS:
2005-06-28  Andy Wingo  <wingo@pobox.com>

* gst/gstghostpad.c (gst_proxy_pad_do_activate): Don't proxy
activate.
2005-06-28 08:41:43 +00:00
Andy Wingo 7fda2039b3 shut up gcc3
Original commit message from CVS:
shut up gcc3
2005-06-27 18:39:41 +00:00
Andy Wingo f2cf753b17 gst/base/gsttypefindhelper.c (gst_type_find_helper): Unref any remaining buffer.
Original commit message from CVS:
2005-06-27  Andy Wingo  <wingo@pobox.com>

* gst/base/gsttypefindhelper.c (gst_type_find_helper): Unref any
remaining buffer.

* gst/gsttrace.c (gst_alloc_trace_list_sorted): New helper,
returns a sorted copy of the trace list.
(gst_alloc_trace_print_live): New API, only prints traces with
live objects. Sort the list.
(gst_alloc_trace_print_all): Sort the list.
(gst_alloc_trace_print): Align columns.

* gst/elements/gstttypefindelement.c:
* gst/elements/gsttee.c:
* gst/base/gstbasesrc.c:
* gst/base/gstbasesink.c:
* gst/base/gstbasetransform.c:
* gst/gstqueue.c: Adapt for pad activation changes.

* gst/gstpipeline.c (gst_pipeline_init): Unref after parenting
sched.
(gst_pipeline_dispose): Drop ref on sched.

* gst/gstpad.c (gst_pad_init): Set the default activate func.
(gst_pad_activate_default): Push mode by default.
(pre_activate_switch, post_activate_switch): New stubs, things to
do before and after switching activation modes on pads.
(gst_pad_set_active): Take a boolean and not a mode, dispatch to
the pad's activate function to choose which mode to activate.
Shortcut on deactivation and call the right function directly.
(gst_pad_activate_pull): New API, (de)activates a pad in pull
mode.
(gst_pad_activate_push): New API, same for push mode.
(gst_pad_set_activate_function)
(gst_pad_set_activatepull_function)
(gst_pad_set_activatepush_function): Setters for new API.

* gst/gstminiobject.c (gst_mini_object_new, gst_mini_object_free):
Trace all miniobjects.
(gst_mini_object_make_writable): Unref the arg if we copy, like
gst_caps_make_writable.

* gst/gstmessage.c (_gst_message_initialize): No trace init.

* gst/gstghostpad.c (gst_proxy_pad_do_activate)
(gst_proxy_pad_do_activatepull, gst_proxy_pad_do_activatepush):
Adapt for new pad API.

* gst/gstevent.c (_gst_event_initialize): Don't initialize trace.

* gst/gstelement.h:
* gst/gstelement.c (gst_element_iterate_src_pads)
(gst_element_iterate_sink_pads): New API functions.

* gst/gstelement.c (iterator_fold_with_resync): New utility,
should fold into gstiterator.c in some form.
(gst_element_pads_activate): Simplified via use of fold and
delegation of decisions to gstpad->activate.

* gst/gstbus.c (gst_bus_source_finalize): Set the bus to NULL,
help in debugging.

* gst/gstbuffer.c (_gst_buffer_initialize): Ref the buffer type
class once in init, like gstmessage. Didn't run into this issue
but it seems correct. Don't initialize a trace, gstminiobject does
that.

* check/pipelines/simple_launch_lines.c (test_stop_from_app): New
test, runs fakesrc ! fakesink, stopping on ::handoff via a message
to the bus.
(assert_live_count): New util function, uses alloc traces to check
cleanup.

* check/gst/gstghostpad.c (test_ghost_pads): More refcount checks.
To be modified when unlink drops the internal pad.
2005-06-27 18:35:05 +00:00
Wim Taymans adbd17c378 gst/gstbin.c: Cleanup the get_state() function a little, make sure it iterates the same set of elements.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_get_state), (gst_bin_iterate_state_order),
(gst_bin_change_state):
Cleanup the get_state() function a little, make sure it
iterates the same set of elements.
Added stub iterate_state_order().
2005-06-27 18:11:24 +00:00
Thomas Vander Stichele 0b44c713a7 adding basetransform and iterator docs
Original commit message from CVS:
adding basetransform and iterator docs
2005-06-27 14:40:09 +00:00
Thomas Vander Stichele 012d4ec9de more doc and whitespace fixes
Original commit message from CVS:
more doc and whitespace fixes
2005-06-27 08:16:51 +00:00
Wim Taymans 2d63826a90 gst/gstghostpad.c: At least get the chain function correct, needs more fixing.
Original commit message from CVS:
* gst/gstghostpad.c: (gst_proxy_pad_do_chain):
At least get the chain function correct, needs more
fixing.
2005-06-25 19:53:02 +00:00
Wim Taymans 97194517fe gst/: Right, two problems here: ghostpads don't take locks and glib _rec_mutex_lock_full() with depth==0 still locks.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_preroll_queue_empty),
(gst_basesink_handle_object), (gst_basesink_event),
(gst_basesink_do_sync), (gst_basesink_handle_event),
(gst_basesink_change_state):
* gst/gsttask.h:
Right, two problems here: ghostpads don't take locks and
glib _rec_mutex_lock_full() with depth==0 still locks.
Catch illegal locking and g_warn them.
2005-06-25 19:37:59 +00:00
Wim Taymans 613dc3d631 gst/: Unlock STREAM_LOCK whatever the recursion was.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_preroll_queue_empty),
(gst_basesink_handle_object), (gst_basesink_event),
(gst_basesink_do_sync), (gst_basesink_handle_event),
(gst_basesink_change_state):
* gst/gstpad.h:
Unlock STREAM_LOCK whatever the recursion was.
2005-06-25 19:09:28 +00:00
Wim Taymans 8303454db7 gst/base/gstbasesink.c: Reworked the base sink, handle event and buffer serialisation correctly and removed possible ...
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_set_property),
(gst_basesink_preroll_queue_empty),
(gst_basesink_preroll_queue_flush), (gst_basesink_handle_object),
(gst_basesink_event), (gst_basesink_do_sync),
(gst_basesink_handle_event), (gst_basesink_handle_buffer),
(gst_basesink_chain), (gst_basesink_loop), (gst_basesink_activate),
(gst_basesink_change_state):
Reworked the base sink, handle event and buffer serialisation
correctly and removed possible deadlock.
Handle EOS correctly.
2005-06-25 17:54:58 +00:00
Wim Taymans 4e9438da9f Allow elements to post EOS in the state change function.
Original commit message from CVS:
* gst/gstpipeline.c: (is_eos), (pipeline_bus_handler),
(gst_pipeline_change_state):
* tools/gst-launch.c: (check_intr), (event_loop), (main):
Allow elements to post EOS in the state change function.
Fix up -launch, make it exit the poll loop when the
pipeline actually changed state.
Fix up warning parsing in -launch.
2005-06-25 17:51:12 +00:00
Wim Taymans f4f2cadeb5 gst/elements/gsttee.c: Core takes STREAM_LOCK for us now.
Original commit message from CVS:
* gst/elements/gsttee.c: (gst_tee_chain), (gst_tee_loop),
(gst_tee_sink_activate):
Core takes STREAM_LOCK for us now.
2005-06-25 17:44:39 +00:00
Wim Taymans 2169b1a5d8 gst/: Keep track of current target state while performing a state change so that subclasses can do something interest...
Original commit message from CVS:
* gst/gstelement.c: (gst_element_get_state_func),
(gst_element_set_state):
* gst/gstelement.h:
* gst/gstmessage.c: (gst_message_parse_error),
(gst_message_parse_warning):
Keep track of current target state while performing a state
change so that subclasses can do something interesting.
Fix parsing of warning/error messages when GError is NULL.
2005-06-25 17:42:17 +00:00
Thomas Vander Stichele 87d6d3143b start pulling in base classes and elements for docs
Original commit message from CVS:
start pulling in base classes and elements for docs
2005-06-24 18:16:14 +00:00
Wim Taymans 52a445a41d gst/gstelement.c: When the state did not change, also report NO_PREROLL when it matters.
Original commit message from CVS:
* gst/gstelement.c: (gst_element_get_state_func),
(gst_element_set_state), (gst_element_change_state):
When the state did not change, also report NO_PREROLL
when it matters.
2005-06-23 17:11:49 +00:00
Wim Taymans d56ab76d57 gst/: No unsafe task pausing please.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_event_default):
* gst/gstqueue.c: (gst_queue_loop):
No unsafe task pausing please.
2005-06-23 17:09:21 +00:00
Wim Taymans 830a0368b4 gst/schedulers/threadscheduler.c: Ref the task before pushing it on the threadpool. This makes sure that we have a re...
Original commit message from CVS:
* gst/schedulers/threadscheduler.c:
(gst_thread_scheduler_task_start),
(gst_thread_scheduler_task_pause), (gst_thread_scheduler_func):
Ref the task before pushing it on the threadpool. This
makes sure that we have a ref when the threadfunction is
actually called.
2005-06-23 17:07:08 +00:00
Andy Wingo 09ab1d8fb2 gst/base/gstbasesrc.c (gst_basesrc_get_range): Check if the offset is greater than the file's size.
Original commit message from CVS:
2005-06-23  Andy Wingo  <wingo@pobox.com>

* gst/base/gstbasesrc.c (gst_basesrc_get_range): Check if the
offset is greater than the file's size.
2005-06-23 15:26:09 +00:00
Andy Wingo cc2d216e88 gst/gstobject.h (GST_CLASS_LOCK, GST_CLASS_TRYLOCK) (GST_CLASS_UNLOCK, GST_CLASS_GET_LOCK, GstObjectClass)
Original commit message from CVS:
2005-06-23  Andy Wingo  <wingo@pobox.com>

* gst/gstobject.h (GST_CLASS_LOCK, GST_CLASS_TRYLOCK)
(GST_CLASS_UNLOCK, GST_CLASS_GET_LOCK, GstObjectClass)
* gst/gstobject.c (gst_object_class_init): Make the class lock
recursive. Wim won't let me drop deep_notify. Decodebin works
again, whoopdy doo.
2005-06-23 15:04:48 +00:00
Andy Wingo 57bfdb30e4 gst/gstghostpad.c (on_int_notify): Catches notify::caps on the internal pad, and hacks accordingly. Doesn't do it on ...
Original commit message from CVS:
2005-06-23  Andy Wingo  <wingo@pobox.com>

* gst/gstghostpad.c (on_int_notify): Catches notify::caps on the
internal pad, and hacks accordingly. Doesn't do it on the target
pad because we change its caps. Probably catches all cases of
interest tho.
(gst_ghost_pad_set_property): Connect to notify::caps as
appropritate.
2005-06-23 14:18:15 +00:00
Jan Schmidt 8bd306b791 gst/elements/gsttypefindelement.c: Don't restart typefinding on a discont.
Original commit message from CVS:
2005-06-23  Jan Schmidt  <thaytan@mad.scientist.com>

* gst/elements/gsttypefindelement.c:
(gst_type_find_element_handle_event):
Don't restart typefinding on a discont.
* gst/gstelement.c: (gst_element_set_state):
Debug spelling fix.
* gst/gstpad.c: (gst_pad_set_active), (gst_pad_send_event):
Allow changing mode of an active pad.
Debug output fixes.
* gst/registries/gstlibxmlregistry.c: (load_feature):
Don't cast a static pad template to a normal pad template.
2005-06-23 11:43:39 +00:00
Thomas Vander Stichele e6b233bb4d remove gst_strtoll completely, since it didn't actually do anything more than what g_ascii_strtoull already does.
Original commit message from CVS:
* check/gst/gstvalue.c: (START_TEST), (gst_value_suite):
* gst/gstvalue.c: (gst_value_deserialize_int_helper):
remove gst_strtoll completely, since it didn't actually do
anything more than what g_ascii_strtoull already does.
check for range errors when deserializing
do a cast for the unsigned cases; but further fixing needs
a decision on what the interpretation of "(int)" and
deserialization should be for values that fall outside the
type's boundaries (ie, refuse, or interpret as casting)
2005-06-23 11:25:29 +00:00
Wim Taymans 1cda8197e9 Added support for live sources and other elements that cannot do preroll.
Original commit message from CVS:
Added support for live sources and other elements that
cannot do preroll.
Updated design docs, added live-source design doc.
Implemented live source functionality in basesrc
Fix error condition in _bin_get_state()
Implement live source handling in -launch.
Added check for live sources.
Fixed case in GstBin where elements were changed state
multiple times.
2005-06-23 10:37:09 +00:00
Andy Wingo 678bb923f1 commit the file
Original commit message from CVS:
commit the file
2005-06-23 09:41:41 +00:00
Andy Wingo ee38ed3c9d gst/gstghostpad.c (gst_proxy_pad_do_setcaps): Call the full gst_pad_set_caps on the target, not just its setcaps() fu...
Original commit message from CVS:
2005-06-23  Andy Wingo  <wingo@pobox.com>

* gst/gstghostpad.c (gst_proxy_pad_do_setcaps): Call the full
gst_pad_set_caps on the target, not just its setcaps() function.
2005-06-23 09:28:27 +00:00
Thomas Vander Stichele c3efeeb64c check/: copy over from 0.8, and add two with bitmasks specified with (int) 0xFF...
Original commit message from CVS:
* check/Makefile.am:
* check/gst/capslist.h:
copy over from 0.8, and add two with bitmasks specified with
(int) 0xFF...
* check/gst/gstcaps.c: (START_TEST), (gst_caps_suite):
add test to parse everything from capslist.h
* check/gst/gststructure.c: (START_TEST), (gst_value_suite),
(main):
add test for structure deserialization
* check/gst/gstvalue.c: (START_TEST), (gst_value_suite):
add tests for deserialization of strings to int types
* gst/gststructure.c: (gst_structure_nth_field_name):
* gst/gststructure.h:
add a way to get the name of a field referenced by index
* gst/gstvalue.c: (gst_value_deserialize_int_helper):
instead of checking if the resulting long long lies between
min and max, we check if the long long would fit into
a number of bytes for the final type.
This fixes cases where a string represents 2^32 - 1, which
when cast to int would be the (valid) -1, but is bigger than
G_MAXINT
2005-06-22 19:22:34 +00:00
Thomas Vander Stichele 8952d2c571 add a log line for type deserialization
Original commit message from CVS:
add a log line for type deserialization
2005-06-22 11:02:57 +00:00
Thomas Vander Stichele bdc643ddb9 return long long, not int, so gint64 deserialization actually works. Is there any flag that makes the compiler check...
Original commit message from CVS:

* check/gst/gstvalue.c: (START_TEST):
* gst/gstvalue.c: (gst_value_deserialize):
return long long, not int, so gint64 deserialization actually
works.  Is there any flag that makes the compiler check this ?
Fixes #308559
2005-06-22 10:52:18 +00:00
Wim Taymans 202c113397 gst/gstbuffer.h: Added convenience macros for setting buffers in GValue.
Original commit message from CVS:
* gst/gstbuffer.h:
Added convenience macros for setting buffers in GValue.
2005-06-22 09:55:16 +00:00
Wim Taymans 5d66b9af57 gst/gstpad.c: Small doc updates.
Original commit message from CVS:
* gst/gstpad.c:
Small doc updates.

* gst/gstvalue.c: (gst_value_compare_buffer),
(gst_value_serialize_buffer), (gst_value_deserialize_buffer),
(gst_value_compare_flags), (gst_value_serialize_flags),
(gst_value_deserialize_flags), (_gst_value_initialize):
Fix serialisation of buffers, they are not boxed types anymore
2005-06-20 15:18:17 +00:00
Andy Wingo 3468457954 gst/gstsystemclock.c (gst_system_clock_init): Unlock the clock if its socks fill with rocks.
Original commit message from CVS:
2005-06-20  Andy Wingo  <wingo@pobox.com>

* gst/gstsystemclock.c (gst_system_clock_init): Unlock the clock
if its socks fill with rocks.
(gst_system_clock_obtain): Set the name on object construction.
Avoid double-checked locking.
2005-06-20 11:41:17 +00:00
Tim-Philipp Müller 5910c2f938 gst/gsturi.c: Fix potential endless loop.
Original commit message from CVS:
* gst/gsturi.c: (gst_element_make_from_uri):
Fix potential endless loop.
2005-06-20 11:32:14 +00:00
Thomas Vander Stichele d10d12dbcb check/Makefile.am: add gsttag
Original commit message from CVS:

* check/Makefile.am:
add gsttag
* check/gst/gsttag.c: (check_tags), (START_TEST), (gst_tag_suite),
(main):
move over from testsuite dir and clean up
* configure.ac:
* gst/gsttag.c:
* testsuite/Makefile.am:
* testsuite/tags/.cvsignore:
* testsuite/tags/Makefile.am:
* testsuite/tags/merge.c:
remove testsuite/tags
2005-06-19 11:32:42 +00:00
Thomas Vander Stichele 0944ac134b some more docs cleanup
Original commit message from CVS:
some more docs cleanup
2005-06-19 10:54:12 +00:00
Thomas Vander Stichele 4ae0c46b63 check/gstcheck.h: add macros for checking refcounts on objects and caps
Original commit message from CVS:

* check/gstcheck.h:
add macros for checking refcounts on objects and caps
* check/gst/gstpad.c: (START_TEST), (gst_pad_suite):
add some more unit tests
* gst/gstpad.c: (gst_pad_link_check_compatible_unlocked),
(gst_pad_link_prepare), (gst_pad_link), (gst_pad_get_allowed_caps):
fix leaked refcounts (I hope :)) so unittest works
* gst/gstpad.h:
whitespace removal
2005-06-19 00:52:31 +00:00
Andy Wingo 355499790b gst/base/gstbasesink.c (gst_basesink_chain): Remove bogus assert; it's always possible that the pad gets deactivated ...
Original commit message from CVS:
2005-06-17  Andy Wingo  <wingo@pobox.com>

* gst/base/gstbasesink.c (gst_basesink_chain): Remove bogus
assert; it's always possible that the pad gets deactivated in
between the checks in gstpad.c and the implementation. Rely on
finish_preroll() to return a FLUSHING or similar instead of on the
assert.
2005-06-17 11:58:48 +00:00
Andy Wingo d47ea57975 gst/base/gstbasesink.c (gst_basesink_event): Only wait for the clock and post an EOS message if we come out of finish...
Original commit message from CVS:
2005-06-17  Andy Wingo  <wingo@pobox.com>

* gst/base/gstbasesink.c (gst_basesink_event): Only wait for the
clock and post an EOS message if we come out of finish_preroll in
the playing state.
2005-06-17 11:33:27 +00:00
Thomas Vander Stichele d85fc27ecb ignore more
Original commit message from CVS:
ignore more
2005-06-17 09:32:19 +00:00
Thomas Vander Stichele dd9cc6adb7 ignore more
Original commit message from CVS:
ignore more
2005-06-17 09:12:33 +00:00
Thomas Vander Stichele 8a3824efac ignore more; fix README
Original commit message from CVS:
ignore more; fix README
2005-06-17 08:59:41 +00:00
David Schleef 6dbed89c01 gst/elements/gstcapsfilter.c: Allow NULL as possible value for filter_caps property, indicating GST_CAPS_ANY.
Original commit message from CVS:
* gst/elements/gstcapsfilter.c: (gst_capsfilter_class_init),
(gst_capsfilter_set_property): Allow NULL as possible value
for filter_caps property, indicating GST_CAPS_ANY.
2005-06-16 17:50:16 +00:00
Thomas Vander Stichele 013b77e072 gst/elements/gstfakesrc.c: fix debug output
Original commit message from CVS:

* gst/elements/gstfakesrc.c: (gst_fakesrc_create):
fix debug output
* gst/schedulers/Makefile.am:
use libgst prefix
* gstreamer.spec.in:
fix spec for it
2005-06-09 13:33:00 +00:00
Andy Wingo 4b908e33e0 gst/gstutils.c: RPAD fixes all around.
Original commit message from CVS:
2005-06-08  Andy Wingo  <wingo@pobox.com>

* gst/gstutils.c: RPAD fixes all around.
(gst_element_link_pads): Refcounting fixes.

* tools/gst-inspect.c:
* tools/gst-xmlinspect.c:
* parse/grammar.y:
* gst/base/gsttypefindhelper.c:
* gst/base/gstbasesink.c:
* gst/gstqueue.c: RPAD fixes.

* gst/gstghostpad.h:
* gst/gstghostpad.c: New ghost pad implementation as full proxy
pads. The tricky thing is they provide both source and sink
interfaces, since they proxy the internal pad for the external
pad, and vice versa. Implement with lower-level ProxyPad objects,
with the interior proxy pad as a child of the exterior ghost pad.
Should write a doc on this.

* gst/gstpad.h: s/RPAD/PAD/, s/RealPad/Pad/.
(gst_pad_set_name, gst_pad_set_parent): Macros removed, use
gst_object API.

* gst/gstpad.c: Big changes. No more stub base GstPad, now all
pads are real pads. No ghost pads in this file. Not documenting
the myriad s/RPAD/PAD/ and REALIZE fixes.
(gst_pad_class_init): Add properties for "direction" and
"template". Both are construct-only, so they can't change during
the life of the pad. Fixes properly deriving from GstPad.
(gst_pad_custom_new, gst_pad_custom_new_from_template): Gone. For
derived objects, just set properties when creating the objects via
g_object_new.
(gst_pad_get_parent): Implement as a function, return NULL if the
parent is not an element.
(gst_pad_get_real_parent, gst_pad_add_ghost_pad)
(gst_pad_remove_ghost_pad, gst_pad_realize): Removed.

* gst/gstobject.c (gst_object_class_init): Make name a construct
property. Don't set it in the object init.

* gst/gstelement.c (gst_element_add_pad): Don't allow adding pads
with UNKNOWN direction.
(gst_element_add_ghost_pad): Remove non-orthogonal API. Replace
with gst_element_add_pad (e, gst_ghost_pad_new (name, pad)).
(gst_element_remove_pad): Remove ghost-pad special cases.
(gst_element_pads_activate): Remove rpad cruft.

* gst/gstbin.c (gst_bin_change_state): Use gst_pad_get_parent to
catch the pad's-parent-not-an-element case.

* gst/gst.h: Include gstghostpad.h.

* gst/gst.c (init_post): No more real, ghost pads.

* gst/Makefile.am: Add gstghostpad.[ch].

* check/Makefile.am:
* check/gst/gstbin.c:
* check/gst/gstghostpad.c (test_ghost_pads): Check that linking
into a bin creates ghost pads, and that the refcounts are right.
Partly moved from gstbin.c.
2005-06-08 22:16:27 +00:00
Thomas Vander Stichele d282f08209 add a 'plugins' dir to the PLUGIN_PATH in the uninstalled script to drop random other plugin-having projects in
Original commit message from CVS:
add a 'plugins' dir to the PLUGIN_PATH in the uninstalled script to drop random other plugin-having projects in
2005-06-08 13:42:52 +00:00
Thomas Vander Stichele c87c44b07f OBJECT acts on obj not caps
Original commit message from CVS:
OBJECT acts on obj not caps
2005-06-08 13:41:31 +00:00
Thomas Vander Stichele 41a8de905b add a debug line
Original commit message from CVS:
add a debug line
2005-06-08 13:41:05 +00:00
Thomas Vander Stichele 1ffd2bc0ce white space fixes
Original commit message from CVS:
white space fixes
2005-06-08 13:40:46 +00:00
Jan Schmidt c9f30f98b7 gst/elements/gstcapsfilter.c: Free existing caps if the capsfilter changes. Add a FIXME about setting those caps on t...
Original commit message from CVS:
* gst/elements/gstcapsfilter.c: (gst_capsfilter_set_property):
Free existing caps if the capsfilter changes. Add a FIXME about
setting those caps on the pads.

* gst/gstutils.c: (gst_element_get_compatible_pad), (ghost_up):
Before adding a ghost pad to a parent bin, check that there isn't
already one for the element on the bin. Prevents infinite recursion
when using decodebin in parse pipelines. Andy says he'll rewrite the
way this works anyway, so ignore the hack.
2005-06-02 15:45:16 +00:00
Andy Wingo 26a1c2c663 gst/elements/gsttypefindelement.c (do_pull_typefind): Query the file size, pass it on to the type find helper.
Original commit message from CVS:
2005-06-02  Andy Wingo  <wingo@pobox.com>

* gst/elements/gsttypefindelement.c (do_pull_typefind): Query the
file size, pass it on to the type find helper.

* gst/base/gstbasesrc.c (gst_basesrc_do_seek): Set the
segment_start and segment_end properly according to the seek
method. Segment_end is still a bit flaky because offset can be
negative for CUR and END cases, but it takes -1 as an "unset"
value.
2005-06-02 11:12:34 +00:00
Wim Taymans d3edbe1718 gst/: Bufferalloc: return GstFlowReturn to more accuratly report why allocation failed.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_pad_buffer_alloc),
(gst_base_sink_buffer_alloc), (gst_basesink_preroll_queue_push),
(gst_basesink_activate):
* gst/base/gstbasesink.h:
* gst/gstpad.c: (gst_pad_set_active), (gst_pad_link_prepare),
(gst_pad_link), (gst_pad_accept_caps), (gst_pad_alloc_buffer),
(gst_pad_query), (gst_pad_start_task):
* gst/gstpad.h:
* gst/gstqueue.c: (gst_queue_bufferalloc),
(gst_queue_handle_sink_event), (gst_queue_chain):
Bufferalloc: return GstFlowReturn to more accuratly report
why allocation failed.
2005-06-02 09:42:02 +00:00
Wim Taymans 5c026ec0db gst/gstpipeline.c: Take snapshot of state without blocking.
Original commit message from CVS:
* gst/gstpipeline.c: (gst_pipeline_send_event):
Take snapshot of state without blocking.
2005-06-02 09:39:21 +00:00
Wim Taymans fcc76e3d07 gst/elements/gstidentity.c: Protect last_message property as it is accessed from multiple threads.
Original commit message from CVS:
* gst/elements/gstidentity.c: (gst_identity_event),
(gst_identity_transform), (gst_identity_get_property):
Protect last_message property as it is accessed from
multiple threads.
2005-05-30 16:28:41 +00:00
Wim Taymans 8d0a4e1d4f gst/gstelement.c: Slicker pad activation code.
Original commit message from CVS:
* gst/gstelement.c: (gst_element_init),
(gst_element_pads_activate), (gst_element_change_state):
Slicker pad activation code.
2005-05-30 15:53:04 +00:00
Wim Taymans e1b5b74857 gst/: Move elementfactory methods to separate .h file.
Original commit message from CVS:
* gst/Makefile.am:
* gst/gstelement.h:
* gst/gstelementfactory.h:
* gst/gsttypes.h:
Move elementfactory methods to separate .h file.
2005-05-30 15:51:40 +00:00
Wim Taymans 99d49f2c43 Small typo fixes, doc updates.
Original commit message from CVS:
* docs/design/part-overview.txt:
* gst/gstsystemclock.h:
Small typo fixes, doc updates.
2005-05-30 15:48:45 +00:00
Wim Taymans 248dce3e13 gst/gst.c: Remove cpu-opt flag.
Original commit message from CVS:
* gst/gst.c: (gst_init_get_popt_table), (init_post),
(init_popt_callback):
Remove cpu-opt flag.
2005-05-30 15:46:15 +00:00
Wim Taymans a86feaf099 gst/gstbuffer.*: Avoid typechecking in places where not needed.
Original commit message from CVS:
* gst/gstbuffer.c: (gst_subbuffer_finalize),
(gst_buffer_create_sub), (gst_buffer_is_span_fast):
* gst/gstbuffer.h:
Avoid typechecking in places where not needed.
Added accessor for malloc_data.
2005-05-30 15:44:50 +00:00
Wim Taymans 0e1ad862de gst/gstpad.c: Propagate errors from _set_caps() in configure_src/sink functions instead of returning TRUE.
Original commit message from CVS:
* gst/gstpad.c: (gst_real_pad_init), (gst_pad_set_active),
(gst_pad_link_prepare), (gst_pad_link), (gst_pad_accept_caps),
(gst_pad_configure_sink), (gst_pad_configure_src),
(gst_pad_alloc_buffer), (gst_pad_query), (gst_pad_send_event),
(gst_pad_start_task):
Propagate errors from _set_caps() in configure_src/sink
functions instead of returning TRUE.
FLUSH events can travel up and downstream
2005-05-30 15:41:54 +00:00
Wim Taymans be66bb03b4 gst/base/gstbasesink.c: Handle EOS in preroll.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_preroll_queue_push),
(gst_basesink_activate):
Handle EOS in preroll.
2005-05-30 15:36:09 +00:00
Wim Taymans 148057fa10 gst/gstqueue.c: Remove old pieces of code
Original commit message from CVS:
* gst/gstqueue.c: (gst_queue_handle_sink_event), (gst_queue_chain),
(gst_queue_loop), (gst_queue_handle_src_event):
Remove old pieces of code
Flushing the queue in an upstream event is a very bad idea.
2005-05-30 15:34:13 +00:00
Andy Wingo 1457b69cb7 gst/gstminiobject.c (gst_value_mini_object_collect): Use gst_value_set_mini_object so as to add a ref on the object (...
Original commit message from CVS:
2005-05-26  Andy Wingo  <wingo@pobox.com>

* gst/gstminiobject.c (gst_value_mini_object_collect): Use
gst_value_set_mini_object so as to add a ref on the object (which
will be removed when the value is unset).

* gst/elements/gstfakesink.c (gst_fakesink_class_init): Fix signal
arg type in ::handoff.

* gst/gstelement.c (gst_element_change_state): Also deactivate
pads in READY->NULL, just in case the element didn't make it to
PAUSED. Wingo tested, Wim approved.
2005-05-27 09:27:35 +00:00
Wim Taymans 61167c9097 gst/gstpad.c: A flushing pad cannot be used to alloc_buffer from.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_set_active), (gst_pad_link_prepare),
(gst_pad_link), (gst_pad_accept_caps), (gst_pad_alloc_buffer),
(gst_pad_query), (gst_pad_send_event), (gst_pad_start_task):
A flushing pad cannot be used to alloc_buffer from.
2005-05-26 10:50:12 +00:00
Wim Taymans ea2dd0057c gst/gstbus.*: Implement a real GSource and use g_main_context_wakeup() to signal new messages instead of the socketpair.
Original commit message from CVS:
* gst/gstbus.c: (gst_bus_init), (gst_bus_dispose), (gst_bus_post),
(gst_bus_pop), (gst_bus_source_prepare), (gst_bus_source_check),
(gst_bus_source_dispatch), (gst_bus_source_finalize),
(gst_bus_create_watch), (gst_bus_add_watch_full):
* gst/gstbus.h:
Implement a real GSource and use g_main_context_wakeup() to
signal new messages instead of the socketpair.
2005-05-26 10:48:53 +00:00
Wim Taymans 56d9730d20 gst/: Fix state changes for non sinks. We now change sinks, then elements with unconnected srcpads, then the rest.
Original commit message from CVS:
* gst/gstbin.c: (bin_element_is_sink), (has_ancestor),
(bin_element_is_semi_sink), (append_child), (gst_bin_change_state):
* gst/gstpad.c: (gst_pad_set_active), (gst_pad_link_prepare),
(gst_pad_link), (gst_pad_accept_caps), (gst_pad_query),
(gst_pad_send_event), (gst_pad_start_task):
* gst/gstqueue.c: (gst_queue_init), (gst_queue_locked_flush),
(gst_queue_handle_sink_event), (gst_queue_chain), (gst_queue_loop),
(gst_queue_sink_activate), (gst_queue_src_activate),
(gst_queue_change_state):
* gst/gstqueue.h:
Fix state changes for non sinks. We now change sinks, then elements
with unconnected srcpads, then the rest.
More efficient queue unlocking in flush and state changes.
Set the pad activate mode even if it does not have an activate
function.
2005-05-25 19:33:39 +00:00
Ronald S. Bultje c6d2acd587 happify buildbot
Original commit message from CVS:
happify buildbot
2005-05-25 16:09:34 +00:00
Ronald S. Bultje f0ed41684a gst/base/gstbasesrc.c: Don't go in pull mode for non-seekable sources.
Original commit message from CVS:
* gst/base/gstbasesrc.c: (gst_basesrc_activate):
Don't go in pull mode for non-seekable sources.
* gst/elements/gsttypefindelement.c: (gst_type_find_element_init),
(gst_type_find_element_dispose), (gst_type_find_handle_src_query),
(free_entry), (stop_typefinding),
(gst_type_find_element_handle_event), (find_peek),
(gst_type_find_element_chain), (do_pull_typefind),
(gst_type_find_element_change_state):
Allow typefinding (w/o seeking) in push-mode, simplified version
of what was in 0.8.
* gst/gstutils.c: (gst_buffer_join):
* gst/gstutils.h:
gst_buffer_join() from 0.8.
2005-05-25 15:57:57 +00:00
Wim Taymans 25576cb626 gst/gstpad.c: Disable attempt at mode switching until it is figured out.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_set_active), (gst_pad_link_prepare),
(gst_pad_link), (gst_pad_accept_caps), (gst_pad_query),
(gst_pad_send_event), (gst_pad_start_task):
Disable attempt at mode switching until it is figured out.
2005-05-25 13:59:18 +00:00
Wim Taymans add280cd10 gst/: Implement gst_pad_pause/start/stop_task(), take STREAM lock in task function.
Original commit message from CVS:
* gst/base/gstadapter.c: (gst_adapter_peek), (gst_adapter_flush):
* gst/base/gstbasesink.c: (gst_basesink_preroll_queue_push),
(gst_basesink_finish_preroll), (gst_basesink_chain),
(gst_basesink_loop), (gst_basesink_activate),
(gst_basesink_change_state):
* gst/base/gstbasesrc.c: (gst_basesrc_do_seek),
(gst_basesrc_get_range), (gst_basesrc_loop),
(gst_basesrc_activate):
* gst/elements/gsttee.c: (gst_tee_sink_activate):
* gst/gstpad.c: (gst_pad_dispose), (gst_real_pad_class_init),
(gst_real_pad_init), (gst_real_pad_set_property),
(gst_real_pad_get_property), (gst_pad_set_active),
(gst_pad_is_active), (gst_pad_get_query_types), (gst_pad_unlink),
(gst_pad_link_prepare), (gst_pad_link), (gst_pad_get_real_parent),
(gst_real_pad_get_caps_unlocked), (gst_pad_peer_get_caps),
(gst_pad_accept_caps), (gst_pad_get_peer), (gst_pad_realize),
(gst_pad_event_default_dispatch), (gst_pad_event_default),
(gst_pad_dispatcher), (gst_pad_query), (gst_real_pad_dispose),
(gst_pad_save_thyself), (handle_pad_block), (gst_pad_chain),
(gst_pad_push), (gst_pad_get_range), (gst_pad_pull_range),
(gst_pad_send_event), (gst_pad_start_task), (gst_pad_pause_task),
(gst_pad_stop_task):
* gst/gstpad.h:
* gst/gstqueue.c: (gst_queue_handle_sink_event), (gst_queue_chain),
(gst_queue_loop), (gst_queue_src_activate):
* gst/gsttask.c: (gst_task_init), (gst_task_set_lock),
(gst_task_get_state):
* gst/gsttask.h:
* gst/schedulers/threadscheduler.c:
(gst_thread_scheduler_task_start), (gst_thread_scheduler_func):
Implement gst_pad_pause/start/stop_task(), take STREAM lock
in task function.
Remove ACTIVE pad flag, use FLUSHING everywhere
Added _pad_chain(), _pad_get_range() to call chain/getrange
functions.
Add locks around IS_FLUSHING when reading.
Take STREAM lock in chain(), get_range() functions so plugins
don't need to take it anymore.
2005-05-25 11:50:11 +00:00
David Schleef 4c9d07cf22 gst/gstminiobject.*: Add GValue set/get functions.
Original commit message from CVS:
* gst/gstminiobject.c: (gst_value_set_mini_object),
(gst_value_take_mini_object), (gst_value_get_mini_object):
* gst/gstminiobject.h: Add GValue set/get functions.
2005-05-19 19:41:12 +00:00
Wim Taymans fbe9b20d09 gst/: Make subbufer unref the parent in finalize. some more debugging info.
Original commit message from CVS:
* gst/gstbuffer.c: (gst_buffer_init), (gst_subbuffer_get_type),
(gst_subbuffer_class_init), (gst_subbuffer_finalize),
(gst_subbuffer_init), (gst_buffer_is_span_fast):
* gst/gstbuffer.h:
* gst/gstbus.c: (gst_bus_post):
* gst/gstelement.c: (gst_element_get_random_pad):
* gst/gstmessage.c: (gst_message_init), (gst_message_finalize):
Make subbufer unref the parent in finalize.
some more debugging info.
2005-05-19 16:26:50 +00:00
Wim Taymans 637c74bdb8 gst/base/gstbasesink.c: Don't free preroll queue too early.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_class_init),
(gst_basesink_init), (gst_basesink_finalize),
(gst_basesink_activate), (gst_basesink_change_state):
Don't free preroll queue too early.
2005-05-19 16:23:04 +00:00
Ronald S. Bultje 1b2ade5361 gst/: Hi, I'm outdated. Please shoot me.
Original commit message from CVS:
* gst/Makefile.am:
* gst/ROADMAP:
Hi, I'm outdated. Please shoot me.
2005-05-19 14:52:16 +00:00
Ronald S. Bultje 9909bf96dc gst/gstpipeline.c: Do not access variables after they have been deleted.
Original commit message from CVS:
* gst/gstpipeline.c: (gst_pipeline_send_event):
Do not access variables after they have been deleted.
2005-05-19 12:07:35 +00:00
Wim Taymans 0dd4810c73 gst/gstbuffer.c: Port _span() functions to new subbuffers.
Original commit message from CVS:
* gst/gstbuffer.c: (gst_buffer_is_span_fast), (gst_buffer_span):
Port _span() functions to new subbuffers.
2005-05-18 17:35:23 +00:00
Ronald S. Bultje f704550b84 gst/gstbin.c: Fix clock settery in bins when adding kids after the clock has been selected.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_add_func):
Fix clock settery in bins when adding kids after the clock has
been selected.
2005-05-18 13:49:08 +00:00
Ronald S. Bultje ca6017610d gst/elements/gstidentity.c: Workaround until signals support GstMiniObject.
Original commit message from CVS:
* gst/elements/gstidentity.c: (gst_identity_class_init):
Workaround until signals support GstMiniObject.
2005-05-18 13:23:24 +00:00
Jan Schmidt ea9c819e6e gst/gstbuffer.c: Oops, fix a typo GST_TYPE_BUFFER -> GST_TYPE_SUBBUFFER.
Original commit message from CVS:

* gst/gstbuffer.c:
Oops, fix a typo GST_TYPE_BUFFER -> GST_TYPE_SUBBUFFER.
2005-05-18 11:34:45 +00:00
Wim Taymans 8074f6687d gst/base/: Ported and added adapter to the base classes.
Original commit message from CVS:
* gst/base/Makefile.am:
* gst/base/gstadapter.c: (gst_adapter_base_init),
(gst_adapter_class_init), (gst_adapter_init),
(gst_adapter_dispose), (gst_adapter_finalize), (gst_adapter_new),
(gst_adapter_clear), (gst_adapter_push), (gst_adapter_peek),
(gst_adapter_flush), (gst_adapter_available),
(gst_adapter_available_fast):
* gst/base/gstadapter.h:
Ported and added adapter to the base classes.
2005-05-18 09:55:43 +00:00
Thomas Vander Stichele cb9388c96e gst/: Make sure the class is reffed/unreffed once before threads can be used. Fixes #304551.
Original commit message from CVS:

* gst/gst.c:
* gst/gstmessage.c:
Make sure the class is reffed/unreffed once before threads can be
used.  Fixes #304551.
2005-05-17 17:50:41 +00:00
Wim Taymans 576b2181d8 gst/: Don't queue buffers in basesink when we are flushing.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_finish_preroll),
(gst_basesink_chain_unlocked), (gst_basesink_activate):
* gst/gstminiobject.c: (gst_mini_object_get_type),
(gst_mini_object_free):
* gst/gstpad.c: (gst_pad_accept_caps), (gst_pad_query),
(gst_pad_push), (gst_pad_push_event):
* gst/gstqueue.c: (gst_queue_change_state):
Don't queue buffers in basesink when we are flushing.
Unref buffer when flushing in basesink.
Flush queue when going to READY
Unref buffer when _push() returns an error.
Don't free MiniObject instance when refcount is incremented
in _finalize() so that we can recover objects.
2005-05-17 17:37:43 +00:00
Wim Taymans 8b61f54757 gst/: Clear queue when going to READY.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_accept_caps), (gst_pad_set_caps),
(gst_pad_alloc_buffer), (gst_pad_query), (gst_pad_push):
* gst/gstqueue.c: (gst_queue_change_state):
Clear queue when going to READY.
Remove IN_SETCAPS flag too.
2005-05-17 14:11:32 +00:00
Tim-Philipp Müller 7fa9d7eb65 gst/base/gstbasesrc.c: Remove implicit cast from gboolean to GstElementStateReturn; make sure we still return failure...
Original commit message from CVS:
* gst/base/gstbasesrc.c: (gst_basesrc_change_state):
Remove implicit cast from gboolean to GstElementStateReturn;
make sure we still return failure in paused => ready case if
the parent class fails to change state and our own stop
vfunc succeeds.
2005-05-17 14:01:51 +00:00
Andy Wingo 04312000d0 gst/gstbin.c (sink_iterator_filter): Err... um...
Original commit message from CVS:
2005-05-16  Andy Wingo  <wingo@pobox.com>

* gst/gstbin.c (sink_iterator_filter): Err... um...

* check/gst/gstbin.c (test_ghost_pads): New test for the
ghosting-if-elements-not-in-same-bin behavior.
2005-05-16 21:17:14 +00:00
David Schleef b52ba4751a gst/gstminiobject.c: Use g_atomic_int_get() instead of accessing refcount directly.
Original commit message from CVS:
* gst/gstminiobject.c: Use g_atomic_int_get() instead of
accessing refcount directly.
2005-05-16 21:05:21 +00:00
David Schleef e134f7f75b check/Makefile.am: remove GstData checks
Original commit message from CVS:
* check/Makefile.am: remove GstData checks
* check/gst-libs/gdp.c: (START_TEST): fix for API changes
* gst/Makefile.am: add miniobject, remove data
* gst/gst.h: add miniobject, remove data
* gst/gstdata.c: remove
* gst/gstdata.h: remove
* gst/gstdata_private.h: remove
* gst/gsttypes.h: remove GstEvent and GstMessage
* gst/gstelement.c: (gst_element_post_message): fix for API changes
* gst/gstmarshal.list: change BOXED -> OBJECT
Implement GstMiniObject.
* gst/gstminiobject.c:
* gst/gstminiobject.h:
Modify to be subclasses of GstMiniObject.
* gst/gstbuffer.c: (_gst_buffer_initialize), (gst_buffer_get_type),
(gst_buffer_class_init), (gst_buffer_finalize), (_gst_buffer_copy),
(gst_buffer_init), (gst_buffer_new), (gst_buffer_new_and_alloc),
(gst_subbuffer_get_type), (gst_subbuffer_init),
(gst_buffer_create_sub), (gst_buffer_is_span_fast),
(gst_buffer_span):
* gst/gstbuffer.h:
* gst/gstevent.c: (_gst_event_initialize), (gst_event_get_type),
(gst_event_class_init), (gst_event_init), (gst_event_finalize),
(_gst_event_copy), (gst_event_new):
* gst/gstevent.h:
* gst/gstmessage.c: (_gst_message_initialize),
(gst_message_get_type), (gst_message_class_init),
(gst_message_init), (gst_message_finalize), (_gst_message_copy),
(gst_message_new), (gst_message_new_error),
(gst_message_new_warning), (gst_message_new_tag),
(gst_message_new_state_changed), (gst_message_new_application):
* gst/gstmessage.h:
* gst/gstprobe.c: (gst_probe_perform),
(gst_probe_dispatcher_dispatch):
* gst/gstprobe.h:
* gst/gstquery.c: (_gst_query_initialize), (gst_query_get_type),
(gst_query_class_init), (gst_query_finalize), (gst_query_init),
(_gst_query_copy), (gst_query_new):
Update elements for GstData -> GstMiniObject changes
* gst/gstquery.h:
* gst/gstqueue.c: (gst_queue_finalize), (gst_queue_locked_flush),
(gst_queue_chain), (gst_queue_loop):
* gst/elements/gstbufferstore.c:
(gst_buffer_store_add_buffer_func),
(gst_buffer_store_cleared_func), (gst_buffer_store_get_buffer):
* gst/elements/gstfakesink.c: (gst_fakesink_class_init),
(gst_fakesink_render):
* gst/elements/gstfakesrc.c: (gst_fakesrc_class_init):
* gst/elements/gstfilesrc.c: (gst_mmap_buffer_get_type),
(gst_mmap_buffer_class_init), (gst_mmap_buffer_init),
(gst_mmap_buffer_finalize), (gst_filesrc_map_region),
(gst_filesrc_create_read):
* gst/elements/gstidentity.c: (gst_identity_class_init):
* gst/elements/gsttypefindelement.c:
(gst_type_find_element_src_event), (free_entry_buffers),
(gst_type_find_element_handle_event):
* libs/gst/dataprotocol/dataprotocol.c:
(gst_dp_header_from_buffer):
* libs/gst/dataprotocol/dataprotocol.h:
* libs/gst/dataprotocol/dp-private.h:
2005-05-16 20:21:55 +00:00
David Schleef 735061ecc6 gst/elements/gstelements.c: Don't include headers that were just removed.
Original commit message from CVS:
* gst/elements/gstelements.c: Don't include headers that were
just removed.
2005-05-15 23:18:40 +00:00
David Schleef abb59b9e80 gst/elements/Makefile.am: Remove some elements that don't need to be in the core (or even exist at all).
Original commit message from CVS:
* gst/elements/Makefile.am: Remove some elements that don't
need to be in the core (or even exist at all).
* gst/elements/gstaggregator.c:
* gst/elements/gstaggregator.h:
* gst/elements/gstmd5sink.c:
* gst/elements/gstmd5sink.h:
* gst/elements/gstmultifilesrc.c:
* gst/elements/gstmultifilesrc.h:
* gst/elements/gstpipefilter.c:
* gst/elements/gstpipefilter.h:
* gst/elements/gstshaper.c:
* gst/elements/gstshaper.h:
* gst/elements/gststatistics.c:
* gst/elements/gststatistics.h:
* po/POTFILES.in: Remove above files.
2005-05-15 23:16:29 +00:00
Andy Wingo ab5ba6271c gst/gstbin.c (gst_bin_iterate_sinks): Use sink_iterator_filter so as to get the refs right.
Original commit message from CVS:
2005-05-14  Andy Wingo  <wingo@pobox.com>

* gst/gstbin.c (gst_bin_iterate_sinks): Use sink_iterator_filter
so as to get the refs right.
(sink_iterator_filter): New function, wraps bin_element_is_sink,
unreffing objects that don't pass the filter.
2005-05-14 18:01:12 +00:00
Andy Wingo 4765634c62 gst/gstpipeline.c (gst_pipeline_init): Drop ref on bus after gst_element_set_bus.
Original commit message from CVS:
2005-05-14  Andy Wingo  <wingo@pobox.com>

* gst/gstpipeline.c (gst_pipeline_init): Drop ref on bus after
gst_element_set_bus.
(gst_pipeline_dispose): Set the bus on the pipeline to NULL. In
normal cases, this will destroy the bus.

* gst/gstutils.c (prepare_link_maybe_ghosting): Drop ref on root
object.
2005-05-14 17:12:11 +00:00
Andy Wingo c967174c17 gst/gstbin.c (gst_bin_change_state): Fix state changes if a bin has no sinks.
Original commit message from CVS:
2005-05-14  Andy Wingo  <wingo@pobox.com>

* gst/gstbin.c (gst_bin_change_state): Fix state changes if a bin
has no sinks.
2005-05-14 15:54:49 +00:00
Andy Wingo 79d4977020 gst/gstutils.c (gst_element_link_pads): Instead of calling gst_pad_link, call pad_link_maybe_ghosting,
Original commit message from CVS:
2005-05-13  Andy Wingo  <wingo@pobox.com>

* gst/gstutils.c (gst_element_link_pads): Instead of calling
gst_pad_link, call pad_link_maybe_ghosting,
(pad_link_maybe_ghosting): Links pads, making sure that the
elements being linked are in the same bin.
(find_common_root, object_has_ancestor, ghost_up, remove_pad):
Helpers for pad_link_maybe_ghosting.
2005-05-14 15:32:36 +00:00
Wim Taymans 1c4ea6213b gst/: Identify sinks by their flag to avoid overly complicated checks (fow now).
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_init),
(gst_basesink_activate):
* gst/base/gstbasesrc.c: (gst_basesrc_unlock),
(gst_basesrc_is_seekable):
* gst/gstbin.c: (gst_bin_add_func), (gst_bin_remove_func),
(bin_element_is_sink), (gst_bin_change_state):
* gst/gstelement.c: (gst_element_add_pad), (gst_element_query):
* gst/gstelement.h:
Identify sinks by their flag to avoid overly complicated
checks (fow now).
Do state changes even for elements not reachable from the
sinks.
BaseSink is a sink now :)
Some more debugging info in the basesrc.
2005-05-12 19:45:44 +00:00
Ronald S. Bultje e4c1ba46c8 gst/gstbin.c: Implement _query on a bin, similar to _send_event.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_class_init), (gst_bin_query):
Implement _query on a bin, similar to _send_event.
2005-05-12 15:09:17 +00:00
Tim-Philipp Müller 7eb36ed16f gst/base/gstbasesrc.c: Discont event offset format should be GST_FORMAT_BYTES, not GST_FORMAT_TIME.
Original commit message from CVS:
* gst/base/gstbasesrc.c: (gst_basesrc_do_seek):
Discont event offset format should be GST_FORMAT_BYTES,
not GST_FORMAT_TIME.
2005-05-12 13:59:58 +00:00
Wim Taymans 8694ff47b4 gst/gstbin.c: Same fix as Ronald's but without the signal.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_remove_func), (gst_bin_get_state):
Same fix as Ronald's but without the signal.
2005-05-12 13:18:14 +00:00
Ronald S. Bultje e5f4d65005 gst/gstutils.c: No, an element is not a pad.
Original commit message from CVS:
* gst/gstutils.c: (gst_element_query_position):
No, an element is not a pad.
2005-05-12 12:27:07 +00:00
Ronald S. Bultje e805d1b78b gst/gstbin.c: If a child is removed from a bin while we remove the child from the bin and while we're retrieving its ...
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_add_func), (cb_parent_unset),
(gst_bin_get_state):
If a child is removed from a bin while we remove the child from
the bin and while we're retrieving its state, signal this to the
get_state function so we abort the wait (instead of waiting for
a timeout) and can immediately re-iterate over all other elements.
2005-05-12 12:17:23 +00:00
Wim Taymans 88d6683316 gst/base/: Added is_seekable to BaseSrc
Original commit message from CVS:
* gst/base/Makefile.am:
* gst/base/gstbasesrc.c: (gst_basesrc_is_seekable),
(gst_basesrc_start):
* gst/base/gstbasesrc.h:
* gst/base/gstpushsrc.c: (gst_pushsrc_get_type),
(gst_pushsrc_base_init), (gst_pushsrc_class_init),
(gst_pushsrc_init), (gst_pushsrc_create):
* gst/base/gstpushsrc.h:
Added is_seekable to BaseSrc
Added simple PushSrc.
2005-05-12 10:43:14 +00:00
Wim Taymans c9aaf4663f gst/: Fix refcounting in utils function.
Original commit message from CVS:
* gst/gstelement.c: (gst_element_add_pad), (gst_element_query):
* gst/gstutils.c: (gst_element_get_compatible_pad_template),
(gst_element_link_pads), (gst_element_query_position),
(gst_element_query_convert), (intersect_caps_func),
(gst_pad_query_position), (gst_pad_query_convert):
Fix refcounting in utils function.
No point in trying to activate a pad when it's added, it could
be added from the state change function and then we deadlock, the
element has to decide what to do.
2005-05-11 09:21:24 +00:00
Andy Wingo e44beb9f04 gst/elements/gstfakesink.c (gst_fakesink_render): Er, emit with
Original commit message from CVS:
2005-05-10  Andy Wingo  <wingo@pobox.com>

* gst/elements/gstfakesink.c (gst_fakesink_render): Er, emit with
*all* the arguments.

* gst/base/gstbasetransform.c (gst_base_transform_event): Grab the
stream lock if it's a FLUSH_DONE; normal flushes don't get the
lock (according to the docs -- if this is wrong change the docs).

* gst/gstpipeline.c (gst_pipeline_change_state): Set the bus to
flush messages in the NULL state.

* gst/gstbus.c (gst_bus_post): If a bus is flushing, unref the
message immediately and return.
(gst_bus_set_flushing): New function. If a bus is flushing, it
flushes out any queued messages and immediately unrefs new
messages. This is so when an element goes to NULL, all of the
unhandled messages coming from it can be freed, and their
references to the element dropped. In other words: message source
ref considered harmful :P

* gst/gstbin.c (gst_bin_change_state): Unref peer element when
we're finished with it.

* gst/gstmessage.c (gst_message_new_state_changed):
2005-05-11 03:37:10 +00:00
Wim Taymans ee4cf984cf remove stupid printf
Original commit message from CVS:
remove stupid printf
2005-05-10 14:51:49 +00:00
Wim Taymans 33992f775b gst/gstvalue.c: Added flags serialize/deserialize/compare code.
Original commit message from CVS:
* gst/gstvalue.c: (gst_value_compare_flags),
(gst_value_serialize_flags), (gst_value_deserialize_flags),
(_gst_value_initialize):
Added flags serialize/deserialize/compare code.
2005-05-10 14:50:55 +00:00
Andy Wingo b594010249 gst/base/gstbasetransform.c (gst_base_transform_proxy_getcaps): Intersect the peer's caps with our caps.
Original commit message from CVS:
2005-05-09  Andy Wingo  <wingo@pobox.com>

* gst/base/gstbasetransform.c (gst_base_transform_proxy_getcaps):
Intersect the peer's caps with our caps.
2005-05-09 21:37:54 +00:00
Ronald S. Bultje 5b9c84091d gst/: Handle negative offsets better. Fixes decodebin.
Original commit message from CVS:
* gst/base/gsttypefindhelper.c: (helper_find_peek):
* gst/elements/gsttypefindelement.c: (find_peek):
Handle negative offsets better. Fixes decodebin.
2005-05-09 15:54:26 +00:00
Wim Taymans e70ec7b807 gst/: Implement accept_caps.
Original commit message from CVS:
* gst/base/gstbasetransform.c: (gst_base_transform_proxy_getcaps),
(gst_base_transform_event):
* gst/gstpad.c: (gst_pad_accept_caps), (gst_pad_query):
Implement accept_caps.
Fix silly lock/unlock mismatch in base class.
2005-05-09 14:47:15 +00:00
Wim Taymans 8df6cd7243 Remove old query functions. Ported old code.
Original commit message from CVS:
Remove old query functions. Ported old code.
Added position/convert helper functions to gstutils.
Reordered gstpad.c code, grouping relevant things.
Remove gst_message_new(), always need to speficy a specific
message.
2005-05-09 10:53:13 +00:00
Andy Wingo 328ddd7363 gst/gstiterator.h: Add some includes.
Original commit message from CVS:
2005-05-09  Andy Wingo  <wingo@pobox.com>

* gst/gstiterator.h: Add some includes.

* gst/gstqueryutils.h: Include more headers.

* gst/gstpad.h:
* gst/gstpad.c (gst_pad_query_position): New routine, replaces
some uses of gst_pad_query.

* gst/gstqueryutils.c: Build fixes. Make parse functions ignore
NULL out parameters.
(gst_query_new_position): New proc, allocates a new position
query.

* gst/Makefile.am (libgstreamer_@GST_MAJORMINOR@_la_SOURCES): Add
gstqueryutils.c to the build.

* gst/gststructure.c (gst_structure_set_valist): Implement with
the generic G_VALUE_COLLECT.
2005-05-09 06:21:10 +00:00
Edward Hervey 01162bee21 gst/Makefile.am: Added gstqueryutils.h to the list of headers to install, that was a 'nachty' move wingo :)
Original commit message from CVS:
* gst/Makefile.am: (gst_headers):
Added gstqueryutils.h to the list of headers to install, that was
a 'nachty' move wingo :)
2005-05-08 17:07:05 +00:00
Andy Wingo 8970bda4ba gst/gstquery.h
Original commit message from CVS:
2005-05-06  Andy Wingo  <wingo@pobox.com>

* gst/gstquery.h
* gst/gstquery.c (_gst_query_initialize): Extend GstQuery from
GstData, init a memchunk.
(standard_definitions): Add a few query types, deprecate a few.
(gst_query_get_type): New proc.
(_gst_query_copy, _gst_query_free, gst_query_new): GstData
implementation.
(gst_query_new_application, gst_query_get_structure): New public
procs.

* docs/design/draft-query.txt: Removed LINKS from the query types,
because all the rest can be dispatched to other pads -- seemed
ugly to have a query that couldn't be dispatched. internal_links
is fine as a pad method.

* gst/gstpad.h: Add query2 as a pad method, add the new functions
in gstpad.c, but maintain binary compatibility for the moment.
Will fix before 0.9 is out.

* gst/gstqueryutils.c:
* gst/gstqueryutils.h: New files, implement 3 methods for each
query type: parse_query, parse_response, and set. Probably need an
allocator as well.

* gst/gst.h: Add gstquery.h and gstqueryutils.h to the list.

* gst/elements/gstfilesink.c (gst_filesink_query2):
* gst/base/gstbasesrc.c (gst_basesrc_query2): Replace old query,
query_types, and formats methods.

* gst/gstpad.c (gst_pad_query2, gst_pad_query2_default)
(gst_pad_set_query2_function): New functions.
(gst_real_pad_init): Set query2_default as the default query2
function. Basically just dispatches to internally linked pads.

Needs review!

* gst/gstdata_private.h (_GST_DATA_INIT): Set data->refcount to 1
without using the atomic operations. Only one thread can possibly
be accessing the data at this point. Changed so as to avoid
gst_atomic operations.
2005-05-06 21:41:22 +00:00
Wim Taymans 1185aabed9 gst/gstpad.c: Also set caps if we use the fallback buffer alloc.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_alloc_buffer), (gst_pad_push):
Also set caps if we use the fallback buffer alloc.
2005-05-06 19:50:23 +00:00
Wim Taymans d7b231e6d1 gst/: Fix gst_pad_peer_get_caps(), make it return NULL if no peer.
Original commit message from CVS:
* gst/base/gstbasetransform.c: (gst_base_transform_proxy_getcaps):
* gst/elements/gstcapsfilter.c: (gst_capsfilter_getcaps):
* gst/gstpad.c: (gst_pad_peer_get_caps):
* gst/gstqueue.c: (gst_queue_init), (gst_queue_getcaps),
(gst_queue_bufferalloc), (gst_queue_handle_sink_event),
(gst_queue_src_activate), (gst_queue_change_state):
* gst/gstqueue.h:
* gst/gstutils.c: (gst_element_get_compatible_pad_template),
(intersect_caps_func):
Fix gst_pad_peer_get_caps(), make it return NULL if no peer.
Always take QUEUE_LOCK after STREAM_LOCK or we might deadlock.
Some fixes for the peer_get_caps() change.
2005-05-06 17:10:49 +00:00
Wim Taymans 92dd87a8c5 gst/base/gstbasesink.c: Actually do something with error codes returned from the push functions.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_preroll_queue_empty),
(gst_basesink_handle_buffer), (gst_basesink_chain_unlocked),
(gst_basesink_activate):
Actually do something with error codes returned from the push
functions.
2005-05-06 16:19:59 +00:00
Wim Taymans c11c932f88 Some more documentation.
Original commit message from CVS:
* docs/design/part-element-sink.txt:
* docs/design/part-element-source.txt:
* gst/base/gstbasesink.c: (gst_basesink_class_init),
(gst_basesink_event), (gst_basesink_activate):
* gst/base/gstbasesink.h:
* gst/base/gstbasesrc.c: (gst_basesrc_init), (gst_basesrc_unlock),
(gst_basesrc_activate):
* gst/base/gstbasesrc.h:
* gst/gstelement.c: (gst_element_pads_activate):
Some more documentation.
Fixed scheduling decision in _pads_activate().
2005-05-06 08:25:19 +00:00
Andy Wingo e33d96ba60 final cruft fixage
Original commit message from CVS:
final cruft fixage
2005-05-05 21:59:53 +00:00
Andy Wingo 89858fc1b7 cruft removal
Original commit message from CVS:
cruft removal
2005-05-05 21:45:54 +00:00
Andy Wingo 57183c39dc revert cruft
Original commit message from CVS:
revert cruft
2005-05-05 21:42:24 +00:00
Andy Wingo e19563e43e revert accidental commit of cruft -- doh
Original commit message from CVS:
revert accidental commit of cruft -- doh
2005-05-05 21:37:34 +00:00
Wim Taymans 113250d274 gst/: Added object to help in making collect pad based elements.
Original commit message from CVS:
* gst/base/Makefile.am:
* gst/base/gstbasesink.h:
* gst/base/gstbasesrc.c: (gst_basesrc_init),
(gst_basesrc_set_dataflow_funcs), (gst_basesrc_query):
* gst/base/gstcollectpads.c: (gst_collectpads_get_type),
(gst_collectpads_class_init), (gst_collectpads_init),
(gst_collectpads_finalize), (gst_collectpads_new),
(gst_collectpads_set_function), (gst_collectpads_add_pad),
(find_pad), (gst_collectpads_remove_pad),
(gst_collectpads_is_active), (gst_collectpads_collect),
(gst_collectpads_collect_range), (gst_collectpads_start),
(gst_collectpads_stop), (gst_collectpads_peek),
(gst_collectpads_pop), (gst_collectpads_available),
(gst_collectpads_read), (gst_collectpads_flush),
(gst_collectpads_chain):
* gst/base/gstcollectpads.h:
* gst/elements/Makefile.am:
* gst/elements/gstelements.c:
* gst/elements/gstfakesink.c: (gst_fakesink_class_init),
(gst_fakesink_get_times), (gst_fakesink_event),
(gst_fakesink_preroll), (gst_fakesink_render):
* gst/elements/gstfilesink.c: (gst_filesink_class_init),
(gst_filesink_init), (gst_filesink_set_location),
(gst_filesink_open_file), (gst_filesink_close_file),
(gst_filesink_pad_query), (gst_filesink_event),
(gst_filesink_render), (gst_filesink_change_state):
* gst/elements/gstfilesink.h:
Added object to help in making collect pad based elements.
Ported filesink.
Make event function in sink baseclass return gboolean.
2005-05-05 09:31:59 +00:00
Wim Taymans d2bf92842c gst/: Fix name lookup in GstBin.
Original commit message from CVS:
* gst/gstbin.c: (gst_bin_send_event), (compare_name),
(gst_bin_get_by_name):
* gst/gstbuffer.h:
* gst/gstclock.c: (gst_clock_entry_new), (gst_clock_class_init),
(gst_clock_finalize):
* gst/gstdata.c: (gst_data_replace):
* gst/gstdata.h:
* gst/gstelement.c: (gst_element_request_pad),
(gst_element_pads_activate):
* gst/gstobject.c: (gst_object_init), (gst_object_ref),
(gst_object_unref):
* gst/gstpad.c: (gst_pad_set_active), (gst_pad_peer_set_active),
(gst_pad_set_checkgetrange_function),
(gst_pad_link_check_compatible_unlocked), (gst_pad_set_caps),
(gst_pad_check_pull_range), (gst_pad_pull_range),
(gst_static_pad_template_get_caps), (gst_pad_start_task),
(gst_pad_pause_task), (gst_pad_stop_task):
* gst/gstutils.c: (gst_element_get_compatible_pad_template),
(gst_element_request_pad), (gst_pad_proxy_getcaps):
Fix name lookup in GstBin.
Added _data_replace() function and _buffer_replace()
Use finalize method to clean up clock.
Fix refcounting on request pads.
Fix pad schedule mode error.
Some more object refcounting debug info,
2005-05-05 09:28:01 +00:00
Andy Wingo b4d7be2014 GCC 4 fixen.
Original commit message from CVS:
2005-05-04  Andy Wingo <wingo@pobox.com>

* check/Makefile.am:
* docs/gst/tmpl/gstatomic.sgml:
* docs/gst/tmpl/gstplugin.sgml:
* gst/base/gstbasesink.c: (gst_basesink_activate):
* gst/base/gstbasesrc.c: (gst_basesrc_class_init),
(gst_basesrc_init), (gst_basesrc_set_dataflow_funcs),
(gst_basesrc_query), (gst_basesrc_set_property),
(gst_basesrc_get_property), (gst_basesrc_check_get_range),
(gst_basesrc_activate):
* gst/base/gstbasesrc.h:
* gst/base/gstbasetransform.c: (gst_base_transform_sink_activate),
(gst_base_transform_src_activate):
* gst/elements/gstelements.c:
* gst/elements/gstfakesrc.c: (gst_fakesrc_class_init),
(gst_fakesrc_set_property), (gst_fakesrc_get_property):
* gst/elements/gsttee.c: (gst_tee_sink_activate):
* gst/elements/gsttypefindelement.c: (find_element_get_length),
(gst_type_find_element_checkgetrange),
(gst_type_find_element_activate):
* gst/gstbin.c: (gst_bin_save_thyself), (gst_bin_restore_thyself):
* gst/gstcaps.c: (gst_caps_do_simplify), (gst_caps_save_thyself),
(gst_caps_load_thyself):
* gst/gstelement.c: (gst_element_pads_activate),
(gst_element_save_thyself), (gst_element_restore_thyself):
* gst/gstpad.c: (gst_pad_load_and_link), (gst_pad_save_thyself),
(gst_ghost_pad_save_thyself), (gst_pad_check_pull_range):
* gst/gstpad.h:
* gst/gstxml.c: (gst_xml_write), (gst_xml_parse_doc),
(gst_xml_parse_file), (gst_xml_parse_memory),
(gst_xml_get_element), (gst_xml_make_element):
* gst/indexers/gstfileindex.c: (gst_file_index_load),
(_file_index_id_save_xml), (gst_file_index_commit):
* gst/registries/gstlibxmlregistry.c: (read_string), (read_uint),
(read_enum), (load_pad_template), (load_feature), (load_plugin),
(load_paths):
* libs/gst/dataprotocol/dataprotocol.c: (gst_dp_packet_from_caps),
(gst_dp_packet_from_event), (gst_dp_caps_from_packet):
* tools/gst-complete.c: (main):
* tools/gst-compprep.c: (main):
* tools/gst-inspect.c: (print_element_properties_info):
* tools/gst-launch.c: (xmllaunch_parse_cmdline):
* tools/gst-xmlinspect.c: (print_element_properties):
GCC 4 fixen.
2005-05-04 21:29:44 +00:00
Thomas Vander Stichele 5aed75335c gst/gstplugin.c: apply patch from #172526 to make register work on MacOSX
Original commit message from CVS:

* gst/gstplugin.c: (gst_plugin_check_module),
(gst_plugin_check_file), (gst_plugin_load_file):
apply patch from #172526 to make register work on MacOSX
2005-05-03 12:46:47 +00:00
Thomas Vander Stichele 8f87745592 merges from 0.8 for 64 bit issues
Original commit message from CVS:
merges from 0.8 for 64 bit issues
2005-05-02 15:20:30 +00:00
Wim Taymans 0757f3df2e Added draft for new query API.
Original commit message from CVS:
* docs/design/draft-push-pull.txt:
* docs/design/draft-query.txt:
* gst/base/gstbasesrc.c: (gst_basesrc_get_range_unlocked),
(gst_basesrc_start):
Added draft for new query API.
Added draft for better selecting scheduling methods.
Make basesrc ignore length if the subclass does not support
it.
2005-05-02 13:55:21 +00:00
Thomas Vander Stichele 82bb4f0093 automake 1.5 fixes
Original commit message from CVS:
automake 1.5 fixes
2005-05-02 11:54:32 +00:00
Thomas Vander Stichele d3f4ae10f2 possible fixes for automake-1.5
Original commit message from CVS:
possible fixes for automake-1.5
2005-05-02 11:47:17 +00:00
Wim Taymans 71359c38a0 gst/: Better debugging of clocking info.
Original commit message from CVS:
* gst/base/gstbasesink.c: (gst_basesink_base_init),
(gst_basesink_pad_getcaps), (gst_basesink_init),
(gst_basesink_do_sync):
* gst/gstclock.c: (gst_clock_entry_new):
* gst/gstevent.c: (gst_event_discont_get_value):
* gst/gstpipeline.c: (pipeline_bus_handler),
(gst_pipeline_change_state):
* gst/gstsystemclock.c: (gst_system_clock_id_wait_unlocked):
Better debugging of clocking info.
Allow NULL values when getting discont values.
2005-04-28 16:28:28 +00:00
Wim Taymans d68914ad64 gst/gsttrashstack.h: Ooohh. a nasty one! After having a failed pop() from the stack, it's possible that the stack is ...
Original commit message from CVS:
* gst/gsttrashstack.h:
Ooohh. a nasty one! After having a failed pop() from the stack,
it's possible that the stack is empty. In that case, don't
follow the NULL pointer.
2005-04-26 18:07:45 +00:00
Wim Taymans 50b44cdd16 gst/: Remove gst_library_load as it does more harm than good with the new g_module flags.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_set_active), (gst_pad_peer_set_active),
(gst_pad_set_checkgetrange_function),
(gst_pad_link_check_compatible_unlocked), (gst_pad_link_prepare),
(gst_pad_check_pull_range), (gst_pad_pull_range),
(gst_static_pad_template_get_caps), (gst_pad_start_task),
(gst_pad_pause_task), (gst_pad_stop_task):
* gst/gstplugin.c: (gst_plugin_load):
* gst/gstplugin.h:
Remove gst_library_load as it does more harm than good with
the new g_module flags.
Revert bogus caps template check in pad linking, pad caps
are important when linking not the template, which is more
general than the current caps.
2005-04-25 13:00:47 +00:00
Ronald S. Bultje 778981a34e gst/autoplug/: Die, spider, die.
Original commit message from CVS:
* gst/autoplug/.cvsignore:
* gst/autoplug/Makefile.am:
* gst/autoplug/gstsearchfuncs.c:
* gst/autoplug/gstsearchfuncs.h:
* gst/autoplug/gstspider.c:
* gst/autoplug/gstspider.h:
* gst/autoplug/gstspideridentity.c:
* gst/autoplug/gstspideridentity.h:
* gst/autoplug/spidertest.c:
Die, spider, die.
2005-04-25 09:51:06 +00:00
Wim Taymans f494f49acd gst/gstpad.*: Added stubs for unimplemented functions.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_set_active), (gst_pad_peer_set_active),
(gst_pad_set_checkgetrange_function), (gst_pad_check_pull_range),
(gst_pad_pull_range), (gst_static_pad_template_get_caps),
(gst_pad_start_task), (gst_pad_pause_task), (gst_pad_stop_task):
* gst/gstpad.h:
Added stubs for unimplemented functions.
2005-04-25 09:45:35 +00:00
David Schleef 4956e9d512 gst/gstpad.h: Disable some unimplemented functions. Wim, please fix.
Original commit message from CVS:
* gst/gstpad.h: Disable some unimplemented functions.  Wim,
please fix.
2005-04-24 23:53:06 +00:00
David Schleef 46e13eb5e2 Convert everything from GstAtomicInt to g_atomic_int_*, and remove gstatomic.
Original commit message from CVS:
Convert everything from GstAtomicInt to g_atomic_int_*, and
remove gstatomic.
* gst/Makefile.am:
* gst/gstatomic.c:
* gst/gstatomic.h:
* gst/gstatomic_impl.h:
* gst/gstbuffer.c:
* gst/gstcaps.c:
* gst/gstcaps.h:
* gst/gstclock.c:
* gst/gstclock.h:
* gst/gstdata.c:
* gst/gstdata.h:
* gst/gstdata_private.h:
* gst/gstevent.c:
* gst/gstinfo.c:
* gst/gstinfo.h:
* gst/gstmessage.c:
* gst/gstobject.c:
* gst/gstobject.h:
* gst/gststructure.c:
* gst/gststructure.h:
* gst/gstutils.c: Add gst_atomic_int_set() compaitibility function.
* gst/gstutils.h:
2005-04-24 22:49:45 +00:00
David Schleef 01c25dc75f check/gst/gstpad.c: Oh yeah, it's always nice to make the regressions tests work. Remove some code that is no longer...
Original commit message from CVS:
* check/gst/gstpad.c: (START_TEST): Oh yeah, it's always nice to
make the regressions tests work.  Remove some code that is no
longer true.
* gst/gstpad.c: (gst_pad_link_check_templates_compatible_unlocked):
Disable warning for pads without templates.
2005-04-24 22:44:13 +00:00
David Schleef 65dd8e9726 gst/gstpad.c: Remove handling of filtered caps. Fix/merge functions that handle filtered links.
Original commit message from CVS:
* gst/gstpad.c: Remove handling of filtered caps.  Fix/merge
functions that handle filtered links.
* gst/gstpad.h: Remove 'appfilter' field and prototypes of
removed functions.
* gst/gstutils.c: Fix/remove utility functions that handle
filtered caps.
* gst/gstutils.h:
* gst/gstvalue.c: Add serialization/deserialization of caps
* gst/parse/grammar.y: Ignore filtered caps when linking.  This
requires fixing so that the filter caps notation creates
a capsfilter element and sets the filter_caps property.  I
think everyone probably wants to keep the shorthand notation.
* docs/gst/tmpl/gstelement.sgml: updates for API changes.
* docs/gst/tmpl/gstpad.sgml:
* gst/elements/gstelements.c: Register capsfilter element.
* gst/Makefile.am: fix spacing
* docs/random/ds/0.9-suggested-changes: random
2005-04-24 21:16:45 +00:00