Skip to main content

ISP PQ Tool User Guide

Overview

This document mainly introduces SpacemiT image tuning, including

  • The tuning tool
  • Calibration plugins
  • Image analysis tool (VRF Viewer)
  • Platform debugging support

Abbreviations

NameDescription
ISPImage Signal Process
VRF / vrfRAW image with information at the end
BLCBlack Level Correction
LSCLens Shading Correction
AWBAuto White Balance
AECAuto Exposure Control
AFAuto Focus
OTPOne Time Programmable
AEMAuto Exposure Monitor
AFMAuto Focus Monitor
CCMColor Correction Matrix
CTColor Temperature
BPCBad Pixel Correction
CACColor Aberration Correction
LTMLocal Tone Mapping
PDCPhase Detection Compensation
PDFPhase Detection Correction
PDAFPhase Detection Auto Focus
SESpecial Effect
EISElectronic Image Stabilization
CDAFContrast Detection Auto Focus
FVFocus Value
SADSum of absolute difference
ROIRegion of Interest
NRNoise Reduction
EEEdge Enhancement
HDRHigh Dynamic Range
QnAccuracy, 2n is double

Tuning Tool Overview

Tuning Tool Architecture

PC-Side Tuning Tool Installation

The tuning software is a portable compressed package — no installation is required. Simply extract the file named AsrIspToolVX.X.X.X.rar to use it. The tool can be downloaded from the following link: https://archive.spacemit.com/tools/isp-tunning/

After extraction, the following files are included:

Debugging Environment Setup

Hardware and Software Requirements

  • Hardware Environment

    • Desktop or laptop computer
    • 1GHz or faster processor
    • 1GB RAM (32-bit) / 2GB RAM (64-bit)
    • At least 10GB of available hard disk space
    • Screen resolution of 1920 × 1080 or higher
    • USB port
    • Terminal device integrated with ASR ISP
  • Software Environment

    • Windows 7 64-bit or later version of the operating system

Device Connection

AsrIspTool connects to the terminal device via USB and communicates with the device through ADB.

Note. Before connecting, the device must first start the tuning server thread, i.e., start the camera.

Basic Operations of the Tuning Tool

Main Interface of the Tuning Tool

Double-click AsrIspTool.exe to launch the tuning tool. The main interface is shown below:

  • Menu: Functional Menu Area

    • Open: Open parameter file.
    • Save: Save parameter file.
    • Save As: Save parameter file under a new name.
    • IP Address: Reserved.
    • ADB (SN): Connect to the terminal device via ADB; supports manual input of ADB serial number.
    • Connect: Connect to the terminal device.
    • View: Switch between single-window, horizontal split, and vertical split display modes.
    • Format: Toggle between decimal and hexadecimal display.
    • Display: Switch between matrix editing, row editing, and column editing modes.
    • Plugins: Plugins.
    • Frequency: Adjust parameter refresh rate.
    • Capture: Capture VRF data (vrf).
    • Register: ISP register read/write tool.
    • I2C: I2C read/write tool.
    • Push: Reserved.
    • Transfer: Reserved.
    • VRF: Image viewer tool.
    • DNG: Reserved.
  • Module list & Filter list: Module and filter list

  • Parameter list: List of parameter

  • Log: Log area

Basic Online Operations

Connecting to the Terminal Device

After launching the tool, select ADB (SN) and click Connect. Once the connection is successful, the tool will automatically read the parameters of all current modules and periodically refresh the read-only parameters every 500 ms (this interval can be adjusted via the Frequency option in the menu). If multiple terminal devices are connected to the PC, you can specify the serial number manually.

To enable periodic refreshing of read-write parameters as well, check the AutoUpdate option in the upper-right corner (Note. Parameters cannot be modified while this option is checked).

To perform a one-time read of all parameters, click the Read button in the upper-right corner.

Note. The ADB connection method is only applicable for projects using the Android system. We primarily use TCP network connections to tune the development board.

Parameter Type Description

  • Adjustable Parameters

    • Parameters that can be checked, for example, m_bAutoCalculateAEMWindow.
    • Editable parameters, for example, m_nPreEndingPercentage.
    • Editable array parameters, for example, m_pSubROIPermil. For two-dimensional arrays, you can switch between matrix, row, and column editing modes.
  • Read-Only (Gray)

    • Read-only parameters, for example, m_nAdjacentLumaSAD.
  • Special Notes

    • After modifying parameters in plugins or the parameter list, the changed content will be highlighted in red. Hovering the mouse over it will display the original value.

Real-Time Parameter Modification

  1. Expand the module list for the module you want to debug.
  2. Click the desired module in the module list area.
  3. Adjust the parameter value using the slider or by directly editing the value in the parameter list area. The changes take effect immediately.

Capturing VRF Images

  1. Click the Capture button in the menu area.
  2. Select RAW and set the save path.
  3. Click Start Capturing to generate raw images with the .vrf file extension.

Register Read/Write

  1. Click the Register button in the menu area.
  2. Set the Address (register address).
  3. Set the Value (8bit) (register value).
    • Read: Read the register.
    • Write: Write to the register.
  4. Set the Value (32bit) (register value).
    • Read: Read the register.
    • Write: Write to the register.

I2C Read/Write

  1. Click the I2C button in the menu area.
  2. Set the Device ID (I2C device number).
  3. Set the Device Address (slave device address).
  4. Set the Address Bytes (register address byte width).
  5. Set the Register Address (register address).
  6. Set the Value Bytes (register value byte width).
  7. Set the Value (register value).
    • Read: Read the register.
    • Batch Read: Batch read registers by importing a file.
    • Write: Write to the register.
    • Batch Write: Batch write registers by importing a file.

Batch Register Read/Write File Format
The file format should be {Address, Value}. When performing batch register operations, click Batch Read or Batch Write to import the reg_batch.txt file. The results will be displayed in the red log area, and a file with the same name ending in _read.txt will be generated for later review.

Example of Batch Register Read/Write File Format

Saving Parameters

  1. Click the Save button in the menu area.
  2. Choose the path and set a file name.
  3. Click Save to generate the parameter file.

Opening a Local Parameter File

Click the Open button in the menu area, or simply drag the parameter file into the corresponding module in the tool. This operation will directly write the parameters to the hardware.

Basic Offline Operations

Open a Local Parameter File

  • Click the Open button in the menu area, or drag the parameter file into the tool directly.

Modify Parameters

  1. Expand the module list for the module you want to debug.
  2. Click the desired module in the module list area.
  3. Adjust parameter values using the slider or by directly editing the values in the parameter list.
  4. If it is a one-dimensional vector, click the waveform button in the parameter editing interface to enter curve editing mode.

Calibration Plugins

  • Click the Plugins drop-down menu in the menu area to select a plugin.

Save Parameters

  • Click the Save button in the menu area, enter a file name, and the parameters will be saved to a local file

ISP Plugins

This section introduces calibration and tuning for BLC, LSC, AWB, CCM, Curve, Noise, PDC, and PDAF, as well as auxiliary debugging tools like General Information and Raw Preprocessor.

Calibration plugins support both online(connecting device) and offline(importing paqrameter files) modes. The plugin can only be opened when the corresponding Filter parameters are enabled.

BLC Calibration and Tuning

VRF Image Requirements for BLC Calibration

Capture VRF data in a completely dark environment or with the lens fully covered.

BLC Calibration Steps

The BLC calibration interface is shown below:

  1. In the BLC plugin, click Load to import the VRF image.
  2. Select the Pipe ID (optional if not a single pipeline).
  3. Select the Channel ID.
  4. Click Calibrate. The calibration result will be displayed in the Calibrated Result section. If the result is unsatisfactory, you can also manually edit the Result.
  5. Click Update to apply the parameters to the parameter list. If the result is unsatisfactory, click Cancel to recalibrate.

Notes on BLC Calibration

  • The Calibrated Result panel displays the values of 4 channels in both 10-bit and 8-bit formats. When the parameters are saved to a file, they are mapped to 12-bit values.
  • Channel ID: Indicates the BLC parameters corresponding to a specific gain level of 2ᵅ. BLC can be adjusted dynamically with gain, ranging from 1x to 2048x gain, for a total of 12 levels (see the Gain–BlackValue diagram below). The final level, manual, takes effect only when manual mode is enabled; in this mode, BLC does not adjust with gain.

Gain – BlackValue Diagram

Notes on BLC Tuning

BLC parameters are located in CDigitalGainFirmwareFilter.

  • If BLC should not change with gain, set m_bManualMode to 1. In this case, the BLC value is taken from m_pGlobalBlackValueManual.
  • If BLC should change with gain, set m_bManualMode to 0. In this case, the BLC value is taken from m_pGlobalBlackValue.

LSC Calibration and Tuning

VRF Image Requirements for LSC Calibration

Capture several uniformly illuminated images using a diffuse cover over the lens in a lightbox environment (D65, CWF, or A light) or any environment with shading.

LSC Calibration Steps

The LSC calibration interface is shown below:

  1. In the LSC plugin, click Load to import the VRF image.
  2. Select the Pipe ID (optional if not a single pipeline).
  3. Select the Channel ID.
  4. Adjust the compensation ratio using Current Percentage. It is recommended to start with 100%; you can later fine-tune the compensation intensity using strength.
  5. Click Calibrate. The simulated correction result will be displayed in Calibrated Image.
  6. Click Update to apply the parameters to the parameter list. If the result is not satisfactory, click Cancel to recalibrate.

Notes on LSC Calibration

  • Channel ID:
    • 0: Low color temperature compensation table
    • 1: Medium color temperature compensation table
    • 2: High color temperature compensation table
    • manual: Effective when manual mode is enabled; in this mode, LSC does not adjust with color temperature changes.

Notes on LSC Tuning

LSC can be adjusted according to CT or CorrelatedCT (see the CT-LSCProfile diagram below).

  • CT Definition: 256 × AWB_RGain / AWB_BGain (can be obtained via CT info / 4 in the AWB plugin).
  • CorrelatedCT Definition: Correlated color temperature, representing how closely the light emitted by a source matches the blackbody radiation at a certain color temperature.

LSC parameters are located in CLSCFirmwareFilter.

  • If LSC needs to change with color temperature, set an appropriate m_pCTIndex to select the shading table for different color temperatures.
  • Recommended to use: m_nCorrelationCT (read from CCTCalculatorFilter).

Note. LSC interpolation can be based on either the CT result calculated by AWBFilter (read CT in AWB plugin) or the CCT result calculated by CCTCalculatorFilter (read m_nCorrelationCT in WbFirmwareFilter)

CCM and CCT Calibration and Tuning

VRF Image Requirements for CCM Calibration

Capture an image of a 24-color chart in a lightbox environment. The color chart should be as centered and aligned as possible, occupying about 1/9 of the frame. D65, CWF, and A light sources are required.

CCM Calibration Steps

The CCM calibration interface is shown below:

  1. In the CCM plugin, click Load to import the VRF image. The VRF image should be compensated for LSC and PDF (if PD pixels exist) using the Raw Preprocessor plugin.
  2. Select the entire color chart in the image by drawing a box, ensuring all 24 ROIs fall within the color patches. If the image is misaligned or heavily distorted, click Start, check the ROIs you want to adjust individually, and then manually drag the ROIs.
  3. Set the desired saturation for calibration.
  4. Click Calibrate. The calibration simulation result will be displayed in Calibrated Result.
  5. Select the Pipe ID (optional if not a single pipeline).
  6. Select the Channel ID.
  7. Click Update to apply the parameters to the parameter list. If the result is not satisfactory, you can adjust the saturation of individual blocks in the Saturation Table and then recalibrate.

CCT Calibration Steps

The CCM calibration interface is shown below:

  1. The CCT calibration can be performed simultaneously with CCM calibration. CCT requires only A and D65 light sources.
  2. After calibrating CCM with A light, select profile 2850K and click UpdateCTMatrix.
  3. After calibrating CCM with D65 light, select profile 6500K and click UpdateCTMatrix.
  4. The results will automatically update in CCTCalculatorFilter under m_pCTMatrix_low / m_pCTMatrix_high.

Notes on CCM Calibration

  • Use Internal Curve – Calibration: No need to check.
  • Use Internal Curve – Render: No need to check.
  • Use AGTM: Check this option.
  • Target: Keep as D50
  • View Environment: Keep as D50
  • Calibrated Result: Displays the simulated result after calibration.
  • CCM Result: Lists the calibrated color matrix. This can also be manually edited here. Click Set to apply it to the hardware。
  • Channel ID:
    • 0: Low color temperature CCM parameters
    • 1: Medium color temperature CCM parameters
    • 2: High color temperature CCM parameters
    • manual: Effective when manual mode is enabled; CCM does not adjust with color temperature changes.
  • Make DNG Profile: reserved
  • UpdateCTMatrix: Update the CCT matrix
  • SaveImage: Save the rendered image

Notes on CCM Tuning

CCM can be adjusted based on color temperature (see the CCM–Color Temperature Control Curve below).

CCM parameters are located in CColorMatrixFirmwareFilter.

  • If CCM needs to change with color temperature, set an appropriate m_pCTIndex to select the color matrix for different color temperatures.
  • Recommended to use: CorrelatedCT.

Note. CCM interpolation can be based on either the CT result calculated by AWBFilter (read CT in the AWB plugin) or the CCT result calculated by CCTCalculatorFilter (read m_nCorrelationCT in WbFirmwareFilter).

AWB Calibration and Tuning

VRF Image Requirements for AWB White Point Calibration

No additional images are needed for AWB calibration; it can be performed after completing CCT calibration.

AWB White Point Calibration Steps

The AWB calibration interface is shown below:

  1. Open the AWB plugin.
  2. Click Optimize. The calibration parameters will be automatically updated in the parameter interface.

AWB Brightness Calibration

After AE tuning is completed, brightness calibration of the module is required to obtain the Lux value needed by AWB. The calibration steps are as follows:

  1. Place the camera in the lightbox and capture the lightbox wall with the light source set to D65.
  2. Measure the lightbox illuminance using a color temperature illuminance meter and enter the value into m_nCalibSceneLux in the AECFilter.
  3. Read m_nExpIndexLong from AECFilter and enter it into m_nCalibExposureIndex in AECFilter.
  4. Read m_nLumQ16 from AECFilter and enter it into m_nCalibSceneLum in AECFilter.
Parameter NameDescriptionRecommended to TuneSpecial Notes
m_nCalibExposureIndexExposure index for brightness calibrationYes
m_nCalibSceneLumScene brightness for brightness calibrationYes
m_nCalibSceneLuxActual illuminance corresponding to calibration sceneYes
m_nSceneLuxAWB debug parameter, current scene illuminance calculated by AE-Read-Only

AWB Debug

Block Debug Information

When connected to the device, open the AWB plugin. The position of each block will be displayed as a blue dot on the coordinate axis, and the AWB statistics image will be shown as a thumbnail.

You can select a region on the statistics chart (by default, points from all regions are displayed). After selection, only the points within the selected blocks will be shown.

White Points within ROI

Click Show ROI to view the blocks contained within different ROIs. The white blocks are those participating in the white balance calculation, meaning the blocks that fall inside the ROI area. The image below shows the specific affiliation of 32 x 24 blocks to their respective ROIs

Block Weight

Checking auto update will periodically refresh the lux value and statistics chart, and calculate the block weights in real-time.

By adjusting the Weight Percentage slider, you can control the ratio between the actual scene and the blocks participating in the white balance calculation on the debug image.

  • At 0%, the image shows the actual scene.
  • At 100%, it shows the weights of blocks participating in the white balance calculation (weights are referenced in the heatmap).

If set to 100%, the screen may appear completely black, indicating that all blocks have zero weight under the current lux.

Setting Weight Percentage to 100% displays the block weights as a heatmap. You can hover the mouse over any block to see its weight displayed on the right side of the heatmap (debug info is also available in AWB Frameinfo).In the image below, the mouse is selecting block[12][2], which has a weight of 16.

White Balance Gain Position

In the RGB gain panel module, check enabled, and enter RGB gain values in Q12 precision (from debug info CurrentResult). The corresponding white balance gain will be displayed as a blue square in the chromaticity (color temperature) coordinate system. You can zoom in by dragging the mouse from the top-left to the bottom-right, and zoom out by dragging from the bottom-right to the top-left.

The current white balance gain is shown as a red square in the chromaticity coordinate system.

AWB Debug Description

  • Calibration Panel

    • Calibrate Panel
      • Visible: When checked, this ROI will be shown in the chromaticity coordinate system.
      • Enable: When checked, this ROI is enabled for calibration.
    • Calibrate Files Panel
      • Percentage: Proportion of the VRF image to be used for calibration. For example, 20% means the central 20% area of the image will be used, as the center is less affected by shading.
      • Optimize: Performs automatic calibration.
      • Load config: Reserved.
      • Save config: Reserved.
      • Load: Import VRF file.
      • Calibrate: Reserved.
      • Update: Update parameters to the parameter list.
      • Cancel: Cancel parameter updates.
      • ShowROI: Show the white points within each ROI.
  • Debugging Panel

    • Control Panel

      • Pipe ID: Current pipeline ID (selectable when not using a single pipe).
      • Auto Update: Automatically updates the current brightness and statistics window when online (when checked, parameters in the plugin cannot be modified).
      • Manual Lux: Fixes the current brightness.
      • Weight Percentage: Debug parameter to adjust the display of white balance statistic blocks and their weights.
        • 0% shows the statistic blocks;
        • 100% shows a heatmap of block weights.
      • RGB Gain Debug-applied gain, corresponding to the red point in the chromaticity coordinate system.
      • Luminance Boundary: Brightness range (8-bit) of pixels participating in AWB statistics.
      • Valid Number: Minimum number of valid blocks required for white balance calculation, range [0,768]。
      • Correct Limit Panel: Block range limits. Blocks that exceed the limits and fall within the ROI will be remapped in the XY direction.
    • Green Shift Panel

      • Shift Max Weight: Shift weight; multiplied by exposure shift to get the final shift weight. Maximum is 32, which fully biases toward the outdoor gain.
      • Green Number Threshold: Threshold: The number of blocks falling into the "G region"; if within this range, green shift is activated.
      • Outdoor RGB Gain: Target gain for green shift.。
      • Shift Weight: Weight adjusted based on exposure.
    • Luminance Panel

      • Lux: Brightness index.
      • Weight: The weight of the corresponding ROI at the current brightness level.
      • Min / Max: Luminance range (8-bit).
  • Debug Panel

    • RGB Gain Panel

      • enabled: Used to display the white balance gain position in the color temperature coordinate system.
      • RGB: White balance gain.
    • Gain Panel: Debug information. Hovering the mouse over the color temperature coordinate system will display the corresponding debug info.

      • X Y: The XY coordinates of the point on the color temperature coordinate system.。
      • CT: The correlated color temperature (CT) value at the point, which can be used as a reference for LSC and CCM interpolation.
      • RGB: The white balance gain at the point on the color temperature coordinate system.
      • CCTTint: The correlated color temperature and tint at the point, also usable for LSC and CCM interpolation.
      • CCT curve: Displays the CCT curve on the color temperature coordinate system.
      • Vaild only: Displays only the valid statistic blocks on the color temperature coordinate system.
      • Applied Gain: The white balance gain point of the current scene, shown as a red dot on the color temperature coordinate system.。
      • BlockWeight: When hovering the mouse over the statistics image, the corresponding block position and weight are displayed.

Curve Debugging

Curve Debugging Steps

The Curve debugging interface is shown below:

  1. Open the Curve plugin.
  2. Select Pipe ID (applicable if not using a single pipeline).
  3. Select Channel ID.
  4. Move the mouse to the point on the curve you want to adjust, then left-click and drag it to the desired position.
  5. Click Update to apply the parameters to the parameter list. If the result is unsatisfactory, click Cancel to redo the calibration.

Curve Debugging Description

  • Channel ID:
    • BacklightCurveManual: Controls the background brightness. It is recommended to keep the curve unchanged and only adjust the strength.
    • ContrastCurveManual: Controls the contrast. It is recommended to keep the curve unchanged and only adjust the strength.
    • GTMCurve0: Curve used when the gain equals m_pGainIndex[0] (Q4 precision).
    • GTMCurve1: Curve used when the gain equals m_pGainIndex[1] (Q4 precision).
    • GTMCurve2: Curve used when the gain equals m_pGainIndex[2] (Q4 precision).

Note. When m_nCurveSelectOption is set to 0, the curve is interpolated based on the current gain (see diagram below: Curve-Gain Control Curve Diagram).

Curve parameters are located in CCurveFirmwareFilter.

  • The curve can vary with gain. Set appropriate m_pGainIndex values to specify different curves for different gains.

Noise Calibration and Debugging

RAW Image Requirements for Noise Calibration

In a laboratory environment, use a 24-color chart for shooting. Ensure that the color chart is as straight/aligned as possible, centered in the frame, and occupies approximately 1/9 of the image.

Adjust the lighting brightness accordingly, and sequentially capture images of the color chart under the following gain settings: 1×, 2×, 4×, 8×, 16×, 32×, 64×, 128×, 256×, 512×, 1024×, and 2048× gain.

Noise Calibration Steps

The calibration interface is shown in the figure below:

  1. In the Noise plugin, click Load to import the RAW image. Use the Raw Preprocessor plugin to compensate for LSC and PDF (if there are PD pixels).
  2. In the image, select the bottom 6 color patches on the color chart. Ensure that all 6 ROIs fall entirely within the color blocks. If the image is tilted or has noticeable distortion, click Start, check the ROIs you want to manually adjust, and drag them into the correct position.
  3. Set the desired Denoise Strength.
  4. Click Calibrate. The calibrated noise levels will appear under Noise Result.
  5. Select the Pipe ID.
  6. Select the Channel ID.
  7. Click Update to apply the parameters to the parameter list. If the result is not satisfactory, click Cancel to re-calibrate

Noise Calibration Description

  • Noise Result: Displays the calibrated noise level.
  • Channel ID:
    • 0: Denoise parameters at 1× gain.
    • 1: Denoise parameters at 2× gain.
    • And so on, up to 11: Denoise parameters at 2048× gain.
    • manual: Denoise parameters used in manual mode.

PDAF Calibration

PDAF Calibration VRF Image Requirements

Capture a checkerboard pattern in a laboratory environment, with the object distance at 2 meters, and the checkerboard parallel to the sensor. Control the lighting brightness so that the gain is as close to 1× as possible. Capture images from the motor moving from the minimum to the maximum valid position (divide the entire scan area into 30 segments, resulting in 31 positions), for a total of 31 images. (VRF file naming convention: position.vrf; PD raw files naming convention: position_L.raw, position_R.raw).

PDAF Calibration Steps

The PDAF calibration interface is shown below:

  1. In the PDC plugin, click Load to select the folder containing VRF files (if importing already extracted PD raw files, you will also need to input the raw width and height).
  2. Click Calibrate, which will display a position – shift map corresponding to the image divided into 5x5 blocks.
  3. Select the Pipe ID (applicable if not a single pipeline).
  4. Click Update, and the m_pPDShiftPositionLUT parameter in CAFFilter will be updated.
  5. If the result is unsatisfactory, click Cancel to recalibrate.

PDC Calibration

PDC is used to compensate the brightness of PD pixels or shadow pixels to normal brightness for use by the PDAF autofocus algorithm. Given the known PD points and shadow distribution (via m_pPixelMask and m_pPixelTypeMask), PDC parameters m_pRatioBMap are calibrated using images containing the PD pixel distribution.

PDC Calibration VRF Image Requirements

In a lightbox environment D65, shoot the lightbox wall using frosted glass.

PDC Calibration Steps

  1. In the PDC plugin, click Analyze. The plugin will check whether the settings for m_pPixelMask and m_pPixelTypeMask are reasonable. If not, these two parameters need to be adjusted.
  2. After the Analyze process confirms the settings are reasonable, the Load button becomes enabled. For QuadBayer PD, you can select the compensation mode (channel 0-1 complementary or channel 2-3 complementary; if the number of PD points in the four channels is equal, four-channel complementary compensation is also available).
  3. After successfully Loading the image, the right panel will display small images composed of extracted PD points for the corresponding channels. Press the Calibrate button to calculate the m_pRatioBMap based on the image, and the compensated PD points using the new m_pRatioBMap will be displayed on the right.
  4. The Update button updates the m_pRatioBMap parameter in PDC. If the result is unsatisfactory, click Cancel to recalibrate.
  5. Select the Pipe ID (if multiple pipelines are used).
  6. Click Update to apply the parameters to the parameter list. If the result is unsatisfactory, click Cancel to recalibrate.

PDC Calibration Explanation

Explanation of m_pPixelMask and m_pPixelTypeMask

  1. These two parameters calibrate the distribution of PD and shadow pixels in the image, with a 32x32 periodic pattern.
  • If m_pPixelMask = 1, the current pixel is a PD pixel, and m_pPixelTypeMask indicates one of four directions of pixel shadowing.
  • If m_pPixelMask = 0 and m_pPixelTypeMask > 0, the current pixel is a shadow pixel.
  1. These two parameters are usually provided by the sensor manufacturer. If not available, manual calibration can be performed by capturing RAW images.

Raw Preprocessor Plugin

Raw Preprocessor Plugin Description

The Raw Preprocessor plugin is used for raw data preprocessing. It supports PD pixel correction, LSC compensation, and unpacking VRF files (ASR RAW packed format).

Using the Raw Preprocessor Plugin

The Raw Preprocessor interface is shown below

  1. Set the input and output VRF files in the Raw Preprocessor plugin.
  2. Select the corresponding pipe and LSC channel.
  3. Choose the desired preprocessing functions: PDF, LSC, and Unpack.
  4. Click Preprocess.
  5. Batch preprocess supports importing folders for batch processing of VRF files.

General Information Plugin

The General Information plugin is used to connect to the device and display some debug information in real-time.

General Information Display

By default, the following information is configured for debugging engineers’ reference:

General Information Extension

Click Setting to open the information editing page as shown below. You can freely edit the information you want to monitor. Each line represents one display item. For format details, refer to the Expression Manual.

ISP Tuning

CTopFirmwareFilter Debug Explanation

CTopFirmwareFilter is used to configure ISP Top information.

TOP Parameters

Parameter NameDescriptionRecommended to TuneSpecial Notes
m_nBayerPatternBayer pattern mode: 0: RGGB; 1: GRBG; 2: GBRG; 3: BGGR; 4: Monochrome modeAccording to hardware settings
m_bAELinkZoomAE window linked to zoomUser setting
m_bAFLinkZoomAF linked to zoomUser setting
m_bAWBLinkZoomAWB linked to zoomUser setting
m_nPreviewZoomRatioPreview zoom ratio, Q8 formatUser setting
m_bPreviewLowPowerModePreview low power modeUser setting
m_nAEProcessPositionAE processing timing 0: eof; 1: sofUser setting
m_nAEProcessFrameNumAE processing frequency: EOF every frame EOF every two frames SOF every frame SOF every three framesUser setting
m_bHighQualityPreviewZoomEnableReserved

CAEMFirmwareFilter Parameter Description

The CAEMFirmwareFilter module is used to configure the Auto Exposure (AE) statistics module.

AEM Enable and Parameters

Parameter NameDescriptionRecommended to TuneSpecial Note
m_bEnableAEM Enable: 0: Disable AE statistics module; 1: Enable AE statistics moduleNo
m_nAEStatModeAE statistics mode: 0: Statistics without white balance 1: Statistics with white balanceNo
m_bZSLHDRCaptureZero Shutter Lag HDR capture enable 0: Disable 1: Enable zero shutter lag HDR captureUser setting
m_nInitialExpTimevInitial exposure timeYes
m_nInitialAnaGainInitial analog gainYes
m_nInitialSnsTotalGainInitial sensor total gainYes
m_nInitialTotalGainInitial total gainYes
m_nStableToleranceAE stability tolerance percentage: If the difference between current exposure and previous exposure is less than previous exposure * m_nStableTolerance%, AE StableFlag is issued for use by other modules like LTMUser setting
m_nStableToleranceExternalAE stability tolerance percentage for external systemsUser setting
m_bAutoCalculateAEMWindowAE statistics window calculation method: 0: Configured by hardware; 1: Controlled by firmwareNo
m_nPreEndingPercentagePercentage of rows (relative to image height) excluded from AE statisticsNo
m_bDRCGainSyncOptionDDRC gain synchronization: 0: Sync every frame; 1: Sync after AE stableNo
m_pSceneChangeSADThrSAD threshold for scene change detectionUser setting
m_pSubROIPermilStart and end coordinates of 6 sub-statistics modules relative to image width and height in permille; modifiable by application (e.g., face metering or focus metering linkage)User setting
m_nSubROIScaleFactorSub-window scaling percentage factorUser setting
m_nFaceLumaOptionFace luminance statistics method: 0: Hardware statistics (pixel) ; 1: Software statistics (block)No
m_bMotionDetectEnableMotion detection enable: 0: Disable 1: EnableUser setting
m_bMotionDetectExtMotion detection method: 0: Use internal AEM statistics; 1: Use external gyro sensorUser setting
m_nMotionStrengthExtExternal motion strength control, effective when motion detection method is external gyroUser setting
m_nSADIntervalFrameInterval frame count for SAD calculation, effective when motion detection method is internal AEM statisticsNo
m_nMotionThresholdSAD threshold to judge motion, effective when motion detection method is internal AEM statisticsNo
m_nMotionDetectFrameNumber of consecutive frames with SAD exceeding threshold to consider as motion sceneNo
m_nFaceDetFrameIDFrame ID where face was detected-Read-only
m_nAdjacentLumaSADCurrent SAD-Read-only
m_pMainRoiCoordinateMain window coordinates-Read-only
m_pSubRoiCoordinateSub-window coordinates-Read-only

CDigitalGainFirmwareFilter Parameter Description

The CDigitalGainFirmwareFilter module is used to configure digital gain and black level.

Digital Gain Enable and Parameters

Parameter NameDescriptionRecommended to TuneSpecial Note
m_bEnableDigital gain enable: 0: Disable digital gain; 1: Enable digital gainUser setting
m_nISPGlobalOffsetValue12bit0: Subtract black level in stretch; 1: Subtract black level fully in digital gain; 2-511: Offset added after black level subtraction at 12-bit (this offset is subtracted in stretch)User setting
m_bManualModeManual mode enable 0: Auto mode 1: Enable manual mode; black level parameters do not change with gain and use manual parameters; for debug use
m_pGlobalBlackValueManualManual mode parameters, function same as auto mode
m_pGlobalBlackValueManualCaptureSame as above, effective during capture
m_pGlobalBlackValueBlack levels for R/GR/GB/B channels (see Gain-BlackValue illustration)Calibration resultCan vary with gain
m_pGlobalBlackValueCaptureSame as above, effective during captureCalibration resultCan vary with gain
m_pWBGoldenSignatureWhite balance golden module signature-Read-only
m_pWBCurrentSignatureWhite balance current module signature-Read-only

The BlackValue diagram is as follows:

CWBGainFirmwareFilter Parameter Description

The CWBGainFirmwareFilter module is used for Auto White Balance (AWB) gain.

WB Gain Enable

Parameter NameDescriptionRecommended to TuneSpecial Note
m_bEnableWB gain enable: 0: Disable white balance gain; 1: Enable white balance gainNo

CStretchFirmwareFilter Parameter Description

The CStretchFirmwareFilter module is used to compensate for pixel undersaturation after black level subtraction.

Stretch Enable

Parameter NameDescriptionRecommended to TuneSpecial Note
m_bEnableStretch enable: always on, used to compensate for black level subtraction and pixel undersaturationNo

CColorMatrixFirmwareFilter Parameter Description

The CColorMatrixFirmwareFilter (CCM) module is used for color correction.

CCM Enable

Parameter NameDescriptionRecommended to TuneSpecial Note
m_bEnableCCM enable: 0: Disable the color correction matrix; 1: Enable the color correction matrixNo

CCM Parameters and Tuning

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bUseCorrelatedCTInterpolation basis option: 0: Use AWB's CT; 1: Use m_nCorrelationCT from WbFirmwareFilter (CCT matrix needs calibration)User-defined
m_pColorTemperatureIndexColor temperature segmentation control points. (See example below: cmc-color temperature control curve) If the color temperature is in the range [0, Index[0]], it is considered a low color temperature range, and CMC0 is used; In [Index[0], Index[1]], an interpolated matrix between CMC0 and CMC1 is used; In [Index[1], Index[2]], it is considered a medium color temperature range, and CMC1 is used; In [Index[2], Index[3]], an interpolated matrix between CMC1 and CMC2 is used; In [Index[3], 8192], it is considered a high color temperature range, and CMC2 is used;Yes
m_pCMC0Low color temperature correction matrix, calibrated by the CCM plugin. R'G'B' to RGB, Q12 precision.Calibration result parameterCallable based on color temperature
m_pCMC1Medium color temperature correction matrix, calibrated by the CCM plugin. R'G'B' to RGB, Q12 precision.Calibration result parameterCallable based on color temperature
m_pCMC2High color temperature correction matrix, calibrated by the CCM plugin. R'G'B' to RGB, Q12 precision.Calibration result parameterCallable based on color temperature

cmc-Color Temperature Control Curve (see figure below)

CCM Color Fringe Suppression Function and Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bColorFringleRemoveEnableColor fringe suppression enable: 0: Disable 1: EnableUser-defined
m_nColorFringRemovalStrengthColor fringe suppression strength: The larger the value, the stronger the suppression effectYes

Note. Final CFR_Ratio = HueRatio*EdgeRatio>>HighFreqTransShiftNum

  • Hue Control Parameters
Parameter NameDescriptionRecommended TuningSpecial Notes
m_nHueTransShiftNumHue transition zone offset coefficient: (See example below: HueTrans-HueRatio control curve) Hue values falling in the range [(ColorFringeHueRange[0]-(1<<ShiftNum),ColorFringeHueRange[0]] will be smoothed; Hue values in the range [ColorFringeHueRange[1],(ColorFringeHueRange[1]+(1<<ShiftNum)] will also be smoothed;Yes
m_pColorFringeHueRangeHue range for color fringe suppression (see example below: HueTrans-HueRatio control curve). HueRange[0] must be less than HueRange[1]Yes

ColorFringeHueRange[0],[1] is used to define the Hue range for color fringe suppression;

HueTransShiftNum is used to set the smoothing transition zone:

  • Freq Control Parameters
Parameter NameDescriptionRecommended TuningSpecial Notes
m_nHighFreqThresholdLower frequency threshold for color fringe suppression (see example in HighFreqTrans-EdgeRatio curve). The larger the value, the fewer edges enter the color fringe suppression areaYes
m_nHighFreqTransShiftNumHigh-frequency transition band offset coefficient (see example in HighFreqTrans-EdgeRatio curve). Frequencies falling into the range [HighFreqThreshold, HighFreqThreshold +(1<<HighFreqTransShiftNum)] are smoothedYes

HighFreqTrans-EdgeRatio curve shown below

CCM Manual Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bManualModeManual mode enable 0: Automatic mode; 1: Enable manual mode; in this case, the color correction matrix parameters do not change with color temperature, manual parameters are used; for debugging-Debug parameter
m_pCMCManualManual mode parameters, same function as automatic-Debug parameter

CCM Other Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bDisgardHFEnableDiscard high-frequency information enable: 0: Add high-frequency information; 1: Discard high-frequency informationUser-defined
m_pCMCSaturationListSaturation controlCan vary with Gain

CBPCFirmwareFilter Tuning Description

CBPCFirmwareFilter (BPC) module is used for bad pixel correction.

BPC Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableBPC enable 0: Disable bad pixel correction; 1: Enable bad pixel correctionUser-defined

BPC Dynamic Control Parameters

BPC strength can be dynamically adjusted according to gain and brightness.

Parameter NameDescriptionRecommended TuningSpecial Notes
m_pBpcGainIndexGain index, it is recommended to keep the default valueNoGain control node
m_pSegGBrightness index, the interval between adjacent levels must be a power of 2, it is recommended to keep the default valueNoLum control node
  • The gain control parameter is m_pBpcGainIndex, with twelve groups from 0 to 11; 16 corresponds to 1x gain. When the gain is between two nodes, the parameter is the interpolation result of the two node parameters.

  • The brightness control parameter is m_pSegG, with nine groups from 0 to 8, where the 8th group is fixed at 255 and cannot be changed, corresponding to VRF data pixel value (mapped to 8 bits). When brightness is between two nodes, the parameter is the interpolation result of the two node parameters. The interval between adjacent levels must be a power of 2, it is recommended to keep the default value.

  • The strength control parameter can be dynamically adjusted with changes in gain and brightness.
Parameter NameDescriptionRecommended TuningSpecial Notes
m_pCrossChnStrengthCross-channel strength; the larger the value, the more other channel information is referenced, but it is also more susceptible to bad pixels from other channelsYesCan vary with Gain
m_pSlopeGG channel control curve parameter; the larger the value, the greater the tolerance and the weaker the bad pixel correction abilityYesCan vary with Gain and Lum
m_pInterceptGG channel control curve parameter; the larger the value, the greater the tolerance and the weaker the bad pixel correction abilityYesCan vary with Gain and Lum
m_pSlopeRBRB channel control curve parameter; the larger the value, the greater the tolerance and the weaker the bad pixel correction abilityYesCan vary with Gain and Lum
m_pInterceptRBRB channel control curve parameter; the larger the value, the greater the tolerance and the weaker the bad pixel correction abilityYesCan vary with Gain and Lum

Taking m_pSlopeG as an example:

  • Column represents the Gain level, corresponding one-to-one with m_pBpcGainIndex.

  • Row represents the Lum level, corresponding one-to-one with m_pSegG.

  • Parameter interpolation with Lum change explanation

Notes:

  • The above values changing with Lum include Slope and Intercept
  • Final tolerance is jointly determined by Slope, Intercept, and Ratio. Tolerance = (Lum*Current_Slope + Current_Intercept)* Ratio. The greater the tolerance, the weaker the bad pixel correction

Explanation: Current_Slope and Current_Intercept are interpolated based on Lum and gain changes. Explanation: Ratio is divided into Dead/SpikeRatio and RB/G, totaling 4 cases.

BPC Functional Modules and Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nMinThrEnDark pixel detection channel selection Bit 0: Enable reference to cross-channel information; Bit 1: Enable reference to GrGb channel information; Bit 2: Enable reference to the same channel information.No
m_nMaxThrEnBright pixel detection channel selection Bit 0: Enable reference to cross-channel information; Bit 1: Enable reference to GrGb channel information; Bit 2: Enable reference to the same channel information.No
m_nNearThrLower brightness threshold for using cross-channel information; cross-channel information is used only when brightness is above this threshold.No
m_bDeadEnableDark pixel correction enableUser-defined
m_nDeadRatioGG channel dark pixel coefficient; the larger the value, the greater the tolerance for G channel dark pixels and the weaker the bad pixel correction abilityYes
m_nDeadRatioRBRB channel dark pixel coefficient; the larger the value, the greater the tolerance for RB channel dark pixels and the weaker the bad pixel correction abilityNumber
m_bSpikeEnableBright pixel correction enableUser-defined
m_nSpikeRatioGG channel bright pixel coefficient; the larger the value, the greater the tolerance for G channel bright pixels and the weaker the bad pixel correction abilityYes
m_nSpikeRatioRBRB channel bright pixel coefficient; the larger the value, the greater the tolerance for RB channel bright pixels and the weaker the bad pixel correction abilityYes
m_bSameChnNumSame channel pre-correction enable; 1: enable same channel pre-correction, which can exclude interference from bad pixels in the same channelUser-defined
m_nDeltaThrSame channel pre-correction threshold; it is recommended to keep the default valueNo
m_nRingGRatioSame channel pre-correction threshold; it is recommended to keep the default valueNo
m_nRingMeanRatioSame channel pre-correction threshold; it is recommended to keep the default valueNo
m_bCornerDetEnCorner detection enable; can protect cornersUser-defined
m_pSlopeCornerCorner control curve parameter; the larger the value, the fewer corners are protected; unrelated to toleranceYesCan vary with Gain and Lum
m_pInterceptCornerCorner control curve parameter; the larger the value, the fewer corners are protected; unrelated to toleranceYesCan vary with Gain and Lum
m_bEdgeDetEnEdge detection enable; can protect edgesUser-defined
m_nEdgeTimesEdge determination threshold; the smaller the value, the more edges are protectedYes
m_bGrGbNumGrGb channel pre-correction enable; 1: enable GrGb channel pre-correction, which can exclude interference from bad pixels in GrGb channelUser-defined
m_bAroundDetEnBright block detection enable; can protect pixels with sudden brightness changesUser-defined
m_bBlockDetEn2x2 bad block detection enable; can exclude interference from 2x2 bad blocksUser-defined

BPC Manual Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bManualModeManual mode enable 1: Enable manual mode; in this case, BPC parameters do not change with gain and manual parameters that are used; for debugging-Debug parameter
m_nCrossChnStrengthManualManual mode parameter, functionally consistent with automatic mode-Debug parameter
m_pSlopeGManualManual mode parameter, functionally consistent with automatic mode-Debug parameter
m_pInterceptGManualManual mode parameter, functionally consistent with automatic mode-Debug parameter
m_pSlopeRBManualManual mode parameter, functionally consistent with automatic mode-Debug parameter
m_pInterceptRBManualManual mode parameter, functionally consistent with automatic mode-Debug parameter
m_pSlopeCornerManualManual mode parameter, functionally consistent with automatic mode-Debug parameter
m_pInterceptCornerManualManual mode parameter, functionally consistent with automatic mode-Debug parameter

CLSCFirmwareFilter Parameter Description

CLSCFirmwareFilter module is used for lens shading correction.

LSC Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableLSC enable 0: Disable lens shading correction; 1: Enable lens shading correctionUser-defined
m_bUseOTPLSC OTP enableUser-defined

LSC Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bAutoScaleAutoScale enable: 0: Disable automatic scaling parameter calculation; 1: Enable automatic scaling parameter calculationNo
m_bEnhanceEnableEnhance enable: Enable when the current module’s expected compensation multiple exceeds 4x 0: Disable shading enhancement; 1: Enable shading enhancementUser-defined
m_nProfileSelectOptionShading compensation table selection: 0: Automatically select based on color temperature; 1: Use LSC Profile[0]; 2: Use LSC Profile[1]; 3: Use LSC Profile[2]No
m_nFOVCropRatioHHorizontal cropping ratioYesDetermined by binning size
m_nFOVCropRatioVVertical cropping ratioYesDetermined by binning size
m_pLSCStrengthShading compensation strength (see Gain-strength illustration) 64 represents 1x; 32 represents 1/2x; 16 represents 1/4x; Other values follow similarlyYesCan be adjusted based on gain
m_bUseCorrelatedCTInterpolation basis option: 0: Use AWB’s CT 1: Use m_nCorrelationCT in WbFirmwareFilter (CCT matrix needs calibration)User-defined
m_pCTIndexColor temperature segment control for LSC profile (see LSC-color temperature control curve below): Effective when m_nProfileSelectOption is set to 0. When color temperature is in [0, CTIndex[0]], considered low color temperature range, use compensation table of LSCProfile[0]; When in [CTIndex[0], CTIndex[1]], use interpolation of LSCProfile[0] and LSCProfile[1]; When in [CTIndex[1], CTIndex[2]], considered medium color temperature range, use compensation table of LSCProfile[1]; When in [CTIndex[2], CTIndex[3]], use interpolation of LSCProfile[1] and LSCProfile[2]; When in [CTIndex[3], 8192], considered high color temperature range, use compensation table of LSCProfile[2];Yes
m_pLSCProfileLSC compensation table, calibrated by LSC pluginCalibration result parameterCan be called based on color temperature

LSC-color temperature control curve below

Gain-strength illustration below

Adaptive Color Shading Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bLSCCSCEnableAdaptive color shading correction enable (CSC)User-defined
m_bAdjustCSCTblMinEnableAdjust CSC table based on minimum R/G (B/G) valuesNo
m_nDifThrDif threshold after vector median filtering; if dif is greater than this value, the block is excluded from CSC calculationNo
m_nDifThrMinPercDif threshold after vector median filtering; if dif is less than DifThrMinPerc*DifThr, angle is not considered in CSC calculationNo
m_nAngleThrAngle threshold after vector median filtering; if angle is greater than this value, the block is excluded from CSC calculationNo
m_nDifThrVMFDif threshold before and after vector median filtering; if dif is greater than this value, the block is excluded from CSC calculationNo
m_nAngleThrVMFAngle threshold before and after vector median filtering; if angle is greater than this value, the block is excluded from CSC calculationNo
m_nGradThrMinMinimum effective gradient after vector median filteringNo
m_nGradThrMaxMaximum effective gradient after vector median filteringNo
m_nGradMaxErrorMaximum tolerance for error between CSC estimated gradient and real gradient statisticsYes
m_nGradThrConvThreshold for gradient difference between two CSC calculations; if difference is less than this value, CSC is not updatedYes
m_nGradMaxMaximum CSC compensation strengthYes
m_nTblAlphaConvergence speed; the larger the value, the faster the convergenceYes
m_nCSCGlobalStrengthCSC global strengthYes
m_nEffPNumAllEffective block threshold for entire imageNo
m_nEffPNumHalfEffective block threshold for half imageNo
m_nEffPNumQuarterEffective block threshold for quarter imageNo
m_pEffNumRingEffective block thresholds for three ROIs: ROI0 is center 6x4 ROI1 is center 12x8 (excluding ROI0) ROI2 is 12x12 (excluding ROI0, ROI1)No
m_pCSCCTIndexCSC color temperature control points; CSC invalid when CT > CSCCTIndex[1]Yes
m_pCSCLuxIndexCSC brightness control points; CSC invalid when Lux > CSCLuxIndex[1]Yes

LSC Manual and frameinfo

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bManualModeManual mode enable: 1: Enable manual mode; in this case LSC parameters do not change with color temperature and manual parameters are used; for debuggingDebug parameter
m_nLSCStrengthManualManual mode parameter, functionally consistent with automatic modeDebug parameter
m_pLSCProfileManualManual mode parameter, functionally consistent with automatic modeDebug parameter
m_nRGPolyCoefROCurrent CSC compensation R ratioRead only
m_nBGPolyCoefROCurrent CSC compensation B ratioRead only
m_pRGRatioR/G ratio corresponding to 16x12 statistical blocksRead only
m_pBGRatioB/G ratio corresponding to 16x12 statistical blocksRead only
m_pOTPProfileInternalOTP shading tableRead only

CDemosaicFirmwareFilter Parameter Description

CDemosaicFirmwareFilter (Demosaic) module is used for Bayer interpolation.

Demosaic Subfunction Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bIfEdgeGenerateHigh-frequency information generation enable: can be used for inline sharpen (inline sharpen function requires cooperation with cmc module) 0: Disable; 1: EnableUser-defined
m_bIfGbGrRebalanceGbGr difference elimination enable 0: Disable; 1: EnableNo
m_bIfDNSInline denoise enable, recommended to disable 0: Disable; 1: EnableNo

Demosaic Dynamic Control Parameters

Demosaic parameters can be dynamically adjusted with gain.

Gain control nodes N range from 0 to 11, twelve groups in total. The gain at node N is 2^N times, i.e., node 0 corresponds to 1x gain; node 11 corresponds to 2048x gain.

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nInterpOffsetNoise tolerance in four directionsNoCan change with Gain
m_nInterpOffsetHVNoise tolerance in horizontal and vertical directionsNoCan change with Gain
m_nNoiseSTDNoise tolerance standard deviationNoCan change with Gain
m_nLowpassGLevelInterpolation frequency control parameter; smaller values favor 4-direction interpolation results, larger values favor directionless low-pass interpolation resultsYesCan change with Gain
m_nGbGrThrThreshold corresponding to GbGr difference elimination function; smaller values weaken the function, larger values strengthen itYesCan change with Gain
m_nSharpenStrengthHigh-frequency information amplification factor; larger values mean stronger sharpeningYesCan change with Gain
m_nShpThresholdThreshold for soft threshold processing of high-frequency information; recommended to keep default valueNoCan change with Gain
m_nDenoiseThresholdSoft threshold for inline denoise function; larger values mean stronger denoise; recommended to keep default valueNoCan change with Gain
m_nNoiseAddbackLevelNoise feedback strength for inline denoise; larger values weaken denoise; recommended to keep default valueNoCan change with Gain
m_pDenoiseLumaStrengthLuma-based scaling coefficient for denoise strength; luma levels in 8-bit [8,16,32]; for luma above 64, coefficient is 32, no scalingNoCan change with Gain
m_nChromaNoiseThresholdThreshold for chroma noise removal; larger values mean stronger removal; recommended to keep default valueNoCan change with Gain
m_pUSMFilterUSMFilter = conv([1 2 1], [usm2 usm1 usm0 64-2*(usm0+usm1+usm2) usm0 usm1 usm2]); recommended to keep default valueNoCan change with Gain

Taking m_nSharpenStrength as an example:

Column represents the gain level

  • Column[0] corresponds to the value at 1x gain
  • Column[11] corresponds to the value at 2048x gain

Gain – Sharpen illustrative chart as below

Demosaic Other Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_pHFFragShiftIndexSegment information for high-frequency segmented gain processing; recommended to keep default valueNo
m_pHFFragGainIndexGain information for high-frequency segmented gain processing; recommended to keep default valueNo

Demosaic Manual Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bManualModeManual mode enable 0: Automatic mode; 1: Manual mode; in this case demosaic parameters do not change with gain, manual parameters are used; for debug-Debug parameter
Parameters ending with ManualManual mode parameters, functionally consistent with automatic mode-Debug parameter

CRawDenoiseFirmwareFilter Parameter Description

CRawDenoiseFirmwareFilter (RawDenoise) module is used for RAW domain denoise.

RawDenoise Enable

Parameter NameDescriptionRecommended ChangeSpecial Notes
m_bEnableRAW denoise module enable switch 0: Disable RAW domain denoise; 1: Enable RAW domain denoiseBased on user settings

RawDenoise Dynamic Control Parameters

RawDenoise parameters can be dynamically adjusted with gain.

Gain control nodes N range from 0 to 11, twelve groups in total. The gain at node N is 2^N times, i.e., node 0 corresponds to 1x gain; node 11 corresponds to 2048x gain. (See Gain-Denoise_strength illustrative chart)

Parameter NameDescriptionRecommended ChangeSpecial Notes
m_pMaxSpacialDenoiseThreGainMaximum corner denoise strength, Q8 precision; the larger the value, the stronger the denoise strength achievable at cornersYesCan change with Gain
m_pSigmaDenoise strength threshold; the larger the value, the stronger the denoise strengthYesCan change with Gain
m_pGnsG channel denoise strength; the larger the value, the stronger the denoise strengthYesCan change with Gain
m_pRbnsRB channel denoise strength; the larger the value, the stronger the denoise strengthYesCan change with Gain
m_pL0Denoise strength scaling coefficient at 1.5% brightness, Q5 precision; the larger the value, the stronger the denoise strength at this brightnessYesCan change with Gain
m_pL1Denoise strength scaling coefficient at 7.8% brightness, Q5 precision; the larger the value, the stronger the denoise strength at this brightnessYesCan change with Gain
m_pL2Denoise strength scaling coefficient at 20% brightness, Q5 precision; the larger the value, the stronger the denoise strength at this brightnessYesCan change with Gain
m_pL3Denoise strength scaling coefficient at 45% brightness, Q5 precision; the larger the value, the stronger the denoise strength at this brightnessYesCan change with Gain

m_pL0 - m_pL3 correspond to denoise strength at different brightness levels, as shown in the figure below:

Taking m_pSigma as an example:

Column represents the Gain level:

  • Column[0] corresponds to the parameter at 1x gain;
  • Column[11] corresponds to the parameter at 2048x gain;

Gain - Denoise_strength illustrative chart is shown below

RawDenoise Functional Modules and Parameters

Parameter NameDescriptionRecommended ChangeSpecial Notes
m_bMergeEnable2x2->1x1 conversion method when calculating denoise weight 0: Take lower-left corner 1: Take average of 2x2No
m_bLocalizedEnableEnable denoise strength variation with local brightness 1: Disable 2: EnableNo
m_bSpacialEnableEnable edge denoise strength enhancement: 0: Disable 1: EnableBased on user settings
m_bSpacialAddbackEnableEnable edge denoise add-back: 0: Disable 1: EnableBased on user settings
m_nSpacialOffCenterPercentageEdge denoise enhancement area control parameter; denoise strength enhancement starts from Centerpercentage*R (see R – CenterPercent illustrative chart below)Yes
m_pMaxSpacialDenoiseThreGainMaximum edge denoise enhancement threshold, the maximum denoise strength achievable at the farthest distance (see Distance – RadialGain illustrative chart below)Yes

R - CenterPercent illustrative chart below

Distance - RadialGain illustrative chart below

RawDenoise debug Parameters

Parameter NameDescriptionRecommended ChangeSpecial Notes
m_bManualModeManual mode enable 0: Auto mode; 1: Enable manual mode; raw denoise parameters do not change with gain and manual parameters that are used for debug
m_nSigmaManualManual mode parameter, same function as auto mode
m_nGnsManualManual mode parameter, same function as auto mode
m_nRbnsManualManual mode parameter, same function as auto mode
m_nL0ManualManual mode parameter, same function as auto mode
m_nL1ManualManual mode parameter, same function as auto mode
m_nL2ManualManual mode parameter, same function as auto mode
m_nL3ManualManual mode parameter, same function as auto mode

CAFMFirmwareFilter Parameter Description

CAFMFirmwareFilter module is used for the Auto Focus Measurement (AFM) statistics module.

AFM Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableAFM enable 0: Disable auto focus statistics module; 1: Enable auto focus statistics moduleUser setting

AFM Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nAFStatModeAF statistics module mode: 0: After white balance; 1: Without white balanceNo
m_nWinStartXPermilAFM horizontal start coordinate in permillageUser setting
m_nWinStartYPermilAFM vertical start coordinate in permillageUser setting
m_nWinEndXPermilAFM horizontal end coordinate in permillageUser setting
m_nWinEndYPermilAFM vertical end coordinate in permillageUser setting
m_nMinWidthPermilAFM minimum width in permillageUser setting
m_nMinHeightPermilAFM minimum height in permillageUser setting
m_bConfigDoneFW control parameter, set to 1 when AF window configuration is doneNo
m_pFVListFocus values of each AF window-Read-only
m_nFVAvgAverage focus value-Read-only
m_nWinStartXAFM horizontal start coordinate-Read-only
m_nWinStartYAFM vertical start coordinate-Read-only
m_nWinWidthAFM width-Read-only
m_nWinHeightAFM height-Read-only

CPDCFirmwareFilter Parameter Description

CPDCFirmwareFilter module is used to compensate PD pixels or shadow pixels to normal brightness for PDAF algorithm usage.

PDC Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnablePDC enable: 0: Disable PDC module; 1: Enable PDC moduleUser setting

PDC Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bOutPD dump enable 0: Disable dumping all PD points inside the window; 1: Enable dumping all PD points inside the windowNo
m_nHOffsetHorizontal offset of ISP processed image relative to sensor output image width (see window diagram below for m_nHOft)Yes
m_nVOffsetVertical offset of ISP processed image relative to sensor output image height (see window diagram below for m_nVOft)Yes
m_bLRAdjustDirection control: 0: Disable mirror; 1: Enable mirrorYes
m_bTBAdjustDirection control: 0: Disable flip; 1: Enable flipYes
m_nFullWidthSensor output image widthYes
m_nFullHeightSensor output image heightYes
m_nWindowModeWindow mode: 0: Auto-calculate PD dump region; 1: Calculate PD dump region via m_nWinStartXPermil, m_nWinStartYPermil, m_nWinEndXPermil, and EndYPermilNo
m_nWindowScaleFactorScale factor of PDC statistics window relative to AFM statistics windowUser setting
m_nMinWidthPermilMinimum width of PDC statistics window (permille)User setting
m_nMinHeightPermilMinimum height of PDC statistics window (permille)User setting
m_pPDFirstXHorizontal offset of PD region relative to sensor output image width (see window diagram below)Yes
m_pPDFirstYVertical offset of PD region relative to sensor output image height (see window diagram below)Yes
m_pRatioAGlobal adjustment ratio for four channelsYes
m_pPixelMaskDistribution of PD points within a 32x32 areaYes
m_pPixelTypeMaskDistribution of PD point types within a 32x32 area; PD types divided into shadow up, down, left, rightYes
m_pRatioBMapCompensation coefficients for four-channel PD pointsYes
m_bSoftCompEnableSoftware compensation switch for PD brightness difference: 0: Use hardware PDC compensation; 1: Software compensation (sensor extracts PD pixels)
m_nWinStartXPermilHorizontal coordinate (permille) of PD dump region top-left corner-Read-only
m_nWinStartYPermilVertical coordinate (permille) of PD dump region top-left corner-Read-only
m_nWinEndXPermilHorizontal coordinate (permille) of PD dump region bottom-right corner-Read-only
m_nWinEndYPermilVertical coordinate (permille) of PD dump region bottom-right corner-Read-only
m_nWinStartXHorizontal start coordinate of PDC statistics window-Read-only
m_nWinStartYVertical start coordinate of PDC statistics window-Read-only
m_nWinWidthWidth of PDC statistics window-Read-only
m_nWinHeightHeight of PDC statistics window-Read-only

Window diagram shown below:

CPDFFirmwareFilter Parameter Description

The CPDFFirmwareFilter module is used to correct PD pixels to normal pixel values.

PDF Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnablePDF enable 0: Disable phase detection pixel correction; 1: Enable phase detection pixel correctionUser setting

PDF Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nExtPRmPD pixel outlier correction enable 0: Disable PD pixel outlier correction; 1: Enable PD pixel outlier correctionUser setting
m_nWACenter block weight; 8 corresponds to 50% weight. Usually, the center point is a compensated PD point, so weight is generally set smaller.No
m_nWBDiagonal block weight; 8 corresponds to 50% weight, usually set to 50%.No
m_nFullWidthSensor output image widthYes
m_nFullHeightSensor output image heightYes
m_nHOffsetHorizontal offset of ISP processed image relative to sensor output image width (see window diagram m_nHOft)Yes
m_nVOffsetVertical offset of ISP processed image relative to sensor output image height (see window diagram m_nVOft)Yes
m_bLRAdjustDirection control: 0: Disable horizontal mirror 1: Enable horizontal mirror;Yes
m_bTBAdjustDirection control: 0: Disable vertical flip; 1: Enable vertical flipYes
m_bRefRB- 0: Green channel correction does not reference RB channel; 1: Green channel correction references RB channelNo
m_bRefCnr- 0: Green channel correction does not reference corner info; 1: Green channel correction references corner infoNo
m_nRefNoiseLCurrent noise level used to determine edge directionNo
m_nExtPThreThreshold for PD pixel outliersNo
m_nExtPSftSoft threshold for PD pixel outliersNo
m_nExtPOptSelection of PD pixel outlier correctionNo
m_pPDFirstXHorizontal offset of PD region relative to sensor output image width (see window diagram)Yes
m_pPDFirstYVertical offset of PD region relative to sensor output image height (see window diagram)Yes
m_pPixelMaskDistribution of PD points within 32x32 areaYes
m_pPDResultFour-direction PD shift and confidenceRead-only

CPDAFFirmwareFilter Parameters Description

CPDAFFirmwareFilter module is used for Phase Detection Auto Focus (PDAF).

PDAF Lookup Table

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bMirrorShiftOutput phase difference inversionUser setting
m_bShiftLutEnLookup table enableUser setting
m_pShiftLutOutput phase difference lookup tableNo

PDAF Error Control

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nErrorDistWeightWeight of error source (see the correlation fitting curve below) 0: shape weight = 1; 128: shape and distance weights are equal; 256: distance weight = 1;No
m_nErrorDistCoefAdjustment coefficient for distance (correlation fitting curve distance)No
m_nErrorShpCoefAdjustment coefficient for shape (correlation fitting curve shape)No

Correlation fitting curve illustration:

PDAF Dynamic Control Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_pLumThreBrightness threshold at different gains (see LumThre-gain control curve below). When current brightness is below the threshold, confidence decreases.YesAdjust according to gain
m_pGainThreBasis for dividing different gain intervals, used to control LumThre and SwingThre according to gainNo
m_pSwingThreAmplitude threshold at different gains (see SwingThre-gain control curve below). When current amplitude is below this threshold, confidence decreases.YesAdjust according to gain

LumThre-Gain control curve:

SwingThre-Gain control curve:

PDAF Confidence Control Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bConfAdjustConfidence adjustment switch: 1: Increase confidence when current amplitude is above this threshold; 0: Confidence remains unchanged when current amplitude is above this thresholdNo
m_nConfOffConfidence offset, used to adjust the final confidence valueNo
m_nConfLimitMaximum confidence (see Error-Confidence conversion curve below)No
m_nErrorThre1Error threshold for confidence conversion (see Error-Confidence conversion curve below)Yes
m_nErrorThre2Confidence threshold for error conversion (see Error-Confidence conversion curve below)Yes
m_nSearchRangePD shift search range. The higher the PD pixel density, the larger this value. Usually 0 for shield pixel density 3 for Dual PDYes

Error-Confidence conversion curve shown below:

CWbFirmwareFilter Parameter Description

The CWbFirmwareFilter module is used for white balance.

WB Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableWB enable: 0: Disable white balance statistics module; 1: Enable white balance statistics moduleNo

WB Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bSyncWBHDR mode white balance synchronization method: 0: AWB calculated separately; 1: Use long exposure as AWB calculation sourceNo
m_bAutoWindowWindow adjustment method: 0: Fixed window size; 1: Automatically calculate window size based on zoom factorNo
m_nModeWhite balance mode selection: 0: auto mode; 1: custom; 2: D75; 3: D65; 4: D50; 5: CWF 6: TL84; 7: A 8: H 9: lockNo
m_nInitModeWhite balance initialization mode: 0: custom; 1: D75; 2: D65; 3: D50; 4: CWF; 5: TL84; 6: A; 7: H;Yes
m_pManualGainManual WB gain: indices 0-7 correspond to custom / D75 / D65 / D50 / CWF / TL84 / A / HYes
m_nAWBStableRangeThreshold for AWB stable state: smaller value means harder to judge AWB as stableYes
m_nAWBStableFrameNumNumber of frames reference for AWB stability: stable frames exceeding this value mean AWB stableYes
m_nAWBUnStableRangeThreshold for AWB unstable state: smaller value means easier to judge AWB as unstableYes
m_nAWBUnStableFrameNumNumber of frames reference for AWB instability: unstable frames exceeding this value mean AWB unstableYes
m_nAWBStep1AWB relative step length for convergence: larger value means larger adjustment step, faster convergence but less accuracyYes
m_nAWBStep2AWB absolute step length for convergence: larger value means larger step, faster convergence but less accuracyYes
m_nLowThrLower brightness threshold for AWB statistics: higher value excludes more dark regions from AWB statsYes
m_nHighThrUpper brightness threshold for AWB statistics: lower value excludes more bright regions from AWB statsYes
m_nCorrelationCTCurrent correlated color temperature-Read-only
m_nTintCurrent tint value-Read-only
m_bAWBStableFlagCurrent AWB status-Read-only
m_nDistanceAbsolute sum of difference between applied white balance gain and target gain-Read-only

CCTCalculatorFilter Parameter Description

CCTCalculatorFilter module is used to calculate the true color temperature (CCT).

CCTCalculator Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nIterateNumberNumber of iterations for CT calculationNo
m_nColorTemperatureLowColor temperature corresponding to the low color temperature matrix
m_nColorTemperatureHighColor temperature corresponding to the high color temperature matrix
m_pCTMatrixLowLow color temperature matrixCalibration result
m_pCTMatrixHighHigh color temperature matrixCalibration result

CRGB2YUVFirmwareFilter Parameter Description

CRGB2YUVFirmwareFilter module is used for RGB to YUV conversion.

RGB2YUV Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nOutputColorSpaceOutput color space selection: 0: Rec.601; 1: Rec.709User setting
m_nGlobalSaturationGlobal saturation coefficient, Q7 precisionYes
m_pSaturationCPSaturation control parameters with gain (see example saturation CP-gain curve)YesChanges with gain

RGB2YUV Manual Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bManualModeManual mode enable: 0: Auto mode, saturation varies with gain; 1: Manual mode, saturation fixed to manual valueDebug parameter
m_nSaturationManualManual saturation coefficient, Q7 precisionDebug parameter

sat_CP-gain control curve is shown below:

CSpecialEffectFirmwareFilter Parameter Description

CSpecialEffectFirmwareFilter module is used for special effect tuning.

SE Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableSpecial effect enable: 0: Disable special effect 1: Enable special effect with 6 control regions; regions 0-5 have decreasing priorityUser setting
SE Parameters

Parameters are divided into zones 0-5, a total of 6 groups. Each group has the same meaning and corresponds to 6 control zones with decreasing priority from zone 0 to zone 5.

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bZoneEb_0Zone 0 special effect enableUser setting
m_pRyTable_0Brightness rotation parameter, calibration parameterCalibration result
m_nSyTable_0Brightness translation parameter, calibration parameterCalibration result
m_pRuvTable_0UV rotation parameter, calibration parameterCalibration result
m_pSuvTable_0UV translation parameter, calibration parameterCalibration result
m_pMargin_0Transition margin band: [Lum_min - Margin_0[0], Lum_max + Margin_0[1]] smooth range; [Hue_min - Margin_0[2], Hue_max + Margin_0[3]] smooth range; [Sat_min - Margin_0[4], Sat_max + Margin_0[5]] smooth rangeYes
m_pYTable_0Target adjustment area Lum rangeYes
m_pHTable_0Target adjustment area Hue rangeYes
m_pSTable_0Target adjustment area Saturation rangeYes

SE Dynamic Control Parameters

GainWeight_0-5 share one GainLut, used to set different intensities for different brightness ranges.

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nGainLutGainWeight segment points, corresponding actual scene value = exposure_time(us) * total_gain(Q8) >> 8
m_pGainWeight_0Intensity of special effect (see GainWeight-GainLut control curve below). Larger values mean stronger special effectYesCan vary according to GainLut

SE Manual Parameters

Parameters are divided into zones 0-5, total 6 groups, each with the same meaning.

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bManualMode_0Zone 0 manual mode enable-Debug parameter
m_nManualGainWeight_0Special effect intensity in manual mode-Debug parameter

CCurveFirmwareFilter Parameter Description

CCurveFirmwareFilter module is used for gamma curve.

Curve Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableCurve enable: 0: Disable gamma curve; 1: Enable gamma curveUser setting

Curve Control Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEbGtmAfterLinearcurveGTM changes with linear curve enable: 0: gtm1 curve unchanged; 1: gtm1 curve changes with linear curveNo
m_nCurveSelectOptionCurve usage selection: 0: Auto calculate based on gain; 1: Use GTMcurve0; 2: Use GTMcurve1; 3: Use GTMcurve2; 4: Use A-Log curve;No
m_nBacklightStrengthManualLow-light area brightness adjustment parameter: the larger the value, the more brightness is provided to the low-light area; 0 means no enhancement, and BacklightCurveManual does not affect the final curveUser
m_nContrastStrengthManualContrast adjustment parameter: the larger the value, the higher the contrast; 128 means no contrast adjustment and ContrastsCurveManual does not affect the final curveUser setting
m_nBrightnessStrengthManualBrightness adjustment parameter: the larger the value, the brighter the overall image; 4096 represents 1x brightnessUser setting
m_pBacklightCurveManualCurve used to adjust low-light areaNo
m_pContrastsCurveManualCurve used to adjust contrastNo
m_pGainIndexGain segment control points (see Curve-Gain control curve illustration below) Color temperature segment control points. Gain in [128, GainIndex[0]] uses GTMCurve0 curve; Gain in [GainIndex[0], GainIndex[1]] interpolates between GTMCurve0 and GTMCurve1; Gain at GainIndex[1] uses GTMCurve1; Gain in [GainIndex[1], GainIndex[2]] interpolates between GTMCurve1 and GTMCurve2; Gain in [GainIndex[2], 2048] uses GTMCurve2 curve.Yes
m_pGTMCurve0Curve 0YesCalled based on Gain
m_pGTMCurve1Curve 1YesCalled based on Gain
m_pGTMCurve2Curve 2YesCalled based on Gain

Curve-Gain control curve illustration below:

CLTMFirmwareFilter Parameter Description

CLTMFirmwareFilter module is used for Local Tone Mapping (LTM).

LTM Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableLTM enable: 0: Disable local tone mapping; 1: Enable local tone mapping;User setting
m_bHistEnableLTM histogram enable: 0: Disable LTM histogram; 1: Enable LTM histogramNo
m_nOffsetYHorizontal image offset, determined by input image sizeUser setting
m_nOffsetXVertical image offset, determined by input image sizeUser setting

LTM Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nLtmStrengthLTM strength; the larger the value, the stronger the LTM effectYes
m_nCurveAlphaConvergence speed for blending the current frame's curve with the historically saved curve; smaller values converge fasterYes
m_nSlopeThrIf Drc DrcDark < Thr, equivalent to GTM; if Drc DrcDark >= Thr, each block calculates LTM strength individuallyNo
m_nPhicBetaLTM curve attenuation control point; smaller values cause earlier curve attenuation, reducing brightening of mid-high luminance blocks (see PhicBeta diagram)No
m_nBlendCurveFPFirst control point for tone mapping curve based on DRCGain and DrcGainDark; BlendCurveFP <= BlendCurveSP. Before FP, tone mapping strength depends on DRCGain * DrcGainDark. Larger BlendCurveFP means a larger brightening range in dark areas.No
m_nBlendCurveSPSecond control point; after SP, tone mapping strength depends on DRCGain; smooth transition between FP and SP. Smaller BlendCurveSP means smaller brightening range.No
m_nSubDarkPercThrLowSub-dark area brightening adjustment parameter; smaller values mean stronger brightening in sub-dark areasNo
m_nSubDarkPercThrHighSub-dark area brightening adjustment parameter; smaller values mean stronger brightening; SubDarkPercThrLow < SubDarkPercThrHighNo
m_nSubDarkAdjMeanThrSub-dark area brightening adjustment; combined with SubDarkPercThrLow, SubDarkPercThrHigh, controls LTM strength in sub-dark areas based on percentage of sub-dark points in a block. If current block mean > SubDarkAdjMeanThr and sub-dark percentage > SubDarkPercThrLow, LTM strength increases. Maximum at SubDarkPercThrHigh.No
m_nDarkPercThrLowDark area brightening adjustment parameter; smaller values mean stronger LTM in dark areasNo
m_nDarkPercThrHighDark area brightening adjustment parameter; smaller values mean stronger LTM; DarkPercThrLow < DarkPercThrHighNo
m_nPhCDarkMaxExtraRatioDark area brightening adjustment parameter; combined with DarkPercThrLow and DarkPercThrHigh, controls LTM strength in darkest areas based on point percentage; larger values mean stronger LTMNo
m_pDstAlphaGainIndexLTM strength gain control nodesNo
m_pDstAlphaIndexControls LTM strength based on DstAlphaGainIndex; larger values mean stronger LTMYes

PhicBeta diagram below:

CUVDenoiseFirmwareFilter Parameter Description

CUVDenoiseFirmwareFilter module is used for removing color noise.

UVDenoise Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableUVDenoise enableNoRecommended to use CPP denoise

CEELiteFirmwareFilter Parameter Description

CEELiteFirmwareFilter module is used for controlling edge enhancement.

EE Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableEE enableUser setting

CEELite Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_pCurveLumaPPositive edge luminance-based adaptive enhancement; larger values increase edge strengthYes
m_pCurveLumaNNegative edge luminance-based adaptive enhancement; larger values increase edge strengthYes
m_pCurveFreqTxPPositive edge frequency-based adaptive enhancement; larger values increase texture detailYes
m_pCurveFreqTxNNegative edge frequency-based adaptive enhancement; larger values increase texture detailYes
m_nNodeFreqFrequency adjustment nodes
m_pGlobal_SharpenStrengthPPositive edge global sharpening; larger values increase edge strengthYes
m_pGlobal_SharpenStrengthNNegative edge global sharpening; larger values increase edge strengthYes
m_pGlobal_SharpenStrengthPCaptureCapture mode positive edge global sharpening; larger values increase edge strengthYes
m_pGlobal_SharpenStrengthNCaptureCapture mode negative edge global sharpening; larger values increase edge strengthYes
m_pLPF1USMFilter filter parametersNo
m_pLPF2USMFilter filter parameters; calculated as conv([(flt1[0]-flt2[0]), (flt1[1]-flt2[1]), 2*(flt2[0]+flt2[1] - flt1[0]-flt1[1]), (flt1[1]-flt2[1]), (flt1[0]-flt2[0])])No
m_pLPF1CaptureCapture mode USMFilter filter parametersNo
m_pLPF2CaptureCapture mode USMFilter filter parameters; same calculation as m_pLPF2No
m_pFreqExpLevel1Low-frequency range frequency segmentation control; larger values mean denser segmentationNo
m_pFreqExpLevel2High-frequency range frequency segmentation control; larger values mean denser segmentationNo
m_pFreqOffsetTxFrequency soft threshold; larger values mean stronger noise resistanceYes
m_pTxClipPTexture region positive edge sharpening clipping; larger values increase sharpeningYes
m_pTxClipNTexture region negative edge sharpening clipping; larger values increase sharpeningYes
m_pTxThrdPTexture region positive edge sharpening threshold; smaller values increase sharpeningYes
m_pTxThrdNTexture region negative edge sharpening threshold; smaller values increase sharpeningYes
m_pClipPosPositive edge sharpening clipping; larger values increase sharpeningYes
m_pClipNegNegative edge sharpening clipping; larger values increase sharpeningYes
m_pHCStrengthEdge halo strength control; smaller values mean stronger halo suppressionYes
m_pCoffWHalo region determination parametersNo
m_pGainIndexGain control nodes (Q4 format)No

EE Manual Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bManualModeManual mode enable-Debug parameter
Manual suffix parametersManual mode parameters, same as automatic mode-Debug parameter

CBitDepthCompressionFirmwareFilter Description

The CBitDepthCompressionFirmwareFilter module is used for bit depth compression.

Dithering Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableDitheringDithering enable: 0: Disable dithering; 1: Enable ditheringNo

CFormatterFirmwareFilter Description

The CFormatterFirmwareFilter module is used for output format control.

Formatter Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_nOutputFormatOutput format: 0: NV12; 1: P010; 2: RGB888No
m_nSwingOption- 0: full swing; 1: studio swingNo
m_bConvertDitheringEnable- 0: rgb2yuv dithering disable; 1: rgb2yuv dithering enableNo
m_bCompressDitheringEnable- 0: full swing to studio swing dithering disable; 1: full swing to studio swing dithering enableNo

CEISFirmwareFilter Description

The CEISFirmwareFilter module is used for electronic image stabilization (EIS).

EIS Enable

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bEnableEIS enable: 0: Disable EIS; 1: Enable EISUser setting
EIS Parameters
Parameter NameDescriptionRecommended TuningSpecial Notes
m_bCalcEnableFirmware calculation enable 0: Disable; 1: EnableUser setting
m_bFilterEnableMotion smoothing filter enable 0: Disable motion smoothing filter (usually off when device/scenario motion is minimal) ; 1: Enable motion smoothing filterYes
m_nRangeXDetection range of movement in X direction (unit: pixels)No
m_nRangeYDetection range of movement in Y direction (unit: pixels)No
m_nMarginXOffset X of LDC crop windowNo
m_nMarginYOffset Y of LDC crop windowNo
m_pFilterWeightMotion smoothing filter weightsYes
m_pPeakConfLevelConfidence levelsYes
m_pPeakErrorThreError tolerance thresholds corresponding to confidence levelsYes
m_bReverseDirectionXHorizontal direction reverse controlYes
m_bReverseDirectionYVertical direction reverse controlYes
m_nCenterStatRatioCenter statistics ratio, 256 equals 100%Yes

CAECFilter Parameters Description

CAECFilter (AEC) module is used for Auto Exposure Control.

AE Basic Parameters

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bManualAEEnableAEC mode selection: 0: Auto mode; 1: Manual mode, exposure value uses manual parameters; 2: Lock mode, exposure value locked, no AEC adjustment; 3: Manual exposure index mode, exposure locked to m_pExpIndexManualUser setting
m_pMinExpTimeMinimum exposure time (parameters with “short” annotations are reserved; applies to AE parameters here)Yes
m_pMaxExpTimeMaximum exposure timeYes
m_pMinAnaGainMinimum analog gainYes
m_pMaxAnaGainMaximum analog gainYes
m_pMinSnsDGainMinimum sensor digital gainYes
m_pMaxSnsDGainMaximum sensor digital gainYes
m_pMinTotalGainMinimum total gainYes
m_pMaxTotalGainMaximum total gainYes
m_pRouteNode50Hz50Hz exposure table, first column: exposure time, second: total gain, third: precise gain control (reserved)Yes
m_pRouteNode60Hz60Hz exposure table, first column: exposure time, second: total gain, third: precise gain control (reserved)Yes
m_pMeteringMatrix16x12 metering weight matrixUser setting
m_bLumaCalcModeLuma calculation method 0: RGB max; 1: Y average;User setting
m_bQuickResponseEnableAE quick response enable; when enabled, AE adjusts immediatelyUser setting

AE Target Brightness Control

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bAdvancedAECEnableTarget brightness control parameter: 0: Use m_pTargetRange[1] as target brightness; 1: Dynamically calculate target brightness in range [m_pTargetRange[0], m_pTargetRange[1]]User setting
m_nCompensationTarget brightness compensation factor, 100 means 1xYes
m_nSensitivityRatioSensitivity ratio between capture and preview, 256 means 1xUser setting
m_pSatRefBinSaturation reference bin; Target constrained to histogram pixels ratio in range [m_pSatRefBin[0], 255] falling within [m_pSatRefPerThr[0][0]/10000%, m_pSatRefPerThr[0][1]/10000%]Yes
m_pSatRefPerThrSaturation ratio upper and lower limitsYes
m_pExpIndexThreExposure threshold, corresponds to 4 groups of m_pLumaBlockWeight, used to select which group participates in weight calculation (see Exp_index-luma_weight diagram)User setting
m_pLumaBlockWeightFour groups of luminance block weight tables, each group: Weight[i][0]: low luminance Weight[i][1]: mid luminance Weight[i][2]: high luminance (see Exp_index-luma_weight and Luma-Weight diagrams)User setting
m_pLumaBlockThreLuminance block threshold, controls weight curve of luminance blocks (see Luma-Weight diagram)User setting
m_pLuma7ZoneWeightWeight table for statistics window and 6 sub-ROIsUser setting
m_pTargetRangeTarget brightness rangeYes
m_pTargetDeclineRatioTarget brightness adjustment by gain; gain nodes are powers of 2YesCan vary with Gain

Exp_index – luma_weight diagram:

Luma – weight diagram:

AE Mode Control

Parameter NameDescriptionRecommended TuningSpecial Notes
m_bLumaSelectOption0: Luminance calculation does NOT reference 6 sub-ROIs in AEM; 1: Luminance calculation references 6 sub-ROIs in AEM
m_nStrategyModeAE adjustment strategy selection: 0: Auto mode; 1: Highlight priority (ensure proper exposure in bright areas) 2: Low light priority (ensure proper exposure in dark areas)
m_bAntiFlickerEnableAnti-flicker enable: 0: Disabled, exposure time not limited by flicker; 1: Enabled, exposure time limited to integer multiples of flicker period
m_nAntiFlickerFreqAnti-flicker frequency selection: 0: 50Hz; 1: 60Hz

AE Convergence Control

Parameter NameDescriptionRecommended TuningNotes
m_nToleranceTarget brightness error tolerance. AE will not adjust when the measured brightness is within [target±m_nTolerance]Yes
m_nStableRangeStable brightness range: when AE converges, if the difference between the measured brightness (mean) and the target brightness exceeds m_nStableRange, analog gain is adjusted to compensateYes
m_nSmoothnessAE convergence smoothness; smaller values result in smoother convergenceYes
m_pStableRefFrameNumber of stable reference frames; if the count of stable frames exceeds this, AE considers the scene stableYes
m_pUnStableRefFrameNumber of unstable reference frames; if the count of unstable frames exceeds this, AE considers the scene unstableYes
m_nDualTargetBlendWeightBlend ratio between the previous target brightness and the current target brightness; 8 means 1:1 blend; 16 means fully use current targetYes
m_pFastStepLarge step adjustment discount ratio. When m_pFastStep = 256 (and not limited by MaxFastRatio), it means a single step adjustment to the target (see step-target diagram below)Yes
m_pFastStepRangePerLarge step threshold; large steps used when conditioncurrent_luma – target_luma> m_nFastStepRangePer * target_luma is met
m_pFastStepMinRangeLower limit of the large step thresholdYes
m_pSlowStepSmall step adjustment discount ratio (same as m_pFastStep, see step-target diagram below)Yes
m_pSlowStepRangePerSmall step threshold; used when m_nSlowStepRangePer * target <current_luma – target< m_nFastStepRangePer * target
m_pSlowStepMinRangeLower limit of the small step thresholdYes
m_pFineStepFine step adjustment discount ratio (same as m_pFastStep, see step-target diagram below)Yes
m_pMaxFastRatioMaximum large step adjustment ratio (Q8): When increasing exposure, max large step ratio is m_pMaxFastRatio; When decreasing exposure, max large step ratio is 65536/m_nMaxFastRatio;Yes
m_pMaxSlowRatioMaximum small step adjustment ratio (Q8): When increasing exposure, small step ratio limits range is [256 + m_nMaxFineRatio, 256 + m_nMaxSlowRatio]; When decreasing exposure, range is [256 - m_nMaxSlowRatio, 256 - m_nMaxFineRatio];Yes
m_pMaxFineRatioMaximum fine step adjustment ratio (Q8)No
m_pMinFineRatioMinimum fine step adjustment ratio When increasing exposure, small step ratio limits range is [256 + m_nMinFineRatio, 256 + m_nMaxFineRatio]; When decreasing exposure, range is [256 - m_nMaxFineRatio, 256 - m_nMinFineRatio];No
m_pAjustSplitFrameNumNumber of steps required for a single adjustment (1st column reserved)No
m_pSingleStepAdjustLumaThrSingle adjustment brightness threshold (1st column reserved). Together with m_pAjustSplitFrameNum determines max luma per single adjustment: Single_luma_max = max((target - mean)/AjustSplitFrameNum, SingleStepAdjustLumaThr) When increasing exposure, if adjusted luma exceeds Single_luma_max, then adjustRatio= 256 + Single_luma_max * 256 / mean Similarly for decreasing exposure.No
m_pFaceAjustSplitFrameNumSame meaning as m_pAjustSplitFrameNum, but only effective in face AE modeNo
m_pFaceSingleStepAdjustLumaThrSame meaning as m_pSingleStepAdjustLumaThr, but only effective in face AE modeNo

Step–Target Illustration:

Luma–Step Illustration:

Automatic Dynamic Range Compensation Gain Calculation

Parameter NameDescriptionRecommended for DebuggingNotes
m_nDarkRefBinUpper limit reference value of pixel brightness in dark areas; the brightness range for dark area statistics will not exceed this valueYes
m_bLumaPredictLuma prediction for DRCgain calculation: 0: No correction during DRCgain calculation (when frame statistics are applied to current frame’s LTM) ; 1: Correction applied during DRCgain calculation (when frame statistics are applied to next frame’s LTM)
m_nDarkPerThrLLower threshold of dark area pixel percentage. When the percentage of dark pixels is below this value, DRCGainDark is set to 1 (see illustration: pixelNumPercent–DRCGainDark)
m_nDarkPerThrHUpper threshold of dark area pixel percentage. When the percentage of dark pixels exceeds this value, all dark pixels are used to calculate DRCGainDark (see illustration: pixelNumPercent–DRCGainDark)
m_nDarkTargetTarget brightness value for dark areas. The larger the value, the higher the resulting DRCGainDark
m_nMaxDRCGainMaximum DRC gainYes
m_nMaxDRCGainDarkMaximum DRC gain for dark areasYes

PixelNumPercent–DRCGainDark Illustration:

Lux Calibration

Parameter NameDescriptionRecommended for DebuggingNotes
m_nCalibExposureIndexExposure index for brightness calibrationYes
m_nCalibSceneLumScene brightness for calibrationYes
m_nCalibSceneLuxActual illumination (lux) of the calibration sceneYes

AEC Manual Parameters

Parameter NameDescriptionRecommended for DebuggingNotes
m_pExpTimeManualManual exposure time, effective when AEC is in manual mode
m_pAnaGainManualManual analog gain, effective when AEC is in manual mode
m_pSnsDGainManualManual sensor digital gain, effective when AEC is in manual mode
m_pTotalGainManualManual total gain, effective when AEC is in manual mode
m_pExpIndexManualManual exposure index, effective when AEC is in manual mode

AEC Frame Info

Parameter NameDescriptionRecommended for DebuggingNotes
m_nFrameCounterAE frame counter-Read-only
m_pExpTimeLongExposure time (us)-Read-only
m_pAnaGainLongAnalog gain (Q8)-Read-only
m_pSnsDGainLongSensor digital gain (Q12)-Read-only
m_pIspDGainLongISP digital gain (Q12)-Read-only
m_pTotalGainLongTotal gain (Q8)-Read-only
m_pExpIndexLongExposure index (Exposure Time * Total Gain / 256)-Read-only
m_pTotalGainDBLongTotal gain (dB)-Read-only
m_pExpTimeShortReserved-Read-only
m_pAnaGainShortReserved-Read-only
m_pSnsDGainShortReserved-Read-only
m_pIspDGainShortReserved-Read-only
m_pTotalGainShortReserved-Read-only
m_pExpIndexShortReserved-Read-only
m_pTotalGainDBShortReserved-Read-only
m_nCurHdrRatioReserved-Read-only
m_nHistPixelNumNumber of pixels used in histogram statistics-Read-only
m_pMeanLumaAE calculated brightness [0]: long [1]: Reserved-Read-only
m_pTargetLumaAE target brightness [0]: long [1]: Reserved-Read-only
m_pLuma7ZoneAE main and 6 sub-window luma-Read-only
m_pAERouteNumAE exposure node [0]: long [1]: Reserved-Read-only
m_pRouteNodeLongLong frame exposure table-Read-only
m_pADNodeLongSensor analog and digital gain allocation table-Read-only
m_pLumaMatrixLongLuma thumbnail-Read-only
m_pHistLongHistogram-Read-only
m_pRouteNodeShortReserved-Read-only
m_pADNodeShortReserved-Read-only
m_pLumaMatrixShortReserved-Read-only
m_pHistShortReserved-Read-only
m_pRefSaturateNumReference overexposed pixel count [0]: long [1]: Reserved-Read-only
m_pCurSaturateNumCurrent overexposed pixel count [0]: long [1]: Reserved-Read-only
m_pEstSaturateNumEstimated overexposed pixel count when brightness reaches upper limit [0]: long [1]: Reserved-Read-only
m_pAdjustRatioAE adjustment ratio-Read-only
m_pStableFlagAE stability flag [0]: long [1]: Reserved-Read-only
m_pStableFlagBufAE frame sequence stability flag [0]: long [1]: Reserved-Read-only
m_pUnStableFlagBufAE frame sequence instability flag [0]: long [1]: Reserved-Read-only
m_nDRCGainDRCGain result of AE calculation for current frame-Read-only
m_nDRCGainDarkDRCGainDark result of AE calculation for current frame-Read-only

CAFFilter Parameter Description

The CAFFilter module is used for automatic focus control.

AF Parameters

Parameter NameDescriptionRecommended for DebuggingNotes
m_nAFModeFocus mode: 0: SAF (Single Auto Focus); 1: CAF (Continuous Auto Focus)User configurable
m_bHybridAFEnableEnable hybrid AF mode (CDAF + PDAF): 0: Disabled; 1: EnabledUser configurable
m_bAFTriggerAF trigger; must be enabled when using CAFUser configurable
m_bMotorManualTriggerManual focus trigger, used together with ManualMotorPositionUser configurable
m_nManualMotorPositionManual motor positionUser configurable
m_nFrameRateCurrent sensor frame rate, used to calculate AF skip frames; should be updated by softwareUser configurable
m_nMaxSkipFrameMaximum number of skipped framesNo

Motor Property Parameters

Parameter NameDescriptionRecommended for DebuggingNotes
m_nMinMotorPositionMinimum motor positionYes
m_nMaxMotorPositionMaximum motor positionYes
m_nMotorResponseTimeResponse time per motor step (ms); used to calculate AF skipped frames — the higher the value, the more frames are skippedYes
m_nHyperFocalMotorPositionHyperfocal positionYes

Motor Movement Control Parameters

Parameter NameDescriptionRecommended for DebuggingNotes
m_nFirstStepDirectionJudgeRatioFirst step direction judgment ratio (%). When AF algorithm is running in CDAF mode, this sets the percentage used to determine the first step direction: If the motor's initial position is within the first X% of its full range, move from min to max position; If it's within the last (100%-X)%, move from max to min position.User Setting
m_bPreMoveModePre-move mode. When AF algorithm is running in CDAF mode, defines motor behavior for first step: 0: Stay at initial position; 1: Move to min or max motor position based on direction judgment percentage.User Setting
m_bPreMoveToInfModePre-move to infinity mode. When AF algorithm is running in CDAF mode, defines motor behavior for first step: 0: Stay at initial position; 1: Move to minimum motor position.User Setting
m_bStartFromTrueCurrentStart from actual current position. When AF algorithm is running in CDAF mode, defines motor behavior for first step: 0: Move to closest macro position from initial position; 1: Stay at initial position.User Setting
m_nBackTimeRatioFrame skipping ratio during motor movement. Higher value means more frames are spent per motor step. Works in conjunction with m_nBackTimeDivisor.User Setting
m_nBackTimeDivisorMotor step frame skipping control divisor. Smaller value means more frames are spent per step. Works in conjunction with m_nBackTimeRatio.User Setting
m_nPreMoveTimeRatioFrame skipping ratio in pre-move mode.User Setting
m_nFailMotorPositionOptionFinal motor position after focus failure: 0: Auto-selected by algorithm (requires correct hyperfocal position); 1: Best sharpness; 2: Infinity; 3: Hyperfocal; 4: Macro; 5: Current positionUser Setting

Motor Step Control Parameters

Parameter NameDescriptionRecommended for DebuggingNotes
m_nMinMacroReverseStepNumMinimum steps motor must move when reversing direction from max to min position upon detecting FV dropYes
m_nMinReverseStepNumMinimum steps motor must move when reversing direction from min to max position upon detecting FV dropYes
m_nFineStepSearchNumNumber of fine step searchesYes
m_nCoarseStepCoarse step size in CDAFYes
m_nFineStepFine step size in CDAFYes
Parameter NameDescriptionRecommended for DebuggingNotes
m_nSoftwareMotorCtrlModeTarget position control mode (used for first-step pre-move, manual move, fine step start, focus failure handling, etc.): 0: Soft landing mode; 1: Fixed step mode; 2: Direct modeUser SettingSee Figure 1
m_nMinSafePositionMinimum safe position when motor moves from max to min position in soft landing modeUser SettingSee Figure 2
m_nMinStepRatioMinimum step ratio in soft landing mode (same as above)User SettingSee Figure 2
m_nMaxSafeStepMaximum safe step in soft landing mode (same as above)User SettingSee Figure 2
m_nMinSafePositionMacroMinimum safe position when motor moves from min to max position in soft landing modeUser SettingSee Figure 2
m_nMinStepRatioMacroMinimum step ratio in soft landing mode (same as above)User SettingSee Figure 2
m_nMaxSafeStepMacroMaximum safe step in soft landing mode (same as above)User SettingSee Figure 2

Figure 1

Description per condition group:

  • Graphic: Visual demonstration
  • Output: One output scenario

Figure 2

Parameter NameDescriptionRecommended for DebuggingNotes
m_bAdaptiveStepAdaptive step mode 0: Disabled; 1: EnabledUser Setting
m_nVCMStep1RatioMotor step ratio 1, divides motor range into segments in adaptive step modeUser SettingSee Figure 3
m_nVCMStep2RatioMotor step ratio 2, divides motor range into segments in adaptive step modeUser SettingSee Figure 3
m_nVCMCoarseStep1Motor coarse step 1, actual step computed based on current motor position segment in adaptive modeUser SettingSee Figure 3
m_nVCMCoarseStep2Motor coarse step 2, actual step computed based on current motor position segment in adaptive modeUser SettingSee Figure 3
m_nVCMFineStep1Motor fine step 1, actual step computed based on current motor position segment in adaptive modeUser SettingSee Figure 3
m_nVCMFineStep2Motor fine step 2, actual step computed based on current motor position segment in adaptive modeUser SettingSee Figure 3
  • MotorMoveStep indicates the real-time step length, changing according to motor movement direction and whether in coarse or fine step mode; it can be positive, negative, large, or small.

Figure 3

Description per condition group:

  • Graphic: Visual demonstration
  • Output: One output scenario

Focus Value (FV) Judgment Parameters

Parameter NameDescriptionRecommended for DebuggingNotes
m_pFVDropPercentageFV drop percentage threshold for pre-move mode. Calculated separately for 6 types of FV based on gain.No
m_pCurrentStartFVDropPercentageFV drop percentage threshold for non-pre-move mode. Calculated separately for 6 types of FV based on gain.No
m_pFVFailPercentageIn pre-move mode, max-min FV difference percentage to judge FV curve invalidity. If difference is below this threshold, FV curve is too flat and considered invalid. Applied separately for 6 FV types based on gain. First condition to judge focus failure.No
m_pCurrentStartFVFailPercentageSame as above but for non-pre-move mode. First condition to judge focus failure.No
m_pLastStepChangePercentagePercentage threshold for judging FV curve as invalid when FV continuously rises or falls. Calculated separately for 6 FV types based on gain.No
m_pWindowWeightMatrix5x5 window weights for FV statistics calculation.No

PDAF Control Parameters

Parameter NameDescriptionRecommended for DebuggingNotes
m_bPDReverseDirectionFlagPDShift step direction reverse flag 0: No reverse; 1: ReverseYes
m_nPDDirectConfThrRatioPD threshold percentage; when confidence exceeds m_nPDDirectConfThrRatio%, directly apply PD step calculatedNo
m_nPDTryStepRatioStep ratio tried first in hybrid AF mode relative to CDAF coarse stepNo
m_nPDCoarseStepPDAF coarse stepYes
m_nPDFineStepPDAF fine stepYes
m_nPDStepDiscountRatioDiscount ratio applied to PDShift calculated stepNo
m_pPDConfThrPD confidence thresholdYes
m_pPDFVIncreaseRatioFV increase ratio used in hybrid AF mode to judge if FV rises after PD step, determining PD info validityNo
m_pPDFVDropPercentageFV drop percentage threshold used in PDAF modeNo
m_pPDShiftPositionLUT_0_0 ~ m_pPDShiftPositionLUT_4_45x5 window PD Shift – step lookup tablePDAF plugin calibration

Continuous Autofocus (CAF) Control

Parameter NameDescriptionRecommended for DebuggingNotes
m_bCAFHoldHold current state in continuous autofocus modeUser setting
m_bCAFForceForce trigger single autofocus once in continuous autofocus modeUser setting
m_nCAFHoldPDShiftThrPD shift threshold to judge scene stability in CAF mode; higher value means easier to judge stableYes
m_nCAFHoldPDConfThrPD confidence threshold to judge scene stability in CAF mode; lower value means easier to judge stableYes
m_nPreFocusModePrefocus mode enable in CAF: 0: No prefocus; 1: Semi-prefocus (try focus once based on PD shift)User setting
m_nPFPDStepDiscountRatioPrefocus step discount ratioYes
m_nLumaCalcOptLuma calculation method 0: Calculate each channel separately; 1: Calculate RGB max value; 2: Calculate weighted Y averageNo
m_bReFocusEnableRefocus enable in CAF modeUser setting
m_pRefocusLumaSADThrSAD threshold to decide whether to trigger SAF when CAF triggers SAFYes
m_nFlatSceneVarThrVariance threshold of thumbnail to judge flat scene in CAF modeYes
m_nFlatSceneLumaThrLuma threshold to judge flat scene in CAF modeYes
m_bStableJudgeOptCondition for scene stability judgment in CAF: 0: FV or luma satisfies condition; 1: Both FV and luma satisfy conditionUser setting
m_nRefStableFrameNumNumber of frames judged stable in reference state during CAFUser setting
m_nDetStableFrameNumNumber of frames judged stable in detection state during CAFUser setting
m_pStableExpIndexPercentagePercentage of exposure index change to judge stability in CAFYes
m_pStableFVSADPercentageSAD percentage of FV to judge stability in CAFYes
m_pStableLumaSADThrSAD threshold of luma to judge stability in CAFYes
m_bChangeJudgeOptCondition for scene change judgment in CAF: 0: FV or luma satisfies condition; 1: Both FV and luma satisfy conditionNo
m_nChangeFrameNumNumber of frames to judge scene change in CAFYes
m_nChangeStatAreaPercentageThreshold percentage of AF statistic window area change to judge scene change in CAF; effective in face modeNo
m_nChangeStatCenterPercentageThreshold percentage of AF statistic window center position change to judge scene change in CAF; effective in face modeNo
m_pChangeExpIndexPercentageExposure index change percentage to judge scene change in CAFYes
m_pChangeFVSADPercentageSAD percentage of FV to judge change in CAFYes
m_pChangeLumaSADThrSAD threshold of luma to judge change in CAFYes
m_pChangePDShiftThrPDShift percentage threshold to judge change in CAFNo

Foreground Tracking Mode

Parameter NameDescriptionRecommended for DebuggingNotes
m_bForeGroundTrackInCoarseForeground tracking enable during coarse step adjustment: 0: Disable foreground tracking; 1: Enable foreground trackingUser setting
m_bForeGroundTrackInFineForeground tracking enable during fine step adjustment: 0: Disable foreground tracking; 1: Enable foreground trackingUser setting
m_nForeGroundTrackWindowForeground tracking window size: 3: 3x3; 4: 4x4; 5: 5x5User setting
m_bForeGroundTrackForeground tracking mode enable: 0: Disable foreground tracking; 1: Enable foreground trackingUser setting
m_pFVBlkDropPercentageFV value drop percentage threshold when foreground tracking mode is enabledNo
m_pFVBlkIncreasePercentageFV value increase percentage threshold when foreground tracking mode is enabledNo
m_pFineStepStartPosSelectConfConfidence threshold for start position when beginning fine step in foreground tracking modeNo
m_pFineStepEndPosSelectConfConfidence threshold for final position after fine step in foreground tracking modeNo

AF Frameinfo

Parameter NameDescriptionRecommended for DebuggingNotes
m_nGainCurrent system gain, Q4 format-Read-only
m_nPDShiftPD offset-Read-only
m_nPDConfPD confidence-Read-only
m_nCurrentPositionCurrent motor position-Read-only
m_nFSMStatusAF state machine status-Read-only
m_nFocusStatFlagFocus status flag 0: Initial; 1: Success; 2: Failure-Read-only
m_nFocusFrameCostNumber of frames taken for a single focus-Read-only
m_nMotorMoveStepReal-time motor step-Read-only
m_bCoarseFineStepFlagReal-time coarse/fine step flag 0: Fine step; 1: Coarse step-Read-only
m_nMotorMoveSkipFrameNumNumber of frames skipped per motor move-Read-only
m_bStartFromMinFlagReal-time motor movement direction 0: From max to min motor position; 1: From min to max-Read-only
m_bStartFromCurrentFlagMotor initial movement from current position flag 0: From pre-move position; 1: From initial position-Read-only
m_bSoftwareMotorCtrlFlagFlag for software control during movement from current to target position-Read-only
m_nPositionScanNumCount of motor movement direction scans-Read-only
m_nPositionAdjustNumCount of motor moved positions-Read-only
m_pRTFVListReal-time FV (Focus Value) list-Read-only
m_pMinFVListMinimum FV values during single focus process-Read-only
m_pMaxFVListMaximum FV values during single focus process-Read-only
m_pMaxFVPositionListPositions of maximum FV values during single focus process-Read-only
m_pFVUnchangeFlagFV curve invalidation flag 0: FV curve valid; 1: FV curve invalid-Read-only
m_pFailConditionStatus of three local focus fail conditions 0: Success; 1: Fail-Read-only
m_pFSMPosSingleFocusFrame number - motor position - state machine info during single focus-Read-only
m_pPosFvSingleFocusFrame number - 6 types of FV values during single focus-Read-only
m_pRefFVReference FV value in continuous focus mode-Read-only
m_pSeqFVReal-time FV sequence in continuous focus mode-Read-only
m_pRefLumaRReference R channel thumbnail in continuous focus mode-Read-only
m_pRefLumaGReference G channel thumbnail in continuous focus mode-Read-only
m_pRefLumaBReference B channel thumbnail in continuous focus mode-Read-only
m_pSeqLumaRReal-time R channel thumbnail in continuous focus mode-Read-only
m_pSeqLumaGReal-time G channel thumbnail in continuous focus mode-Read-only
m_pSeqLumaBReal-time B channel thumbnail in continuous focus mode-Read-only
m_nRefExpIndexReference exposure index in continuous focus mode-Read-only
m_nRTExpIndexReal-time exposure index in continuous focus mode-Read-only
m_bPDInfoDisableFlag for PD info usage in continuous focus mode-Read-only
m_nLumaAverageAverage luminance-Read-only
m_nSceneVarianceReal-time variance of thumbnail-Read-only
m_bSceneFlatFlagScene flatness flag-Read-only
m_nChangeExpIndexDifference between current and reference exposure index in continuous focus mode-Read-only
m_nChangeExpIndexThrExposure index threshold for scene change detection in continuous focus mode-Read-only
m_nChangeFVSADSAD difference between real-time and reference FV in continuous focus mode-Read-only
m_nChangeFVSADThrSAD threshold for scene change detection in continuous focus mode-Read-only
m_nChangeLumaSADReal-time luminance SAD value-Read-only
m_nChangeLumaSADThrReal-time luminance SAD threshold-Read-only
m_nRefocusLumaSADPrevious frame luminance SAD when CAF triggers SAF-Read-only
m_nRefocusLumaSADThrSAD threshold deciding whether SAF is triggered by CAF-Read-only
m_bStableExpIndexFlagAE exposure table stability flag-Read-only
m_bStableFVFlagFV stability flag-Read-only
m_bStableAFLumaFlagAFM luminance stability flag-Read-only
m_bStableAELumaFlagAEM luminance stability flag-Read-only
m_bPDTriggerCAFPD triggered AF flag-Read-only
m_bFVTriggerCAFFV triggered AF flag-Read-only
m_bLumaTriggerCAFLuma triggered AF flag-Read-only
m_bExpIndexTriggerCAFExposure index triggered AF flag-Read-only
m_bRefocusTriggerCAFCAF triggered SAF flag-Read-only

CAWBFilter Parameter Description

The CAWBFilter (AWB) module is used for automatic white balance control.

Gray World

Parameter NameDescriptionSuggested TuningSpecial Notes
m_bGrayWorldEnGray World mode enable: 0: Disable Gray World; 1: Enable Gray World; in this mode, white balance gains are calculated by the Gray World algorithmUser Setting

ROI Control

Parameter NameDescriptionSuggested TuningSpecial Notes
m_pRoiBoundControl for 16 ROI regionsYes
m_pRoiLumLutHighUpper limit of brightness for statistic blocksNo
m_pRoiLumLutLowLower limit of brightness for statistic blocksNo
m_pRoiEnROI enableYes
m_pRoiWeightLutWeights corresponding to different brightness indicesYes
m_pRoiLumThreBrightness lux index thresholdYes
m_bRoiLimitManualFixed ROI enable: 0: Calculate white point limit area based on auto white point ROI and low color temperature block ratio; 1: White point limit area fixed to RoiCtHigh, RoiCtLow, RoiXMax, RoiXMin
m_nRoiCtHighUpper Y coordinate of white point ROI; weights for blocks outside ROI area are zero when calculating white balance (CT = BlockBlue_sum(8bit) / BlockRed_sum * 1024)Yes
m_nRoiCtLowLower Y coordinate of white point ROIYes
m_nRoiXMaxUpper X coordinate of white point ROI (X = BlockBlue_sum x BlockRed_sum / BlockGreen_sum / BlockGreen_sum x 1024)Yes
m_nRoiXMinLower X coordinate of white point ROIYes
m_pRoiCtHighAutoUpper Y coordinate of white point ROI at different brightness levelsYes
m_nRoiCtLowAutoLower Y coordinate of auto white point ROI at different brightness levelsYes
m_nRoiXMaxAutoUpper X coordinate of auto white point ROI at different brightness levelsYes
m_nRoiXMinAutoLower X coordinate of auto white point ROI at different brightness levelsYes
m_nValidNumMinimum number of valid blocks in each ROI; if the number of blocks in the brightness statistics range is less than this value, the ROI does not participate in white balance calculationNo
m_bWeightOnSumBlock weight calculation method: 0: Use total brightness sum of blocks; 1: Use RGB gain of blocksNo

White Balance Gain Control

Parameter NameDescriptionSuggested TuningSpecial Notes
m_pAWBGainLimitFinal WB gain limitation rangeYes
m_nAWBCTShiftWB Gain upward shift distance, used to shift low color temperature scenes toward warmer tonesYes
m_pAWBCTShiftThrWB Gain shift Y threshold: When Y < AWBCTShiftThr[0], WB Gain is shifted up by m_nAWBCTShift When Y > AWBCTShiftThr[1], WB Gain is not shifted Intermediate values are interpolatedYes

Mixed Lighting Scene - Reduce High Color Temperature Weight

Parameter NameDescriptionSuggested TuningSpecial Notes
m_sRoiBoundDayLightMixed high and low color temperature scene, bounding region for high color temperature statistic blocks; blocks falling in this area are counted as high color temperature blocksYes
m_pLowCtNumThrThreshold for the ratio (per mille) of low color temperature statistic blocks (see the illustration below lowCtLightPermillage-ratio) When the ratio of low CT blocks > LowCtNumThr[0], the weight of high CT blocks begins to decrease; When the ratio ≥ LowCtNumThr[1], the weight of high CT blocks is reduced to the minimum.Yes
m_pDayLightNumThrThreshold for the ratio (per mille) of high color temperature statistic blocks (see the illustration below dayLightPermillage-ratio) When the ratio of high CT blocks < DayLightNumThr[1], the weight of high CT blocks begins to decrease; When the ratio ≤ DayLightNumThr[0], the weight no longer decreases. Works together with m_pLowCtNumThr to determine the base strength (baseRatio) for reducing high CT block weights.Yes
m_pLowCtThrY threshold for reducing the weight of high CT statistic blocks in mixed CT scenes (see CtThr – ProtectRatio illustration); blocks with Y < m_pLowCtThr[1] are counted as low CT blocksYes
m_pLowCtProtectRatioCoefficient for reducing the weight of high CT blocks; the smaller the value, the lower the weight of high CT blocks. Together with baseRatio determines block weight (see CtThr – ProtectRatio)YesChanges with CtThr
m_nLog2CwtOverAWeight ratio of CWF to A lightNo

CtThr – ProtectRatio illustration

lowCtLightPermillage-ratio illustration

dayLightPermillage-ratio illustration

Green Zone Control

Parameter NameDescriptionSuggested TuningSpecial Notes
m_pRoiBoundGGreen zone ROI controlYes
m_pRoiLumLutHighGUpper brightness limit for green zone statistic blocksYes
m_pRoiLumLutLowGLower brightness limit for green zone statistic blocksYes
m_bGreenShiftEnGreen zone ROI enableUser setting
m_pGreenLumThreWeight table for different brightness indices in the green zoneYes
m_nGreenShiftMaxMax weight for green zone: multiplied by exposure shift to get the final shift weight; max 32, fully biased toward outdoor gainYes
m_pGreenNumThreThreshold for green zone statistic blocks count; if the number of blocks in green zone is within this range, green shift is appliedYes
m_pOutdoorGainTarget WB gain for green zoneYes

AWB Frameinfo

Parameter NameDescriptionSuggested TuningSpecial Notes
m_bAwbCalStatusAWB calculation status-Read-only
CurrentResultCurrently applied white balance gain-Read-only
CurrentTargetTarget white balance gain calculated by AWB-Read-only
m_nSceneLuxAWB debug parameter, current AE calculated scene illuminance-Read-only
m_nValidBlkNumNumber of valid statistic blocks-Read-only
m_nLowCtBlkRatioLow color temperature statistic block ratio (per mille)-Read-only
m_pCtLimitCurrent ROI range (X_Max, X_Min, CT_High, CT_Low)-Read-only
m_nDayLightBlkRatioDaylight statistic block ratio (per mille)-Read-only
m_nGreenShiftWeightGreen zone shift weight-Read-only
m_pStatBlkRR channel statistics-Read-only
m_pStatBlkGG channel statistics-Read-only
m_pStatBlkBB channel statistics-Read-only
m_pBlkCtXStatistic block horizontal coordinate X-Read-only
m_pBlkCtYStatistic block vertical coordinate Y-Read-only
m_pBlkRoiIdROI of statistic block-Read-only
m_pBlkWeightWeight of statistic block for white balance calculation-Read-only
m_pDebugBlcokData[23][31]RGB values of AWB statistic blocks-Read-only

C3DNRFirmwareFilter Debug Description

C3DNRFirmwareFilter (NR) module is used for 2D and 3D noise reduction.

NR Enable

Parameter NameDescriptionSuggested ModificationSpecial Notes
m_nTnrEb3DNR enable, controls 3DNR onlyUser setting
m_pTnr3dYEb3DNR luminance noise reduction enableYes, adjustable by Gain/Layer
m_pTnr3dUVEb3DNR chrominance noise reduction enableYes, adjustable by Gain/Layer
m_pTnr2dYEb2DNR luminance noise reduction enableYes, adjustable by Gain/Layer

2D NR Basic Control Parameters

Parameter NameDescriptionSuggested ModificationSpecial Notes
m_pMax_diff_thrMaximum luminance reference threshold, effective when Dynamic enable is onNo
m_pSig_gainLuminance reference threshold; smaller values cause more areas to be denoisedYesAdjustable by Gain/Layer
m_pAback_alphaLuminance noise re-addition; larger values re-add more luminance noiseYesAdjustable by Gain/Layer
m_pCnrSig_yCNR reference Y threshold; larger values cause more areas to be denoisedYesAdjustable by Gain/Layer
m_pCnrSig_uvCNR reference UV threshold; larger values cause more areas to be denoisedYesAdjustable by Gain/Layer
m_pCnrAback_alphaChrominance noise re-addition; larger values re-add more chrominance noiseYesAdjustable by Gain/Layer
m_pCnrSig_uv_shiftCNR threshold left shift factor (1 means shift left by 1 bit, i.e., multiply by 2)YesAdjustable by Gain/Layer
m_pGainIndexGain index, suggested to keep default valueNo
m_bDynamic_enAdaptive denoise threshold enable; when enabled, luminance denoise ratio is dynamically calculated based on image contentNo
m_nGlobalYnrStrengthGlobal luminance noise reduction strengthYesAdjustable by Gain/Layer
m_nGlobalCnrStrengthGlobal chrominance noise reduction strengthYesAdjustable by Gain/Layer

Some parameters adjust according to Gain/Layer, for example, m_pCnrSig_y:

  • Columns represent gain levels:
    • Column[0] means 1x gain
    • Column[11] means 2048x gain
  • Rows represent different layers:
    • Row[0] means parameters for layer 0
    • Row[4] means parameters for layer 4

Higher layers correspond to processing higher frequency regions of the image.

2D NR Gain/Layer Example

2D NR Luminance Control Parameters

Parameter NameDescriptionSuggested ModificationSpecial Notes
m_bLuma_enYNR (Y noise reduction) enable according to luminanceUser setting
m_pLuma_sigYNR strength varies with luminance, levels 0-16 correspond to luminance 0-255, divided into 16YesAdjustable by Gain/Luma
m_bCnrLuma_enCNR (color noise reduction) strength control enable according to luminanceUser setting
m_pCnrLuma_sigCNR strength varies with luminance, levels 0-16 correspond to luminance 0-255, divided into 16YesAdjustable by Gain/Luma

2D NR Radial Noise Reduction Strength Adjustment

Parameter NameDescriptionSuggested ModificationSpecial Notes
m_bRadial_enEnable noise reduction strength adjustment along the radius: 0: Disable 1: EnableUser setting
m_pRadial_ratioControl of noise reduction strength increase along the radius; higher values mean stronger edge noise reductionYesAdjustable by Gain/Layer
m_bCnrRadial_enEnable chroma noise reduction strength adjustment along the radius: 0: Disable 1: EnableUser setting
m_pCnrRadial_ratioControl of chroma noise reduction strength increase along the radius; higher values mean stronger edge chroma noise reductionYesAdjustable by Gain/Layer

3D NR Motion Area Detection and Noise Reduction Strength Control

Parameter NameDescriptionSuggested ModificationSpecial Notes
m_pTnrDAvgInter-frame luminance average difference threshold; smaller values make motion detection easierYesAdjustable by Gain/Layer
m_pTnrWAvgWeight of inter-frame luminance average difference; larger values increase reliance on luminance diffYesAdjustable by Gain/Layer
m_pTnrQWeightAvgCoefficient for inter-frame luminance average difference; larger values make motion detection easierYesAdjustable by Gain/Layer
m_pTnrDSadThreshold for sum of absolute inter-frame luminance differences; smaller values make motion detection easierYesAdjustable by Gain/Layer
m_pTnrWSadWeight for sum of absolute inter-frame luminance differences; larger values increase reliance on this metricYesAdjustable by Gain/Layer
m_pTnrQWeightSadCoefficient for sum of absolute inter-frame luminance differences; larger values make motion detection easierYesAdjustable by Gain/Layer
m_pTnrDuvThreshold for inter-frame UV average difference; smaller values make motion detection easierYesAdjustable by Gain/Layer
m_pTnrWuvWeight for inter-frame UV average difference; larger values increase reliance on UV differenceYesAdjustable by Gain/Layer
m_pTnrQWeightUVCoefficient for inter-frame UV average difference; larger values make motion detection easierYesAdjustable by Gain/Layer
m_nTnrLumaBaseBase luminance difference threshold; smaller values make motion detection easierNo
m_pTnrLumaThreshold for luminance-based inter-frame average difference; smaller values make motion detection easierYesAdjustable by Gain/Layer
m_pTnrYStrengthQ6TNR global luminance noise reduction strength; larger values increase luminance noise reduction in static areasYesAdjustable by Gain/Layer
m_pTnrUVStrengthQ6TNR global chroma noise reduction strength; larger values increase chroma noise reduction in static areasYesAdjustable by Gain/Layer
m_pStrongSig_gainReference threshold for luminance noise reduction in motion areas; smaller values increase noise reductionYesAdjustable by Gain/Layer
m_pStrongAback_alphaLuminance noise re-addition in motion areas; larger values increase re-added noiseYesAdjustable by Gain/Layer

3D NR Other Parameters

Parameter NameDescriptionSuggested ModificationSpecial Notes
m_nTnrLumaWeightWindow size used for luminance calculationNo
m_pTnrBlockWeight0Window size for luminance difference calculation in Layer 0No
m_pTnrBlockWeight1Window size for luminance difference calculation in Layer 1No
m_pTnrBlockWeight234Window size for luminance difference calculation in Layers 2, 3, and 4No
m_pTnr2dMappingCurveFusion coefficient for noise reduction intensity between motion and still areas: 256 = full weak (still area) noise reduction, 0 = max strong (motion area) weightNo
m_p*RatioReserved
Chromatic Aberration Suppression

The chromatic aberration suppression function is controlled jointly by overexposed points and the hue_pf interval. Color fringes that meet the overexposed points condition and fall within the hue_pf interval will be suppressed.

Parameter NameDescriptionSuggested ModificationSpecial Notes
ebColor detection switch; when enabled, denoising for skin and blue sky regions is enhancedUser setting
m_ppf_enPurple fringe removal enable: 0: Disable 1: EnableUser setting
m_nwp_enOverexposure area detection enable for purple fringe removal: 0: Disable 1: EnableUser setting
m_nwp_thThreshold for overexposed pixel determination; higher value means fewer pixels considered overexposed (see Uv_wp_gain - num_wb diagram)Yes
m_nnum_wp_minThreshold to start overexposed area effect; purple fringe removal starts when overexposed points exceed this number (see Uv_wp_gain - num_wb diagram)Yes
m_nnum_wp_stepControls the transition interval (see Uv_wp_gain - num_wb diagram)Yes
m_nhue_pf_minLower bound of the purple fringe hue interval (see Uv_pf_gain - hue_pf diagram)Yes
m_nhue_pf_maxUpper bound of the purple fringe hue interval (see Uv_pf_gain - hue_pf diagram)Yes
m_nhue_pf_tr_stepTransition control for the purple fringe hue interval (see Uv_pf_gain - hue_pf diagram)Yes
m_nuv_wp_gainWeight of overexposed points; higher value means overexposed points have greater impact on final saturation (see Uv_wp_gain - num_wb diagram)YesCan vary with Gain
m_nuv_pf_gainWeight of the purple fringe interval; higher value means greater impact on final saturation (see Uv_pf_gain - hue_pf diagram)YesCan vary with Gain

Uv_pf_gain – hue_pf Diagram

Uv_wb_gain – num_wp Diagram


Raw HDR Parameter Description

The Raw_HDR_Soft module controls software HDR processing.

Raw HDR Parameters

Parameter NameDescriptionSuggested TuningSpecial Notes
m_nHDRDownSampleEbDownsampling enable; should be enabled when input image width or height exceeds 8225 pixelsNo
m_nINTFlagError handling flagNo
m_pGTMCurveSetGTM curve set; 5 sets corresponding to long and short exposure multiples: 1, 4, 16, 64, 256No

File to File

File to File Function Description

he platform supports hardware simulation called File to File (f2f), which pushes a VRF file into the device, replacing the sensor image data, and obtains the ISP-processed image. This is suitable for single-frame simulation.

File to File Usage Instructions

  1. Connect the device to the PC via USB.

  2. Use ADB to push the VRF file to the specified path with the specified filename (different filenames correspond to different tuning parameters):

    • Main camera

      adb push xxx.vrf vendor/etc/camera/rear_primary_sensor.vrf
    • 副摄

      adb push xxx.vrf vendor/etc/camera/rear_secondary_sensor.vrf
    • 前摄

      db push xxx.vrf vendor/etc/camera/front_sensor.vrf
  3. Start the camera to see the VRF preview processed by the ISP. You can also capture photos saved as JPG.

Quick Validation of Tuning Parameters

Quick Validation Function Description

  1. The platform supports quick validation of tuning parameters. Enable the following property:

    adb shell setprop persist.vendor.camera.enable.settingfile 1
  2. Save the tuning parameters from the Tuning Tool, then push them to the device at the specified path with the specified filename via ADB. Restart the camera for the changes to take effect:

    adb push xx.data /vendor/etc/camera/tuning_files/

Storage Path:

/vendor/etc/camera/tuning_files/

Common File Names:

FlickerSetting.data
front_cpp_nightshot_setting.data // Front Camera
front_cpp_preview_setting.data front_cpp_snapshot_setting.data front_cpp_video_setting.data front_isp_setting.data front_isp_setting_video.data front_nightshot_setting.data rawhdr_default_setting.data rear_primary_cpp_nightshot_setting.data // Main Camera
rear_primary_cpp_preview_setting.data rear_primary_cpp_snapshot_setting.data rear_primary_cpp_video_setting.data rear_primary_isp_setting.data rear_primary_isp_setting_video.data rear_primary_nightshot_setting.data
rear_secondary_cpp_nightshot_setting.data // Rear Secondary Camera
rear_secondary_cpp_preview_setting.data rear_secondary_cpp_snapshot_setting.data rear_secondary_cpp_video_setting.data rear_secondary_isp_setting.data rear_secondary_isp_setting_video.data rear_secondary_nightshot_setting.data

VRF viewer

VRF Viewer Interface

Click on a VRF file to launch the VRF viewer. The interface is shown below:

Menu: Functional Area

  • Open: Open an image (supported formats: *.vrf, *.nv12, *.nv21, *.yuv, *.bmp, *.jpg, *.jpeg, *.png)

  • Save: Save the image (supported formats: *.bmp, *.jpg, *.jpeg, *.png)

  • Options: Image processing options (click Apply to apply options, click Save to save current settings)

  • Options for VRF images:

    • Demosaic: Apply demosaicing
    • Linearization: Apply linearization processing
    • WB: Apply white balance gains from VRF
    • Dgain: Apply digital gain from VRF
    • Gamma: Apply sRGB Gamma curve
    • Split Channel: Display the four Bayer channels separately
  • Options for YUV images:

    • Color Standard: Choose BT601 or BT709
    • Swing: Set YUV data range (Full range or Standard range)
    • YUV: NV12 / NV21 conversion
    • Gray Image: Display grayscale image

Other Function Buttons

  • ZoomIn: Zoom in the image
  • Normal: Display the image at original size
  • ZoomOut: Zoom out the image
  • Move: Drag the image to view different areas
  • Select: Select a region in the image by drawing a rectangle
  • Histogram: View the brightness and color histograms of the image
  • Info: Display metadata of the VRF image (e.g., format, resolution, gain)
  • Window: Switch between opened image windows
  • Previous: Show the previous image
  • Next: Show the next image