diff --git a/meta-digi-arm/recipes-bsp/libedgetpu/files/0001-gstreamer-fix-video-sink-for-wayland-images.patch b/meta-digi-arm/recipes-bsp/libedgetpu/files/0001-gstreamer-fix-video-sink-for-wayland-images.patch new file mode 100644 index 000000000..acf910e78 --- /dev/null +++ b/meta-digi-arm/recipes-bsp/libedgetpu/files/0001-gstreamer-fix-video-sink-for-wayland-images.patch @@ -0,0 +1,27 @@ +From: Arturo Buzarra +Date: Mon, 28 Jun 2021 15:00:58 +0200 +Subject: [PATCH] gstreamer: fix video sink for wayland images + +Signed-off-by: Arturo Buzarra +--- + gstreamer/gstreamer.py | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/gstreamer/gstreamer.py b/gstreamer/gstreamer.py +index 2676439..e055d77 100644 +--- a/gstreamer/gstreamer.py ++++ b/gstreamer/gstreamer.py +@@ -249,11 +249,11 @@ def run_pipeline(user_function, + scale_caps = 'video/x-raw,width={width},height={height}'.format(width=scale[0], height=scale[1]) + PIPELINE += """ ! tee name=t + t. ! {leaky_q} ! videoconvert ! videoscale ! {scale_caps} ! videobox name=box autocrop=true + ! {sink_caps} ! {sink_element} + t. ! {leaky_q} ! videoconvert +- ! rsvgoverlay name=overlay ! videoconvert ! ximagesink sync=false ++ ! rsvgoverlay name=overlay ! videoconvert ! waylandsink sync=false + """ + + SINK_ELEMENT = 'appsink name=appsink emit-signals=true max-buffers=1 drop=true' + SINK_CAPS = 'video/x-raw,format=RGB,width={width},height={height}' + LEAKY_Q = 'queue max-size-buffers=1 leaky=downstream' +-- diff --git a/meta-digi-arm/recipes-bsp/libedgetpu/libedgetpu-examples_git.bb b/meta-digi-arm/recipes-bsp/libedgetpu/libedgetpu-examples_git.bb new file mode 100644 index 000000000..f505fa88c --- /dev/null +++ b/meta-digi-arm/recipes-bsp/libedgetpu/libedgetpu-examples_git.bb @@ -0,0 +1,34 @@ +SUMMARY = "Edge TPU simple camera examples" +HOMEPAGE = "https://coral.ai/examples" +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57" + +SRCREV = "19335531f599133e054ec2ddcc31733d24031ba5" +SRC_URI = "git://github.com/google-coral/examples-camera.git;protocol=https \ + file://0001-gstreamer-fix-video-sink-for-wayland-images.patch \ + " + +S = "${WORKDIR}/git" + +inherit gobject-introspection + +RDEPENDS_${PN} = "python3-pycoral \ + gstreamer1.0-plugins-base \ +" + +do_configure() { + bash download_models.sh +} + +do_install() { + # Install Gstreamer examples + install -d ${D}/opt/libedgetpu + install -d ${D}/opt/libedgetpu/all_models + install -d ${D}/opt/libedgetpu/gstreamer + rm -f ${S}/gstreamer/install_requirements.sh + install -m 0555 ${S}/all_models/* ${D}/opt/libedgetpu/all_models/ + install -m 0555 ${S}/gstreamer/* ${D}/opt/libedgetpu/gstreamer/ +} + +FILES_${PN} += "/opt/libedgetpu/* \ +"