question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

waveform draw fails silently with short sounds at certain window widths, esp on hi dpi displays

See original GitHub issue

Wavesurfer.js version(s):

4.1.1

Browser and operating system version(s):

observed on at least Windows latest FF & Chrome, Mac latest Chrome, probably others

Code needed to reproduce the issue:

https://codepen.io/keymapper/pen/XWKdwvz?editors=0010

Use behaviour needed to reproduce the issue:

With very (very) short sounds, the waveform is blank on responsive wavesurfer elements if the window is set wide enough, regardless of minPxPerSec setting, and with no firing of the ‘error’ callback. The above codepen loads 3 short drum sound waveforms (all around 0.1 seconds or less) in responsive mode. On my 2k desktop monitor the topmost sound waveform is always rendered blank at just about any window width, and if I maximize (2048x1040 reported innerWidth but this is scaled with window.devicePixelRatio of 1.25) the top 2 are blank. On my 13" macbook pro retina display if I maximize all 3 turn blank. In all cases if I resize the window width small enough the waveform comes back into view. It seems like some threshold is reached where minPxPerSec has no effect, but ideally wavesurfer should catch this situation and adjust the minPxPerSec automatically even if it means a pixelated waveform (or at least partially fill the container or fire an error rather than be blank). It seems like differing system scaling settings and monitor hi-dpi-ness comes into play here as well.

Issue Analytics

  • State:open
  • Created 3 years ago
  • Comments:14 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
marcelblumcommented, Nov 23, 2020

Sure, here’s the same demo in a standalone page on my own server: https://soundplant.org/wavesurfer/wavesurferresizebug.html

0reactions
marcelblumcommented, Mar 9, 2021

@thijstriemstra IMO it’s still a bug at least because the error event is not emitted in this situation, but certainly a low priority one with an easy workaround now that I know how to handle it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Fix DPI display issues in Windows Form Designer - Visual ...
To do so, type display settings in the task bar search box, and then select Change display settings.
Read more >
mintty [OPTION]... [ - | PROGRAM [ARG]... ]
For example, mintty -s maxwidth -p 0,0 -s 0,10 will start a window at full screen width, positioned at the top of the...
Read more >
کتاب راهنما - MuseScore
If you're on Windows 10, MuseScore can be installed from the Windows Store. ... In the Inspector, the properties of any selected object...
Read more >
Untitled
Fraterna domus civita castellana, Wii u wii menu screen size, ... Homestead high school marching band 2014 indiana, Lee joon we got married...
Read more >
Wireshark User's Guide
The Statusbar with a selected protocol field; 3.25. The Statusbar with a display filter message; 4.1. Capture interfaces on Microsoft Windows; 4.2.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found