diff --git a/src/common/tools/crawl.ts b/src/common/tools/crawl.ts index cb1e5f6fc737..9e060f485903 100644 --- a/src/common/tools/crawl.ts +++ b/src/common/tools/crawl.ts @@ -83,6 +83,8 @@ export async function crawl(suiteDir: string, validate: boolean): Promise { + .expand('offsetVariant', function* (p) { const formatInfo = kVertexFormatInfo[p.format]; const formatSize = formatInfo.byteSize; - return [ - { mult: 0, add: 0 }, - { mult: 0, add: formatSize }, - { mult: 0, add: 4 }, - { mult: 0.5, add: 0 }, - { mult: 1, add: -formatSize * 2 }, - { mult: 1, add: -formatSize - 4 }, - { mult: 1, add: -formatSize }, - ]; + yield { mult: 0, add: 0 }; + yield { mult: 0, add: 4 }; + if (formatSize !== 4) yield { mult: 0, add: formatSize }; + yield { mult: 0.5, add: 0 }; + yield { mult: 1, add: -formatSize * 2 }; + if (formatSize !== 4) yield { mult: 1, add: -formatSize - 4 }; + yield { mult: 1, add: -formatSize }; }) ) .fn(t => {