@dawcore/components 0.0.25 → 0.0.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +8 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.js +6 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +12 -3
- package/dist/index.mjs.map +1 -1
- package/package.json +5 -5
package/dist/index.mjs
CHANGED
|
@@ -2708,7 +2708,12 @@ var AudioResumeController = class {
|
|
|
2708
2708
|
};
|
|
2709
2709
|
|
|
2710
2710
|
// src/controllers/recording-controller.ts
|
|
2711
|
-
import {
|
|
2711
|
+
import {
|
|
2712
|
+
appendPeaks,
|
|
2713
|
+
concatenateAudioData,
|
|
2714
|
+
createAudioBuffer,
|
|
2715
|
+
resolveRecordingOffsetSamples
|
|
2716
|
+
} from "@waveform-playlist/core";
|
|
2712
2717
|
var RecordingController = class {
|
|
2713
2718
|
constructor(host) {
|
|
2714
2719
|
this._sessions = /* @__PURE__ */ new Map();
|
|
@@ -2771,8 +2776,12 @@ var RecordingController = class {
|
|
|
2771
2776
|
}
|
|
2772
2777
|
const channelCount = detectedChannelCount ?? options.channelCount ?? 1;
|
|
2773
2778
|
const startSample = options.startSample ?? Math.floor(this._host._currentTime * this._host.effectiveSampleRate);
|
|
2774
|
-
const
|
|
2775
|
-
|
|
2779
|
+
const latencySamples = resolveRecordingOffsetSamples({
|
|
2780
|
+
overrideSeconds: options.latencyOffset,
|
|
2781
|
+
outputLatency: rawCtx.outputLatency ?? 0,
|
|
2782
|
+
lookAhead: 0,
|
|
2783
|
+
sampleRate: rawCtx.sampleRate
|
|
2784
|
+
});
|
|
2776
2785
|
const source = this._host.createMediaStreamSource ? this._host.createMediaStreamSource(stream) : rawCtx.createMediaStreamSource(stream);
|
|
2777
2786
|
const workletNode = this._host.createAudioWorkletNode ? this._host.createAudioWorkletNode("recording-processor", {
|
|
2778
2787
|
channelCount,
|