ifw-odp 5.0.0
Loading...
Searching...
No Matches
clipm_priv_image.h
Go to the documentation of this file.
1
2/*********************************************************************
3 * E.S.O. - VLT project
4 *
5 * "@(#) $Id: clipm_priv_image.h 262062 2014-11-24 12:32:58Z cgarcia $"
6 *
7 * Private functions for handling images
8 *
9 * who when what
10 * -------- ---------- ----------------------------------------------
11 * hlorch 2006-08-12 created
12 */
13
14#ifndef CLIPM_PRIV_IMAGE_H
15#define CLIPM_PRIV_IMAGE_H
16
17/*-----------------------------------------------------------------------------
18 Includes
19 -----------------------------------------------------------------------------*/
20
21#include <cpl.h>
22
23/*-----------------------------------------------------------------------------
24 Declaration Block
25 -----------------------------------------------------------------------------*/
26
27#ifdef __cplusplus
28extern "C" {
29#endif
30
31/*-----------------------------------------------------------------------------
32 Prototypes
33 -----------------------------------------------------------------------------*/
34
35cpl_image *clipm_priv_image_wrap( const cpl_size *size,
36 cpl_type type,
37 void *data);
38
40 const cpl_image *image,
41 double x,
42 double y,
43 cpl_size *out_x,
44 cpl_size *out_y);
45
46const cpl_binary *clipm_priv_image_bpm_get_if_exist(
47 const cpl_image *image);
48
49cpl_error_code clipm_priv_image_bpm_or( cpl_image *mod_image,
50 const cpl_image *ref_image);
51
53 cpl_image *image,
54 cpl_size left,
55 cpl_size right,
56 cpl_size lower,
57 cpl_size upper);
58
60 cpl_image *image,
61 const cpl_size *window_xxyy,
62 double limit);
63
65 const cpl_image *image,
66 const cpl_size *window_xxyy,
67 cpl_size *out_ngood);
68
70 const cpl_image *image,
71 const cpl_size *window_xxyy,
72 int allow_window_NULL,
73 cpl_size *img_size_xy,
74 cpl_size *window_size_xy,
75 cpl_size *buffer_start_xy,
76 cpl_type *type,
77 const void **data_start,
78 const cpl_binary
79 **badp_start);
80
82 const cpl_image *input,
83 const cpl_size *window_xxyy,
84 cpl_type outtype);
85
87 const cpl_image *input,
88 const cpl_size *window_xxyy);
89
90cpl_error_code clipm_priv_image_fill( cpl_image *image,
91 const cpl_size *window_xxyy,
92 double value);
93
94cpl_error_code clipm_priv_image_fill_circle(
95 cpl_image *img_modified,
96 double centre_xy[2],
97 double radius,
98 double brightness,
99 int anti_alias,
100 int additive);
101
102cpl_error_code clipm_priv_image_fill_polygon(
103 cpl_image *image,
104 const cpl_matrix *points,
105 double brightness,
106 int anti_alias,
107 int additive);
108
110 cpl_image *image,
111 const double centre_xy[2],
112 double angle,
113 const double size_lw[2],
114 double brightness,
115 int anti_alias,
116 int additive);
117
118cpl_error_code clipm_priv_image_save_debug(const cpl_image *img,
119 const char *filename);
120
121void clipm_priv_image_null( cpl_image **i);
122
123/*----------------------------------------------------------------------------*/
124
125#ifdef __cplusplus
126} /* extern "C" */
127#endif
128
129#endif /* CLIPM_PRIV_IMAGE_H */
cpl_error_code clipm_priv_image_fill_circle(cpl_image *img_modified, double centre_xy[2], double radius, double brightness, int anti_alias, int additive)
Fill a circle.
Definition clipm_priv_image.c:1674
double clipm_priv_image_get_nearest_good(const cpl_image *image, double x, double y, cpl_size *out_x, cpl_size *out_y)
Return closest pixel which is not flagged as bad.
Definition clipm_priv_image.c:480
cpl_error_code clipm_priv_image_get_data_const(const cpl_image *image, const cpl_size *window_xxyy, int allow_window_NULL, cpl_size *img_size_xy, cpl_size *window_size_xy, cpl_size *buffer_start_xy, cpl_type *type, const void **data_start, const cpl_binary **badp_start)
Get image and window sizes, and data pointers to image (window).
Definition clipm_priv_image.c:1127
const cpl_binary * clipm_priv_image_bpm_get_if_exist(const cpl_image *image)
Return bad pixel mask data, if there are bad pixels, otherwise NULL.
Definition clipm_priv_image.c:633
cpl_error_code clipm_priv_image_fill(cpl_image *image, const cpl_size *window_xxyy, double value)
Apply a value to all pixels inside the image or a window of the image.
Definition clipm_priv_image.c:1548
cpl_image * clipm_priv_image_extract_cast(const cpl_image *input, const cpl_size *window_xxyy, cpl_type outtype)
Extract an image window and cast into a new image.
Definition clipm_priv_image.c:1229
cpl_vector * clipm_priv_image_copy_good_data_vector(const cpl_image *image, const cpl_size *window_xxyy, cpl_size *out_ngood)
Copy all non-bad pixels into a new vector of appropriate size.
Definition clipm_priv_image.c:956
cpl_image * clipm_priv_image_extract_round(const cpl_image *input, const cpl_size *window_xxyy)
Extract an image window and round to integer.
Definition clipm_priv_image.c:1386
cpl_image * clipm_priv_image_wrap(const cpl_size *size, cpl_type type, void *data)
Create an image by wrapping it around an existing data buffer.
Definition clipm_priv_image.c:405
cpl_error_code clipm_priv_image_bpm_reject_above(cpl_image *image, const cpl_size *window_xxyy, double limit)
Reject all pixels equal to or greater than a limit.
Definition clipm_priv_image.c:826
cpl_error_code clipm_priv_image_bpm_or(cpl_image *mod_image, const cpl_image *ref_image)
Perform a logical OR between the bad pixel masks of 2 images.
Definition clipm_priv_image.c:673
cpl_error_code clipm_priv_image_save_debug(const cpl_image *img, const char *filename)
Write an image to disk and print a message.
Definition clipm_priv_image.c:2183
cpl_error_code clipm_priv_image_bpm_border_bad(cpl_image *image, cpl_size left, cpl_size right, cpl_size lower, cpl_size upper)
Mark the border of an image as bad.
Definition clipm_priv_image.c:727
void clipm_priv_image_null(cpl_image **i)
Delete a CPL image object and set the pointer to NULL.
Definition clipm_priv_image.c:2274
cpl_error_code clipm_priv_image_fill_rectangle(cpl_image *image, const double centre_xy[2], double angle, const double size_lw[2], double brightness, int anti_alias, int additive)
Fill a rectangle.
Definition clipm_priv_image.c:2113
cpl_error_code clipm_priv_image_fill_polygon(cpl_image *image, const cpl_matrix *points, double brightness, int anti_alias, int additive)
Fill a polygon.
Definition clipm_priv_image.c:1889