MCPcopy Create free account
hub / github.com/microsoft/SandDance / getAttributeBufferLength

Function getAttributeBufferLength

docs/app/js/sanddance-app.js:86431–86435  ·  view source on GitHub ↗
(attribute, numInstances)

Source from the content-addressed store, hash-verified

86429 buffers.push(buffers.shift());
86430}
86431function getAttributeBufferLength(attribute, numInstances) {
86432 var doublePrecision = attribute.doublePrecision, settings = attribute.settings, value = attribute.value, size = attribute.size;
86433 var multiplier = doublePrecision ? 2 : 1;
86434 return (settings.noAlloc ? value.length : numInstances * size) * multiplier;
86435}
86436function padBuffer(_ref) {
86437 var buffer = _ref.buffer, numInstances = _ref.numInstances, attribute = _ref.attribute, fromLength = _ref.fromLength, fromStartIndices = _ref.fromStartIndices, _ref$getData = _ref.getData, getData = _ref$getData === void 0 ? function(x) {
86438 return x;

Callers 1

padBufferFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected