From 26eb0121a4bdabe9ba965363634cfc314ba0bd0a Mon Sep 17 00:00:00 2001 From: William Joye Date: Thu, 1 Jun 2017 14:53:02 -0400 Subject: fix HealPix NESTED --- tksao/fitsy++/hpx.C | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/tksao/fitsy++/hpx.C b/tksao/fitsy++/hpx.C index 0078858..7b5e7ef 100644 --- a/tksao/fitsy++/hpx.C +++ b/tksao/fitsy++/hpx.C @@ -148,6 +148,8 @@ void FitsHPX::build(FitsFile* fits) FitsHead* head = fits->head(); FitsTableHDU* hdu = (FitsTableHDU*)(head->hdu()); int rowlen = hdu->width(); + int nrow = hdu->rows(); + int repeat = col_->repeat(); char* data = (char*)fits->data(); int nside = nside_; @@ -213,9 +215,19 @@ void FitsHPX::build(FitsFile* fits) } // Gather data into the output vector. + /* long* healp = healidx; for (float* rowp = row; rowp < row+nside; rowp++) - *rowp = col_->value(data+*(healp++)*rowlen,0); + *rowp = col_->value(data+*(healp++),0); + */ + for (int ii=0; iivalue(data+aa*rowlen,bb); + else + row[ii] = 0; + } // Apply blanking to halved facets. if (halve) { -- cgit v0.12