Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 94422aa5 authored by Austin Borger's avatar Austin Borger
Browse files

cameraservice_test: Add DepthProcessorTest to the host build.

DepthProcessorTest depends on libdynamic_depth and lib_image_io, which
up until now have had no host build. The topic-related patches add the
host_supported flag to both of them.

Some additions have been made to NVCompressor.h and DepthPhotoProcessor.cpp
to build successfully on the host. These have minimal impact.

Bug: 207411352
Test: Ran test on gLinux.
Change-Id: Ifa3a5f93690c7d4c5c6898dfd7370f090037fc37
parent ab7b1f3e
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -47,7 +47,6 @@ cc_library_shared {
        "common/CameraDeviceBase.cpp",
        "common/CameraOfflineSessionBase.cpp",
        "common/CameraProviderManager.cpp",
        "common/DepthPhotoProcessor.cpp",
        "common/FrameProcessorBase.cpp",
        "api1/Camera2Client.cpp",
        "api1/client2/Parameters.cpp",
@@ -197,6 +196,7 @@ cc_library_static {
    // Camera service source

    srcs: [
        "common/DepthPhotoProcessor.cpp",
        "device3/CoordinateMapper.cpp",
        "device3/DistortionMapper.cpp",
        "device3/RotateAndCropMapper.cpp",
@@ -209,12 +209,17 @@ cc_library_static {
        "libbase",
        "libbinder",
        "libcamera_metadata",
        "libdynamic_depth",
        "libexif",
        "libjpeg",
        "liblog",
        "libutils",
        "libxml2",
    ],

    include_dirs: [
        "external/dynamic_depth/includes",
        "external/dynamic_depth/internal",
        "frameworks/av/camera/include",
        "frameworks/av/camera/include/camera",
    ],
+4 −0
Original line number Diff line number Diff line
@@ -42,6 +42,10 @@
#include <xmpmeta/xmp_data.h>
#include <xmpmeta/xmp_writer.h>

#ifndef __unused
#define __unused __attribute__((__unused__))
#endif

using dynamic_depth::Camera;
using dynamic_depth::Cameras;
using dynamic_depth::CameraParams;
+4 −0
Original line number Diff line number Diff line
@@ -90,7 +90,9 @@ cc_test_host {
        "libbase",
        "libbinder",
        "libcamera_metadata",
        "libdynamic_depth",
        "libexif",
        "libjpeg",
        "liblog",
        "libutils",
    ],
@@ -103,8 +105,10 @@ cc_test_host {

    srcs: [
        "ClientManagerTest.cpp",
        "DepthProcessorTest.cpp",
        "DistortionMapperTest.cpp",
        "ExifUtilsTest.cpp",
        "NV12Compressor.cpp",
        "RotateAndCropMapperTest.cpp",
        "ZoomRatioTest.cpp",
    ],
+1 −0
Original line number Diff line number Diff line
@@ -19,6 +19,7 @@

#include <setjmp.h>
#include <stdlib.h>
#include <stdio.h>
extern "C" {
#include <jpeglib.h>
#include <jerror.h>