summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tests/Camera2Tests/SmartCamera/SimpleCamera/jni/Android.mk2
-rw-r--r--tests/Camera2Tests/SmartCamera/SimpleCamera/jni/colorspace.cpp3
-rw-r--r--tests/Camera2Tests/SmartCamera/SimpleCamera/jni/sobeloperator.cpp2
3 files changed, 2 insertions, 5 deletions
diff --git a/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/Android.mk b/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/Android.mk
index 616a11b36616..39ad0ac4bcdb 100644
--- a/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/Android.mk
+++ b/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/Android.mk
@@ -38,6 +38,8 @@ LOCAL_SRC_FILES := contrast.cpp \
sobeloperator.cpp \
stats_scorer.cpp
+LOCAL_CFLAGS += -Wall -Wextra -Werror -Wno-unused-parameter
+
LOCAL_STATIC_LIBRARIES += \
libcutils
diff --git a/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/colorspace.cpp b/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/colorspace.cpp
index 63e2ebf2f3e7..ffb8003d4c50 100644
--- a/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/colorspace.cpp
+++ b/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/colorspace.cpp
@@ -65,9 +65,6 @@ void JNI_COLORSPACE_METHOD(nativeYuv420pToRgba8888)(
uint8* pInV = pInput + size + size / 4;
Rgba* pOutColor = pOutput;
- const int u_offset = size;
- const int v_offset = u_offset + size / 4;
-
for (int y = 0; y < height; y += 2) {
for (int x = 0; x < width; x += 2) {
int u, v, y1, y2, y3, y4;
diff --git a/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/sobeloperator.cpp b/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/sobeloperator.cpp
index dc5c305ea23f..808b90da372b 100644
--- a/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/sobeloperator.cpp
+++ b/tests/Camera2Tests/SmartCamera/SimpleCamera/jni/sobeloperator.cpp
@@ -81,8 +81,6 @@ jboolean Java_androidx_media_filterpacks_image_SobelFilter_sobelOperator(
short* gyPtr = new short[3 * numPixels];
computeGradient(srcPtr, width, height, gxPtr, gyPtr);
- unsigned char* mag = magPtr;
- unsigned char* dir = dirPtr;
for (int i = 0; i < numPixels; ++i) {
for (int c = 0; c < 3; c++) {
int gx = static_cast<int>(*(gxPtr + 3 * i + c) / 8 + 127.5);