ngc 1.5.0
 
Loading...
Searching...
No Matches
ngcdttPUBLISH.hpp
Go to the documentation of this file.
1
8#ifndef ngcdttPUBLISH_H
9#define ngcdttPUBLISH_H
10
11
12#ifndef __cplusplus
13#error This is a C++ include file and cannot be used from plain C
14#endif
15
16/*
17 * System Headers
18 */
19
20/*
21 * Local Headers
22 */
23#include <ngc/core/ngcppInt.h>
24
28#define ngcdttPUBLISH_MAXBUF 8
29
35 char *memPtr;
36
39
41 int locked;
42
44 int sub;
45
48 memPtr = NULL;
50 locked = 0;
51 sub = 0;
52 }
53};
54
58class ngcdttFP {
59public:
62
65 enabled = 0; size_ = 0; dtype_ = ngcppDTYPE_BYTE; dtypeOrig_ = dtype_;
66 }
67
69 virtual ~ngcdttFP() {
70 Clear();
71 }
72
74 void Clear() {
75 if (frame_.memPtr != NULL)
76 {
77 free(frame_.memPtr); frame_.memPtr = NULL;
78 }
79 ngcppHdrInit(&frame_.hdr);
80 size_ = 0;
81 }
82
85 int size = f->hdr.nx * f->hdr.ny;
86
87 if (f->memPtr == NULL)
88 {
89 /*
90 * We simply do not store this
91 */
92 return (ngcbSUCCESS);
93 }
94
95 if (Stored() && f->sub)
96 {
97 if (Add_(f) != ngcbSUCCESS)
98 {
99 Clear();
100 return (ngcbFAILURE);
101 }
102 }
103
104 switch (f->hdr.dtype)
105 {
106 case ngcppDTYPE_INT16:
108 {
109 size *= 2; break;
110 }
111 case ngcppDTYPE_INT32:
113 {
114 size *= 4; break;
115 }
116 case ngcppDTYPE_INT64:
118 {
119 size *= 8; break;
120 }
121 default:
122 break;
123 }
124
125 /*
126 * Allocate
127 */
128 if (frame_.memPtr == NULL)
129 {
130 frame_.memPtr = (char *)malloc(size);
131 if (frame_.memPtr == NULL)
132 {
133 return (ngcbFAILURE);
134 }
135 size_ = size;
136 }
137 else if (size_ != size)
138 {
139 char *p = (char *)realloc(frame_.memPtr, size);
140 if (p == NULL)
141 {
142 Clear();
143 return (ngcbFAILURE);
144 }
145 else
146 {
147 frame_.memPtr = p;
148 size_ = size;
149 }
150 }
151
152 /*
153 * Copy header + data
154 */
155 memcpy(&frame_.hdr, &f->hdr, sizeof(ngcpp_hdr_t));
156 memcpy(frame_.memPtr, f->memPtr, size_);
157
158 return (ngcbSUCCESS);
159 }
160
162 int Store(const char *fileName) {
163 ngcb_cube_t cube;
164 char erms[256];
165 int size;
166
167 /*
168 * Open FITS-file
169 */
170 if (ngcbCubeOpen(fileName, &cube, erms) != ngcbSUCCESS)
171 {
172 /*
173 * We simply do nothing
174 */
175 return (ngcbSUCCESS);
176 }
177
178 if ((cube.bitPix != 16) && (cube.bitPix != 32) &&
179 (cube.bitPix != -32) && (cube.bitPix != -64))
180 {
181 /*
182 * The format is not supported - we do not load this
183 */
184 ngcbCubeClose(cube);
185 return (ngcbSUCCESS);
186 }
187
188 size = cube.naxis1 * cube.naxis2 * abs(cube.bitPix / 8);
189 if (size < 0)
190 {
191 /*
192 * The format is not supported - we do not load this
193 */
194 ngcbCubeClose(cube);
195 return (ngcbSUCCESS);
196 }
197
198 /*
199 * Allocate
200 */
201 if (frame_.memPtr == NULL)
202 {
203 frame_.memPtr = (char *)malloc(size);
204 if (frame_.memPtr == NULL)
205 {
206 ngcbCubeClose(cube);
207 return (ngcbFAILURE);
208 }
209 size_ = size;
210 }
211 else if (size_ != size)
212 {
213 char *p = (char *)realloc(frame_.memPtr, size);
214 if (p == NULL)
215 {
216 Clear();
217 ngcbCubeClose(cube);
218 return (ngcbFAILURE);
219 }
220 else
221 {
222 frame_.memPtr = p;
223 size_ = size;
224 }
225 }
226
227 /*
228 * Copy header + data
229 */
230 ngcppHdrInit(&frame_.hdr);
231 if (ngcbCubeRead(cube, frame_.memPtr, 0, erms) != ngcbSUCCESS)
232 {
233 Clear();
234 ngcbCubeClose(cube);
235 return (ngcbFAILURE);
236 }
237 frame_.hdr.nx = cube.naxis1;
238 frame_.hdr.ny = cube.naxis2;
239 switch (cube.bitPix)
240 {
241 case 16:
242 {
243 frame_.hdr.dtype = ngcppDTYPE_INT16;
244 frame_.hdr.bzero = (int)cube.bzero;
245 break;
246 }
247 case 32:
248 {
249 frame_.hdr.dtype = ngcppDTYPE_INT32;
250 break;
251 }
252 case -32:
253 {
254 frame_.hdr.dtype = ngcppDTYPE_REAL32;
255 break;
256 }
257 case -64:
258 {
259 frame_.hdr.dtype = ngcppDTYPE_REAL64;
260 break;
261 }
262 default:
263 {
264 frame_.hdr.dtype = ngcppDTYPE_REAL32;
265 break;
266 }
267 }
268
269 ngcbCubeClose(cube);
270
271 return (ngcbSUCCESS);
272 }
273
275 int Stored() {return ((frame_.memPtr != NULL));}
276
279 int i, n;
280
281 if (!Stored() || !enabled) return (ngcbSUCCESS);
282
283 /*
284 * Check compatibility
285 */
286 if ((f->hdr.nx != frame_.hdr.nx) || (f->hdr.ny != frame_.hdr.ny))
287 {
288 return (ngcbFAILURE);
289 }
290
291 n = f->hdr.nx * f->hdr.ny;
292 dtypeOrig_ = f->hdr.dtype;
293
294 if (f->hdr.dtype == ngcppDTYPE_REAL32)
295 {
296 float *p1 = (float *)(void *)f->memPtr;
297 if (frame_.hdr.dtype == ngcppDTYPE_REAL32)
298 {
299 float *p2 = (float *)(void *)frame_.memPtr;
300 for (i=0;i<n;i++)
301 {
302 *p1++ -= *p2++;
303 }
304 }
305 else if (frame_.hdr.dtype == ngcppDTYPE_INT32)
306 {
307 int *p2 = (int *)frame_.memPtr;
308 for (i=0;i<n;i++)
309 {
310 *p1++ -= (float)*p2++;
311 }
312 }
313 else if (frame_.hdr.dtype == ngcppDTYPE_INT16)
314 {
315 short *p2 = (short *)frame_.memPtr;
316 float bz = (float)frame_.hdr.bzero;
317 for (i=0;i<n;i++)
318 {
319 *p1++ -= ((float)*p2++ + bz);
320 }
321 }
322 else if (frame_.hdr.dtype == ngcppDTYPE_UINT16)
323 {
324 unsigned short *p2 = (unsigned short *)frame_.memPtr;
325 float bz = (float)frame_.hdr.bzero;
326 for (i=0;i<n;i++)
327 {
328 *p1++ -= ((float)*p2++ + bz);
329 }
330 }
331 else
332 {
333 return (ngcbFAILURE);
334 }
335 }
336 else if (f->hdr.dtype == ngcppDTYPE_INT32)
337 {
338 int *p1 = (int *)f->memPtr;
339 if (frame_.hdr.dtype == ngcppDTYPE_INT32)
340 {
341 int *p2 = (int *)frame_.memPtr;
342 for (i=0;i<n;i++)
343 {
344 *p1++ -= *p2++;
345 }
346 }
347 else if (frame_.hdr.dtype == ngcppDTYPE_INT16)
348 {
349 short *p2 = (short *)frame_.memPtr;
350 for (i=0;i<n;i++)
351 {
352 *p1++ -= ((int)*p2++ + frame_.hdr.bzero);
353 }
354 }
355 else if (frame_.hdr.dtype == ngcppDTYPE_UINT16)
356 {
357 unsigned short *p2 = (unsigned short *)frame_.memPtr;
358 for (i=0;i<n;i++)
359 {
360 *p1++ -= ((int)*p2++ + frame_.hdr.bzero);
361 }
362 }
363 else
364 {
365 return (ngcbFAILURE);
366 }
367 }
368 else if (f->hdr.dtype == ngcppDTYPE_REAL64)
369 {
370 double *p1 = (double *)(void *)f->memPtr;
371 if (frame_.hdr.dtype == ngcppDTYPE_REAL64)
372 {
373 double *p2 = (double *)(void *)frame_.memPtr;
374 for (i=0;i<n;i++)
375 {
376 *p1++ -= *p2++;
377 }
378 }
379 else if (frame_.hdr.dtype == ngcppDTYPE_REAL32)
380 {
381 float *p2 = (float *)(void *)frame_.memPtr;
382 for (i=0;i<n;i++)
383 {
384 *p1++ -= (double)*p2++;
385 }
386 }
387 else if (frame_.hdr.dtype == ngcppDTYPE_INT32)
388 {
389 int *p2 = (int *)frame_.memPtr;
390 for (i=0;i<n;i++)
391 {
392 *p1++ -= (double)*p2++;
393 }
394 }
395 else if (frame_.hdr.dtype == ngcppDTYPE_INT16)
396 {
397 short *p2 = (short *)frame_.memPtr;
398 double bz = (double)frame_.hdr.bzero;
399 for (i=0;i<n;i++)
400 {
401 *p1++ -= ((double)*p2++ + bz);
402 }
403 }
404 else if (frame_.hdr.dtype == ngcppDTYPE_UINT16)
405 {
406 unsigned short *p2 = (unsigned short *)frame_.memPtr;
407 double bz = (double)frame_.hdr.bzero;
408 for (i=0;i<n;i++)
409 {
410 *p1++ -= ((double)*p2++ + bz);
411 }
412 }
413 else
414 {
415 return (ngcbFAILURE);
416 }
417 }
418 else if (f->hdr.dtype == ngcppDTYPE_UINT16)
419 {
420 if (frame_.hdr.dtype == ngcppDTYPE_INT16)
421 {
422 unsigned short *p11 = (unsigned short *)f->memPtr;
423 unsigned short *p12 = p11 + n;
424 int *p1 = (int *)f->memPtr;
425 short *p2 = (short *)frame_.memPtr;
426
427 memcpy(p12, p11, n * sizeof(unsigned short));
428 for (i=0;i<n;i++)
429 {
430 *p1++ = (int)*p12++ - ((int)*p2++ + frame_.hdr.bzero);
431 }
433 }
434 else if (frame_.hdr.dtype == ngcppDTYPE_UINT16)
435 {
436 unsigned short *p11 = (unsigned short *)f->memPtr;
437 unsigned short *p12 = p11 + n;
438 int *p1 = (int *)f->memPtr;
439 unsigned short *p2 = (unsigned short *)frame_.memPtr;
440
441 memcpy(p12, p11, n * sizeof(unsigned short));
442 for (i=0;i<n;i++)
443 {
444 *p1++ = (int)*p12++ - ((int)*p2++ + frame_.hdr.bzero);
445 }
447 }
448 else
449 {
450 return (ngcbFAILURE);
451 }
452 }
453 else if (f->hdr.dtype == ngcppDTYPE_INT16)
454 {
455 if (frame_.hdr.dtype == ngcppDTYPE_INT16)
456 {
457 short *p11 = (short *)f->memPtr;
458 short *p12 = p11 + n;
459 int *p1 = (int *)f->memPtr;
460 short *p2 = (short *)frame_.memPtr;
461
462 memcpy(p12, p11, n * sizeof(short));
463 for (i=0;i<n;i++)
464 {
465 *p1++ = (int)*p12++ - ((int)*p2++ + frame_.hdr.bzero);
466 }
468 }
469 else if (frame_.hdr.dtype == ngcppDTYPE_UINT16)
470 {
471 short *p11 = (short *)f->memPtr;
472 short *p12 = p11 + n;
473 int *p1 = (int *)f->memPtr;
474 unsigned short *p2 = (unsigned short *)frame_.memPtr;
475
476 memcpy(p12, p11, n * sizeof(short));
477 for (i=0;i<n;i++)
478 {
479 *p1++ = (int)*p12++ - ((int)*p2++ + frame_.hdr.bzero);
480 }
482 }
483 else
484 {
485 return (ngcbFAILURE);
486 }
487 }
488 else
489 {
490 f->sub = 0;
491 dtype_ = ngcppFRAME_ANY;
492 return (ngcbFAILURE);
493 }
494
495 f->sub = 1;
496 dtype_ = f->hdr.dtype;
497
498 return (ngcbSUCCESS);
499 }
500
501protected:
502
503private:
505 ngcdtt_frame_t frame_;
506
508 int size_;
509
511 int dtype_;
512
514 int dtypeOrig_;
515
517 int Add_(ngcdtt_frame_t *f) {
518 int i, n;
519
520 if (!Stored() || !enabled) return (ngcbSUCCESS);
521
522 /*
523 * Check compatibility
524 */
525 if ((f->hdr.nx != frame_.hdr.nx) || (f->hdr.ny != frame_.hdr.ny) ||
526 (f->hdr.dtype != dtype_))
527 {
528 return (ngcbFAILURE);
529 }
530
531 n = f->hdr.nx * f->hdr.ny;
532
533 if (f->hdr.dtype == ngcppDTYPE_REAL32)
534 {
535 float *p1 = (float *)(void *)f->memPtr;
536 if (frame_.hdr.dtype == ngcppDTYPE_REAL32)
537 {
538 float *p2 = (float *)(void *)frame_.memPtr;
539 for (i=0;i<n;i++)
540 {
541 *p1++ += *p2++;
542 }
543 }
544 else if (frame_.hdr.dtype == ngcppDTYPE_INT32)
545 {
546 int *p2 = (int *)frame_.memPtr;
547 for (i=0;i<n;i++)
548 {
549 *p1++ += (float)*p2++;
550 }
551 }
552 else if (frame_.hdr.dtype == ngcppDTYPE_INT16)
553 {
554 short *p2 = (short *)frame_.memPtr;
555 float bz = (float)frame_.hdr.bzero;
556 for (i=0;i<n;i++)
557 {
558 *p1++ += (float)*p2++ + bz;
559 }
560 }
561 else if (frame_.hdr.dtype == ngcppDTYPE_UINT16)
562 {
563 unsigned short *p2 = (unsigned short *)frame_.memPtr;
564 float bz = (float)frame_.hdr.bzero;
565 for (i=0;i<n;i++)
566 {
567 *p1++ += (float)*p2++ + bz;
568 }
569 }
570 else
571 {
572 return (ngcbFAILURE);
573 }
574 }
575 else if (f->hdr.dtype == ngcppDTYPE_INT32)
576 {
577 if (dtypeOrig_ != f->hdr.dtype)
578 {
579 if (frame_.hdr.dtype == ngcppDTYPE_INT16)
580 {
581 if (dtypeOrig_ == ngcppDTYPE_INT16)
582 {
583 short *p1 = (short *)f->memPtr;
584 short *p2 = (short *)frame_.memPtr;
585 int *p11 = (int *)f->memPtr;
586 for (i=0;i<n;i++)
587 {
588 *p1++ = (short)(*p11++ + *p2++ + frame_.hdr.bzero);
589 }
590 }
591 else if (dtypeOrig_ == ngcppDTYPE_UINT16)
592 {
593 unsigned short *p1 = (unsigned short *)f->memPtr;
594 short *p2 = (short *)frame_.memPtr;
595 int *p11 = (int *)f->memPtr;
596 for (i=0;i<n;i++)
597 {
598 *p1++ = (unsigned short)(*p11++ + *p2++ + frame_.hdr.bzero);
599 }
600 }
601 else
602 {
603 return (ngcbFAILURE);
604 }
605 f->hdr.dtype = dtypeOrig_;
606 }
607 else if (frame_.hdr.dtype == ngcppDTYPE_UINT16)
608 {
609 if (dtypeOrig_ == ngcppDTYPE_INT16)
610 {
611 short *p1 = (short *)f->memPtr;
612 unsigned short *p2 = (unsigned short *)frame_.memPtr;
613 int *p11 = (int *)f->memPtr;
614 for (i=0;i<n;i++)
615 {
616 *p1++ = (short)(*p11++ + *p2++ + frame_.hdr.bzero);
617 }
618 }
619 else if (dtypeOrig_ == ngcppDTYPE_UINT16)
620 {
621 unsigned short *p1 = (unsigned short *)f->memPtr;
622 unsigned short *p2 = (unsigned short *)frame_.memPtr;
623 int *p11 = (int *)f->memPtr;
624 for (i=0;i<n;i++)
625 {
626 *p1++ = (unsigned short)(*p11++ + *p2++ + frame_.hdr.bzero);
627 }
628 }
629 else
630 {
631 return (ngcbFAILURE);
632 }
633 f->hdr.dtype = dtypeOrig_;
634 }
635 else
636 {
637 return (ngcbFAILURE);
638 }
639 }
640 else
641 {
642 int *p1 = (int *)f->memPtr;
643 if (frame_.hdr.dtype == ngcppDTYPE_INT32)
644 {
645 int *p2 = (int *)frame_.memPtr;
646 for (i=0;i<n;i++)
647 {
648 *p1++ += *p2++;
649 }
650 }
651 else if (frame_.hdr.dtype == ngcppDTYPE_INT16)
652 {
653 short *p2 = (short *)frame_.memPtr;
654 for (i=0;i<n;i++)
655 {
656 *p1++ += (int)*p2++ + frame_.hdr.bzero;
657 }
658 }
659 else if (frame_.hdr.dtype == ngcppDTYPE_UINT16)
660 {
661 unsigned short *p2 = (unsigned short *)frame_.memPtr;
662 for (i=0;i<n;i++)
663 {
664 *p1++ += (int)*p2++ + frame_.hdr.bzero;
665 }
666 }
667 else
668 {
669 return (ngcbFAILURE);
670 }
671 }
672 }
673 else if (f->hdr.dtype == ngcppDTYPE_REAL64)
674 {
675 double *p1 = (double *)(void *)f->memPtr;
676 if (frame_.hdr.dtype == ngcppDTYPE_REAL64)
677 {
678 double *p2 = (double *)(void *)frame_.memPtr;
679 for (i=0;i<n;i++)
680 {
681 *p1++ += *p2++;
682 }
683 }
684 else if (frame_.hdr.dtype == ngcppDTYPE_REAL32)
685 {
686 float *p2 = (float *)(void *)frame_.memPtr;
687 for (i=0;i<n;i++)
688 {
689 *p1++ += (double)*p2++;
690 }
691 }
692 else if (frame_.hdr.dtype == ngcppDTYPE_INT32)
693 {
694 int *p2 = (int *)frame_.memPtr;
695 for (i=0;i<n;i++)
696 {
697 *p1++ += (double)*p2++;
698 }
699 }
700 else if (frame_.hdr.dtype == ngcppDTYPE_INT16)
701 {
702 short *p2 = (short *)frame_.memPtr;
703 double bz = (double)frame_.hdr.bzero;
704 for (i=0;i<n;i++)
705 {
706 *p1++ += (double)*p2++ + bz;
707 }
708 }
709 else if (frame_.hdr.dtype == ngcppDTYPE_UINT16)
710 {
711 unsigned short *p2 = (unsigned short *)frame_.memPtr;
712 double bz = (double)frame_.hdr.bzero;
713 for (i=0;i<n;i++)
714 {
715 *p1++ += (double)*p2++ + bz;
716 }
717 }
718 else
719 {
720 return (ngcbFAILURE);
721 }
722 }
723 else
724 {
725 return (ngcbFAILURE);
726 }
727
728 f->sub = 0;
729
730 return (ngcbSUCCESS);
731 }
732};
733
738public:
741
743 char uri[256];
744
746 ngcdttPUBLISH();
747
749 explicit ngcdttPUBLISH(int n);
750
752 virtual ~ngcdttPUBLISH();
753
756
759
761 char *ErrMsg();
762
764 const char *Type();
765
767 int BytesPerPix(int dataType);
768
770 int Size(ngcpp_hdr_t hdr);
771
773 int NumBuf();
774
776 void NumBuf(int n);
777
780
782 int Publish();
783
785 int TryLock();
786
788 int Lock();
789
791 int Unlock();
792
794 void Invalidate();
795
796 /*
797 * Virtual interface
798 */
799
801 virtual int Configure(const char *name, int nx, int ny);
802
804 virtual void Shutdown();
805
807 virtual int IdxOut();
808
810 virtual int IdxIn();
811
813 virtual int Locked(int idx);
814
816 virtual int Lock(int idx);
817
819 virtual int TryLock(int idx);
820
822 virtual int Unlock(int idx);
823
825 virtual int Wait(int idx);
826
828 virtual int Publish(int idx);
829
831 virtual void Invalidate(int idx);
832
833protected:
834 void Type(const char *name);
835
836private:
838 void Init_();
839
841 void Shutdown_();
842
844 char erms_[256];
845
847 int numBuf_;
848
850 char type_[64];
851};
852
853#endif
int Store(const char *fileName)
Store FITS-frame.
Definition ngcdttPUBLISH.hpp:162
int Store(ngcdtt_frame_t *f)
Store given frame.
Definition ngcdttPUBLISH.hpp:84
int Stored()
Stored.
Definition ngcdttPUBLISH.hpp:275
int Sub(ngcdtt_frame_t *f)
Subtract from frame.
Definition ngcdttPUBLISH.hpp:278
ngcdttFP()
Constructor.
Definition ngcdttPUBLISH.hpp:64
int enabled
Subtraction enabled;.
Definition ngcdttPUBLISH.hpp:61
virtual ~ngcdttFP()
Destructor.
Definition ngcdttPUBLISH.hpp:69
void Clear()
Clear.
Definition ngcdttPUBLISH.hpp:74
int TryLock()
Try to lock current frame bbuffer.
Definition ngcdttPUBLISH.cpp:106
virtual ~ngcdttPUBLISH()
Destructor.
Definition ngcdttPUBLISH.cpp:35
int initialized
Initialized (flag)
Definition ngcdttPUBLISH.hpp:740
int Size(ngcpp_hdr_t hdr)
Compute frame size in bytes.
Definition ngcdttPUBLISH.cpp:85
const char * Type()
Return display type.
Definition ngcdttPUBLISH.cpp:62
virtual int Locked(int idx)
Check whether the image stored in frame[idx] is locked.
Definition ngcdttPUBLISH.cpp:170
int NumBuf()
Return number of available display buffers.
Definition ngcdttPUBLISH.cpp:90
int Lock()
Lock current frame buffer.
Definition ngcdttPUBLISH.cpp:108
virtual int IdxOut()
Return actual display buffer index.
Definition ngcdttPUBLISH.cpp:162
char uri[256]
URI, if applicable.
Definition ngcdttPUBLISH.hpp:743
void Invalidate()
Invalidate current frame buffer.
Definition ngcdttPUBLISH.cpp:112
char * ErrMsg()
Return actual error message.
Definition ngcdttPUBLISH.cpp:66
int Unlock()
Unlock current frame buffer.
Definition ngcdttPUBLISH.cpp:110
virtual int Wait(int idx)
Wait until the image stored in frame[idx] is unlocked.
Definition ngcdttPUBLISH.cpp:211
int frameId
Unique frame-id for display.
Definition ngcdttPUBLISH.hpp:755
virtual void Shutdown()
Shutdown publisher.
Definition ngcdttPUBLISH.cpp:152
ngcdtt_frame_t * frame
Frames array.
Definition ngcdttPUBLISH.hpp:758
virtual int IdxIn()
Return the buffer index to be used for next transfer.
Definition ngcdttPUBLISH.cpp:154
int BytesPerPix(int dataType)
Return number of bytes per pixel for specific data type.
Definition ngcdttPUBLISH.cpp:68
ngcdttPUBLISH()
Constructor.
Definition ngcdttPUBLISH.cpp:23
int Publish()
Publish current frame buffer.
Definition ngcdttPUBLISH.cpp:104
ngcdtt_frame_t * Frame()
Get current frame slot.
Definition ngcdttPUBLISH.cpp:99
virtual int Configure(const char *name, int nx, int ny)
Initialize/configure publisher.
Definition ngcdttPUBLISH.cpp:114
int ngcbCubeOpen(const char *fileName, ngcb_cube_t *cube, char *erms)
Definition ngcbFitsTools.c:1795
#define ngcbSUCCESS
Definition ngcb.h:138
void ngcbCubeClose(ngcb_cube_t cube)
Definition ngcbFitsTools.c:2140
int ngcbCubeRead(ngcb_cube_t cube, void *buffer, int slice, char *erms)
Definition ngcbFitsTools.c:2044
#define ngcbFAILURE
Definition ngcb.h:140
#define ngcppDTYPE_UINT16
Definition ngcppInt.h:221
#define ngcppDTYPE_INT64
Definition ngcppInt.h:219
#define ngcppDTYPE_BYTE
Definition ngcppInt.h:214
#define ngcppDTYPE_REAL64
Definition ngcppInt.h:216
#define ngcppDTYPE_INT16
Definition ngcppInt.h:217
#define ngcppDTYPE_INT32
Definition ngcppInt.h:218
#define ngcppDTYPE_REAL32
Definition ngcppInt.h:215
#define ngcppFRAME_ANY
Definition ngcppInt.h:231
void ngcppHdrInit(ngcpp_hdr_t *hdr)
Definition ngcppDataRecv.c:371
Definition ngcb.h:1037
int naxis2
Definition ngcb.h:1042
double bzero
Definition ngcb.h:1045
int naxis1
Definition ngcb.h:1041
int bitPix
Definition ngcb.h:1040
Definition ngcdttPUBLISH.hpp:33
ngcdtt_frame_t()
Constructor.
Definition ngcdttPUBLISH.hpp:47
int locked
Flag indicating that the frame is locked.
Definition ngcdttPUBLISH.hpp:41
char * memPtr
Pointer to memory.
Definition ngcdttPUBLISH.hpp:35
int sub
Flag indicating that a bias frame has been subtracted.
Definition ngcdttPUBLISH.hpp:44
ngcpp_hdr_t hdr
Frame header (copy of last frame)
Definition ngcdttPUBLISH.hpp:38
Definition ngcppInt.h:518
int nx
Definition ngcppInt.h:523
int ny
Definition ngcppInt.h:524
int dtype
Definition ngcppInt.h:519