You are here

Qtractor crash when normalizing clip

Hi @rncbc, here's a continuation of our discussion on LinuxMusicians.com.

The project I'm using for the testing we've done is already the bare minimum. I start Qtractor, which automatically presents a new, empty project. I create an audio track, add a clip to it, and select the clip and do a Normalize. That's when it crashes.

Just as a reminder, this is on an up-to-date install of Manjaro. When I used the same function on Mint, it worked.

Let me know how I can help.

Forums: 
scott.thomason's picture

The crash is due to a buffer overflow in the memcpy() starting on the second line of code below, which is line 178 in qtractorRingBuffer.h:

	for (unsigned short i = 0; i < m_iChannels; ++i) {
		::memcpy((T *)(ppFrames[i] + iOffset),
			(T *)(m_ppBuffer[i] + r), n1 * sizeof(T));
		if (n2) {
			n1 += iOffset;
			::memcpy((T *)(ppFrames[i] + n1),
				m_ppBuffer[i], n2 * sizeof(T));
		}
	}

I'm happy to help in any way I can.

scott.thomason's picture

For the sake of being thorough, here's the .qtz you asked for...

File attachments: 
rncbc's picture

Ok. Will try to investigate later today.

Meanwhile, does it happen on any audio file (.wav) you throw in or just that one in particular?

Also of interest might be the main sample-rate you are running (as seen on the bottom-right status bar in the main window): is it 44100, 48000 or else?

Cheers

scott.thomason's picture

I'm running it at 48000, but the clip was recorded at 44100.

It's crashed on several of the .wav files I tried, but now that you mention it, they were all kick drums from the same recording session. One thing that's weird about them is they don't show any wave pattern on the clip. Since you brought it up, I tried samples from other recording sessions, and those worked (and they displayed the normal visible wave pattern on the clip). So perhaps there is something unusual about the .wav file?

rncbc's picture

the audio file has an unusual number of 16 channels (!) ... no wonder it doesn't show so many waveforms though...

may I ask where and how did you record that? those kind of files are not that suitable to be on an qtractor audio track, unless you provide a 16ch audio output bus... which is unlikely to be useful anyway, just saying :S

UPDATE: can you try this qtractor >= 0.9.26.28git.549930 ? cheers

scott.thomason's picture

They come from the MuldjordKit2 drum samples by the DrumGizmo people. It looks like they did use 16 microphones: https://drumgizmo.org/wiki/doku.php?id=kits:muldjordkit

I tried the latest git version. It still crashes, but now that I know the problem is with the .wav files, I'll just choose different drum samples. Maybe there should be an alert or something when you try to place a file with more channels than the bus, or something like that?

Thanks much for your efforts.

rncbc's picture

would you please try it all again, with >= 0.9.26.29git.3bbb5e ?

the previous bet was surely on blinds ;)
cheers

scott.thomason's picture

It doesn't crash anymore, and even though you can't see the waves on the clip, you can hear that the normalize worked. Thanks a lot, Rui.

rncbc's picture

but the waveforms are there alright only that they're a lot of 16 remember? stacked vertically and probably the very tiny signal shapes are not at all distinguishable from the straight lines.

if you wish you may try to merge or export the clip resulting in a mix-down audio file with the same number of channels as the current track's output bus... maybe after that you can better see the waveforms...

however, I must tell it again, it is unlikely to be of any use, as the resulting de-multiplexing of 16 into 2 (if that's the case) it is not the intended purpose for the original sample file: it is supposed to be used by DrumGizmo and strictly only relevant in that context.

cheers

Add new comment