Sebastian Dröge [Tue, 12 Feb 2013 10:49:21 +0000 (11:49 +0100)]
omx: Some minor refactoring and cleanup
Sebastian Dröge [Tue, 12 Feb 2013 10:45:40 +0000 (11:45 +0100)]
omx: Don't access the port's buffers array if it wasn't allocated yet
Sebastian Dröge [Tue, 12 Feb 2013 10:44:40 +0000 (11:44 +0100)]
omx: Mark an array as const
Sebastian Dröge [Tue, 12 Feb 2013 10:41:43 +0000 (11:41 +0100)]
omx: Split enabling/disabling of port into sending the command and waiting for it
This allows to do anything necessary after sending the command to actually let it finish
Sebastian Dröge [Tue, 12 Feb 2013 10:37:38 +0000 (11:37 +0100)]
omx: Flushing is also allowed in Paused state
Sebastian Dröge [Tue, 12 Feb 2013 10:28:36 +0000 (11:28 +0100)]
omxvideoenc: Set stride, slice height and buffer size
Sebastian Dröge [Tue, 12 Feb 2013 10:09:30 +0000 (11:09 +0100)]
config: Add h264 and mpeg2 encoders to the raspberry pi config
Not completely working yet though.
Sebastian Dröge [Tue, 12 Feb 2013 10:03:32 +0000 (11:03 +0100)]
omxvideoenc: Properly negotiate OMX color format with the component
Sebastian Dröge [Tue, 12 Feb 2013 09:53:24 +0000 (10:53 +0100)]
omxvideoenc: Implement getcaps() vfunc
Tim-Philipp Müller [Tue, 29 Jan 2013 21:32:53 +0000 (21:32 +0000)]
configure: use 1.0 gstconfig.h to detect disabled subsystems
Update unused configure check for GStreamer core subsystem
features from 0.10 to 1.0.
Stefan Sauer [Mon, 28 Jan 2013 19:44:41 +0000 (20:44 +0100)]
Automatic update of common submodule
From a942293 to 2de221c
Julian Scheel [Thu, 24 Jan 2013 13:02:36 +0000 (14:02 +0100)]
omx: add mpeg2 video decoder
This adds a decoder class for mpeg2, as well as an extended
configuration for raspberry pi.
https://bugzilla.gnome.org/show_bug.cgi?id=692446
Signed-off-by: Julian Scheel <julian@jusst.de>
Sebastian Dröge [Fri, 18 Jan 2013 15:47:04 +0000 (16:47 +0100)]
omx: Minimize the time when the messages lock is held
Fixes a deadlock if any OMX functions are called when the
messages are handled.
Thanks to Nicolas Dufresne for noticing.
Tim-Philipp Müller [Fri, 18 Jan 2013 15:28:20 +0000 (15:28 +0000)]
omx: improve debug message when we can't find the config file
Mention where we looked for the config file.
Tim-Philipp Müller [Fri, 18 Jan 2013 12:34:38 +0000 (12:34 +0000)]
build: fix autogen.sh with automake 1.13
AM_CONFIG_HEADER -> AC_CONFIG_HEADERS
Sebastian Dröge [Thu, 17 Jan 2013 17:07:41 +0000 (18:07 +0100)]
omx: Fix includes to properly work with the 1.0 releases
Tim-Philipp Müller [Tue, 15 Jan 2013 15:08:28 +0000 (15:08 +0000)]
Automatic update of common submodule
From a72faea to a942293
Sebastian Dröge [Tue, 15 Jan 2013 13:34:45 +0000 (14:34 +0100)]
omx: Update port definition when changing some port setting
Sebastian Dröge [Mon, 14 Jan 2013 10:41:57 +0000 (11:41 +0100)]
omx: Rename from libgstopenmax.so to ligstomx.so for consistency
Nicolas Dufresne [Fri, 11 Jan 2013 15:32:22 +0000 (15:32 +0000)]
omx: Add a method to send message
Sebastian Dröge [Fri, 11 Jan 2013 14:44:38 +0000 (15:44 +0100)]
omx: Atomic ops are not required anymore for the reconfiguration
Sebastian Dröge [Fri, 11 Jan 2013 11:52:10 +0000 (12:52 +0100)]
omx: Fix some memory leaks and suboptimal locking
Sebastian Dröge [Fri, 11 Jan 2013 11:34:04 +0000 (12:34 +0100)]
omxvideoenc: Don't forget to unmap frame in error cases
Sebastian Dröge [Fri, 11 Jan 2013 11:29:20 +0000 (12:29 +0100)]
omxvideoenc: Fix copying of the video frames to the OMX buffers
Sebastian Dröge [Fri, 11 Jan 2013 11:24:13 +0000 (12:24 +0100)]
omxvideodec: Fix copying of the video frames from the OMX buffers
Sebastian Dröge [Thu, 10 Jan 2013 13:44:33 +0000 (14:44 +0100)]
omx: Implement new approach for locking that should solve all deadlocks on RPi
No mutex is locked while calling any OpenMAX functions anymore
and everything from the OpenMAX callbacks is inserted into a message
queue and handled from outside the callbacks.
Also there's only a single mutex and condition variable per component
now for handling anything from OpenMAX callbacks and a single mutex
for keeping our component/port state sane.
Sebastian Dröge [Thu, 20 Dec 2012 18:30:38 +0000 (19:30 +0100)]
omxvideodec: Set the OMX buffer nFilledLength field properly
Sebastian Dröge [Thu, 20 Dec 2012 17:48:21 +0000 (18:48 +0100)]
omxrecmutex: Fix another race condition when two threads are trying to lock for recursion at the same time
Sebastian Dröge [Thu, 20 Dec 2012 17:16:43 +0000 (18:16 +0100)]
omxrecmutex: Fix yet another race condition that resulted in deadlocks
Sebastian Dröge [Thu, 20 Dec 2012 16:46:36 +0000 (17:46 +0100)]
omx: Fix another race condition in the recursive mutex
Between lock() and begin_recursion() it was possible for another thread to
try to do a recursive_lock(). This would block because the mutex was already
locked(), but not ready for recursive locking yet. unlock() would never
happen in the original thread because it was waiting for the other thread
to finish first.
Happened on the Raspberry Pi.
Sebastian Dröge [Thu, 20 Dec 2012 13:45:18 +0000 (14:45 +0100)]
omxrecmutex: Fix a small race condition when unlocking a non-recursive lock
Sebastian Dröge [Thu, 20 Dec 2012 11:30:05 +0000 (12:30 +0100)]
omx: Fix ununsed variable compiler warning
Sebastian Dröge [Thu, 20 Dec 2012 11:27:47 +0000 (12:27 +0100)]
omx: No need to start the srcpad task in ::start() already
It will be started properly after the caps are set.
Sebastian Dröge [Thu, 20 Dec 2012 11:23:49 +0000 (12:23 +0100)]
omxvideodec: OMX_ErrorNoMore is no error and just means we ended iteration
Sebastian Dröge [Thu, 20 Dec 2012 11:20:31 +0000 (12:20 +0100)]
omx: Improve debug output
Sebastian Dröge [Thu, 20 Dec 2012 11:02:30 +0000 (12:02 +0100)]
omxvideodec: Don't forget to free a GList
Sebastian Dröge [Thu, 20 Dec 2012 10:56:29 +0000 (11:56 +0100)]
omxvideodec: Map OMX_COLOR_FormatYUV420PackedPlanar to I420 too
This is used on the Raspberry Pi.
Sebastian Dröge [Thu, 20 Dec 2012 10:55:36 +0000 (11:55 +0100)]
omxvideodec: During negotiation of the output format make sure we use the correct OpenMAX format
Sebastian Dröge [Thu, 20 Dec 2012 10:42:17 +0000 (11:42 +0100)]
omxvideodec: If negotiation fails this could also mean that the component can't do it at this point yet
Sebastian Dröge [Thu, 20 Dec 2012 10:40:13 +0000 (11:40 +0100)]
omxvideodec: Improve format negotiation a bit
Don't leak caps and make sure to fixate caps.
Sebastian Dröge [Wed, 19 Dec 2012 12:05:28 +0000 (13:05 +0100)]
omx: Also initialize nStep field of the OMX structures
Sebastian Dröge [Wed, 19 Dec 2012 12:03:37 +0000 (13:03 +0100)]
omx: Initialize struct version with the OMX version we compiled with
Sebastian Dröge [Wed, 19 Dec 2012 11:44:31 +0000 (12:44 +0100)]
omxvideodec: Extract data from the input buffer, not the codec data
Sebastian Dröge [Wed, 19 Dec 2012 11:19:12 +0000 (12:19 +0100)]
omx: Use has_suffix() instead of has_prefix() for the Broadcom hack
Sebastian Dröge [Wed, 19 Dec 2012 11:08:35 +0000 (12:08 +0100)]
tools: Add tool to list all components and their roles
Sebastian Dröge [Wed, 19 Dec 2012 10:31:51 +0000 (11:31 +0100)]
omx: Add hack to load and initialize libbcm_host.so
Needed on the Raspberry Pi. Patch based on a patch by
George Kiagiadakis <george.kiagiadakis@collabora.com>
Sebastian Dröge [Wed, 19 Dec 2012 10:22:16 +0000 (11:22 +0100)]
configure: Add configure option to pack OpenMAX structures
This is required to set to 4 for the Raspberry Pi for example.
Sebastian Dröge [Wed, 19 Dec 2012 10:07:44 +0000 (11:07 +0100)]
configure: Require GStreamer 1.0.0
George Kiagiadakis [Fri, 20 Apr 2012 14:13:52 +0000 (17:13 +0300)]
omx: Initialize structures to version 1.1.2
Sebastian Dröge [Wed, 19 Dec 2012 09:51:22 +0000 (09:51 +0000)]
config: Add raspberry-pi configuration in a different directory
George Kiagiadakis [Sun, 20 May 2012 17:11:59 +0000 (20:11 +0300)]
raspberry: Add a gstomx.conf for the Raspberry Pi
Sebastian Dröge [Wed, 12 Dec 2012 17:45:39 +0000 (17:45 +0000)]
omx: Fix some compilation errors caused by circular includes
Tim-Philipp Müller [Mon, 19 Nov 2012 11:29:44 +0000 (11:29 +0000)]
Automatic update of common submodule
From 6bb6951 to a72faea
Sebastian Dröge [Mon, 12 Nov 2012 14:14:09 +0000 (15:14 +0100)]
omx: Fix refcount problem with frames being dropped because of decoder bugs
Sebastian Dröge [Mon, 12 Nov 2012 10:29:48 +0000 (11:29 +0100)]
omx: Update to new GLib thread API
Sebastian Dröge [Mon, 22 Oct 2012 12:34:53 +0000 (14:34 +0200)]
omx: Use open/close vfuncs
Sebastian Dröge [Mon, 22 Oct 2012 12:28:04 +0000 (14:28 +0200)]
omx: Handle video meta correctly
Sebastian Dröge [Wed, 20 Jun 2012 12:11:58 +0000 (13:11 +0100)]
omx: Port to video base classes from -base
Tim-Philipp Müller [Wed, 17 Oct 2012 16:57:43 +0000 (17:57 +0100)]
omx: gst_element_class_set_details_simple() -> set_static_metadata()
Tim-Philipp Müller [Sat, 6 Oct 2012 14:01:11 +0000 (15:01 +0100)]
Automatic update of common submodule
From 6c0b52c to 6bb6951
Tim-Philipp Müller [Sat, 22 Sep 2012 15:10:38 +0000 (16:10 +0100)]
Automatic update of common submodule
From 4f962f7 to 6c0b52c
George Kiagiadakis [Thu, 21 Jun 2012 17:22:13 +0000 (20:22 +0300)]
omx: fix debug statement
George Kiagiadakis [Thu, 21 Jun 2012 17:21:03 +0000 (20:21 +0300)]
omx: use recursive_lock inside set_last_error(), since this function may be called from an event handler
Stefan Sauer [Wed, 22 Aug 2012 11:31:59 +0000 (13:31 +0200)]
Automatic update of common submodule
From 668acee to 4f962f7
Tim-Philipp Müller [Sun, 5 Aug 2012 15:42:43 +0000 (16:42 +0100)]
Automatic update of common submodule
From 94ccf4c to 668acee
Tim-Philipp Müller [Fri, 3 Aug 2012 18:32:13 +0000 (19:32 +0100)]
omx: fix plugin name for new GST_PLUGIN_DEFINE API
Sebastian Dröge [Mon, 23 Jul 2012 06:47:32 +0000 (08:47 +0200)]
Automatic update of common submodule
From 98e386f to 94ccf4c
Sebastian Dröge [Tue, 10 Jul 2012 07:57:09 +0000 (09:57 +0200)]
omx: Update for allocation query API changes
Sebastian Dröge [Wed, 20 Jun 2012 10:09:13 +0000 (11:09 +0100)]
omx: Fix compilation after gst_pad_start_task() API changes
Edward Hervey [Fri, 8 Jun 2012 13:06:35 +0000 (15:06 +0200)]
Automatic update of common submodule
From 03a0e57 to 98e386f
Edward Hervey [Wed, 6 Jun 2012 16:20:18 +0000 (18:20 +0200)]
Automatic update of common submodule
From 1fab359 to 03a0e57
Edward Hervey [Fri, 1 Jun 2012 08:30:27 +0000 (10:30 +0200)]
Automatic update of common submodule
From f1b5a96 to 1fab359
Sebastian Dröge [Thu, 31 May 2012 11:10:33 +0000 (13:10 +0200)]
Automatic update of common submodule
From 92b7266 to f1b5a96
Sebastian Dröge [Wed, 30 May 2012 10:47:59 +0000 (12:47 +0200)]
Automatic update of common submodule
From ec1c4a8 to 92b7266
Sebastian Dröge [Wed, 30 May 2012 09:26:30 +0000 (11:26 +0200)]
Automatic update of common submodule
From 3429ba6 to ec1c4a8
Sebastian Dröge [Sun, 13 May 2012 13:58:10 +0000 (15:58 +0200)]
Automatic update of common submodule
From dc70203 to 3429ba6
George Kiagiadakis [Tue, 8 May 2012 13:13:32 +0000 (16:13 +0300)]
omx: Fix spelling mistake found by lintian: s/Seperate/Separate/
George Kiagiadakis [Mon, 30 Apr 2012 20:58:43 +0000 (23:58 +0300)]
Implement a new custom recursive mutex type and fix locking in callbacks so that in-context calls are allowed.
According to the OMX specification, implementations are allowed to call
callbacks in the context of their function calls. However, our callbacks
take locks and this causes deadlocks if the unerlying OMX implementation
uses this kind of in-context calls.
A solution to the problem would be a recursive mutex. However, a normal
recursive mutex does not fix the problem because it is not guaranteed
that the callbacks are called from the same thread. What we see in Broadcom's
implementation for example is:
- OMX_Foo is called
- OMX_Foo waits on a condition
- A callback is executed in a different thread
- When the callback returns, its calling function
signals the condition that OMX_Foo waits on
- OMX_Foo wakes up and returns
The solution I came up with here is to take a second lock inside the callback,
but only if recursion is expected to happen. Therefore, all calls to OMX
functions are guarded by calls to gst_omx_rec_mutex_begin_recursion() / _end_recursion(),
which effectively tells the mutex that at this point we want to allow calls
to _recursive_lock() to succeed, although we are still holding the master lock.
George Kiagiadakis [Fri, 20 Apr 2012 14:51:34 +0000 (14:51 +0000)]
omx: Add hack to disable setting roles to components.
Conflicts:
omx/gstomx.c
George Kiagiadakis [Mon, 30 Apr 2012 23:20:24 +0000 (23:20 +0000)]
omxvideodec: Implement no-empty-eos-buffer hack, as in omxvideoenc.
Conflicts:
omx/gstomxvideodec.c
George Kiagiadakis [Mon, 30 Apr 2012 23:19:55 +0000 (23:19 +0000)]
omxvideodec: Fix coding style in the drain-may-not-return hack code
Arun Raghavan [Wed, 25 Apr 2012 13:33:48 +0000 (19:03 +0530)]
omx: Fix trivial debug print bug
Arun Raghavan [Wed, 25 Apr 2012 13:31:32 +0000 (19:01 +0530)]
omxvideodec: Add hack for Ducati components not returning from drain
This happens on the Galaxy Nexus, and causes the pipeline to hang waiting
endlessly for a drain. The hack replaces the wait with a wait + 500ms timeout.
Arun Raghavan [Wed, 25 Apr 2012 11:05:40 +0000 (16:35 +0530)]
omx: Fix deadlock between ending a flush and the event handler
gst_omx_port_set_flushing() calls OMX_FillThisBuffer at the end of a flush
without releasing the port lock, and this can cause a deadlock with the
EventHandler. This patches fixes this by dropping the lock for the duration of
the fill buffer call.
Sebastian Dröge [Tue, 24 Apr 2012 13:41:38 +0000 (15:41 +0200)]
omx: Update video encoder/decoder base classes from gst-plugins-bad
Sebastian Dröge [Mon, 16 Apr 2012 07:16:10 +0000 (09:16 +0200)]
configure: Modernize autotools setup a bit
Also we now only create tar.bz2 and tar.xz tarballs.
Sebastian Dröge [Mon, 16 Apr 2012 07:12:37 +0000 (09:12 +0200)]
Automatic update of common submodule
Sebastian Dröge [Mon, 16 Apr 2012 06:34:56 +0000 (08:34 +0200)]
omxaudioenc: Use gst_buffer_extract() to copy the input buffer data to the OpenMAX buffer
Alessandro Decina [Fri, 13 Apr 2012 21:16:42 +0000 (17:16 -0400)]
Fix relative/absolute path glitch
Signed-off-by: Reynaldo H. Verdejo Pinochet <reynaldo@collabora.com>
Olivier Crête [Thu, 12 Apr 2012 19:57:32 +0000 (15:57 -0400)]
Port to Gst 0.11
Reynaldo H. Verdejo Pinochet [Wed, 18 Jan 2012 19:53:16 +0000 (16:53 -0300)]
Enable building with Android's buildsystem
This change adds prelimary buildsystem hooks to
build gst-omx with the Android buildsystem. Like
the rest of GStreamer's Android hooks, the process
relies on the availability of androgenizer. A tool
developed by Collabora to automatically generate
Android.mk files from within the auto* setup.
Androgenizer is currently available at:
http://cgit.collabora.com/git/user/derek/androgenizer.git/
Sebastian Dröge [Tue, 13 Dec 2011 09:17:41 +0000 (10:17 +0100)]
basevideocodec: Don't use G_TYPE_REGISTER_BOXED() yet
This would require GLib 2.26.
Jonas Larsson [Wed, 14 Dec 2011 09:09:34 +0000 (10:09 +0100)]
omxaudioenc: Add hack for encoder components that don't allow empty EOS buffers
Jonas Larsson [Wed, 14 Dec 2011 09:07:29 +0000 (10:07 +0100)]
omxvideoenc: Fix deadlock when using the EOS hack
Sebastian Dröge [Mon, 12 Dec 2011 13:26:48 +0000 (14:26 +0100)]
omxvideoenc: Remove workaround for basevideocodec bug
Sebastian Dröge [Mon, 12 Dec 2011 13:26:34 +0000 (14:26 +0100)]
omxvideodec: Remove workaround for basevideocodec bug
Matej Knopp [Mon, 5 Dec 2011 17:57:01 +0000 (17:57 +0000)]
basevideo: Make GstVideoFrame a reference counted boxed object
...and also clear all existing frames when resetting the decoder or encoder.
Sebastian Dröge [Fri, 9 Dec 2011 11:17:29 +0000 (12:17 +0100)]
omx: Add hack for encoder components that don't allow empty EOS buffers
Dake Gu [Fri, 9 Dec 2011 09:21:47 +0000 (10:21 +0100)]
omxaacenc: Generate and set codec_data on the caps for raw AAC
Alessandro Decina [Mon, 31 Oct 2011 10:36:06 +0000 (11:36 +0100)]
basevideoencoder: handle failures in start() and stop()