summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJason Chen <b02280@freescale.com>2009-11-24 18:53:24 +0800
committerJason Chen <b02280@freescale.com>2009-11-24 18:53:24 +0800
commit7668c6f2527d862d78c8b45aa6d97cb15214a9ad (patch)
tree9456eede74165632dd72457316a3a96e29c9fce1 /include
parentba0e7753bfb874294f7776e76b52e19aa51e3505 (diff)
ENGR00116313 ipuv3: DP gamma support
Support DP gamma by setting piecewise linear approximation, application need set coefficient const[k] and slope[k]. The algorithm to calculate these coefficient pls refer to unit test. Signed-off-by: Jason Chen <b02280@freescale.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/ipu.h2
-rw-r--r--include/linux/mxcfb.h7
2 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/ipu.h b/include/linux/ipu.h
index 167abf1b900a..af2bb266244d 100644
--- a/include/linux/ipu.h
+++ b/include/linux/ipu.h
@@ -940,6 +940,8 @@ int32_t ipu_disp_set_global_alpha(ipu_channel_t channel, bool enable,
uint8_t alpha);
int32_t ipu_disp_set_color_key(ipu_channel_t channel, bool enable,
uint32_t colorKey);
+int32_t ipu_disp_set_gamma_correction(ipu_channel_t channel, bool enable,
+ int constk[], int slopek[]);
int ipu_init_async_panel(int disp, int type, uint32_t cycle_time,
uint32_t pixel_fmt, ipu_adc_sig_cfg_t sig);
diff --git a/include/linux/mxcfb.h b/include/linux/mxcfb.h
index 79c23c344dfa..f7d60a3377d3 100644
--- a/include/linux/mxcfb.h
+++ b/include/linux/mxcfb.h
@@ -51,6 +51,12 @@ struct mxcfb_pos {
__u16 y;
};
+struct mxcfb_gamma {
+ int enable;
+ int constk[16];
+ int slopek[16];
+};
+
#define MXCFB_WAIT_FOR_VSYNC _IOW('F', 0x20, u_int32_t)
#define MXCFB_SET_GBL_ALPHA _IOW('F', 0x21, struct mxcfb_gbl_alpha)
#define MXCFB_SET_CLR_KEY _IOW('F', 0x22, struct mxcfb_color_key)
@@ -58,6 +64,7 @@ struct mxcfb_pos {
#define MXCFB_GET_FB_IPU_CHAN _IOR('F', 0x25, u_int32_t)
#define MXCFB_SET_LOC_ALPHA _IOWR('F', 0x26, struct mxcfb_loc_alpha)
#define MXCFB_SET_LOC_ALP_BUF _IOW('F', 0x27, unsigned long)
+#define MXCFB_SET_GAMMA _IOW('F', 0x28, struct mxcfb_gamma)
#ifdef __KERNEL__