fix type bug in zfp.

This commit is contained in:
Dave Pugmire 2019-03-04 10:04:44 -05:00
parent d974bcb5c3
commit e670b0910d
2 changed files with 7 additions and 1 deletions

@ -359,7 +359,7 @@ struct ZFPBlockEncoder<BlockSize, vtkm::UInt8, PortalType>
{
using Int = typename zfp::zfp_traits<vtkm::UInt8>::Int;
zfp::BlockWriter<BlockSize, PortalType> blockWriter(stream, maxbits, vtkm::Id(blockIdx));
encode_block<BlockSize>(blockWriter, maxbits, get_precision<vtkm::Int32>(), (Int*)fblock);
encode_block<BlockSize>(blockWriter, maxbits, get_precision<vtkm::UInt8>(), (Int*)fblock);
}
};

@ -97,6 +97,12 @@ inline VTKM_EXEC int get_precision<int>()
return 32;
}
template <>
inline VTKM_EXEC int get_precision<unsigned char>()
{
return 8;
}
template <typename T>
inline VTKM_EXEC int get_min_exp();
template <>