00001 /* 00002 * Copyright (c) 2009-2011, A. Buades <toni.buades@uib.es> 00003 * All rights reserved. 00004 * 00005 * 00006 * Patent warning: 00007 * 00008 * This file implements algorithms possibly linked to the patents 00009 * 00010 * # J. Hamilton Jr and J. Adams Jr, “Adaptive color plan interpolation 00011 * in single sensor color electronic camera,” 1997, US Patent 5,629,734. 00012 * 00013 * # D. Cok, “Signal processing method and apparatus for producing 00014 * interpolated chrominance values in a sampled color image signal”, 00015 * 1987, US Patent 4,642,678. 00016 * 00017 * # A. Buades, T. Coll and J.M. Morel, Image data processing method by 00018 * reducing image noise, and camera integrating means for implementing 00019 * said method, EP Patent 1,749,278 (Feb. 7, 2007). 00020 * 00021 * This file is made available for the exclusive aim of serving as 00022 * scientific tool to verify the soundness and completeness of the 00023 * algorithm description. Compilation, execution and redistribution 00024 * of this file may violate patents rights in certain countries. 00025 * The situation being different for every country and changing 00026 * over time, it is your responsibility to determine which patent 00027 * rights restrictions apply to you before you compile, use, 00028 * modify, or redistribute this file. A patent lawyer is qualified 00029 * to make this determination. 00030 * If and only if they don't conflict with any patent terms, you 00031 * can benefit from the following license terms attached to this 00032 * file. 00033 * 00034 * License: 00035 * 00036 * This program is provided for scientific and educational only: 00037 * you can use and/or modify it for these purposes, but you are 00038 * not allowed to redistribute this work or derivative works in 00039 * source or executable form. A license must be obtained from the 00040 * patent right holders for any other use. 00041 * 00042 * 00043 */ 00044 00045 00046 00047 #ifndef _LIBDEMOSAICKING_H_ 00048 #define _LIBDEMOSAICKING_H_ 00049 00050 00051 00052 #include <stdio.h> 00053 #include <stdlib.h> 00054 #include <math.h> 00055 00056 #include "libAuxiliary.h" 00057 00084 void demosaicking_adams(float threshold, int redx,int redy,float *ired,float *igreen,float *iblue,float *ored,float *ogreen,float *oblue,int width,int height); 00085 00086 00087 00099 void demosaicking_bilinear_red_blue(int redx,int redy,float *ored,float *ogreen,float *oblue,int width,int height); 00100 00101 00102 00103 00120 void demosaicking_nlmeans(int bloc, float h,int redx,int redy,float *ired,float *igreen,float *iblue,float *ored,float *ogreen,float *oblue,int width,int height); 00121 00122 00123 00140 void chromatic_median(int iter,int redx,int redy,int projflag,float side,float *ired,float *igreen, float *iblue,float *ored,float *ogreen,float *oblue,int width,int height); 00141 00142 00143 00144 00174 void ssd_demosaicking_chain(int redx,int redy,float *ired,float *igreen,float *iblue,float *ored,float *ogreen,float *oblue,int width,int height); 00175 00176 00177 00178 00179 00180 #endif