b400551321
Replace the fire-and-forget matplotlib pipeline (render() -> throwaway Figure -> canvas teardown) with a three-stage architecture that supports zoom/pan, lin/log toggling, and multi-file overlay: compute(audio_file) -> data # heavy, worker thread, backend-neutral build_spec(data, view) -> PlotSpec # cheap, GUI thread, view-aware show_specs([(label, spec, color)]) # pyqtgraph, persistent PlotItem, overlay - plotspec.py: backend-agnostic descriptors (Curve, Band, HLine, Heatmap, AxisSpec, PlotSpec) + ViewState (recompute-free lin/log) - audio_visualization_widget.py: persistent pyqtgraph plot, never torn down; per-dataset colours for overlay; spectrogram log-freq via row resample (ImageItem is affine-only); ColorBarItem at a fixed cell - Compare/overlay driven by file-list checkboxes; stable per-song colour by row - Custom draggable reference lines (add/clear), persist across redraws - Axis-constrained scroll zoom: Ctrl=time, Shift=value (_AxisZoomViewBox) - RMS render no longer per-segment fill_between (was the slow path) Fixes found in review/testing: - FillBetweenItem needs penned child curves or it fills nothing (RMS/Waveform were blank); band fill verified by pixel count - band overlay alpha was a no-op (QBrush.color() returns a copy) - colorbar could stack across renders; now added/removed at a fixed layout cell Deferred (per scope): stereo retention, deep perf rewrites (eager beat_track, true-peak/crest loops, shared LUFS), per-song colour picker UI. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
39 lines
788 B
TOML
39 lines
788 B
TOML
[build-system]
|
|
requires = ["setuptools>=68"]
|
|
build-backend = "setuptools.build_meta"
|
|
|
|
[project]
|
|
name = "uj-mastering-master"
|
|
version = "0.1.0"
|
|
requires-python = ">=3.10"
|
|
dependencies = [
|
|
"librosa",
|
|
"numpy",
|
|
"matplotlib",
|
|
"mutagen",
|
|
"pyloudnorm",
|
|
"PyQt5>=5.15.10",
|
|
# 5.15.2 is the only pyqt5-qt5 release with a Windows wheel; later
|
|
# versions are Linux/macOS only.
|
|
"PyQt5-Qt5==5.15.2 ; sys_platform == 'win32'",
|
|
"pyqtgraph>=0.14.0",
|
|
]
|
|
|
|
[project.scripts]
|
|
ujm = "main:main"
|
|
|
|
[tool.setuptools]
|
|
py-modules = [
|
|
"main",
|
|
"analysis_results_manager",
|
|
"audio_visualization_widget",
|
|
"master_core",
|
|
"metrics",
|
|
"plotspec",
|
|
"font_manager",
|
|
"font_control_widget",
|
|
"plot_control_widget",
|
|
"logger_setup",
|
|
"setup_fonts",
|
|
]
|