Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(424)

Unified Diff: media/base/audio_hash.h

Issue 1727953005: Enable AudioDecoder unit tests on Android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed contitions from base/container_names.* compilation Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/base/BUILD.gn ('k') | media/base/audio_hash.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/audio_hash.h
diff --git a/media/base/audio_hash.h b/media/base/audio_hash.h
index 83ee901d3c97a29d0a703fd98a446f5c3d4f9e94..5ac1aa267b716565ccdd892719e10c3b377716fd 100644
--- a/media/base/audio_hash.h
+++ b/media/base/audio_hash.h
@@ -43,6 +43,11 @@ class MEDIA_EXPORT AudioHash {
// Return a string representation of the current hash.
std::string ToString() const;
+ // Compare with another hash value given as string representation.
+ // Returns true if for every bucket the difference between this and
+ // other is less than tolerance.
+ bool IsEquivalent(const std::string& other, double tolerance) const;
+
private:
// Storage for the audio hash. The number of buckets controls the importance
// of position in the hash. A higher number reduces the chance of false
« no previous file with comments | « media/base/BUILD.gn ('k') | media/base/audio_hash.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698