This makes it possible to see special sound waves where the min/max difference between steps doesn't differ.
Before:
After:
Differential D11184
VSE: Use lines to draw waveform Authored by Sebastian Parborg (zeddb) on May 6 2021, 8:50 PM.
Details This makes it possible to see special sound waves where the min/max difference between steps doesn't differ. Before: After:
Diff Detail Event TimelineComment Actions Updated so we now mix lines and triangles when drawing. I also fixed and added RMS visualization: Comment Actions Just a reminder for myself that I found a ASAN error in audaspace when loading very long audio files (~20min): blender/extern/audaspace/plugins/ffmpeg/FFMPEGReader.cpp:377:63: runtime error: 8.84558e+20 is outside the range of representable values of type 'int' blender/extern/audaspace/plugins/ffmpeg/FFMPEGReader.cpp:385:16: runtime error: signed integer overflow: 0 - -2147483648 cannot be represented in type 'int' Perhaps I should split the RMS calculation fix and the fix for the above issue into separate commits.
Comment Actions Updated so that the drawn waveform doesn't jump around because of rounding when changing strip start offset. Comment Actions So far I have checkedperformance and don't see any regression here Some code here seems to be compactifyable I guess? especially over tri_strip_iter and line_strip_iter perhaps even in a way that would explain the code better? Comment Actions I'm a bit unsure what you mean. I'm sure I could explain it better in the code but I don't think it can easily be simplified further. (I could of course be wrong).
It creates two data sets. One for the triangle strip and one for the linestrips. These two never overlap. If the amplitude difference in the sound signal is small then we draw a line, if it is not small we draw a triangle to create a "filled in" area in the waveform. In the end we draw two overlapping triangle strips to produce the RMS display. Comment Actions Maybe this is unrelated to this patch? When switching off Overlay texts, the waveform doesn't seem to be centered: When transforming, the drawing of the waveform "jitters": Comment Actions From the audio side this looks good (it's basically only the RMS fix anyway), I didn't check the drawing code in detail. And the issues raised by @Peter Fog (tintwotin) probably need to be fixed before committing this to master. Comment Actions Just wanted to run it by you so the small change did cause some unforeseen domino effect as the output data changed. The issues pointed out has been fixed in my branch. | ||||||