From patchwork Thu Apr 28 09:55:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Harvey Yang X-Patchwork-Id: 15742 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 8E6A3C3256 for ; Thu, 28 Apr 2022 09:55:57 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id CDC3665646; Thu, 28 Apr 2022 11:55:56 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1651139756; bh=uthl/UqtX7G7viaA6FNSaFhg8LGMSYXEIGtRzY7VsO8=; h=To:Date:Subject:List-Id:List-Unsubscribe:List-Archive:List-Post: List-Help:List-Subscribe:From:Reply-To:Cc:From; b=qDZXJTgDx4Bz/89f0TuL2ARcQRQUiWXW9sum+gnNBOzgLeMZKRrgnGPj1V3OhUlGm dDXsKHCiH4NbGLeyw9qet8WPLrEI63M4ADh5+8VzrTqv1aQAKBDRKUtMy9soM+axiY KFMWIyzlhSluGq7B5232Vdbr3UUEHH3FggE/Pm5wv3szmjRT0ONOD+0HmVrRM/ftte GFRiTTgMZD44TIeIklNroXB1duMVN86Qq6HlUK6JH38kFgZUQQY50hXYCfEfz+l8dy PQtUZ7AEfZD0Zu7bOfrTFgnlatcuhqkYtCItA/zIBJ7Fix+l18AebnHrBYOUqHdQEl qVa5pzRhxaOLQ== Received: from mail-pl1-x62d.google.com (mail-pl1-x62d.google.com [IPv6:2607:f8b0:4864:20::62d]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 63DA06563E for ; Thu, 28 Apr 2022 11:55:55 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="A0gkQUX/"; dkim-atps=neutral Received: by mail-pl1-x62d.google.com with SMTP id c23so3935735plo.0 for ; Thu, 28 Apr 2022 02:55:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=eaeoVXmzsKQLezGbV6RqHiK8+buFXM6Nysa/hvX80xg=; b=A0gkQUX//7ywYAZFUSRm++hg8FtBfji7bb7Ns6AaSs/NmJf+KOOzITb44LoyYCRUtB xjdx0d80BtAxhC/tlctumx2Wl5lqnll9xuRs8Tiigjiwh1g732iQuoBgeKXNp/MmXwh/ sQ+A6Y/TCIzOZbuR5wL/vfPHtMi3sAPKlb2Zg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=eaeoVXmzsKQLezGbV6RqHiK8+buFXM6Nysa/hvX80xg=; b=0k+nyGhNcP7WqFKMAaWQ4sLVqNj2++1R+ujOr8qhaYU1HnMfSJHenHOG6/H2JaW/AU y1t6RWfqPs+lgpfr+mPW+Njratq+s8XyF7PGlh80Kk3CTOpJCJGfFhkto7X0jyPAzuve tHpe9huu9v2RAEnVf65yLATrgGUFUu4y0jQr1aqKekdR7DRVzOUFS7DMYyE3PMsAdHzM 0y2yS+K+3OH01qr/5UwFpRpegu6+KV/HT6bDXZeLsVVL0FDRL8eyqF6fOhJQDTrS5Vvy TZUkmIVP17vQkThZuZCndtWNbYJuu69VN25LxBoHxvIYvdeuHj2XV5L5p1LgZZrqFpem 5L6Q== X-Gm-Message-State: AOAM531T4mwc5+yXvKAJ4ozvI31b0RDMm5yZubx08eTFbN2Wtj11KmWH pruJlw88gebZewC/MnRTVkDajDl8zgY1LLcY X-Google-Smtp-Source: ABdhPJxKc1egmCMUkj59bV4sAiAnZp0hOKIgMY5sNrEqgaL8kGffY4IqeMpOBnz+yRSponVxS2XqbA== X-Received: by 2002:a17:90a:bd95:b0:1d9:6735:e9ef with SMTP id z21-20020a17090abd9500b001d96735e9efmr23880186pjr.157.1651139753160; Thu, 28 Apr 2022 02:55:53 -0700 (PDT) Received: from chenghaoyang.c.googlers.com.com (93.135.240.35.bc.googleusercontent.com. [35.240.135.93]) by smtp.gmail.com with ESMTPSA id x6-20020a17090a46c600b001d960eaed66sm5861256pjg.42.2022.04.28.02.55.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Apr 2022 02:55:52 -0700 (PDT) To: libcamera-devel@lists.libcamera.org Date: Thu, 28 Apr 2022 09:55:38 +0000 Message-Id: <20220428095544.2795980-1-chenghaoyang@chromium.org> X-Mailer: git-send-email 2.36.0.rc2.479.g8af0fa9b8e-goog MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v4 0/6] Add CrOS JEA implementation X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Harvey Yang via libcamera-devel From: Harvey Yang Reply-To: Harvey Yang Cc: Harvey Yang Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Hi everyone, Thanks Laurent for your detailed comments! Mostly updated in the new patches, and please let me know if I missed anything. More comments are still welcome. BR, Harvey Harvey Yang (6): Allow inheritance of FrameBuffer Add HALFrameBuffer and replace FrameBuffer in src/android Add meson.build in src/android/jpeg Move generateThumbnail from PostProcessorJpeg to Encoder Pass StreamBuffer to Encoder::encoder Add JEA implementation include/libcamera/framebuffer.h | 3 +- src/android/camera_device.cpp | 3 +- src/android/cros/camera3_hal.cpp | 2 + src/android/cros_mojo_token.h | 12 +++ src/android/frame_buffer_allocator.h | 7 +- src/android/hal_framebuffer.cpp | 25 ++++++ src/android/hal_framebuffer.h | 27 +++++++ src/android/jpeg/encoder.h | 10 ++- src/android/jpeg/encoder_jea.cpp | 81 +++++++++++++++++++ src/android/jpeg/encoder_jea.h | 35 ++++++++ src/android/jpeg/encoder_libjpeg.cpp | 81 ++++++++++++++++++- src/android/jpeg/encoder_libjpeg.h | 23 +++++- src/android/jpeg/meson.build | 16 ++++ src/android/jpeg/post_processor_jpeg.cpp | 65 +++------------ src/android/jpeg/post_processor_jpeg.h | 11 +-- src/android/meson.build | 6 +- .../mm/cros_frame_buffer_allocator.cpp | 14 ++-- .../mm/generic_frame_buffer_allocator.cpp | 12 +-- 18 files changed, 345 insertions(+), 88 deletions(-) create mode 100644 src/android/cros_mojo_token.h create mode 100644 src/android/hal_framebuffer.cpp create mode 100644 src/android/hal_framebuffer.h create mode 100644 src/android/jpeg/encoder_jea.cpp create mode 100644 src/android/jpeg/encoder_jea.h create mode 100644 src/android/jpeg/meson.build