superdough: add logger

This commit is contained in:
Felix Roos 2023-08-17 10:08:55 +02:00
parent 0c6a0720af
commit 8bdbc9ec4c
5 changed files with 19 additions and 7 deletions

View file

@ -11,6 +11,7 @@ import { clamp } from './util.mjs';
import workletsUrl from './worklets.mjs?url';
import { getFilter, gainNode } from './helpers.mjs';
import { map } from 'nanostores';
import { logger } from './logger.mjs';
export const soundMap = map();
export function registerSound(key, onTrigger, data = {}) {
@ -195,7 +196,7 @@ export const superdough = async (value, deadline, hapDuration) => {
return;
}
if (ac.currentTime > t) {
// logger('[webaudio] skip hap: still loading', ac.currentTime - t);
logger('[webaudio] skip hap: still loading', ac.currentTime - t);
return;
}
const chain = []; // audio nodes that will be connected to each other sequentially