MCPcopy Index your code
hub / github.com/processing/p5.js / cb

Function cb

src/webgl/loading.js:420–441  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

418 if (fileType.match(/\.stl$/i)) {
419 const { data } = await request(path, 'arrayBuffer');
420 const cb = () => {
421 parseSTL(model, data);
422
423 if (normalize) {
424 model.normalize();
425 }
426
427 if (flipU) {
428 model.flipU();
429 }
430
431 if (flipV) {
432 model.flipV();
433 }
434 model._makeTriangleEdges();
435
436 if (successCallback) {
437 return successCallback(model);
438 } else {
439 return model;
440 }
441 };
442 return this._internal ? this._internal(cb) : cb();
443
444 } else if (fileType.match(/\.obj$/i)) {

Callers 2

withGlobalStrandsFunction · 0.70
loadingFunction · 0.70

Calls 6

parseSTLFunction · 0.85
parseObjFunction · 0.85
flipUMethod · 0.80
flipVMethod · 0.80
_makeTriangleEdgesMethod · 0.80
normalizeMethod · 0.45

Tested by

no test coverage detected