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

Commit a1ed1689 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Cleanup dvr api headers for exporting"

parents 5d2c364c 14bc55a2
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -211,7 +211,7 @@ typedef int (*DvrVSyncClientGetSchedInfoPtr)(DvrVSyncClient* client,
                                             uint32_t* next_vsync_count);

// libs/vr/libvrsensor/include/dvr/pose_client.h
typedef DvrPoseClient* (*DvrPoseClientCreatePtr)(void);
typedef DvrPoseClient* (*DvrPoseClientCreatePtr)();
typedef void (*DvrPoseClientDestroyPtr)(DvrPoseClient* client);
typedef int (*DvrPoseClientGetPtr)(DvrPoseClient* client, uint32_t vsync_count,
                                   DvrPoseAsync* out_pose);
@@ -222,7 +222,13 @@ typedef int (*DvrPoseClientGetControllerPtr)(DvrPoseClient* client,
                                             DvrPoseAsync* out_pose);

// services/vr/virtual_touchpad/include/dvr/virtual_touchpad_client.h
typedef DvrVirtualTouchpad* (*DvrVirtualTouchpadCreatePtr)(void);

// Touchpad IDs for *Touch*() and *ButtonState*() calls.
enum {
  DVR_VIRTUAL_TOUCHPAD_PRIMARY = 0,
  DVR_VIRTUAL_TOUCHPAD_VIRTUAL = 1,
};
typedef DvrVirtualTouchpad* (*DvrVirtualTouchpadCreatePtr)();
typedef void (*DvrVirtualTouchpadDestroyPtr)(DvrVirtualTouchpad* client);
typedef int (*DvrVirtualTouchpadAttachPtr)(DvrVirtualTouchpad* client);
typedef int (*DvrVirtualTouchpadDetachPtr)(DvrVirtualTouchpad* client);
+1 −1
Original line number Diff line number Diff line
@@ -84,7 +84,7 @@ int dvrSurfaceStateGetSurfaceCount(DvrSurfaceState* surface_state,
                                   size_t* count_out);

// Returns the update flags for the surface at |surface_index| in the state
// object. The flags may be used to determine what changes, if any, occured to
// object. The flags may be used to determine what changes, if any, occurred to
// the surface since the last state update.
// @return 0 on success. Otherwise returns a negative error value.
int dvrSurfaceStateGetUpdateFlags(DvrSurfaceState* surface_state,
+8 −0
Original line number Diff line number Diff line
@@ -13,10 +13,15 @@ shared_libs = [
    "libutils",
]

header_libraries = [
    "libdvr_headers"
]

cc_library {
    srcs: src,
    export_include_dirs: ["include"],
    shared_libs: shared_libs,
    header_libs: header_libraries,
    cppflags: ["-std=c++11"],
    cflags: ["-DLOG_TAG=\"VrVirtualTouchpad\""],
    name: "libvirtualtouchpad",
@@ -42,6 +47,7 @@ cc_test {
    srcs: test_src_files,
    static_libs: test_static_libs,
    shared_libs: test_shared_libs,
    header_libs: header_libraries,
    cppflags = [
        "-std=c++11",
    ],
@@ -77,6 +83,7 @@ cc_binary {
    srcs: service_src,
    static_libs: service_static_libs,
    shared_libs: service_shared_libs,
    header_libs: header_libraries,
    cppflags: ["-std=c++11"],
    cflags: [
        "-DLOG_TAG=\"VrVirtualTouchpad\"",
@@ -107,6 +114,7 @@ client_shared_libs = [
cc_library {
    srcs: client_src,
    shared_libs: client_shared_libs,
    header_libs: header_libraries,
    cppflags: ["-std=c++11"],
    cflags: ["-DLOG_TAG=\"VirtualTouchpadClient\""],
    host_ldlibs: ["-llog"],
+2 −5
Original line number Diff line number Diff line
#ifndef ANDROID_DVR_VIRTUAL_TOUCHPAD_C_CLIENT_H
#define ANDROID_DVR_VIRTUAL_TOUCHPAD_C_CLIENT_H

#include <dvr/dvr_api.h>

#ifdef __cplusplus
extern "C" {
#endif

typedef struct DvrVirtualTouchpad DvrVirtualTouchpad;

enum {
  DVR_VIRTUAL_TOUCHPAD_PRIMARY = 0,
  DVR_VIRTUAL_TOUCHPAD_VIRTUAL = 1,
};

// Creates a new virtual touchpad client.
//
// @return Pointer to the created virtual touchpad client; nullptr on failure.