MCPcopy Create free account
hub / github.com/Bzi-Han/AndroidSurfaceImgui / DataHash

Method DataHash

modules/ANativeWindowCreator.h:518–531  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

516 size_t version;
517
518 consteval size_t DataHash(const std::string_view &data) const
519 {
520 constexpr size_t fnvOffsetBasis = 0x811C9DC5ull;
521 constexpr size_t fnvPrime = 0x1000193ull;
522 size_t hash = fnvOffsetBasis;
523
524 for (size_t i = 0; i < data.size(); ++i)
525 {
526 hash ^= static_cast<size_t>(data[i]);
527 hash *= fnvPrime;
528 }
529
530 return hash;
531 }
532
533 consteval bool operator==(const char *rhs) const
534 {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected