From patchwork Mon Aug 10 12:04:11 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Umang Jain X-Patchwork-Id: 9273 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 6460CBD87E for ; Mon, 10 Aug 2020 12:04:16 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 48CA560F72; Mon, 10 Aug 2020 14:04:15 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=uajain.com header.i=@uajain.com header.b="TJMaHJ2d"; dkim-atps=neutral Received: from o1.f.az.sendgrid.net (o1.f.az.sendgrid.net [208.117.55.132]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 69CE66038C for ; Mon, 10 Aug 2020 14:04:13 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=uajain.com; h=from:subject:in-reply-to:references:mime-version:to:cc: content-transfer-encoding:content-type; s=s1; bh=4S5AU31LwYsKdg3XtpmVn1HGzj2LiTc8pFtq4RaXXR4=; b=TJMaHJ2dA6e2b/CYn10bUdmDRjrfSOH7c/b9F2irvC+WbOUhZBbw5Q3G7gVsSOpAonlw 39mS61ScHV7dgl+b11gA0mIJimF12Yqo2F618oVCJ/OBKZ4DeN4gbwWDgNyEIkc10iKjgY /0UEO/tV32/euVIrLaAfKzbQmxZCiPmBs= Received: by filterdrecv-p3mdw1-7ff865655c-m68sw with SMTP id filterdrecv-p3mdw1-7ff865655c-m68sw-20-5F3137BB-94 2020-08-10 12:04:11.916873617 +0000 UTC m=+1014473.745401019 Received: from mail.uajain.com (unknown) by ismtpd0005p1maa1.sendgrid.net (SG) with ESMTP id _BTqMKDXRNmn_uxe1HbCpA for ; Mon, 10 Aug 2020 12:04:11.571 +0000 (UTC) From: Umang Jain Date: Mon, 10 Aug 2020 12:04:11 +0000 (UTC) Message-Id: <20200810120406.52654-2-email@uajain.com> In-Reply-To: <20200810120406.52654-1-email@uajain.com> References: <20200810120406.52654-1-email@uajain.com> Mime-Version: 1.0 X-SG-EID: 1Q40EQ7YGir8a9gjSIAdTjhngY657NMk9ckeo4dbHZDiOpywc/L3L9rFqlwE4KPc9vLW9W8H4bP+KZ0PPVtunxkrf1/W/GGIxTt+w0T9coG+TvKWFla874XTCVC06G0uYrHkhIxtRas0H6PgWUg0T6cUukIag/BVGRRbUiJV9R89aK7U+SUJLSeul57LTwW/3FGpcMdnGUcTz930fJIqKz7lopIJdr/eZ0jw4hB5gKlZToXN6WVvM3l5JloVGt5rWNVS6bMc0byH4KY+GO1FlQ== To: libcamera-devel@lists.libcamera.org Subject: [libcamera-devel] [PATCH v2 1/4] libcamera: pipeline: uvcvideo: Treat all UVC cameras as external 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: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Treat all UVC cameras as external for android framework to know that they are external. Signed-off-by: Umang Jain Reviewed-by: Kieran Bingham Reviewed-by: Laurent Pinchart Reviewed-by: Niklas Söderlund --- src/libcamera/pipeline/uvcvideo/uvcvideo.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/libcamera/pipeline/uvcvideo/uvcvideo.cpp b/src/libcamera/pipeline/uvcvideo/uvcvideo.cpp index bc892ec..ed61d12 100644 --- a/src/libcamera/pipeline/uvcvideo/uvcvideo.cpp +++ b/src/libcamera/pipeline/uvcvideo/uvcvideo.cpp @@ -14,6 +14,7 @@ #include #include #include +#include #include #include @@ -500,6 +501,9 @@ int UVCCameraData::init(MediaEntity *entity) video_->bufferReady.connect(this, &UVCCameraData::bufferReady); + /* Initialise Camera Property. Treat all UVC cameras as external. */ + properties_.set(properties::Location, properties::CameraLocationExternal); + /* Initialise the supported controls. */ ControlInfoMap::Map ctrls;