1 /* SPDX-License-Identifier: GPL-2.0 */
2 /* Release Version: irci_stable_candrpv_0415_20150521_0458 */
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 #ifndef __IA_CSS_HDR_TYPES_H
18 #define __IA_CSS_HDR_TYPES_H
19 
20 #define IA_CSS_HDR_MAX_NUM_INPUT_FRAMES         (3)
21 
22 /**
23  * \brief HDR Irradiance Parameters
24  * \detail Currently HDR parameters are used only for testing purposes
25  */
26 struct ia_css_hdr_irradiance_params {
27 	int test_irr;                                          /** Test parameter */
28 	int match_shift[IA_CSS_HDR_MAX_NUM_INPUT_FRAMES -
29 							1];  /** Histogram matching shift parameter */
30 	int match_mul[IA_CSS_HDR_MAX_NUM_INPUT_FRAMES -
31 						      1];    /** Histogram matching multiplication parameter */
32 	int thr_low[IA_CSS_HDR_MAX_NUM_INPUT_FRAMES -
33 						    1];      /** Weight map soft threshold low bound parameter */
34 	int thr_high[IA_CSS_HDR_MAX_NUM_INPUT_FRAMES -
35 						     1];     /** Weight map soft threshold high bound parameter */
36 	int thr_coeff[IA_CSS_HDR_MAX_NUM_INPUT_FRAMES -
37 						      1];    /** Soft threshold linear function coefficien */
38 	int thr_shift[IA_CSS_HDR_MAX_NUM_INPUT_FRAMES -
39 						      1];    /** Soft threshold precision shift parameter */
40 	int weight_bpp;                                        /** Weight map bits per pixel */
41 };
42 
43 /**
44  * \brief HDR Deghosting Parameters
45  * \detail Currently HDR parameters are used only for testing purposes
46  */
47 struct ia_css_hdr_deghost_params {
48 	int test_deg; /** Test parameter */
49 };
50 
51 /**
52  * \brief HDR Exclusion Parameters
53  * \detail Currently HDR parameters are used only for testing purposes
54  */
55 struct ia_css_hdr_exclusion_params {
56 	int test_excl; /** Test parameter */
57 };
58 
59 /**
60  * \brief HDR public paramterers.
61  * \details Struct with all parameters for HDR that can be seet from
62  * the CSS API. Currenly, only test parameters are defined.
63  */
64 struct ia_css_hdr_config {
65 	struct ia_css_hdr_irradiance_params irradiance; /** HDR irradiance parameters */
66 	struct ia_css_hdr_deghost_params    deghost;    /** HDR deghosting parameters */
67 	struct ia_css_hdr_exclusion_params  exclusion; /** HDR exclusion parameters */
68 };
69 
70 #endif /* __IA_CSS_HDR_TYPES_H */
71