35 #include "giextraction.h"
57 giraffe_extraction_new(
void)
60 GiExtraction*
self = cx_malloc(
sizeof *
self);
65 self->centroid = NULL;
91 giraffe_extraction_create(GiImage* spectra, GiImage* error, GiImage* npixels,
92 GiImage* centroid, GiImage* model)
95 GiExtraction*
self = giraffe_extraction_new();
98 if (spectra != NULL) {
99 self->spectra = spectra;
106 if (npixels != NULL) {
107 self->npixels = npixels;
110 if (centroid != NULL) {
111 self->centroid = centroid;
140 giraffe_extraction_delete(GiExtraction* extraction)
143 if (extraction != NULL) {
166 giraffe_extraction_destroy(GiExtraction* extraction)
169 if (extraction != NULL) {
171 if (extraction->spectra != NULL) {
173 extraction->spectra = NULL;
176 if (extraction->error != NULL) {
178 extraction->error = NULL;
181 if (extraction->npixels != NULL) {
183 extraction->npixels = NULL;
186 if (extraction->centroid != NULL) {
188 extraction->centroid = NULL;
191 if (extraction->model != NULL) {
193 extraction->model = NULL;