Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
dtschump committed Nov 6, 2023
2 parents 57d6ef5 + 76e9fdc commit 803c48d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions CImg.h
Original file line number Diff line number Diff line change
Expand Up @@ -24608,7 +24608,7 @@ namespace cimg_library {
"Specified dynamic array #%u contains no elements.",
mp.imgout.pixel_type(),s_op,ind);
const int siz1 = siz - 1;
if (is_pop_heap) { // Heapify
if (is_pop_heap) { // Heapify-down
if (dim==1) cimg::swap(img[0],img[siz1]);
else {
T *ptr0 = img.data(), *ptr1 = img.data(0,siz1);
Expand Down Expand Up @@ -24702,7 +24702,7 @@ namespace cimg_library {
for (unsigned int k = 0; k<nb_elts; ++k) {
int index = pos + k;
img[index] = (T)_mp_arg(6 + k);
if (is_push_heap) while (index>0) { // Heapify
if (is_push_heap) while (index>0) { // Heapify-up
const int index_parent = (index - 1)/2;
if (img[index]<img[index_parent]) {
cimg::swap(img[index],img[index_parent]);
Expand All @@ -24716,7 +24716,7 @@ namespace cimg_library {
const double *const ptrs = &_mp_arg(6 + k) + 1;
T *ptrd = img.data(0,index);
cimg_forC(img,c) { *ptrd = ptrs[c]; ptrd+=img._height; }
if (is_push_heap) while (index>0) { // Heapify
if (is_push_heap) while (index>0) { // Heapify-up
const int index_parent = (index - 1)/2;
if (img[index]<img[index_parent]) {
T *ptr0 = img.data(0,index), *ptr1 = img.data(0,index_parent);
Expand Down

0 comments on commit 803c48d

Please sign in to comment.