7#ifndef PXR_EXEC_VDF_MASK_MEMOIZER_H
8#define PXR_EXEC_VDF_MASK_MEMOIZER_H
20PXR_NAMESPACE_OPEN_SCOPE
32template <
template <
typename...>
class MapType>
41 typename _Cache::iterator it = _appended.find(key);
42 if (it != _appended.end()) {
46 return _appended.insert({std::move(key), lhs | rhs}).first->second;
52 using _Key = std::pair<VdfMask, VdfMask>;
57 size_t operator()(
const _Key &v)
const {
63 using _Cache = MapType<_Key, VdfMask, _Hash>;
67PXR_NAMESPACE_CLOSE_SCOPE
static size_t Combine(Args &&... args)
Produce a hash code by combining the hash codes of several objects.
A VdfMask is placed on connections to specify the data flowing through them.
Memoizes the results of mask append (union) operations.
const VdfMask & Append(const VdfMask &lhs, const VdfMask &rhs)
Append lhs and rhs and return the result.