diff options
Diffstat (limited to 'camera')
-rw-r--r-- | camera/CameraHal.cpp | 9 | ||||
-rw-r--r-- | camera/OMXCameraAdapter/OMXCapabilities.cpp | 18 | ||||
-rw-r--r-- | camera/inc/CameraHal.h | 5 |
3 files changed, 30 insertions, 2 deletions
diff --git a/camera/CameraHal.cpp b/camera/CameraHal.cpp index a345e64..2a1cf25 100644 --- a/camera/CameraHal.cpp +++ b/camera/CameraHal.cpp @@ -4157,12 +4157,21 @@ void CameraHal::initDefaultParameters() // TI extensions for enable/disable algos // Hadcoded for now +#ifdef OMAP_TUNA + p.set(TICameraParameters::KEY_ALGO_FIXED_GAMMA, android::CameraParameters::FALSE); + p.set(TICameraParameters::KEY_ALGO_NSF1, android::CameraParameters::FALSE); + p.set(TICameraParameters::KEY_ALGO_NSF2, android::CameraParameters::FALSE); + p.set(TICameraParameters::KEY_ALGO_SHARPENING, android::CameraParameters::FALSE); + p.set(TICameraParameters::KEY_ALGO_THREELINCOLORMAP, android::CameraParameters::FALSE); + p.set(TICameraParameters::KEY_ALGO_GIC, android::CameraParameters::FALSE); +#else p.set(TICameraParameters::KEY_ALGO_FIXED_GAMMA, android::CameraParameters::TRUE); p.set(TICameraParameters::KEY_ALGO_NSF1, android::CameraParameters::TRUE); p.set(TICameraParameters::KEY_ALGO_NSF2, android::CameraParameters::TRUE); p.set(TICameraParameters::KEY_ALGO_SHARPENING, android::CameraParameters::TRUE); p.set(TICameraParameters::KEY_ALGO_THREELINCOLORMAP, android::CameraParameters::TRUE); p.set(TICameraParameters::KEY_ALGO_GIC, android::CameraParameters::TRUE); +#endif LOG_FUNCTION_NAME_EXIT; } diff --git a/camera/OMXCameraAdapter/OMXCapabilities.cpp b/camera/OMXCameraAdapter/OMXCapabilities.cpp index a21cc20..b339768 100644 --- a/camera/OMXCameraAdapter/OMXCapabilities.cpp +++ b/camera/OMXCameraAdapter/OMXCapabilities.cpp @@ -191,9 +191,14 @@ const CapPixelformat OMXCameraAdapter::mPixelformats [] = { { OMX_COLOR_FormatCbYCrY, android::CameraParameters::PIXEL_FORMAT_YUV422I }, { OMX_COLOR_FormatYUV420SemiPlanar, android::CameraParameters::PIXEL_FORMAT_YUV420SP }, { OMX_COLOR_Format16bitRGB565, android::CameraParameters::PIXEL_FORMAT_RGB565 }, +#if 0 /*def OMAP_TUNA*/ + { OMX_COLOR_FormatRawBayer10bit, android::CameraParameters::PIXEL_FORMAT_BAYER_RGGB }, + { OMX_COLOR_FormatYUV420SemiPlanar, android::CameraParameters::PIXEL_FORMAT_YUV420P }, +#else { OMX_COLOR_FormatYUV420SemiPlanar, android::CameraParameters::PIXEL_FORMAT_YUV420P }, { OMX_COLOR_FormatUnused, TICameraParameters::PIXEL_FORMAT_UNUSED }, { OMX_COLOR_FormatRawBayer10bit, android::CameraParameters::PIXEL_FORMAT_BAYER_RGGB }, +#endif }; const userToOMX_LUT OMXCameraAdapter::mFrameLayout [] = { @@ -969,6 +974,11 @@ status_t OMXCameraAdapter::insertImageFormats(CameraProperties::Properties* para #endif if ( NO_ERROR == ret ) { +#ifdef OMAP_TUNA + //jpeg is not supported in (our) OMX capabilies + strncat(supported, PARAM_SEP, MAX_PROP_VALUE_LENGTH - 1); + strncat(supported, android::CameraParameters::PIXEL_FORMAT_JPEG, MAX_PROP_VALUE_LENGTH - 1); +#endif params->set(CameraProperties::SUPPORTED_PICTURE_FORMATS, supported); } @@ -1595,13 +1605,17 @@ status_t OMXCameraAdapter::insertRaw(CameraProperties::Properties* params, OMX_T LOG_FUNCTION_NAME; memset(supported, '\0', sizeof(supported)); -#ifndef OMAP_TUNA +#ifdef OMAP_TUNA + sprintf(supported,"%d",int(caps.tImageResRange.nWidthMax)); +#else sprintf(supported,"%d",int(caps.uSenNativeResWidth)); #endif params->set(CameraProperties::RAW_WIDTH, supported); memset(supported, '\0', sizeof(supported)); -#ifndef OMAP_TUNA +#ifdef OMAP_TUNA + sprintf(supported,"%d",int(caps.tImageResRange.nHeightMax)); +#else if (caps.bMechanicalMisalignmentSupported) { sprintf(supported,"%d",int(caps.uSenNativeResHeight) * 2); } else { diff --git a/camera/inc/CameraHal.h b/camera/inc/CameraHal.h index d20db1e..f1b013e 100644 --- a/camera/inc/CameraHal.h +++ b/camera/inc/CameraHal.h @@ -63,8 +63,13 @@ #define MIN_WIDTH 640 #define MIN_HEIGHT 480 +#ifdef OMAP_TUNA +#define PICTURE_WIDTH 2592 /* 5mp - 2560. 8mp - 3280 */ /* Make sure it is a multiple of 16. */ +#define PICTURE_HEIGHT 1944 /* 5mp - 2048. 8mp - 2464 */ /* Make sure it is a multiple of 16. */ +#else #define PICTURE_WIDTH 3264 /* 5mp - 2560. 8mp - 3280 */ /* Make sure it is a multiple of 16. */ #define PICTURE_HEIGHT 2448 /* 5mp - 2048. 8mp - 2464 */ /* Make sure it is a multiple of 16. */ +#endif #define PREVIEW_WIDTH 176 #define PREVIEW_HEIGHT 144 #define PIXEL_FORMAT V4L2_PIX_FMT_UYVY |