feat(fxrt): hien thi telemetry stats tren UI (vi WebView2 khong mo devtools)
This commit is contained in:
@@ -13508,6 +13508,13 @@ const addMasterVst = (path) => { const fx = (masterFxList || []).find(f => f.pat
|
||||
const previewAudioRef = React.useRef(null);
|
||||
const [addMasterVstSel, setAddMasterVstSel] = React.useState('');
|
||||
const [masterVstPickerOpen, setMasterVstPickerOpen] = React.useState(false);
|
||||
// FX RT telemetry (WebView2 không mở được devtools → hiển thị thẳng trên UI).
|
||||
const [fxRtStats, setFxRtStats] = React.useState(null);
|
||||
React.useEffect(() => {
|
||||
if (!isOpen) return;
|
||||
const iv = setInterval(() => { if (fxRt && fxRt.stats) setFxRtStats({ ...fxRt.stats }); }, 2000);
|
||||
return () => clearInterval(iv);
|
||||
}, [isOpen]);
|
||||
|
||||
// Wave Observer Refs & States
|
||||
const woCanvasRef = React.useRef(null);
|
||||
@@ -14223,6 +14230,17 @@ const addMasterVst = (path) => { const fx = (masterFxList || []).find(f => f.pat
|
||||
</button>
|
||||
</div>
|
||||
|
||||
{/* FX RT TELEMETRY — WebView2 không mở devtools, hiển thị thẳng trên UI */}
|
||||
<div id="fxrt-stats-ui" className="h-6 bg-slate-950 border-b border-slate-800 px-4 flex items-center gap-3 text-[10px] oz-font-mono shrink-0">
|
||||
<span className="text-slate-500 font-bold uppercase tracking-widest">FXRT</span>
|
||||
{fxRtStats ? (
|
||||
<span className={fxRtStats.underruns > 0 || fxRtStats.silences > 0 ? 'text-red-400' : 'text-emerald-400'}>
|
||||
u={fxRtStats.underruns} h={fxRtStats.holds} f={fxRtStats.fades} s={fxRtStats.silences} q={fxRtStats.queueLen} cap={fxRtStats.capDrops} fadeIn={fxRtStats.fadeIns}
|
||||
</span>
|
||||
) : <span className="text-slate-600">off</span>}
|
||||
{fxRtStats && (fxRtStats.underruns > 0 || fxRtStats.silences > 0) && <span className="text-red-400">⚠ main-thread stall? Giảm tải UI / tăng FILL</span>}
|
||||
</div>
|
||||
|
||||
{/* MAIN WORKSPACE */}
|
||||
<main className="flex-1 flex overflow-hidden min-h-0">
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -51,7 +51,7 @@
|
||||
<script src="/static/js/services/promptTemplateManager.js?v=202607281039"></script>
|
||||
<script src="/static/js/services/undoRedoEngine.js?v=202607290941"></script>
|
||||
<script src="/static/js/services/chordTheory.js?v=202608211300"></script>
|
||||
<script src="/static/js/app.precompiled.js?v=202608242100" defer></script>
|
||||
<script src="/static/js/app.precompiled.js?v=202608242200" defer></script>
|
||||
<link rel="stylesheet" href="/static/css/styles.css?v=202607271016">
|
||||
<style>
|
||||
:root {
|
||||
|
||||
Reference in New Issue
Block a user