Restore Camera definitions file.

Change-Id: I5a0c61666abd09135ef951c332123c58c0e2c7f2
diff --git a/shared/BoardConfig.mk b/shared/BoardConfig.mk
index 17466f5..939bbcb 100644
--- a/shared/BoardConfig.mk
+++ b/shared/BoardConfig.mk
@@ -63,12 +63,6 @@
 # TODO(san): See if we can get rid of this.
 BOARD_FLASH_BLOCK_SIZE := 512
 
-# master has breaking changes in dlfcn.h, but the platform SDK hasn't been
-# bumped. Restore the line below when it is.
-GCE_VERSION_CFLAGS := -DGCE_PLATFORM_SDK_VERSION=26
-# GCE_VERSION_CFLAGS := -DGCE_PLATFORM_SDK_VERSION=${PLATFORM_SDK_VERSION}
-STAGEFRIGHT_AVCENC_CFLAGS := -DANDROID_GCE
-
 WITH_DEXPREOPT := true
 
 USE_OPENGL_RENDERER := true
@@ -88,16 +82,31 @@
 
 BOARD_SEPOLICY_DIRS += device/google/cuttlefish/shared/sepolicy
 
-GCE_STLPORT_INCLUDES :=
-GCE_STLPORT_LIBS :=
-GCE_STLPORT_STATIC_LIBS :=
+# master has breaking changes in dlfcn.h, but the platform SDK hasn't been
+# bumped. Restore the line below when it is.
+# VSOC_VERSION_CFLAGS := -DVSOC_PLATFORM_SDK_VERSION=26
+VSOC_VERSION_CFLAGS := -DVSOC_PLATFORM_SDK_VERSION=${PLATFORM_SDK_VERSION}
+VSOC_STLPORT_INCLUDES :=
+VSOC_STLPORT_LIBS :=
+VSOC_STLPORT_STATIC_LIBS :=
+VSOC_TEST_INCLUDES := external/googletest/googlemock/include external/googletest/googletest/include
+VSOC_TEST_LIBRARIES := libgmock_main_host libgtest_host libgmock_host
+VSOC_LIBCXX_STATIC := libc++_static
+VSOC_PROTOBUF_SHARED_LIB := libprotobuf-cpp-full
 
-GCE_TEST_INCLUDES := external/googletest/googlemock/include external/googletest/googletest/include
-GCE_TEST_LIBRARIES := libgmock_main_host libgtest_host libgmock_host
+# TODO(ender): Remove all these once we stop depending on GCE code.
+GCE_VERSION_CFLAGS := -DGCE_PLATFORM_SDK_VERSION=${PLATFORM_SDK_VERSION}
+GCE_STLPORT_INCLUDES := $(VSOC_STLPORT_INCLUDES)
+GCE_STLPORT_LIBS := $(VSOC_STLPORT_LIBS)
+GCE_STLPORT_STATIC_LIBS := $(VSOC_STLPORT_STATIC_LIBS)
+GCE_TEST_INCLUDES := $(VSOC_TEST_INCLUDES)
+GCE_TEST_LIBRARIES := $(VSOC_TEST_LIBRARIES)
+GCE_LIBCXX_STATIC := $(VSOC_LIBCXX_STATIC)
+GCE_PROTOBUF_SHARED_LIB := $(VSOC_PROTOBUF_SHARED_LIB)
+# TODO(ender): up till here.
 
-GCE_LIBCXX_STATIC := libc++_static
+STAGEFRIGHT_AVCENC_CFLAGS := -DANDROID_GCE
 
-GCE_PROTOBUF_SHARED_LIB := libprotobuf-cpp-full
 INIT_BOOTCHART := true
 
 DEVICE_MANIFEST_FILE := device/google/cuttlefish/shared/config/manifest.xml
diff --git a/shared/config/camera_v1.json b/shared/config/camera_v1.json
new file mode 100644
index 0000000..8a2ae5b
--- /dev/null
+++ b/shared/config/camera_v1.json
@@ -0,0 +1,52 @@
+{
+  "__readme": [
+    "Basic Camera HAL v1 configuration."
+  ],
+
+  "camera_definitions": [
+    {
+      "orientation": "back",
+      "hal_version": "1",
+      "resolutions": [
+        {
+          "width": "1600",
+          "height": "1200"
+        },
+        {
+          "width": "1280",
+          "height": "720"
+        },
+        {
+          "width": "640",
+          "height": "480"
+        },
+        {
+          "width": "320",
+          "height": "240"
+        }
+      ]
+    },
+    {
+      "orientation": "front",
+      "hal_version": "1",
+      "resolutions": [
+        {
+          "width": "1024",
+          "height": "768"
+        },
+        {
+          "width": "800",
+          "height": "600"
+        },
+        {
+          "width": "640",
+          "height": "480"
+        },
+        {
+          "width": "320",
+          "height": "240"
+        }
+      ]
+    }
+  ]
+}
diff --git a/shared/config/camera_v3.json b/shared/config/camera_v3.json
new file mode 100644
index 0000000..3479004
--- /dev/null
+++ b/shared/config/camera_v3.json
@@ -0,0 +1,52 @@
+{
+  "__readme": [
+    "Basic Camera HAL v3 configuration."
+  ],
+
+  "camera_definitions": [
+    {
+      "orientation": "back",
+      "hal_version": "3",
+      "resolutions": [
+        {
+          "width": "1600",
+          "height": "1200"
+        },
+        {
+          "width": "1280",
+          "height": "720"
+        },
+        {
+          "width": "640",
+          "height": "480"
+        },
+        {
+          "width": "320",
+          "height": "240"
+        }
+      ]
+    },
+    {
+      "orientation": "front",
+      "hal_version": "3",
+      "resolutions": [
+        {
+          "width": "1024",
+          "height": "768"
+        },
+        {
+          "width": "800",
+          "height": "600"
+        },
+        {
+          "width": "640",
+          "height": "480"
+        },
+        {
+          "width": "320",
+          "height": "240"
+        }
+      ]
+    }
+  ]
+}
diff --git a/shared/device.mk b/shared/device.mk
index b884efa..fad6e44 100644
--- a/shared/device.mk
+++ b/shared/device.mk
@@ -99,6 +99,7 @@
 #
 PRODUCT_COPY_FILES += \
     device/google/cuttlefish/shared/config/audio_policy_configuration.xml:$(TARGET_COPY_OUT_VENDOR)/etc/audio_policy_configuration.xml \
+    device/google/cuttlefish/shared/config/camera_v1.json:vendor/etc/config/camera.json \
     device/google/cuttlefish/shared/config/init.vsoc.rc:root/init.vsoc.rc \
     device/google/cuttlefish/shared/config/media_codecs.xml:system/etc/media_codecs.xml \
     device/google/cuttlefish/shared/config/media_codecs_performance.xml:system/etc/media_codecs_performance.xml \