// SPDX-FileCopyrightText: 2019-2022 Connor McLaughlin // SPDX-License-Identifier: (GPL-3.0 OR CC-BY-NC-ND-4.0) #pragma once #include "common/progress_callback.h" #include "common/types.h" #include #include #include class CDImage; namespace CDImageHasher { using Hash = std::array; std::string HashToString(const Hash& hash); std::optional HashFromString(const std::string_view& str); bool GetImageHash(CDImage* image, Hash* out_hash, ProgressCallback* progress_callback = ProgressCallback::NullProgressCallback); bool GetTrackHash(CDImage* image, u8 track, Hash* out_hash, ProgressCallback* progress_callback = ProgressCallback::NullProgressCallback); } // namespace CDImageHasher