[var] Add VarStoreInstancer
This commit is contained in:
parent
c64661b2f8
commit
a3a3d37b95
|
@ -219,6 +219,23 @@ struct DeltaSetIndexMap
|
|||
DEFINE_SIZE_UNION (1, format);
|
||||
};
|
||||
|
||||
|
||||
struct VarStoreInstancer
|
||||
{
|
||||
VarStoreInstancer (const VariationStore &varStore,
|
||||
const DeltaSetIndexMap &varIdxMap,
|
||||
hb_array_t<int> coords) :
|
||||
varStore (varStore), varIdxMap (varIdxMap), coords (coords) {}
|
||||
|
||||
float operator() (uint32_t varIdx) const
|
||||
{ return varStore.get_delta (varIdxMap.map (varIdx), coords); }
|
||||
|
||||
const VariationStore &varStore;
|
||||
const DeltaSetIndexMap &varIdxMap;
|
||||
hb_array_t<int> coords;
|
||||
};
|
||||
|
||||
|
||||
} /* namespace OT */
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue