mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-20 15:27:07 +00:00
androidmedia: Add androidmedia plugin
This commit is contained in:
parent
5b04e77c0c
commit
347dbf123d
2 changed files with 123 additions and 0 deletions
74
sys/androidcamera/Makefile.am
Normal file
74
sys/androidcamera/Makefile.am
Normal file
|
@ -0,0 +1,74 @@
|
|||
plugin_LTLIBRARIES = libgstandroidmedia.la
|
||||
|
||||
VIDEO_BASE_CLASSES_C =
|
||||
video/video.c \
|
||||
video/gstvideodecoder.c \
|
||||
video/gstvideoencoder.c \
|
||||
video/gstvideoutils.c
|
||||
VIDEO_BASE_CLASSES_H =
|
||||
video/video.h \
|
||||
video/gstvideodecoder.h \
|
||||
video/gstvideoencoder.h \
|
||||
video/gstvideoutils.h
|
||||
|
||||
libgstandroidmedia_la_SOURCES = \
|
||||
gst-androidmedia.c \
|
||||
gstamc.c \
|
||||
gstamcaudiodec.c \
|
||||
gstamcvideodec.c \
|
||||
video/video.c \
|
||||
video/gstvideodecoder.c \
|
||||
video/gstvideoencoder.c \
|
||||
video/gstvideoutils.c
|
||||
|
||||
noinst_HEADERS = \
|
||||
gstamc.h \
|
||||
gstamc-constants.h \
|
||||
gstamcaudiodec.h \
|
||||
gstamcvideodec.h \
|
||||
video/video.h \
|
||||
video/gstvideodecoder.h \
|
||||
video/gstvideoencoder.h \
|
||||
video/gstvideoutils.h
|
||||
|
||||
if !HAVE_GST_0_10_37
|
||||
libgstandroidmedia_la_SOURCES += $(VIDEO_BASE_CLASSES_C)
|
||||
noinst_HEADERS += $(VIDEO_BASE_CLASSES_H)
|
||||
endif
|
||||
|
||||
libgstandroidmedia_la_CFLAGS = \
|
||||
$(GST_PLUGINS_BASE_CFLAGS) \
|
||||
$(GST_BASE_CFLAGS) \
|
||||
$(GST_CFLAGS) \
|
||||
$(ORC_CFLAGS) \
|
||||
$(JAVA_CFLAGS) \
|
||||
-I$(srcdir)
|
||||
libgstandroidmedia_la_LIBADD = \
|
||||
$(GST_PLUGINS_BASE_LIBS) \
|
||||
-lgstaudio-@GST_MAJORMINOR@ \
|
||||
-lgstpbutils-@GST_MAJORMINOR@ \
|
||||
-lgstvideo-@GST_MAJORMINOR@ \
|
||||
$(GST_BASE_LIBS) \
|
||||
$(GST_LIBS) \
|
||||
$(ORC_LIBS)
|
||||
libgstandroidmedia_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
|
||||
if !GST_PLUGIN_BUILD_STATIC
|
||||
libgstandroidmedia_la_LIBTOOLFLAGS = --tag=disable-static
|
||||
endif
|
||||
|
||||
EXTRA_DIST = $(VIDEO_BASE_CLASSES_C) $(VIDEO_BASE_CLASSES_H)
|
||||
|
||||
Android.mk: Makefile.am $(BUILT_SOURCES)
|
||||
androgenizer \
|
||||
-:PROJECT libgstandroidmedia -:SHARED libgstandroidmedia \
|
||||
-:TAGS eng debug \
|
||||
-:REL_TOP $(top_srcdir) -:ABS_TOP $(abs_top_srcdir) \
|
||||
-:SOURCES $(libgstandroidmedia_la_SOURCES) \
|
||||
$(nodist_libgstandroidmedia_la_SOURCES) \
|
||||
-:CFLAGS $(DEFS) $(DEFAULT_INCLUDES) $(libgstandroidmedia_la_CFLAGS) \
|
||||
-:LDFLAGS $(libgstandroidmedia_la_LDFLAGS) \
|
||||
$(libgstandroidmedia_la_LIBADD) \
|
||||
-ldl \
|
||||
-:PASSTHROUGH LOCAL_ARM_MODE:=arm \
|
||||
LOCAL_MODULE_PATH:='$$(TARGET_OUT)/lib/gstreamer-@GST_MAJOR_MINOR@' \
|
||||
> $@
|
49
sys/androidcamera/gst-androidmedia.c
Normal file
49
sys/androidcamera/gst-androidmedia.c
Normal file
|
@ -0,0 +1,49 @@
|
|||
/*
|
||||
* Copyright (C) 2012, Collabora Ltd.
|
||||
* Author: Sebastian Dröge <sebastian.droege@collabora.co.uk>
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation
|
||||
* version 2.1 of the License.
|
||||
*
|
||||
* This library is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||||
* Lesser General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU Lesser General Public
|
||||
* License along with this library; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*
|
||||
*/
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "gstamc.h"
|
||||
|
||||
#include <gst/gst.h>
|
||||
|
||||
static gboolean
|
||||
plugin_init (GstPlugin * plugin)
|
||||
{
|
||||
return gst_amc_init (plugin);
|
||||
}
|
||||
|
||||
#ifdef GST_PLUGIN_DEFINE2
|
||||
GST_PLUGIN_DEFINE2 (GST_VERSION_MAJOR,
|
||||
GST_VERSION_MINOR,
|
||||
androidmedia,
|
||||
"Android Media plugin",
|
||||
plugin_init,
|
||||
PACKAGE_VERSION, GST_LICENSE, GST_PACKAGE_NAME, GST_PACKAGE_ORIGIN)
|
||||
#else
|
||||
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
||||
GST_VERSION_MINOR,
|
||||
"androidmedia",
|
||||
"Android Media plugin",
|
||||
plugin_init,
|
||||
PACKAGE_VERSION, GST_LICENSE, GST_PACKAGE_NAME, GST_PACKAGE_ORIGIN)
|
||||
#endif
|
Loading…
Reference in a new issue