GIRAFFE Pipeline Reference Manual

gicube.h
1 /*
2  * This file is part of the GIRAFFE Pipeline
3  * Copyright (C) 2002-2019 European Southern Observatory
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18  */
19 
20 #ifndef GICUBE_H
21 #define GICUBE_H
22 
23 #include <cxtypes.h>
24 
25 #include <cpl_matrix.h>
26 #include <cpl_image.h>
27 #include <cpl_propertylist.h>
28 
29 
30 #ifdef __cplusplus
31 extern "C" {
32 #endif
33 
34 
35  typedef struct GiCube GiCube;
36 
37 
38  GiCube* giraffe_cube_new(void);
39  GiCube* giraffe_cube_create(cxsize width, cxsize height, cxsize depth,
40  cxdouble* data);
41  void giraffe_cube_delete(GiCube* self);
42 
43  cxsize giraffe_cube_get_width(const GiCube* self);
44  cxsize giraffe_cube_get_height(const GiCube* self);
45  cxsize giraffe_cube_get_depth(const GiCube* self);
46 
47  cxsize giraffe_cube_get_size(const GiCube* self);
48  cxint giraffe_cube_set_size(GiCube* self, cxsize width, cxsize height,
49  cxsize depth);
50 
51  cxdouble* giraffe_cube_get_data(const GiCube* self);
52 
53  cxbool giraffe_cube_has_xaxis(const GiCube* self);
54  cxbool giraffe_cube_has_yaxis(const GiCube* self);
55  cxbool giraffe_cube_has_zaxis(const GiCube* self);
56  cxbool giraffe_cube_has_wcs(const GiCube* self);
57 
58  cxint giraffe_cube_get_xaxis(const GiCube* self, cxdouble* start,
59  cxdouble* step);
60  cxint giraffe_cube_get_yaxis(const GiCube* self, cxdouble* start,
61  cxdouble* step);
62  cxint giraffe_cube_get_zaxis(const GiCube* self, cxdouble* start,
63  cxdouble* step);
64 
65  cxint giraffe_cube_set_xaxis(GiCube* self, cxdouble start, cxdouble step);
66  cxint giraffe_cube_set_yaxis(GiCube* self, cxdouble start, cxdouble step);
67  cxint giraffe_cube_set_zaxis(GiCube* self, cxdouble start, cxdouble step);
68 
69  void giraffe_cube_clear_wcs(GiCube* self);
70 
71  cxint giraffe_cube_set_wcs(GiCube* self, const cpl_propertylist* axes,
72  const cpl_matrix* transformation);
73 
74  cxint giraffe_cube_sqrt(GiCube* self);
75 
76  cpl_image* giraffe_cube_integrate(const GiCube* self, cxdouble start,
77  cxdouble end);
78 
79  cxint giraffe_cube_save(const GiCube* self, cpl_propertylist* properties,
80  const cxchar* filename, cxcptr data);
81 
82 
83 #ifdef __cplusplus
84 }
85 #endif
86 
87 #endif /* GICUBE_H */
cxint giraffe_cube_get_xaxis(const GiCube *self, cxdouble *start, cxdouble *step)
Get the data cube's x-axis start value and step size.
Definition: gicube.c:828
cxbool giraffe_cube_has_yaxis(const GiCube *self)
Check whether a y-axis is defined for the given cube.
Definition: gicube.c:759
cxsize giraffe_cube_get_width(const GiCube *self)
Get the width of the given data cube.
Definition: gicube.c:530
cxint giraffe_cube_get_yaxis(const GiCube *self, cxdouble *start, cxdouble *step)
Get the data cube's y-axis start value and step size.
Definition: gicube.c:859
cxint giraffe_cube_set_size(GiCube *self, cxsize width, cxsize height, cxsize depth)
Set the size of a data cube.
Definition: gicube.c:627
cxsize giraffe_cube_get_depth(const GiCube *self)
Get the depth of the given data cube.
Definition: gicube.c:576
cxbool giraffe_cube_has_zaxis(const GiCube *self)
Check whether a z-axis is defined for the given cube.
Definition: gicube.c:780
cxint giraffe_cube_set_yaxis(GiCube *self, cxdouble start, cxdouble step)
Set the data cube's y-axis start value and step size.
Definition: gicube.c:942
cxint giraffe_cube_get_zaxis(const GiCube *self, cxdouble *start, cxdouble *step)
Get the data cube's z-axis start value and step size.
Definition: gicube.c:890
cxint giraffe_cube_set_wcs(GiCube *self, const cpl_propertylist *axes, const cpl_matrix *transformation)
Set the data cube's world coordinate system.
Definition: gicube.c:1032
void giraffe_cube_clear_wcs(GiCube *self)
Remove the world coordinate system from the cube.
Definition: gicube.c:993
cxint giraffe_cube_set_zaxis(GiCube *self, cxdouble start, cxdouble step)
Set the data cube's z-axis start value and step size.
Definition: gicube.c:968
cxint giraffe_cube_set_xaxis(GiCube *self, cxdouble start, cxdouble step)
Set the data cube's x-axis start value and step size.
Definition: gicube.c:916
void giraffe_cube_delete(GiCube *self)
Destroys a cube object.
Definition: gicube.c:504
GiCube * giraffe_cube_new(void)
Create an empty data cube.
Definition: gicube.c:412
cxint giraffe_cube_save(const GiCube *self, cpl_propertylist *properties, const cxchar *filename, cxcptr data)
Save the given data cube to disk.
Definition: gicube.c:1236
GiCube * giraffe_cube_create(cxsize width, cxsize height, cxsize depth, cxdouble *data)
Create a data cube with the given width, height and depth.
Definition: gicube.c:447
cxsize giraffe_cube_get_height(const GiCube *self)
Get the height of the given data cube.
Definition: gicube.c:553
cpl_image * giraffe_cube_integrate(const GiCube *self, cxdouble start, cxdouble end)
Integrate a cube along the z-axis.
Definition: gicube.c:1142
cxint giraffe_cube_sqrt(GiCube *self)
Compute the square root of the elements of a cube.
Definition: gicube.c:1091
cxbool giraffe_cube_has_wcs(const GiCube *self)
Check whether a world coordinate system is defined for the given cube.
Definition: gicube.c:801
cxsize giraffe_cube_get_size(const GiCube *self)
Get the size of the given data cube.
Definition: gicube.c:599
cxbool giraffe_cube_has_xaxis(const GiCube *self)
Check whether an x-axis is defined for the given cube.
Definition: gicube.c:738
cxdouble * giraffe_cube_get_data(const GiCube *self)
Get a reference to the data cube's pixel buffer.
Definition: gicube.c:707

This file is part of the GIRAFFE Pipeline Reference Manual 2.16.10.
Documentation copyright © 2002-2006 European Southern Observatory.
Generated on Thu Dec 15 2022 21:18:51 by doxygen 1.9.1 written by Dimitri van Heesch, © 1997-2004