mirror of
https://github.com/Boof2015/prism.git
synced 2026-08-20 20:39:59 +02:00
improve speed scale for waveform + version bump + profile migration
This commit is contained in:
+15
-2
@@ -3,7 +3,7 @@ import type { ScopeKind } from './scope'
|
||||
import type { ScopeSettings } from './settings'
|
||||
|
||||
export const PROFILE_FILE_FORMAT = 'prism-profile'
|
||||
export const PROFILE_FILE_VERSION = 2
|
||||
export const PROFILE_FILE_VERSION = 3
|
||||
export const PROFILE_LOCAL_STATE_FORMAT = 'prism-profile-local'
|
||||
export const PROFILE_LOCAL_STATE_VERSION = 1
|
||||
export const LEGACY_PROFILE_MIGRATION_VERSION = 1
|
||||
@@ -39,6 +39,19 @@ export interface PrismProfileFileV1 {
|
||||
}
|
||||
|
||||
export interface PrismProfileFileV2 {
|
||||
format: typeof PROFILE_FILE_FORMAT
|
||||
version: 2
|
||||
id: string
|
||||
name: string
|
||||
themeId?: string | null
|
||||
scopeOrder: ScopeKind[]
|
||||
hiddenScopes: ScopeKind[]
|
||||
widthWeights: Record<ScopeKind, number>
|
||||
scopeSettings: ScopeSettings
|
||||
scopePopouts: PrismProfileFileScopePopoutMap
|
||||
}
|
||||
|
||||
export interface PrismProfileFileV3 {
|
||||
format: typeof PROFILE_FILE_FORMAT
|
||||
version: typeof PROFILE_FILE_VERSION
|
||||
id: string
|
||||
@@ -51,7 +64,7 @@ export interface PrismProfileFileV2 {
|
||||
scopePopouts: PrismProfileFileScopePopoutMap
|
||||
}
|
||||
|
||||
export type PrismProfileFile = PrismProfileFileV1 | PrismProfileFileV2
|
||||
export type PrismProfileFile = PrismProfileFileV1 | PrismProfileFileV2 | PrismProfileFileV3
|
||||
|
||||
export interface ProfileLocalMetadata {
|
||||
windowBounds?: WindowBounds
|
||||
|
||||
@@ -9,7 +9,7 @@ import {
|
||||
} from './spectrogram'
|
||||
import { DEFAULT_VU_REFERENCE_DBFS, type VUMeterMode, type VUMeterNeedleChannels, type VUMeterOrientation } from './vumeter'
|
||||
import { DEFAULT_LUFS_METER_READOUT, type LUFSMeterMode, type LUFSMeterReadout } from './lufsmeter'
|
||||
import { DEFAULT_WAVEFORM_MODE, type WaveformMode } from './waveform'
|
||||
import { DEFAULT_WAVEFORM_MODE, DEFAULT_WAVEFORM_SCROLL_SPEED, type WaveformMode } from './waveform'
|
||||
import { DEFAULT_SPECTRUM_PEAK_INFO_MODE, type SpectrumPeakInfoMode } from './spectrum'
|
||||
|
||||
export interface ScopeSettings {
|
||||
@@ -80,7 +80,7 @@ export const DEFAULT_SCOPE_SETTINGS: ScopeSettings = {
|
||||
spectrogram: { fftSize: 4096, tiltDbPerOctave: DEFAULT_SPECTROGRAM_TILT_DB_PER_OCTAVE, scrollSpeed: 2, contrast: DEFAULT_SPECTROGRAM_CONTRAST, clarityMode: 'sharper', scaleMode: 'log', orientation: DEFAULT_SPECTROGRAM_ORIENTATION, colorScheme: 'heat' },
|
||||
vumeter: { mode: 'bar', orientation: 'horizontal', needleChannels: 'stereo', referenceDb: DEFAULT_VU_REFERENCE_DBFS },
|
||||
lufsmeter: { mode: 'bar', readout: DEFAULT_LUFS_METER_READOUT },
|
||||
waveform: { mode: DEFAULT_WAVEFORM_MODE, scrollSpeed: 1, multiband: false },
|
||||
waveform: { mode: DEFAULT_WAVEFORM_MODE, scrollSpeed: DEFAULT_WAVEFORM_SCROLL_SPEED, multiband: false },
|
||||
nowPlaying: {
|
||||
showCoverArt: true,
|
||||
showTitle: true,
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
export type WaveformMode = 'mono' | 'stereo'
|
||||
|
||||
export const MIN_WAVEFORM_SCROLL_SPEED = 0.5
|
||||
export const MIN_WAVEFORM_SCROLL_SPEED = 1
|
||||
export const MAX_WAVEFORM_SCROLL_SPEED = 8
|
||||
export const WAVEFORM_SCROLL_SPEED_STEP = 0.5
|
||||
export const WAVEFORM_SCROLL_SPEED_STEP = 1
|
||||
export const DEFAULT_WAVEFORM_SCROLL_SPEED = 1
|
||||
export const DEFAULT_WAVEFORM_MODE: WaveformMode = 'mono'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user