cothreads userspace threads Cothreads are a simple user-space method for switching between subtasks. They're based on setjmp()/longjmp() in their current form. Cothreads are used for loop-based elements that pull data instead of being fed with data. Cothreads are usually used by a #GstScheduler. #GstScheduler The cothread state structure @ctx: @cothreadnum: @priv: @func: @argc: @argv: @flags: @sp: @jmp: @stack_base: @stack_size: @magic_number: the function that will be called when the cothread starts. The function prototype is like a main() function, so you can do whatever you want with it. @argc: a main-like argument count @argv: a main-like array of arguments @Returns: a return code The cothread context structure @cothreads: @main: @current: @mutex: Indicates the cothread is started. Indicates the cothread is destroyed. @Returns: @ctx: @cothread: @Returns: @cothread: @data: @ctx: @Returns: @cothread: @cothread: @func: @argc: @argv: @cothread: @cothread: @cothread: @key: @Returns: @cothread: @key: @data: @cothread: @cothread: @Returns: @cothread: @ctx: @Returns: @Returns: @Returns: