这边文章记录的是1280x800=1.6屏幕分辨率预览窗口大小,sensor预览实际出图为4656x3496。

(1)App设置不同的预览Size的Log分析

(A)预览Size=960x720=1.333(Surface窗口设置为4:3)——Hal层会进行resize成1280x976

//config
mtkcam-dev3-hidl: [0-hidl-session::configureStreams_3_6] +
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 0, .streamType = OUTPUT, .width = 960, .height = 720, .format = IMPLEMENTATION_DEFINED, .usage = CPU_READ_NEVER | CPU_WRITE_NEVER | GPU_TEXTURE (0x100), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | TRANSFER_UNSPECIFIED | RANGE_UNSPECIFIED (0), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 0}
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 1, .streamType = OUTPUT, .width = 4608, .height = 3456, .format = BLOB, .usage = CPU_READ_NEVER | CPU_READ_RARELY | CPU_READ_OFTEN | CPU_WRITE_NEVER (0x3), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | STANDARD_BT601_625 | TRANSFER_UNSPECIFIED | TRANSFER_LINEAR | TRANSFER_SRGB | TRANSFER_SMPTE_170M | RANGE_UNSPECIFIED | RANGE_FULL | V0_JFIF (0x8c20000), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 24346616}
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 2, .streamType = OUTPUT, .width = 192, .height = 144, .format = YCBCR_420_888, .usage = CPU_READ_NEVER | CPU_READ_RARELY | CPU_READ_OFTEN | CPU_WRITE_NEVER (0x3), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | STANDARD_BT601_625 | TRANSFER_UNSPECIFIED | TRANSFER_LINEAR | TRANSFER_SRGB | TRANSFER_SMPTE_170M | RANGE_UNSPECIFIED | RANGE_FULL | V0_JFIF (0x8c20000), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 0}
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] operationMode=0
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:0 type:OUT (w,h) = (960,720) format:34 usage:0x100 dataSpace:0 rotation:0 physicalCameraId: bufferSize:0
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:1 type:OUT (w,h) = (4608,3456) format:33 usage:0x3 dataSpace:8c20000 rotation:0 physicalCameraId: bufferSize:1737ff8
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:2 type:OUT (w,h) = (192,144) format:35 usage:0x3 dataSpace:8c20000 rotation:0 physicalCameraId: bufferSize:0//预览窗口
CamAp_PreviewManager: updatePreviewSize: new size (960 , 720 ) current size (0 , 0 )
CamAp_PreviewTextureView: previewWidth = 800, previewHeight = 1066, mAspectRatio = 1.3333333333333333//P1HwPolicy
mtkcam-P1HwSettingPolicy: [configP1HwSetting] max_rrzo_size: target size(2560x1922)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] maxYuvStreamSize is too small(960x720)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] maxYuvStreamSize set rrzo to 1280x960
mtkcam-P1HwSettingPolicy: [configP1HwSetting] sensor size: target size(4656x3496)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] target rrzo stream: target size(1280x961)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] eis lower bound limitation: target size(1280x962)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] preview upper bound limitation: target size(1280x962)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] rrzo size(1280x962)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] sensor size upper bound limitation: target size(1280x976)
mtkcam-P1HwSettingPolicy: aligned rrzo size(1280x976)//Hal resize
mtkcam-P1HwSettingPolicy: [queryRecommendResizeMaxRatio] Resize-Ratio-Percentage 25 for isp quality
MtkCam/HwInfoHelper: [querySupportResizeRatio] Support Resize-Ratio-Percentage: 25
MtkCam/HwInfoHelper: [alignRrzoHwLimitation] exceeding sensor size, modified size: 1280x976, original target size: 1280x976, crop size: 4656x3496
MtkCam/HwInfoHelper: [alignPass1HwLimitation] rrzo size 1280x976, stride 2400//P1Node
MtkCam/P1NodeImp: [setupAction] [Cam::0 R5 S5 E5 D2 O2 #1] [P1::ENQ][Num Q:5 M:5 F:4 R:4 @3][Type:1 Out:x15 Rec:x0 Raw:1 Cap:0 Exe:1 Flush:x0] [Exp:3068000ns] [MetaCtrl][SCALER_CROP(1) (0,0_4656x3496) ][SENSOR_CROP(0)][RESIZER_SET(0)]
MtkCam/P1NodeImp: [releaseAction] [Cam::0 R6 S6 E5 D3 O2 #1] [P1::DEQ][Num Q:3 M:3 F:2 R:2 @0][Type:1 Out:x15 Rec:x0 Raw:1 Cap:0 Exe:3 Flush:x0] job(0/1) IMG(pure) RRZ0(0-0-4656x3496)(0-0-1280x976)(1280x976) T-ns(EXP: 0)(Src:0)(SOF: m_1078259426000 b_22763963455000)(SS: 1078259426000) ExpExtend(0, 0)Q(SensorTs:1078

(B)预览Size=1600x1200=1.333(Surface窗口设置为4:3)——Hal层会进行resize成1600x1216

//config
10-27 06:09:30.267   940   940 D mtkcam-dev3-hidl: [0-hidl-session::configureStreams_3_6] +
10-27 06:09:30.267   940   940 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 0, .streamType = OUTPUT, .width = 1600, .height = 1200, .format = IMPLEMENTATION_DEFINED, .usage = CPU_READ_NEVER | CPU_WRITE_NEVER | GPU_TEXTURE (0x100), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | TRANSFER_UNSPECIFIED | RANGE_UNSPECIFIED (0), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 0}
10-27 06:09:30.267   940   940 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 1, .streamType = OUTPUT, .width = 4608, .height = 3456, .format = BLOB, .usage = CPU_READ_NEVER | CPU_READ_RARELY | CPU_READ_OFTEN | CPU_WRITE_NEVER (0x3), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | STANDARD_BT601_625 | TRANSFER_UNSPECIFIED | TRANSFER_LINEAR | TRANSFER_SRGB | TRANSFER_SMPTE_170M | RANGE_UNSPECIFIED | RANGE_FULL | V0_JFIF (0x8c20000), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 24346616}
10-27 06:09:30.267   940   940 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 2, .streamType = OUTPUT, .width = 192, .height = 144, .format = YCBCR_420_888, .usage = CPU_READ_NEVER | CPU_READ_RARELY | CPU_READ_OFTEN | CPU_WRITE_NEVER (0x3), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | STANDARD_BT601_625 | TRANSFER_UNSPECIFIED | TRANSFER_LINEAR | TRANSFER_SRGB | TRANSFER_SMPTE_170M | RANGE_UNSPECIFIED | RANGE_FULL | V0_JFIF (0x8c20000), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 0}
10-27 06:09:30.267   940   940 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] operationMode=0
10-27 06:09:30.267   940   940 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:0 type:OUT (w,h) = (1600,1200) format:34 usage:0x100 dataSpace:0 rotation:0 physicalCameraId: bufferSize:0
10-27 06:09:30.267   940   940 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:1 type:OUT (w,h) = (4608,3456) format:33 usage:0x3 dataSpace:8c20000 rotation:0 physicalCameraId: bufferSize:1737ff8
10-27 06:09:30.267   940   940 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:2 type:OUT (w,h) = (192,144) format:35 usage:0x3 dataSpace:8c20000 rotation:0 physicalCameraId: bufferSize:0//预览窗口
CamAp_PreviewManager: updatePreviewSize: new size (1600 , 1200 ) current size (0 , 0 )
CamAp_PreviewTextureView: previewWidth = 800, previewHeight = 1066, mAspectRatio = 1.3333333333333333//P1HwPolicy
mtkcam-P1HwSettingPolicy: [configP1HwSetting] max_rrzo_size: target size(2560x1922)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] sensor size: target size(4656x3496)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] target rrzo stream: target size(1600x1201)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] eis lower bound limitation: target size(1600x1202)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] preview upper bound limitation: target size(1600x1202)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] rrzo size(1600x1202)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] sensor size upper bound limitation: target size(1600x1216)
mtkcam-P1HwSettingPolicy: aligned rrzo size(1600x1216)//Hal resize
mtkcam-P1HwSettingPolicy: [queryRecommendResizeMaxRatio] Resize-Ratio-Percentage 25 for isp quality
MtkCam/HwInfoHelper: [querySupportResizeRatio] Support Resize-Ratio-Percentage: 25
MtkCam/HwInfoHelper: [alignRrzoHwLimitation] exceeding sensor size, modified size: 1600x1216, original target size: 1600x1216, crop size: 4656x3496
MtkCam/HwInfoHelper: [alignPass1HwLimitation] rrzo size 1600x1216, stride 3008//P1Node
MtkCam/P1NodeImp: [setupAction] [Cam::0 R5 S5 E5 D2 O2 #1] [P1::ENQ][Num Q:5 M:5 F:4 R:4 @3][Type:1 Out:x15 Rec:x0 Raw:1 Cap:0 Exe:1 Flush:x0] [Exp:49995000ns] [MetaCtrl][SCALER_CROP(1) (0,0_4656x3496) ][SENSOR_CROP(0)][RESIZER_SET(0)]
MtkCam/P1NodeImp: [releaseAction] [Cam::0 R6 S6 E5 D3 O2 #1] [P1::DEQ][Num Q:3 M:3 F:2 R:2 @0][Type:1 Out:x15 Rec:x0 Raw:1 Cap:0 Exe:3 Flush:x0] job(0/1) IMG(pure) RRZ0(0-0-4656x3496)(0-0-1600x1216)(1600x1216) T-ns(EXP: 0)(Src:0)(SOF: m_1673252407000 b_23358956441000)(SS: 1673252407000) ExpExtend(0, 0)Q(SensorTs:16

(C)预览Size=1280x798=1.604(Surface窗口设置为4:3)——Hal层会进行resize成1280x976

//config
11-23 17:17:33.012   946  1133 D mtkcam-dev3-hidl: [0-hidl-session::configureStreams_3_6] +
11-23 17:17:33.012   946  1133 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 0, .streamType = OUTPUT, .width = 1280, .height = 798, .format = IMPLEMENTATION_DEFINED, .usage = CPU_READ_NEVER | CPU_WRITE_NEVER | GPU_TEXTURE (0x100), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | TRANSFER_UNSPECIFIED | RANGE_UNSPECIFIED (0), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 0}
11-23 17:17:33.012   946  1133 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 1, .streamType = OUTPUT, .width = 4608, .height = 3456, .format = BLOB, .usage = CPU_READ_NEVER | CPU_READ_RARELY | CPU_READ_OFTEN | CPU_WRITE_NEVER (0x3), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | STANDARD_BT601_625 | TRANSFER_UNSPECIFIED | TRANSFER_LINEAR | TRANSFER_SRGB | TRANSFER_SMPTE_170M | RANGE_UNSPECIFIED | RANGE_FULL | V0_JFIF (0x8c20000), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 24346616}
11-23 17:17:33.012   946  1133 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 2, .streamType = OUTPUT, .width = 192, .height = 144, .format = YCBCR_420_888, .usage = CPU_READ_NEVER | CPU_READ_RARELY | CPU_READ_OFTEN | CPU_WRITE_NEVER (0x3), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | STANDARD_BT601_625 | TRANSFER_UNSPECIFIED | TRANSFER_LINEAR | TRANSFER_SRGB | TRANSFER_SMPTE_170M | RANGE_UNSPECIFIED | RANGE_FULL | V0_JFIF (0x8c20000), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 0}
11-23 17:17:33.012   946  1133 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] operationMode=0
11-23 17:17:33.012   946  1133 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:0 type:OUT (w,h) = (1280,798) format:34 usage:0x100 dataSpace:0 rotation:0 physicalCameraId: bufferSize:0
11-23 17:17:33.012   946  1133 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:1 type:OUT (w,h) = (4608,3456) format:33 usage:0x3 dataSpace:8c20000 rotation:0 physicalCameraId: bufferSize:1737ff8
11-23 17:17:33.012   946  1133 D mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:2 type:OUT (w,h) = (192,144) format:35 usage:0x3 dataSpace:8c20000 rotation:0 physicalCameraId: bufferSize:0//预览窗口
CamAp_PreviewManager: updatePreviewSize: new size (1280 , 798 ) current size (0 , 0 )
CamAp_PreviewTextureView: previewWidth = 800, previewHeight = 1066, mAspectRatio = 1.3333333333333333//P1HwPolicy
mtkcam-P1HwSettingPolicy: [configP1HwSetting] max_rrzo_size: target size(2560x1922)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] sensor size: target size(4656x3496)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] target rrzo stream: target size(1280x961)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] eis lower bound limitation: target size(1280x962)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] preview upper bound limitation: target size(1280x962)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] rrzo size(1280x962)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] sensor size upper bound limitation: target size(1280x976)
mtkcam-P1HwSettingPolicy: aligned rrzo size(1280x976)//Hal resize
mtkcam-P1HwSettingPolicy: [queryRecommendResizeMaxRatio] Resize-Ratio-Percentage 25 for isp quality
MtkCam/HwInfoHelper: [querySupportResizeRatio] Support Resize-Ratio-Percentage: 25
MtkCam/HwInfoHelper: [alignRrzoHwLimitation] exceeding sensor size, modified size: 1280x976, original target size: 1280x976, crop size: 4656x3496
MtkCam/HwInfoHelper: [alignPass1HwLimitation] rrzo size 1280x976, stride 2400//P1Node
MtkCam/P1NodeImp: [setupAction] [Cam::0 R5 S5 E5 D2 O2 #1] [P1::ENQ][Num Q:5 M:5 F:4 R:4 @3][Type:1 Out:x15 Rec:x0 Raw:1 Cap:0 Exe:1 Flush:x0] [Exp:33333000ns] [MetaCtrl][SCALER_CROP(1) (0,0_4656x3496) ][SENSOR_CROP(0)][RESIZER_SET(0)]
MtkCam/P1NodeImp: [releaseAction] [Cam::0 R6 S6 E5 D3 O2 #1] [P1::DEQ][Num Q:3 M:3 F:2 R:2 @0][Type:1 Out:x15 Rec:x0 Raw:1 Cap:0 Exe:3 Flush:x0] job(0/1) IMG(pure) RRZ0(0-0-4656x3496)(0-0-1280x976)(1280x976) T-ns(EXP: 0)(Src:0)(SOF: m_1150300512000 b_1150300499000)(SS: 1150300512000) ExpExtend(0, 0)Q(SensorTs:11503

(2)MTK平台RrzoHwLimit限制

//vendor/mediatek/proprietary/hardware/mtkcam/utils/hw/HwInfoHelper.cppMBOOL
HwInfoHelper::
alignRrzoHwLimitation(MSize const targetSize,MSize const sensorSize,MSize& result,MUINT32 const recommendResizeRatio
) const
{return  mpImp->alignRrzoHwLimitation(targetSize, sensorSize, result, recommendResizeRatio);
}MBOOL
IMPL_CLASSNAME::
alignRrzoHwLimitation(MSize const targetSize,MSize const sensorSize,MSize& result,MUINT32 const recommendResizeRatio
) const
{MUINT32 SupportRatio = 40;bool scaledUp = false;result = targetSize;// figure out the crop region sizeMSize usedRegionSize;usedRegionSize.w = sensorSize.w;usedRegionSize.h = sensorSize.h;// check if the edges are beyond hardware scale limitation(crop region edge * scale ratio)// scale up to cope with the limitation, if neededquerySupportResizeRatio(SupportRatio);//这里可以调整SupportRatio,SupportRatio越大表示Hal对的Limit限制越宽松,Sensor Size进行Resize后的值也越大,画面越清晰int flag = property_get_int32("ro.boot.flag.device", 0);MY_LOGD("SupportRatio = %d, recommendResizeRatio = %d, ctsFlag = %d", SupportRatio,recommendResizeRatio,flag);if(flag == 0){SupportRatio = 60;}else{if (recommendResizeRatio > SupportRatio) {MY_LOGD("Modify resize ratio (%u) to (%u) for isp quality", SupportRatio, recommendResizeRatio);SupportRatio = recommendResizeRatio;}}#define ROUND_UP(x, div) (((x) + (div - 1)) / div)
#define ALIGN16(x) x = (((x) + 15) & ~(15))// check the widthif( (uint32_t)result.w < ROUND_UP(usedRegionSize.w * SupportRatio, 100) ){result = MSize(ROUND_UP(usedRegionSize.w * SupportRatio, 100),result.h * ROUND_UP(usedRegionSize.w * SupportRatio, 100) / result.w);scaledUp = true;ALIGN16(result.w);ALIGN16(result.h);MY_LOGD("width is beyond scale limitation, modified size: %dx%d, original target size: %dx%d, crop size: %dx%d", result.w, result.h, targetSize.w, targetSize.h, usedRegionSize.w, usedRegionSize.h);}// check the heightif( (uint32_t)result.h < ROUND_UP(usedRegionSize.h * SupportRatio, 100) ){result = MSize(result.w * ROUND_UP(usedRegionSize.h * SupportRatio, 100) / result.h,ROUND_UP(usedRegionSize.h * SupportRatio, 100));scaledUp = true;ALIGN16(result.w);ALIGN16(result.h);MY_LOGD("height is beyond scale limitation, modified size: %dx%d, original target size: %dx%d, crop size: %dx%d", result.w, result.h, targetSize.w, targetSize.h, usedRegionSize.w, usedRegionSize.h);}if( !scaledUp ){// we don't attempt to scale down if scaledUp is true,// since it means at least one edge is at the limitMSize temp = result;if( temp.w > sensorSize.w ){temp = MSize(sensorSize.w,temp.h * sensorSize.w / temp.w);}if( temp.h > sensorSize.h ){temp = MSize(temp.w * sensorSize.h / temp.h,sensorSize.h);}if( (uint32_t)temp.w > usedRegionSize.w * SupportRatio / 100 && (uint32_t)temp.h > usedRegionSize.h * SupportRatio / 100 ){result = temp;MY_LOGD("exceeding sensor size, modified size: %dx%d, original target size: %dx%d, crop size: %dx%d", result.w, result.h, targetSize.w, targetSize.h, usedRegionSize.w, usedRegionSize.h);}}
#undef ROUND_UP
#undef ALIGN16return MTRUE;
}

同样的960x720的预览Size,会出现P1Node Resize后的值不一样,可查看如下Log:

//config
mtkcam-dev3-hidl: [0-hidl-session::configureStreams_3_6] +
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 0, .streamType = OUTPUT, .width = 960, .height = 720, .format = IMPLEMENTATION_DEFINED, .usage = CPU_READ_NEVER | CPU_WRITE_NEVER | GPU_TEXTURE (0x100), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | TRANSFER_UNSPECIFIED | RANGE_UNSPECIFIED (0), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 0}
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 1, .streamType = OUTPUT, .width = 4608, .height = 3456, .format = BLOB, .usage = CPU_READ_NEVER | CPU_READ_RARELY | CPU_READ_OFTEN | CPU_WRITE_NEVER (0x3), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | STANDARD_BT601_625 | TRANSFER_UNSPECIFIED | TRANSFER_LINEAR | TRANSFER_SRGB | TRANSFER_SMPTE_170M | RANGE_UNSPECIFIED | RANGE_FULL | V0_JFIF (0x8c20000), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 24346616}
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] {.v3_2 = {.id = 2, .streamType = OUTPUT, .width = 192, .height = 144, .format = YCBCR_420_888, .usage = CPU_READ_NEVER | CPU_READ_RARELY | CPU_READ_OFTEN | CPU_WRITE_NEVER (0x3), .dataSpace = UNKNOWN | STANDARD_UNSPECIFIED | STANDARD_BT601_625 | TRANSFER_UNSPECIFIED | TRANSFER_LINEAR | TRANSFER_SRGB | TRANSFER_SMPTE_170M | RANGE_UNSPECIFIED | RANGE_FULL | V0_JFIF (0x8c20000), .rotation = ROTATION_0}, .physicalCameraId = "", .bufferSize = 0}
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] operationMode=0
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:0 type:OUT (w,h) = (960,720) format:34 usage:0x100 dataSpace:0 rotation:0 physicalCameraId: bufferSize:0
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:1 type:OUT (w,h) = (4608,3456) format:33 usage:0x3 dataSpace:8c20000 rotation:0 physicalCameraId: bufferSize:1737ff8
mtkcam-dev3-hidl: [0-hidl-session::convertStreamConfigurationFromHidl] streamId:2 type:OUT (w,h) = (192,144) format:35 usage:0x3 dataSpace:8c20000 rotation:0 physicalCameraId: bufferSize:0//预览窗口
CamAp_PreviewManager: updatePreviewSize: new size (960 , 720 ) current size (0 , 0 )
CamAp_PreviewTextureView: previewWidth = 800, previewHeight = 1066, mAspectRatio = 1.3333333333333333//P1HwPolicy
mtkcam-P1HwSettingPolicy: [configP1HwSetting] max_rrzo_size: target size(2560x1922)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] maxYuvStreamSize is too small(960x720)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] maxYuvStreamSize set rrzo to 1280x960
mtkcam-P1HwSettingPolicy: [configP1HwSetting] sensor size: target size(4656x3496)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] target rrzo stream: target size(1280x961)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] eis lower bound limitation: target size(1280x962)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] preview upper bound limitation: target size(1280x962)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] rrzo size(1280x962)
mtkcam-P1HwSettingPolicy: [configP1HwSetting] sensor size upper bound limitation: target size(1280x976)
mtkcam-P1HwSettingPolicy: aligned rrzo size(1280x976)//Hal resize
mtkcam-P1HwSettingPolicy: [queryRecommendResizeMaxRatio] Resize-Ratio-Percentage 25 for isp quality
MtkCam/HwInfoHelper: [querySupportResizeRatio] Support Resize-Ratio-Percentage: 25
MtkCam/HwInfoHelper: [alignRrzoHwLimitation] SupportRatio = 25, recommendResizeRatio = 25, flag = 0
//这里的SupportRatio被设置成60(SupportRatio=60)
MtkCam/HwInfoHelper: [alignRrzoHwLimitation] width is beyond scale limitation, modified size: 2800x2144, original target size: 1280x976, crop size: 4656x3496
MtkCam/HwInfoHelper: [alignPass1HwLimitation] rrzo size 2800x2144, stride 5264//P1Node
MtkCam/P1NodeImp: [setupAction] [Cam::0 R5 S5 E5 D1 O1 #1] [P1::ENQ][Num Q:5 M:5 F:4 R:4 @3][Type:1 Out:x15 Rec:x0 Raw:1 Cap:0 Exe:1 Flush:x0] [Exp:12013000ns] [MetaCtrl][SCALER_CROP(1) (0,0_4656x3496) ][SENSOR_CROP(0)][RESIZER_SET(0)]
MtkCam/P1NodeImp: [releaseAction] [Cam::0 R6 S6 E5 D2 O1 #1] [P1::DEQ][Num Q:2 M:2 F:1 R:1 @0][Type:1 Out:x15 Rec:x0 Raw:1 Cap:0 Exe:3 Flush:x0] job(0/1) IMG(pure) RRZ0(0-0-4656x3496)(0-0-2800x2144)(2800x2144) T-ns(EXP: 0)(Src:0)(SOF: m_284036834000 b_284036828000)(SS: 284036834000) ExpExtend(0, 0)Q(SensorTs:284039

可以看到如上虽然App下的Preview Size为960x720,但是实际P1将Sensor Preview Size进行了Resize后为2800x2144,不在是之前的1280x976。

MTK平台设置不同的预览Size相关推荐

  1. .NET环境下有关打印页面设置、打印机设置、打印预览对话框的实现

    原文:.NET环境下有关打印页面设置.打印机设置.打印预览对话框的实现 我个人认为,开发MIS,首先就得解决网格的问题,而开发工具为我们提供了如DataGrid.MSHFlexGrid的控件.其次,是 ...

  2. NET环境下有关打印页面设置、打印机设置、打印预览对话框的实现-

    到网上一搜,有很多关于打印页面设置值怎么老是变.自定义纸张和连续走纸的问题.有很多说法,有些说是VS.NET的bug,有的说必须用API,还有的说...     其实,是我们自己没有研究透,这里给一些 ...

  3. android xml显示调整,AndroidStudio中怎么设置xml与预览同时显示?

    Android Studio做程序开发的时候,为了看程序运行结果和修改错误的地方,经常需要修改xml后就切换到预览去查看效果.经常切换很烦,想要同时显示xml与预览界面,下面我们就来看看详细的教程. ...

  4. 使用3D Max里面自带的门,怎么设置动画并预览

    物体怎么添加门啊?就是怎么开门和关门 @长沙-魁梧的大叔 墙上添加门?还是您自己的柜子要加门? 自己的柜子 不是墙上 那就要自己做柜子门的模型动画了 用什么做?3D max? 一般是的,你喜欢用其它编 ...

  5. .NET环境下有关打印页面设置、打印机设置、打印预览对话框的实现与应用(1)

    From: http://blog.csdn.net/flygoldfish/article/details/77208 .NET环境下有关打印页面设置.打印机设置.打印预览对话框的实现 我个人认为, ...

  6. .Net环境下有关打印页面设置、打印机设置、打印预览对话框的实现(开源)---转

    作者:周方勇 我个人认为,开发MIS,首先就得解决网格的问题,而开发工具为我们提供了如DataGrid.MSHFlexGrid的控件.其次,是打印的问题,将业务单据与数据报表打印出来.可想而知,即使一 ...

  7. 国标平台对接成功,预览失败,下级双网域设置错误

    上级域地址:10.1.1.8  海康平台 下级域地址:10.4.2.251   某家平台 平台注册成功后,预览无图像,抓包结果如下: 首先,下级无tcp流包. 再次,检查到下级200ok回包,注意到c ...

  8. WebBrowser 打印设置,打印预览,去页眉和页脚

    WebBrowser是IE内置的浏览器控件,无需用户下载. 一.WebBrowser控件 <object ID='WebBrowser' WIDTH=0 HEIGHT=0 CLASSID='CL ...

  9. 网页打印问题,打印设置,打印预览,打印分页,纵打,横打及页面的边距

    1.控制"纵打". 横打"和"页面的边距 (1) <object  id="factory"  style="display ...

最新文章

  1. IBM RSA(Rational Software Architect)试用版下载地址
  2. PyQt5初级教程--PyQt5中的部件II[9/13]
  3. 重构碎片化知识_知识碎片化时代,如何妙用思维导图,提高你的学习效率(含福利)...
  4. Print out Android kernel log
  5. python数据分析笔记——数据加载与整理
  6. 你怕是对MD5算法有误解
  7. SAS笔记(2) RETAIN语句
  8. 用较早版本的APIs实现抽象类
  9. redux 函数式组件_如何从函数式编程的角度学习Redux
  10. 如何在.NET Core中创建API
  11. linux c 获取文件数量
  12. 管理:权力是用来完成责任的
  13. 2万字硬核剖析网页自定义字体解析(css样式表解析、字体点阵图绘制与本地图像识别等)
  14. Linux SD卡驱动开发
  15. NANK南卡降噪耳机和小米蓝牙耳机哪个好?谁更值得入手?
  16. java大数求三角形外心_JAVA求两直线交点和三角形内外心的方法
  17. Opencascade TopoDS_Shape Orientation
  18. linux 同步utc时间吗,中国时区utc在服务器上同步的办法
  19. 使用Unity实现时光倒流
  20. KEIL工程文件打不开

热门文章

  1. UC/OS的46个系统函数
  2. OpenJudge1.5.24正常血压
  3. 刚构桥的优缺点_刚构桥特点
  4. V-SYNC什么意思
  5. 泛微OA e-cology8,9 数据库更改
  6. Tessent shell edt_update / edt clock 时序以及组合
  7. CSS3边框及盒子阴影
  8. 葡萄牙—C罗:实力派的蜕变
  9. 导航路径规划之一 路网模型
  10. PICE(5):MongoDBStreaming - gRPC -MGO Service