linux/drivers/staging/media/atomisp/pci/atomisp2/css2400/isp/kernels/bnlm/ia_css_bnlm_param.h
<<
>>
Prefs
   1/*
   2 * Support for Intel Camera Imaging ISP subsystem.
   3 * Copyright (c) 2015, Intel Corporation.
   4 *
   5 * This program is free software; you can redistribute it and/or modify it
   6 * under the terms and conditions of the GNU General Public License,
   7 * version 2, as published by the Free Software Foundation.
   8 *
   9 * This program is distributed in the hope it will be useful, but WITHOUT
  10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
  12 * more details.
  13 */
  14
  15#ifndef __IA_CSS_BNLM_PARAM_H
  16#define __IA_CSS_BNLM_PARAM_H
  17
  18#include "type_support.h"
  19#include "vmem.h" /* needed for VMEM_ARRAY */
  20
  21struct bnlm_lut {
  22        VMEM_ARRAY(thr, ISP_VEC_NELEMS); /* thresholds */
  23        VMEM_ARRAY(val, ISP_VEC_NELEMS); /* values */
  24};
  25
  26struct bnlm_vmem_params {
  27        VMEM_ARRAY(nl_th, ISP_VEC_NELEMS);
  28        VMEM_ARRAY(match_quality_max_idx, ISP_VEC_NELEMS);
  29        struct bnlm_lut mu_root_lut;
  30        struct bnlm_lut sad_norm_lut;
  31        struct bnlm_lut sig_detail_lut;
  32        struct bnlm_lut sig_rad_lut;
  33        struct bnlm_lut rad_pow_lut;
  34        struct bnlm_lut nl_0_lut;
  35        struct bnlm_lut nl_1_lut;
  36        struct bnlm_lut nl_2_lut;
  37        struct bnlm_lut nl_3_lut;
  38
  39        /* LUTs used for division approximiation */
  40        struct bnlm_lut div_lut;
  41        VMEM_ARRAY(div_lut_intercepts, ISP_VEC_NELEMS);
  42
  43        /* 240x does not have an ISP instruction to left shift each element of a
  44         * vector by different shift value. Hence it will be simulated by multiplying
  45         * the elements by required 2^shift. */
  46        VMEM_ARRAY(power_of_2, ISP_VEC_NELEMS);
  47};
  48
  49/* BNLM ISP parameters */
  50struct bnlm_dmem_params {
  51        bool rad_enable;
  52        int32_t rad_x_origin;
  53        int32_t rad_y_origin;
  54        int32_t avg_min_th;
  55        int32_t max_min_th;
  56
  57        int32_t exp_coeff_a;
  58        uint32_t exp_coeff_b;
  59        int32_t exp_coeff_c;
  60        uint32_t exp_exponent;
  61};
  62
  63#endif /* __IA_CSS_BNLM_PARAM_H */
  64