ECC-499: Fix for generic case e.g. polar stereo

This commit is contained in:
Shahram Najm 2023-02-04 14:12:03 +00:00
parent 083b25e6f5
commit 74f24a1296
2 changed files with 6 additions and 1 deletions

View File

@ -437,7 +437,9 @@ int grib_nearest_find_generic(
outlats[i] = neighbours[i].m_lat;
outlons[i] = neighbours[i].m_lon;
indexes[i] = neighbours[i].m_index;
values[i] = neighbours[i].m_value;
if (values) {
values[i] = neighbours[i].m_value;
}
/*printf("(%f,%f) i=%d d=%f v=%f\n",outlats[i],outlons[i],indexes[i],distances[i],values[i]);*/
}

View File

@ -50,6 +50,9 @@ Idx lat lon dist
EOF
diff $tempRef $temp
$EXEC ${test_dir}/grib_nearest_test -n $ECCODES_SAMPLES_PATH/polar_stereographic_pl_grib2.tmpl
# ECC-1295: regular lat/lon on ellipsoid
# ----------------------------------------
sample2=$ECCODES_SAMPLES_PATH/GRIB2.tmpl