summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoger Monk <r-monk@ti.com>2012-05-10 15:18:27 +0100
committerDenys Dmytriyenko <denys@ti.com>2012-05-21 16:16:22 -0400
commita9eca3f6f9258cba5f30b9e9bbb0e31bc5da0d77 (patch)
tree70a885264218fe4c69bc291c38439b6761f2dc4f
parentbe837d63a43e61b9a1d183daee0cbd4ffe8a4130 (diff)
downloadmeta-ti-a9eca3f6f9258cba5f30b9e9bbb0e31bc5da0d77.tar.gz
omapfbplay: import from OE classic + api tweak
Signed-off-by: Roger Monk <r-monk@ti.com> Signed-off-by: Denys Dmytriyenko <denys@ti.com>
-rw-r--r--recipes-graphics/omapfbplay/files/0001-omapfbplay-switch-CODEC_TYPE_VIDEO-to-AVMEDIA_TYPE_V.patch26
-rw-r--r--recipes-graphics/omapfbplay/files/omapfbplay-errorhandling.patch34
-rw-r--r--recipes-graphics/omapfbplay/omapfbplay-cmem_git.bb16
-rw-r--r--recipes-graphics/omapfbplay/omapfbplay-dce_git.bb7
-rw-r--r--recipes-graphics/omapfbplay/omapfbplay-xv_git.bb3
-rw-r--r--recipes-graphics/omapfbplay/omapfbplay.inc33
-rw-r--r--recipes-graphics/omapfbplay/omapfbplay_git.bb3
7 files changed, 122 insertions, 0 deletions
diff --git a/recipes-graphics/omapfbplay/files/0001-omapfbplay-switch-CODEC_TYPE_VIDEO-to-AVMEDIA_TYPE_V.patch b/recipes-graphics/omapfbplay/files/0001-omapfbplay-switch-CODEC_TYPE_VIDEO-to-AVMEDIA_TYPE_V.patch
new file mode 100644
index 00000000..e01fddbf
--- /dev/null
+++ b/recipes-graphics/omapfbplay/files/0001-omapfbplay-switch-CODEC_TYPE_VIDEO-to-AVMEDIA_TYPE_V.patch
@@ -0,0 +1,26 @@
1From 71670f4a067efc169018a9ec9321ccc9af3bbd59 Mon Sep 17 00:00:00 2001
2From: Roger Monk <r-monk@ti.com>
3Date: Thu, 10 May 2012 14:50:11 +0100
4Subject: [PATCH] omapfbplay: switch CODEC_TYPE_VIDEO to AVMEDIA_TYPE_VIDEO
5
6Signed-off-by: Roger Monk <r-monk@ti.com>
7---
8 omapfbplay.c | 2 +-
9 1 files changed, 1 insertions(+), 1 deletions(-)
10
11diff --git a/omapfbplay.c b/omapfbplay.c
12index ad35bd5..818cf2c 100644
13--- a/omapfbplay.c
14+++ b/omapfbplay.c
15@@ -74,7 +74,7 @@ find_stream(AVFormatContext *afc)
16 int i;
17
18 for (i = 0; i < afc->nb_streams; i++) {
19- if (afc->streams[i]->codec->codec_type == CODEC_TYPE_VIDEO && !st)
20+ if (afc->streams[i]->codec->codec_type == AVMEDIA_TYPE_VIDEO && !st)
21 st = afc->streams[i];
22 else
23 afc->streams[i]->discard = AVDISCARD_ALL;
24--
251.7.0.4
26
diff --git a/recipes-graphics/omapfbplay/files/omapfbplay-errorhandling.patch b/recipes-graphics/omapfbplay/files/omapfbplay-errorhandling.patch
new file mode 100644
index 00000000..7dd544f8
--- /dev/null
+++ b/recipes-graphics/omapfbplay/files/omapfbplay-errorhandling.patch
@@ -0,0 +1,34 @@
1From e321ae7df57ada9ecc8c155fa4e5511c96ef5db3 Mon Sep 17 00:00:00 2001
2From: Rob Clark <rob@ti.com>
3Date: Fri, 18 Mar 2011 12:40:51 -0500
4Subject: [PATCH] dce: differentiate between fatal and non-fatal errors
5
6For streams with errors, the codec will throw back an error. But not
7all errors are fatal.
8---
9 dce.c | 10 ++++++++--
10 1 files changed, 8 insertions(+), 2 deletions(-)
11
12diff --git a/dce.c b/dce.c
13index ab7ad0a..88f175e 100644
14--- a/dce.c
15+++ b/dce.c
16@@ -270,8 +270,14 @@ static int dce_decode(AVPacket *p)
17
18 err = VIDDEC3_process(codec, inbufs, outbufs, in_args, out_args);
19 if (err) {
20- fprintf(stderr, "VIDDEC3_process() error %d\n", err);
21- return -1;
22+ fprintf(stderr, "VIDDEC3_process() error %d %08x\n", err,
23+ out_args->extendedError);
24+ /* for non-fatal errors, keep going.. a non-fatal error could
25+ * just indicate an error in the input stream which the codec
26+ * was able to conceal
27+ */
28+ if (XDM_ISFATALERROR(out_args->extendedError))
29+ return -1;
30 }
31
32 for (i = 0; i < out_args->outputID[i]; i++) {
33--
341.7.1
diff --git a/recipes-graphics/omapfbplay/omapfbplay-cmem_git.bb b/recipes-graphics/omapfbplay/omapfbplay-cmem_git.bb
new file mode 100644
index 00000000..a0392f6c
--- /dev/null
+++ b/recipes-graphics/omapfbplay/omapfbplay-cmem_git.bb
@@ -0,0 +1,16 @@
1require omapfbplay.inc
2
3DEPENDS += "ti-linuxutils"
4
5require recipes-ti/includes/ti-paths.inc
6
7PACKAGE_ARCH = "${MACHINE_ARCH}"
8
9SDMA_CFLAGS = " -I${LINUXUTILS_INSTALL_DIR}/packages/ti/sdo/linuxutils/sdma/include/"
10CMEM_CFLAGS = " -I${LINUXUTILS_INSTALL_DIR}/packages/ti/sdo/linuxutils/cmem/include/"
11CFLAGS += " -I. -I${STAGING_KERNEL_DIR}/include ${SDMA_CFLAGS} ${CMEM_CFLAGS}"
12
13export SDMA_LIBS = "-L${LINUXUTILS_INSTALL_DIR}/packages/ti/sdo/linuxutils/sdma/lib -l:sdma.a470MV"
14export CMEM_LIBS = "-L${LINUXUTILS_INSTALL_DIR}/packages/ti/sdo/linuxutils/cmem/lib -l:cmem.a470MV"
15
16OMAPFBPLAYOPTS = "V4L2=y OMAPFB=y NETSYNC=y CMEM=y SDMA=y"
diff --git a/recipes-graphics/omapfbplay/omapfbplay-dce_git.bb b/recipes-graphics/omapfbplay/omapfbplay-dce_git.bb
new file mode 100644
index 00000000..e70ac729
--- /dev/null
+++ b/recipes-graphics/omapfbplay/omapfbplay-dce_git.bb
@@ -0,0 +1,7 @@
1require omapfbplay.inc
2
3DEPENDS += "libdce"
4
5CFLAGS += " -I. -I${STAGING_INCDIR}/dce -I${STAGING_KERNEL_DIR}/include "
6
7OMAPFBPLAYOPTS = "V4L2=y OMAPFB=y NETSYNC=y DCE=y"
diff --git a/recipes-graphics/omapfbplay/omapfbplay-xv_git.bb b/recipes-graphics/omapfbplay/omapfbplay-xv_git.bb
new file mode 100644
index 00000000..cadf6d8e
--- /dev/null
+++ b/recipes-graphics/omapfbplay/omapfbplay-xv_git.bb
@@ -0,0 +1,3 @@
1require omapfbplay.inc
2
3OMAPFBPLAYOPTS = "V4L2=y NETSYNC=y XV=y"
diff --git a/recipes-graphics/omapfbplay/omapfbplay.inc b/recipes-graphics/omapfbplay/omapfbplay.inc
new file mode 100644
index 00000000..77e23806
--- /dev/null
+++ b/recipes-graphics/omapfbplay/omapfbplay.inc
@@ -0,0 +1,33 @@
1DESCRIPTION = "Simple libav-based player that uses the omapfb overlays"
2DEPENDS = "bzip2 lame libav virtual/kernel"
3LICENSE = "MIT"
4LIC_FILES_CHKSUM = "file://omapfbplay.c;beginline=2;endline=22;md5=05d3789ab362e6f4a9682e98100ea0fa"
5
6PV = "0.0+${PR}+gitr${SRCREV}"
7
8SRCREV = "34293052c5a2ae328eac6903512e6b4ce19b5639"
9SRC_URI = "git://git.mansr.com/omapfbplay;protocol=git \
10 file://omapfbplay-errorhandling.patch \
11 file://0001-omapfbplay-switch-CODEC_TYPE_VIDEO-to-AVMEDIA_TYPE_V.patch \
12 "
13
14S = "${WORKDIR}/git"
15
16# We want a kernel header for armv7a, but we don't want to make mplayer machine specific for that
17STAGING_KERNEL_DIR = "${STAGING_DIR}/${MACHINE_ARCH}${TARGET_VENDOR}-${TARGET_OS}/kernel"
18CFLAGS += " -I. -I${STAGING_KERNEL_DIR}/include "
19
20OMAPFBPLAYVARIANT ?= "${PN}"
21OMAPFBPLAYOPTS ?= "V4L2=y NETSYNC=y"
22
23do_compile() {
24 cp ${STAGING_KERNEL_DIR}/arch/arm/plat-omap/include/mach/omapfb.h ${S} || true
25 cp ${STAGING_KERNEL_DIR}/include/asm-arm/arch-omap/omapfb.h ${S} || true
26 cp ${STAGING_KERNEL_DIR}/include/linux/omapfb.h ${S} || true
27 oe_runmake ${TARGET_ARCH}=y ${OMAPFBPLAYOPTS} -e
28}
29
30do_install() {
31 install -d ${D}/${bindir}
32 install -m 0755 ${S}/omapfbplay ${D}/${bindir}/${OMAPFBPLAYVARIANT}
33}
diff --git a/recipes-graphics/omapfbplay/omapfbplay_git.bb b/recipes-graphics/omapfbplay/omapfbplay_git.bb
new file mode 100644
index 00000000..0d3956f1
--- /dev/null
+++ b/recipes-graphics/omapfbplay/omapfbplay_git.bb
@@ -0,0 +1,3 @@
1require omapfbplay.inc
2
3OMAPFBPLAYOPTS = "V4L2=y OMAPFB=y NETSYNC=y"