Patch Detail
Show a patch.
GET /api/patches/204/?format=api
{ "id": 204, "url": "https://patchwork.libcamera.org/api/patches/204/?format=api", "web_url": "https://patchwork.libcamera.org/patch/204/", "project": { "id": 1, "url": "https://patchwork.libcamera.org/api/projects/1/?format=api", "name": "libcamera", "link_name": "libcamera", "list_id": "libcamera_core", "list_email": "libcamera-devel@lists.libcamera.org", "web_url": "", "scm_url": "", "webscm_url": "" }, "msgid": "<20190111130857.17946-1-jacopo@jmondi.org>", "date": "2019-01-11T13:08:57", "name": "[libcamera-devel] utils: ipu3: Use variables for 'yavta' and 'media-ctl'", "commit_ref": null, "pull_url": null, "state": "rejected", "archived": false, "hash": "8af54ceb6c4102cc3eff7afb0b7135912f3da1b3", "submitter": { "id": 3, "url": "https://patchwork.libcamera.org/api/people/3/?format=api", "name": "Jacopo Mondi", "email": "jacopo@jmondi.org" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/204/mbox/", "series": [ { "id": 68, "url": "https://patchwork.libcamera.org/api/series/68/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=68", "date": "2019-01-11T13:08:57", "name": "[libcamera-devel] utils: ipu3: Use variables for 'yavta' and 'media-ctl'", "version": 1, "mbox": "https://patchwork.libcamera.org/series/68/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/204/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/204/checks/", "tags": {}, "headers": { "Return-Path": "<jacopo@jmondi.org>", "Received": [ "from relay7-d.mail.gandi.net (relay7-d.mail.gandi.net\n\t[217.70.183.200])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 33D46600CC\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 11 Jan 2019 14:08:57 +0100 (CET)", "from uno.lan (2-224-242-101.ip172.fastwebnet.it [2.224.242.101])\n\t(Authenticated sender: jacopo@jmondi.org)\n\tby relay7-d.mail.gandi.net (Postfix) with ESMTPSA id A13122000D;\n\tFri, 11 Jan 2019 13:08:56 +0000 (UTC)" ], "X-Originating-IP": "2.224.242.101", "From": "Jacopo Mondi <jacopo@jmondi.org>", "To": "libcamera-devel@lists.libcamera.org", "Date": "Fri, 11 Jan 2019 14:08:57 +0100", "Message-Id": "<20190111130857.17946-1-jacopo@jmondi.org>", "X-Mailer": "git-send-email 2.20.1", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[libcamera-devel] [PATCH] utils: ipu3: Use variables for 'yavta'\n\tand 'media-ctl'", "X-BeenThere": "libcamera-devel@lists.libcamera.org", "X-Mailman-Version": "2.1.23", "Precedence": "list", "List-Id": "<libcamera-devel.lists.libcamera.org>", "List-Unsubscribe": "<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>", "List-Archive": "<https://lists.libcamera.org/pipermail/libcamera-devel/>", "List-Post": "<mailto:libcamera-devel@lists.libcamera.org>", "List-Help": "<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>", "List-Subscribe": "<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>", "X-List-Received-Date": "Fri, 11 Jan 2019 13:08:57 -0000" }, "content": "Use variables defined at the beginning of ipu3 helper scripts to call\nyavta and media-ctl. This makes easier override them if a locally\ncompiled version should be used in place of the system-wide installed\nones.\n\nSigned-off-by: Jacopo Mondi <jacopo@jmondi.org>\n---\n utils/ipu3/ipu3-capture.sh | 9 ++++++---\n utils/ipu3/ipu3-process.sh | 8 +++++---\n 2 files changed, 11 insertions(+), 6 deletions(-)\n\n--\n2.20.1", "diff": "diff --git a/utils/ipu3/ipu3-capture.sh b/utils/ipu3/ipu3-capture.sh\nindex ba6147b..9d83cd4 100755\n--- a/utils/ipu3/ipu3-capture.sh\n+++ b/utils/ipu3/ipu3-capture.sh\n@@ -13,6 +13,9 @@\n # - raw2pnm (from nvt https://github.com/intel/nvt.git)\n # - yavta (from git://git.ideasonboard.org/yavta.git)\n\n+MEDIACTL=$(which media-ctl)\n+YAVTA=$(which yavta)\n+\n # Locate the sensor entity\n find_sensor() {\n \tlocal bus\n@@ -113,8 +116,8 @@ capture_frames() {\n \t\tfile_op=\"--file=/tmp/frame-#.bin\"\n \tfi\n\n-\tyavta -c$frame_count -n5 -I -f $ipu3_format -s $sensor_size $file_op \\\n-\t\t$($mediactl -e \"$ipu3_capture\")\n+\t${YAVTA} -c$frame_count -n5 -I -f $ipu3_format -s $sensor_size $file_op \\\n+\t\t $($mediactl -e \"$ipu3_capture\")\n }\n\n # Convert captured files to ppm\n@@ -173,7 +176,7 @@ sensor_name=$1\n\n sensor=$(find_sensor $sensor_name) || exit\n mdev=$(find_media_device) || exit\n-mediactl=\"media-ctl -d $mdev\"\n+mediactl=\"${MEDIACTL} -d $mdev\"\n\n parse_pipeline $sensor\n configure_pipeline\ndiff --git a/utils/ipu3/ipu3-process.sh b/utils/ipu3/ipu3-process.sh\nindex bb4abbe..ccdeb27 100755\n--- a/utils/ipu3/ipu3-process.sh\n+++ b/utils/ipu3/ipu3-process.sh\n@@ -13,6 +13,8 @@\n # - raw2pnm (from nvt https://github.com/intel/nvt.git)\n # - yavta (from git://git.ideasonboard.org/yavta.git)\n\n+MEDIACTL=$(which media-ctl)\n+YAVTA=$(which yavta)\n imgu_entity=\"ipu3-imgu 0\"\n\n # Locate the media device\n@@ -20,7 +22,7 @@ find_media_device() {\n \tlocal mdev\n\n \tfor mdev in /dev/media* ; do\n-\t\tmedia-ctl -d $mdev -p | grep -q \"^driver[ \\t]*ipu3-imgu$\" && break\n+\t\t$MEDIACTL -d $mdev -p | grep -q \"^driver[ \\t]*ipu3-imgu$\" && break\n \t\tmdev=\n \tdone\n\n@@ -62,7 +64,7 @@ configure_pipeline() {\n process_frames() {\n \tconfigure_pipeline\n\n-\tlocal yavta=\"yavta -n $nbufs -c$frame_count\"\n+\tlocal yavta=\"${YAVTA} -n $nbufs -c$frame_count\"\n\n \t# Save the main and viewfinder outputs to disk, capture and drop 3A\n \t# statistics. Sleep 500ms between each execution of yavta to keep the\n@@ -189,7 +191,7 @@ out_size=${out_size:-$in_size}\n vf_size=${vf_size:-$in_size}\n\n mdev=$(find_media_device) || exit\n-mediactl=\"media-ctl -d $mdev\"\n+mediactl=\"${MEDIACTL} -d $mdev\"\n echo \"Using device $mdev\"\n\n output_dir=\"/tmp\"\n", "prefixes": [ "libcamera-devel" ] }