GNU Linux-libre 4.14.254-gnu1
[releases.git] / drivers / staging / media / atomisp / pci / atomisp2 / css2400 / isp / kernels / hdr / ia_css_hdr.host.c
1 /* Release Version: irci_stable_candrpv_0415_20150521_0458 */
2 /* Release Version: irci_ecr-master_20150911_0724 */
3 /*
4  * Support for Intel Camera Imaging ISP subsystem.
5  * Copyright (c) 2015, Intel Corporation.
6  *
7  * This program is free software; you can redistribute it and/or modify it
8  * under the terms and conditions of the GNU General Public License,
9  * version 2, as published by the Free Software Foundation.
10  *
11  * This program is distributed in the hope it will be useful, but WITHOUT
12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
14  * more details.
15  */
16
17 #include "ia_css_hdr.host.h"
18
19 void
20 ia_css_hdr_init_config(
21         struct sh_css_isp_hdr_params *to,
22         const struct ia_css_hdr_config *from,
23         unsigned size)
24 {
25         int i;
26         (void)size;
27
28         for (i = 0; i < HDR_NUM_INPUT_FRAMES - 1; i++) {
29                 to->irradiance.match_shift[i] = from->irradiance.match_shift[i];
30                 to->irradiance.match_mul[i]   = from->irradiance.match_mul[i];
31                 to->irradiance.thr_low[i]     = from->irradiance.thr_low[i];
32                 to->irradiance.thr_high[i]    = from->irradiance.thr_high[i];
33                 to->irradiance.thr_coeff[i]   = from->irradiance.thr_coeff[i];
34                 to->irradiance.thr_shift[i]   = from->irradiance.thr_shift[i];
35         }
36         to->irradiance.test_irr    = from->irradiance.test_irr;
37         to->irradiance.weight_bpp  = from->irradiance.weight_bpp;
38
39         to->deghost.test_deg    = from->deghost.test_deg;
40         to->exclusion.test_excl = from->exclusion.test_excl;
41 }