gibias.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 #ifndef GIBIAS_H
00029 #define GIBIAS_H
00030
00031 #include <cxstring.h>
00032
00033 #include <cpl_macros.h>
00034 #include <cpl_parameterlist.h>
00035 #include <cpl_matrix.h>
00036
00037 #include <giimage.h>
00038
00039
00040 #ifdef __cplusplus
00041 extern "C" {
00042 #endif
00043
00044
00045 enum GiBiasMethod {
00046 GIBIAS_METHOD_UNDEFINED,
00047 GIBIAS_METHOD_UNIFORM,
00048 GIBIAS_METHOD_PLANE,
00049 GIBIAS_METHOD_CURVE,
00050 GIBIAS_METHOD_MASTER,
00051 GIBIAS_METHOD_ZMASTER
00052 };
00053
00054 typedef enum GiBiasMethod GiBiasMethod;
00055
00056
00057 enum GiBiasOption {
00058 GIBIAS_OPTION_UNDEFINED,
00059 GIBIAS_OPTION_PLANE,
00060 GIBIAS_OPTION_CURVE
00061 };
00062
00063 typedef enum GiBiasOption GiBiasOption;
00064
00065
00066 enum GiBiasModel {
00067 GIBIAS_MODEL_UNDEFINED,
00068 GIBIAS_MODEL_FITTED,
00069 GIBIAS_MODEL_MEAN
00070 };
00071
00072 typedef enum GiBiasModel GiBiasModel;
00073
00074
00075 struct GiBiasConfig {
00076 GiBiasMethod method;
00077 GiBiasModel model;
00078 GiBiasOption option;
00079 cxdouble mbias;
00080 cxint remove;
00081 cxchar *areas;
00082 cxdouble xdeg;
00083 cxdouble ydeg;
00084 cxdouble xstep;
00085 cxdouble ystep;
00086 cxdouble sigma;
00087 cxint iterations;
00088 cxdouble fraction;
00089 };
00090
00091 typedef struct GiBiasConfig GiBiasConfig;
00092
00093
00094
00095
00096
00097
00098 cpl_matrix *giraffe_get_raw_areas(GiImage *image);
00099 cxint giraffe_trim_raw_areas(GiImage *image);
00100
00101
00102
00103
00104
00105 cxint
00106 giraffe_bias_remove(GiImage *result_img, GiImage *raw_frame,
00107 GiImage *master_bias, GiImage *bad_pixels,
00108 cpl_matrix *biaslimits, GiBiasConfig *config);
00109
00110
00111
00112
00113
00114
00115 GiBiasConfig *giraffe_bias_config_create(cpl_parameterlist *list);
00116 void giraffe_bias_config_destroy(GiBiasConfig *config);
00117
00118 void giraffe_bias_config_add(cpl_parameterlist *list);
00119
00120
00121 #ifdef __cplusplus
00122 }
00123 #endif
00124
00125 #endif