Commit graph

96 commits

Author SHA1 Message Date
Benjamin Otte
266cff34c7 gst/gstpad.c: implement enforcing discont events before buffers are passed. This allows state changes of only some el...
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_set_active), (gst_pad_link_new),
(gst_pad_link_free), (gst_pad_link_try), (_invent_event),
(gst_pad_pull):
implement enforcing discont events before buffers are passed. This
allows state changes of only some elements and later correctly going
on where they left off (or in short: you can now set audio sinks to
NULL to release the device when the pipeline is paused)
* gst/gstpad.c: (gst_pad_call_chain_function),
(gst_pad_call_get_function):
* gst/gstpad.h:
add gst_pad_call_chain_function and gst_pad_call_get_function for
scheduler interaction. They are required because of the changes
above.
* gst/schedulers/entryscheduler.c: (get_buffer),
(gst_entry_scheduler_chain_wrapper),
(gst_entry_scheduler_get_wrapper),
(gst_entry_scheduler_state_transition),
(gst_entry_scheduler_pad_link):
* gst/schedulers/gstbasicscheduler.c:
(gst_basic_scheduler_chain_wrapper),
(gst_basic_scheduler_src_wrapper),
(gst_basic_scheduler_chainhandler_proxy),
(gst_basic_scheduler_gethandler_proxy),
(gst_basic_scheduler_cothreaded_chain),
(gst_basic_scheduler_chain_elements):
* gst/schedulers/gstoptimalscheduler.c:
(get_group_schedule_function), (pad_clear_queued),
(gst_opt_scheduler_pad_link):
use the new functions instead of calling get/chain-functions
directly.
2004-04-16 01:36:37 +00:00
Benjamin Otte
9d756dd8e1 gst/schedulers/gstbasicscheduler.c: rename categories to basic_*
Original commit message from CVS:
* gst/schedulers/gstbasicscheduler.c: (plugin_init):
rename categories to basic_*
* gst/schedulers/gstbasicscheduler.c:
(gst_basic_scheduler_chain_wrapper),
(gst_basic_scheduler_chainhandler_proxy),
(gst_basic_scheduler_gethandler_proxy),
(gst_basic_scheduler_eventhandler_proxy):
debugging category fixes - put common stuff in log category
* gst/schedulers/gstbasicscheduler.c:
(gst_basic_scheduler_chain_elements):
dirty fix: call gst_basic_scheduler_cothreaded_chain when already
active and linking two active chains
2004-04-11 18:55:49 +00:00
Benjamin Otte
5ec3dcdd5d gst/schedulers/gstbasicscheduler.c: make sure we can switch back to the main function if we're still in the main func...
Original commit message from CVS:
* gst/schedulers/gstbasicscheduler.c:
make sure we can switch back to the main function if we're still in
the main function (supposed to fix #139617)
* gst/schedulers/gthread-cothreads.h:
don't throw an error when switching to the same cothread
2004-04-09 22:43:06 +00:00
Benjamin Otte
563ce1b133 gst/schedulers/gstbasicscheduler.c: fix to work with recent scheduling changes
Original commit message from CVS:
* gst/schedulers/gstbasicscheduler.c:
(gst_basic_scheduler_pad_link):
fix to work with recent scheduling changes
2004-04-05 02:30:20 +00:00
Benjamin Otte
fd58f301b7 gst/schedulers/gstbasicscheduler.c: fix uninitialized variable warnings
Original commit message from CVS:
* gst/schedulers/gstbasicscheduler.c:
(gst_basic_scheduler_pad_select):
fix uninitialized variable warnings
2004-04-04 03:11:46 +00:00
Benjamin Otte
ac5674b03b gst/: implement gst_pad_collect as replacement for gst_pad_select.
Original commit message from CVS:
* gst/gstpad.c: (gst_pad_collect_array), (gst_pad_collectv),
(gst_pad_collect), (gst_pad_collect_valist), (gst_pad_selectv),
(gst_pad_select):
* gst/gstpad.h:
* gst/gstscheduler.c: (gst_scheduler_pad_select),
(gst_scheduler_lock_element), (gst_scheduler_unlock_element):
* gst/gstscheduler.h:
implement gst_pad_collect as replacement for gst_pad_select.
deprecate gst_pad_select and gst_scheduler_(un)lock_element
add new flag GST_SCHEDULER_FLAG_NEW_API for API that implements the
new pad_select, lock and unlock calls.
* gst/cothreads.c: (cothread_destroy), (cothread_switch):
* gst/cothreads.h:
* gst/schedulers/cothreads_compat.h:
* gst/schedulers/gthread-cothreads.h:
remove unused cothread_lock and cothread_unlock calls
* gst/schedulers/entryscheduler.c:
(gst_entry_scheduler_class_init), (gst_entry_scheduler_init),
(_can_schedule_loop), (gst_entry_scheduler_get_handler),
(gst_entry_scheduler_pad_select):
update to new API
* gst/schedulers/gstbasicscheduler.c:
(gst_basic_scheduler_class_init), (gst_basic_scheduler_init),
(gst_basic_scheduler_pad_select):
remove useless lock and unlock calls, update pad_select to new API
(untested)
* gst/schedulers/gstoptimalscheduler.c:
(gst_opt_scheduler_class_init):
remove useless select, lock and unlock function calls
* gst/elements/gstaggregator.c: (gst_aggregator_loop):
use gst_pad_collect instead of gst_pad_select
2004-04-04 02:36:12 +00:00
Benjamin Otte
7f6e97ebe9 gst/schedulers/: fix GStreamer to not have issues with lvalue casts anymore (fixes some bug, but bugzilla is down)
Original commit message from CVS:
* gst/schedulers/gstbasicscheduler.c:
(gst_basic_scheduler_src_wrapper):
* gst/schedulers/gstoptimalscheduler.c:
(gst_opt_scheduler_loop_wrapper), (gst_opt_scheduler_get_wrapper),
(pad_clear_queued), (gst_opt_scheduler_add_element),
(gst_opt_scheduler_remove_element):
fix GStreamer to not have issues with lvalue casts anymore (fixes
some bug, but bugzilla is down)
2004-03-24 14:06:48 +00:00
Benjamin Otte
0c01133df9 gst/gstelement.c: add documentation about a gobject quirk where the object hasn't the correct class pointer set on in...
Original commit message from CVS:
* gst/gstelement.c:
add documentation about a gobject quirk where the object hasn't the
correct class pointer set on initialization
* gst/schedulers/gstbasicscheduler.c:
(gst_basic_scheduler_src_wrapper):
make sure to not run into an infinite loop
2004-03-24 13:38:17 +00:00
Thomas Vander Stichele
7baa6c18e7 don't mix tabs and spaces
Original commit message from CVS:
don't mix tabs and spaces
2004-03-15 19:27:17 +00:00
Thomas Vander Stichele
a967370df5 gst-indent run on core
Original commit message from CVS:
gst-indent run on core
2004-03-13 15:27:01 +00:00
Thomas Vander Stichele
5f91e9ad66 suffix errors with period.
Original commit message from CVS:
suffix errors with period.
use (NULL) over NULL
2004-01-31 19:30:31 +00:00
Thomas Vander Stichele
c5b612edef GST_ELEMENT_ERROR
Original commit message from CVS:
GST_ELEMENT_ERROR
2004-01-29 23:17:58 +00:00
Thomas Vander Stichele
4efc300279 changing error signal add error codes and domains
Original commit message from CVS:
changing error signal
add error codes and domains
2004-01-18 21:36:20 +00:00
Benjamin Otte
1e82f617e4 gst/gstclock.*: deprecate old interface and disable functions that aren't in use anymore.
Original commit message from CVS:
2004-01-13  Benjamin Otte  <in7y118@public.uni-hamburg.de>

* gst/gstclock.c: (gst_clock_class_init), (gst_clock_init),
(gst_clock_set_speed), (gst_clock_set_active),
(gst_clock_is_active), (gst_clock_reset),
(gst_clock_handle_discont):
* gst/gstclock.h:
deprecate old interface and disable functions that aren't in use
anymore.
* gst/gstelement.h:
* gst/gstelement.c: (gst_element_get_time), (gst_element_wait),
(gst_element_set_time), (gst_element_adjust_time):
add concept of "element time" and functions to get/set this time.
* gst/gstelement.c: (gst_element_change_state):
update element time correctly.
* gst/gstelement.c: (gst_element_get_compatible_pad_filtered):
This is a debug message, not a g_critical.
* gst/gstpad.c: (gst_pad_event_default):
handle discontinuous events right with element time.
* gst/gstscheduler.c: (gst_scheduler_state_transition):
update to clocking fixes.
set clocks on elements in READY=>PAUSED. The old behaviour caused
a wrong element time on the first element that started playing.
* gst/schedulers/gstbasicscheduler.c:
(gst_basic_scheduler_class_init):
* gst/schedulers/gstoptimalscheduler.c:
(gst_opt_scheduler_class_init):
remove code that just implements the default behaviour.
* gst/elements/gstfakesink.c: (gst_fakesink_chain):
update to use new clocking functions
* testsuite/clock/clock1.c: (gst_clock_debug), (main):
* testsuite/clock/clock2.c: (gst_clock_debug), (main):
update to test new element time.
* gst/autoplug/gstspideridentity.c: (gst_spider_identity_getcaps):
use _get_allowed_caps instead of _get_caps. This catches filtered
caps correctly.
* testsuite/debug/commandline.c:
update for new GST_DEBUG syntax.
* testsuite/threads/Makefile.am:
disable a test that only works sometimes.
2004-01-14 00:46:48 +00:00
Benjamin Otte
46a70fddfb removed GST_*_CAST. Disabling of type checking is done in glib.
Original commit message from CVS:
removed GST_*_CAST. Disabling of type checking is done in glib.
2003-12-13 16:58:29 +00:00
Andy Wingo
8ca1b1fe7f remove copyright field from plugin structs
Original commit message from CVS:
remove copyright field from plugin structs
2003-12-04 10:02:41 +00:00
Benjamin Otte
cb853c1bcf change the chainwrapper to allow removing pads during iterations
Original commit message from CVS:
change the chainwrapper to allow removing pads during iterations
2003-11-22 19:11:58 +00:00
Benjamin Otte
907e3e97d9 update plugin initialization restructuring (see email for details
Original commit message from CVS:
update plugin initialization restructuring (see email for details
2003-10-31 19:32:47 +00:00
Andy Wingo
31d748d332 s/GstBuffer/GstData/ in the API where you can pass events. Fix the plugins to deal with that. Fixes #113488. Also inc...
Original commit message from CVS:
s/GstBuffer/GstData/ in the API where you can pass events. Fix the plugins to deal with that. Fixes #113488. Also includes scheduler patches, and probably fixes some queue bugs relating to events and buffers.
2003-10-08 16:06:02 +00:00
Thomas Vander Stichele
c4c3c998df reverting error patches before making a branch.
Original commit message from CVS:
reverting error patches before making a branch.
2003-09-16 09:57:31 +00:00
Benjamin Otte
be1eaa4de3 implement translatable error messages using gerror.
Original commit message from CVS:
implement translatable error messages using gerror.

Includes bugfixes for:
- crash when unlinking Ghostpads
- make *_PAD_* macros use glib casts
- make spider typefinding merge buffers correctly
2003-09-14 19:49:32 +00:00
Benjamin Otte
803ce6bf48 GST_DEBUG reorganization containing loads of stuff:
Original commit message from CVS:
GST_DEBUG reorganization
This is a big diff (ca 450k), containing loads of stuff:
- gstinfo.[ch] complete rewrite
- changing of all GST_DEBUG messages to reflect that change
- reorganization of subsystem disabling
- addition of gstconfig.h.in so we can track the disablings
- <gst/gst.h> does not include <unistd.h> and <config.h> anymore
- documentation updated for gstinfo stuff (build the docs yourself to know what changed)
- bugfixes for making of the docs (files from CVS are not deleted anymore
- testsuite for debugging changes in testsuite/debug

expect breakage
2003-06-29 14:05:49 +00:00
David Schleef
214c557a6d Change GST_DEBUG_FUNCPTR() to return a pointer of the same type that it is called with. Fix lots of warnings due to ...
Original commit message from CVS:
Change GST_DEBUG_FUNCPTR() to return a pointer of the same type that it
is called with.  Fix lots of warnings due to change.
2003-05-18 23:34:12 +00:00
Erik Walthinsen
0da768dacb Fix various inconsistencies discovered while attempting to fix --disable-*.
Original commit message from CVS:
Fix various inconsistencies discovered while attempting to fix --disable-*.
Uraeus: this should fix the bison.simple problem that you've had.
2003-02-10 07:53:58 +00:00
Ronald S. Bultje
637326bc8d older gccs crack here
Original commit message from CVS:
older gccs crack here
2003-02-05 17:09:50 +00:00
Wim Taymans
d7e33dd2ce - Use the eventhandler instead of the event function to send events.
Original commit message from CVS:
- Use the eventhandler instead of the event function to send events.
- make the scheduler setup the eventhandlers
- intercept flush events on pads links that can potentially queue data
and flush it.
- some more debugging info in spider.

I can think of one case where this flush might fail: unconnected pads where
the scheduler has not set up the eventhandler yet. I'll come up with a
solution for that soon.
2003-02-03 22:50:55 +00:00
Erik Walthinsen
bab7be2c91 revert the revert, switch out the new code for the 'working' code with an #if
Original commit message from CVS:
revert the revert, switch out the new code for the 'working' code with an #if
2003-01-21 20:48:23 +00:00
Wim Taymans
69be241342 Revert 1.66 and 1.67 that seemed to break the unlink scheduler function 1.68 is still added
Original commit message from CVS:
Revert 1.66 and 1.67 that seemed to break the unlink scheduler function
1.68 is still added
2003-01-21 18:39:11 +00:00
Wim Taymans
826f848618 - We need to pull UNUSABLE pads too because it might be an event
Original commit message from CVS:
- We need to pull UNUSABLE pads too because it might be an event
2003-01-20 23:10:32 +00:00
Erik Walthinsen
de6bcd890a - added 'remove' argument to _chain_recursive_add to remove elements from old chain before adding to new one
Original commit message from CVS:
- added 'remove' argument to _chain_recursive_add to remove elements from
old chain before adding to new one
- reworked _pad_unlink to be simpler and more correct
2003-01-20 22:22:46 +00:00
Erik Walthinsen
cbbb8371fe moved recursive exit to the front of the call, to make it easier to add prevchain removal
Original commit message from CVS:
moved recursive exit to the front of the call, to make it easier to add prevchain removal
2003-01-20 22:02:46 +00:00
Erik Walthinsen
590604e430 - some minor whitespace cleanups
Original commit message from CVS:
- some minor whitespace cleanups
- rework _chain_add_element to put the element in either the main or
disabled lists depending on whether the element is PLAYING or not.
2003-01-20 21:23:19 +00:00
Wim Taymans
89bf2733e9 - return boolean in _interrupt to better inform element
Original commit message from CVS:
- return boolean in _interrupt to better inform element
- fix default bufferpool unref
2003-01-11 16:27:45 +00:00
Iain Holmes
7ec295a0cd Don't remove an element from its chain if it doesn't have a chain
Original commit message from CVS:
Don't remove an element from its chain if it doesn't have a chain
2003-01-11 13:44:33 +00:00
Thomas Vander Stichele
5529bbc7dc first pass of connect->link gst-plugins and other stuff compiles without change at this point
Original commit message from CVS:
first pass of connect->link
gst-plugins and other stuff compiles without change at this point
2003-01-09 14:15:37 +00:00
Wim Taymans
a03425c8b3 - disable pads when going to PAUSED, we want to make sure no data is passing when an element is not PLAYING.
Original commit message from CVS:
- disable pads when going to PAUSED, we want to make sure no data is
passing when an element is not PLAYING.
- changed the clock sync API, element should now get a ClockID first and
sync on that. This makes it possible to cancel clock requests.
2002-12-27 22:57:13 +00:00
Wim Taymans
68b53ac4ab - Cleanups
Original commit message from CVS:
- Cleanups
- Added padding to structs
- fixed typechecking/casts
- reduced casts
- implemented remove_element in gstbin
- implemented set index on bin
2002-12-19 21:31:03 +00:00
Wim Taymans
f07281a771 Destroying the cothread seems like a good idea here
Original commit message from CVS:
Destroying the cothread seems like a good idea here
2002-12-09 20:33:27 +00:00
David Schleef
2fed56b4a8 Removing unused code related to stack allocation (cothreads_stackquery(), gst_scheduler_get_preferred_stack())
Original commit message from CVS:
Removing unused code related to stack allocation (cothreads_stackquery(),
gst_scheduler_get_preferred_stack())
2002-12-06 23:05:26 +00:00
Wim Taymans
91b824a34c - Reworked the clock to prepare for async notifications
Original commit message from CVS:
- Reworked the clock to prepare for async notifications
- moved some common scheduler checking to gstbin
- added some vmethods to gstbin for future use
- more fixes to the optimal scheduler
- use new clock api in the schedulers
2002-11-02 13:54:34 +00:00
Thomas Vander Stichele
929f37fab1 I ran into this and had to hunt for it
Original commit message from CVS:
I ran into this and had to hunt for it
2002-09-30 10:58:40 +00:00
Wim Taymans
e6e1dc2e0e - some cleanups
Original commit message from CVS:
- some cleanups
- revert a patch that needs more thinking..
- move common code and sanity checks in gstscheduler.c instead of the
real schedulers.
- remove sanity checks from the schedulers
2002-09-13 23:02:54 +00:00
Wim Taymans
37a127d9ed - Make the return GList of gst_element_get_pad_list as const
Original commit message from CVS:
- Make the return GList of gst_element_get_pad_list as const
- Pad scheduler refactoring
- Remove gst_pad_set/unset_scheduler as it's not needed
- Reimplement gst_pad_get_scheduler using the parent scheduler
- Remove gst_pad_peek as it cannot work reliably
- Remove the pad bufpen, replace with scheduler private gpointer
- Make queue use the new _get_scheduler implementation
- Remove _pad_unset_scheduler from GstScheduler
- Remove LOOP_SEEK mode from aggregator
- Other fixes for API changes.
2002-09-12 20:52:03 +00:00
Thomas Vander Stichele
17d01b5d21 scheduler renaming
Original commit message from CVS:
scheduler renaming
- wingo or omega for cothreads package
- basic or fast or optimal for algorithms
2002-09-12 19:23:41 +00:00
Thomas Vander Stichele
dd9d93d295 code cleanup
Original commit message from CVS:
code cleanup
2002-09-12 18:54:16 +00:00
Thomas Vander Stichele
de527dd234 nicer looking
Original commit message from CVS:
nicer looking
2002-08-28 10:11:26 +00:00
Wim Taymans
a33c875057 Don't try to pull on disabled pads in the scheduler
Original commit message from CVS:
Don't try to pull on disabled pads in the scheduler
2002-07-24 21:09:46 +00:00
Wim Taymans
83f2253007 Set the scheduler to NULL in all cases.
Original commit message from CVS:
Set the scheduler to NULL in all cases.
2002-07-02 18:42:00 +00:00
Andy Wingo
2eb7f04289 free stack properly s/prefered/preferred/
Original commit message from CVS:
* free stack properly
* s/prefered/preferred/
2002-06-27 23:55:27 +00:00
Wim Taymans
bcb921d550 This makes more sense and solves the locking problem when a loop based element is selected as the entry point.
Original commit message from CVS:
This makes more sense and solves the locking problem when a loop based
element is selected as the entry point.
2002-06-23 12:50:12 +00:00