fix: update default playhead fps to 30
This commit is contained in:
+1
-1
@@ -69,7 +69,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"editor": {
|
"editor": {
|
||||||
"playhead_update_frequency": 10,
|
"playhead_update_frequency": 30,
|
||||||
"spectrogram_height_resolution": 3
|
"spectrogram_height_resolution": 3
|
||||||
},
|
},
|
||||||
"chatbox": {
|
"chatbox": {
|
||||||
|
|||||||
@@ -299,17 +299,17 @@
|
|||||||
|
|
||||||
.settings-progress-track {
|
.settings-progress-track {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 10px;
|
height: 8px;
|
||||||
border-radius: 999px;
|
border-radius: 999px;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
background-color: #3a3a3a;
|
background-color: #1d1d1d;
|
||||||
border: 1px solid #4a4a4a;
|
border: 1px solid #3a3a3a;
|
||||||
}
|
}
|
||||||
|
|
||||||
.settings-progress-fill {
|
.settings-progress-fill {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
background: linear-gradient(90deg, #5a9fd4 0%, #76c28f 100%);
|
background: linear-gradient(90deg, #5a9fd4 0%, #7cc2f1 100%);
|
||||||
transition: width 0.2s ease;
|
transition: width 0.15s linear;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Settings Help Links */
|
/* Settings Help Links */
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import {
|
|||||||
} from '../../../util/spectrogramUtil';
|
} from '../../../util/spectrogramUtil';
|
||||||
|
|
||||||
const BehaviorSettings: React.FC = () => {
|
const BehaviorSettings: React.FC = () => {
|
||||||
const [playheadUpdateFrequency, setPlayheadUpdateFrequency] = useState<number>(10);
|
const [playheadUpdateFrequency, setPlayheadUpdateFrequency] = useState<number>(30);
|
||||||
const [spectrogramHeightResolution, setSpectrogramHeightResolution] = useState<SpectrogramHeightResolution>(3);
|
const [spectrogramHeightResolution, setSpectrogramHeightResolution] = useState<SpectrogramHeightResolution>(3);
|
||||||
const [chatboxDefaultOpen, setChatboxDefaultOpen] = useState<boolean>(true);
|
const [chatboxDefaultOpen, setChatboxDefaultOpen] = useState<boolean>(true);
|
||||||
const [audioLookaheadTime, setAudioLookaheadTime] = useState<string>('50');
|
const [audioLookaheadTime, setAudioLookaheadTime] = useState<string>('50');
|
||||||
@@ -28,7 +28,7 @@ const BehaviorSettings: React.FC = () => {
|
|||||||
await configManager.initialize();
|
await configManager.initialize();
|
||||||
}
|
}
|
||||||
|
|
||||||
setPlayheadUpdateFrequency((configManager.get('editor.playhead_update_frequency') as number) ?? 10);
|
setPlayheadUpdateFrequency((configManager.get('editor.playhead_update_frequency') as number) ?? 30);
|
||||||
setSpectrogramHeightResolution(
|
setSpectrogramHeightResolution(
|
||||||
normalizeSpectrogramHeightResolution(configManager.get('editor.spectrogram_height_resolution'))
|
normalizeSpectrogramHeightResolution(configManager.get('editor.spectrogram_height_resolution'))
|
||||||
);
|
);
|
||||||
|
|||||||
+1
-1
@@ -367,7 +367,7 @@ export class KGCore {
|
|||||||
|
|
||||||
// Get playhead update frequency from config (in fps)
|
// Get playhead update frequency from config (in fps)
|
||||||
const configManager = ConfigManager.instance();
|
const configManager = ConfigManager.instance();
|
||||||
const updateFrequency = (configManager.get('editor.playhead_update_frequency') as number) ?? 10;
|
const updateFrequency = (configManager.get('editor.playhead_update_frequency') as number) ?? 30;
|
||||||
const updateIntervalMs = 1000 / updateFrequency; // Convert fps to milliseconds
|
const updateIntervalMs = 1000 / updateFrequency; // Convert fps to milliseconds
|
||||||
|
|
||||||
this.playbackIntervalId = window.setInterval(() => {
|
this.playbackIntervalId = window.setInterval(() => {
|
||||||
|
|||||||
@@ -253,7 +253,7 @@ export class ConfigManager {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
editor: {
|
editor: {
|
||||||
playhead_update_frequency: 10,
|
playhead_update_frequency: 30,
|
||||||
spectrogram_height_resolution: 3
|
spectrogram_height_resolution: 3
|
||||||
},
|
},
|
||||||
chatbox: {
|
chatbox: {
|
||||||
|
|||||||
Reference in New Issue
Block a user