| 321 | } |
| 322 | |
| 323 | CompareResult compareAstc(const char* lhs, const char* rhs, std::size_t size, uint32_t width, uint32_t height, |
| 324 | const std::string& filepathLhs, const std::string& filepathRhs, |
| 325 | bool isFormatSRGB, uint32_t blockSizeX, uint32_t blockSizeY, uint32_t blockSizeZ, |
| 326 | float tolerance) { |
| 327 | const auto uncompressedLhs = decodeASTC(lhs, size, width, height, filepathLhs, isFormatSRGB, blockSizeX, blockSizeY, blockSizeZ); |
| 328 | const auto uncompressedRhs = decodeASTC(rhs, size, width, height, filepathRhs, isFormatSRGB, blockSizeX, blockSizeY, blockSizeZ); |
| 329 | |
| 330 | return compareUnorm8( |
| 331 | reinterpret_cast<const char*>(uncompressedLhs.data.get()), |
| 332 | reinterpret_cast<const char*>(uncompressedRhs.data.get()), |
| 333 | uncompressedLhs.size, |
| 334 | tolerance); |
| 335 | } |
| 336 | |
| 337 | bool compare(Texture& lhs, Texture& rhs, float tolerance) { |
| 338 | const auto vkFormat = static_cast<VkFormat>(lhs.header.vkFormat); |
no test coverage detected