Tuning the Brightness Feature

This section describes how to tune the Brightness feature to compensate brightness in a maximum of two regions-of-interest (ROIs) of a DC9400.

Before you begin

Make sure:
  • The details view shows the settings of the Brightness feature for a DC9400 project.

    For information about how to show the settings in the details view, see Tuning a DC9400 Feature.

  • The VTunerClient is connected to a VTunerServer that works with a DC9400.

    For information about how to set up a connection to a VTunerServer, see Setting Up a Connection to a VTunerServer.

Procedure

  1. In the Project Explorer view, select the DPU project.
    Then, the features supported for tuning are listed in the Features view.
  2. In the Features view, click Brightness.
    Then, the settings of the Brightness feature are displayed in the details view.
    Figure 1. Details View When the Brightness is Selected

  3. In the upper-left corner of the details view of the Brightness feature, select the Enable Brightness check box to enable the brightness compensation module.
  4. To the right of Resource File, click and select an 8-bit alpha mask file.
    The RDMA reads only the alpha mask in the specified ROIs to save bandwidth.
  5. In the Resource Width text box, enter the width of the chosen mask.
  6. In the Resource Height text box, enter the height of the chosen mask.
  7. From the Mask Format drop-down list, select the color format of the alpha mask.
  8. From the Mask Tile drop-down list, select the tile mode of the alpha mask.
    • If the mask file is not compressed, set it VS_DPU_LINEAR.
    • If the mask file is compressed, set it to the used tiled format.
  9. Next to Enable Decompressed, select Enable or Disable to specify whether the mask file needs to be decompressed.
  10. Next to Enable ROI0, select Enable or Disable to specify whether to enable ROI 0.
  11. If Enable is selected for Enable ROI0, click View/Edit this Table next to ROI0 Rect and specify ROI 0 for brightness compensation in the prompted dialog.
    The columns in the ROI0 Rect table are described as follows:
    • ROI Width: the width of ROI 0
    • ROI Height: the height of ROI 0
    • ROI X: the X coordinate of the upper-left corner of the ROI 0
    • ROI Y: the Y coordinate of the upper-left corner of the ROI 0
    You can use one of the following methods to specify ROI 0 in the ROI0 Rect table:
    • Double-click and edit a cell in the table to update a single value.
    • Click Edit and update the values in the prompted Edit Table dialog.

      The values must be specified in the same order as the table columns and separated by a comma (,).

    • Click Export to export the values to a .csv file, edit the file, and then import the updated values from the .csv file.

      The order of the values in the exported .csv file is the same as that in the table.

  12. Next to Enable ROI1, select Enable or Disable to specify whether to enable ROI 1.
  13. If Enable is selected for Enable ROI1, specify ROI 1 for brightness compensation by referring to Step 11 and Step 12.
  14. In the Target Gain text box, enter the target brightness gain to adjust the alpha value.
    The target gain must not exceed 1024.
  15. From the Luma Mode drop-down list, select one of the following options to specify the luma calculation mode:
    • VS_DPU_DATAT_CALCU_MAX: the luma is derived from the maximum value among the red, green, and blue components.
    • VS_DPU_DATAT_CALCU_WEIGHT: the luma is derived from a weighted sum of the red, green, and blue components.
  16. If VS_DPU_DATAT_CALCU_WEIGHT is selected for Luma Mode, click View/Edit this Table next to Luma Coef and specify the R, G, and B weights in the prompted dialog.
    The columns in the Luma Coef table indicate the R, G, and B weights in order.
    The methods of updating the RGB weights are similar to those of updating the ROI table described in Step 11.
  17. In the Prot Threshold text box, enter the protection threshold.
    Brightness compensation is performed on a pixel only if its luma value is greater than the protection threshold.

Results

  • The tuning results are printed in the Console view in real time.
  • The image displayed on the VTunerServer side is updated.