From 7a8f5047b68b52bfdfab0603e73fba0ef3d168e4 Mon Sep 17 00:00:00 2001 From: Christian Berger Date: Wed, 15 Aug 2018 12:42:44 +0200 Subject: [PATCH] * Updated documentation Signed-off-by: Christian Berger --- README.md | 38 ++++++++++++++++++++------------------ 1 file changed, 20 insertions(+), 18 deletions(-) diff --git a/README.md b/README.md index a612840..e6d9bca 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,8 @@ -## OpenDLV Microservice to decode video frames from VP8 or VP9 into a shared memory +## Microservice to transform an input image in (A)RGB/(A)BGR format to I420 -This repository provides source code to decode broadcasted video frames in -VP8 or VP9 format into a shared memory area for the OpenDLV software ecosystem. +This repository provides source code to transform an input image in (A)RGB/(A)BGR +format residing in a shared memory to an image in I420 residing in a new shared +memory suitable for subsequent video compression. [![License: GPLv3](https://img.shields.io/badge/license-GPL--3-blue.svg )](https://www.gnu.org/licenses/gpl-3.0.txt) @@ -21,8 +22,7 @@ The following dependency is part of the source distribution: * [libcluon](https://github.com/chrberger/libcluon) - [![License: GPLv3](https://img.shields.io/badge/license-GPL--3-blue.svg )](https://www.gnu.org/licenses/gpl-3.0.txt) -The following dependencies are downloaded and installed during the Docker-ized build: -* [libvpx 1.7.0](https://github.com/webmproject/libvpx/releases/tag/v1.7.0) - [![License: BSD 3-Clause](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause) - [Google Patent License Conditions](https://raw.githubusercontent.com/webmproject/libvpx/f80be22a1099b2a431c2796f529bb261064ec6b4/PATENTS) +The following dependency is downloaded and installed during the Docker-ized build: * [libyuv](https://chromium.googlesource.com/libyuv/libyuv/+/master) - [![License: BSD 3-Clause](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause) - [Google Patent License Conditions](https://chromium.googlesource.com/libyuv/libyuv/+/master/PATENTS) @@ -33,29 +33,31 @@ section to your `docker-compose.yml`: ```yml version: '2' # Must be present exactly once at the beginning of the docker-compose.yml file services: # Must be present exactly once at the beginning of the docker-compose.yml file - video-vpx-decoder: - image: chalmersrevere/opendlv-video-vpx-decoder-multi:v0.0.5 + argb2i420: + image: chalmersrevere/argb2i420-multi:v0.0.1 restart: on-failure - network_mode: "host" ipc: "host" volumes: - /tmp:/tmp environment: - DISPLAY=${DISPLAY} - command: "--cid=111 --name=imageData" + command: "--in=img.argb --width=640 --height=480 --argb --out=imgout.i420" ``` -As this microservice is connecting to an OD4Session to receive VP8 or VP9 frames -to decode them into a shared memory area using SysV IPC, the `docker-compose.yml` -file specifies the use of `ipc:host`. The parameter `network_mode: "host"` is -necessary to receive VP8 or VP9 frames broadcasted from other microservices running -in an `OD4Session` from OpenDLV. The folder `/tmp` is shared into the Docker -container to provide tokens describing the shared memory area. +As this microservice is connecting to an existing shared memory to read the (A)RGB/(A)BGR +image for transform it into a new shared memory area using SysV IPC, the `docker-compose.yml` +file specifies the use of `ipc:host`. The folder `/tmp` is shared into the Docker +container to provide tokens describing the shared memory areas. The parameters to the application are: -* `--cid=111`: Identifier of the OD4Session to listen for VP8 or VP9 frames -* `--id=2`: Optional identifier to listen only for those VP8 or VP9 frames with the matching senderStamp of the OD4Session -* `--name=XYZ`: Name of the shared memory area to create for storing the ARGB image data +* `--in`: Name of the shared memory area containing the (A)RBG/(A)BGR image +* `--out`: Name of the shared memory area to be created for the I420 image +* `--width`: Width of the input image +* `--height`: Height of the input image +* `--argb`: Format of the input image (choose exactly one!) +* `--rgb`: Format of the input image (choose exactly one!) +* `--abgr`: Format of the input image (choose exactly one!) +* `--bgr`: Format of the input image (choose exactly one!) * `--verbose`: Display decoding information and render the image to screen (requires X11; run `xhost +` to allow access to you X11 server)