@@ -212,6 +212,12 @@ export class Visualizer extends Events<VisualizerEvents> {
212212 // as a result of multichannel or differently configured waveHeight
213213 this . setContainerHeight ( ) ;
214214
215+ // Update regions layer height to match the current visualizer height
216+ const regionsLayer = this . getLayer ( "regions" ) ;
217+ if ( regionsLayer ) {
218+ regionsLayer . height = this . height ;
219+ }
220+
215221 // Set renderers array
216222 this . renderers = [ this . waveformRenderer ] ;
217223 if ( isFF ( FF_AUDIO_SPECTROGRAMS ) && this . spectrogramRenderer ) {
@@ -956,18 +962,24 @@ export class Visualizer extends Events<VisualizerEvents> {
956962 // Update layer dimensions
957963 const mainLayer = this . getLayer ( "main" ) ;
958964 if ( mainLayer ) {
965+ mainLayer . pixelRatio = this . pixelRatio ;
959966 mainLayer . width = this . width ;
960967 mainLayer . height = this . height ;
961968 }
962969
963970 // Update other layers
964971 this . layers . forEach ( ( layer ) => {
965972 if ( layer . name !== "main" ) {
973+ layer . pixelRatio = this . pixelRatio ;
966974 layer . width = this . width ;
967975 // Only update height for layers that should match the waveform height
968976 if ( layer . name === "waveform" || layer . name === "spectrogram" || layer . name === "spectrogram-grid" ) {
969977 layer . height = this . waveformHeight ;
970978 }
979+ // Update regions layer height to match the full visualizer height
980+ if ( layer . name === "regions" ) {
981+ layer . height = this . height ;
982+ }
971983 }
972984 } ) ;
973985
0 commit comments