Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Audio export is unreliable #391

Open
G3N-es opened this issue May 13, 2023 · 26 comments
Open

Audio export is unreliable #391

G3N-es opened this issue May 13, 2023 · 26 comments

Comments

@G3N-es
Copy link
Contributor

G3N-es commented May 13, 2023

The export audio option does not correspond 100% to the sound of the mix.
For example:
1_ For mixing I use high buffer values, in order to relieve the processor load. While this helps in the mix to synchronise without xruns. When exporting, the buffer is reflected, creating unwanted delays.

2_ The sound of midi instruments varies subtly between what you hear in the mix and the audio export.

3_ If you use Carla Pluging, sometimes not all sound modifications by different plugins within Carla are reflected in the export.

There is an obvious solution, not to use the audio export, and record the final master on another track (through an aux bus) in real time (although it is slower and sometimes it can generate an xrum that can force to repeat the recording).

So I consider it a minor problem.

However, a warning should be included when hitting the export button:
"Warning: Exports may not be faithful to the mix. If you want a result identical to what you hear while mixing, connect the master output to an aux bus input (with inserts as it doesn't work directly as stated in another issue), and record your mix to a track with input and output assigned to the aux."

@rncbc
Copy link
Owner

rncbc commented May 13, 2023

what qtractor version or build?

@G3N-es
Copy link
Contributor Author

G3N-es commented May 14, 2023

In any of them. The latest 0.9.33 app, and 0.9.12 deb on Zorin (ubuntu).

I've only been using Zorin for a few days. Before on AV-Linux with deb 0.9.31, which I don't remember how I managed to update, because on distros with debian/ubuntu branches, it's not easy to have the latest version of Qtractor installed.


To check this:

TEST 1
Just record a couple of virtual instruments and add a few plugins to the Master (reverb, chorus, compressor, eq... for example).

Export the audio from the master on one side.
On the other side record in Audacity the output of the master.
Compare in Audacity both audio waves, and they are different...
Logically, the one that is equal to the mix is the one from Audacity, because it records what you hear.

TEST 2
Configure jack bufter size to 256. Open a session and export audio to the master.
Configure jack bufter size to 2048. Open a session and export audio to the master.

Compare the two waves on Audacity. Are diffident. One way to check this is to invert one of the two waves (if they were the same, they would cancel each other out and would not reproduce sound, which is not the case). It can also be seen visually.
Listen to bufter size to 2048. You will see that it is out of sync.


I don't think it's a problem with Qtractor but with Jack.
In the documentation you indicate: "Audio export is implemented through the special JACK freewheel mode".

Maybe I'm talking nonsense, but if it's a special (different) mode, it's logical that it gives different results.

As a curiosity that may not be relevant, I have found the same problem in the Daw for IOS N-Track. The final render is not faithful to what you hear in the mix. And just like in Qtractor I perceive it to be of lower quality than in the mix.

So apparently it's not a unique Qtractor problem, it's common in several daws.

@rncbc
Copy link
Owner

rncbc commented May 14, 2023

you may have a point re. different buffer-sizes having slightly different results... I asked which version you're testing and thought that the differences would have been mitigated ever since v0.9.30 ...

but nope, there was a foolish mistake in there making it completely ineffective ever since :)

good news are, it's probably fixed now: please check qtractor >= 0.9.33.18git.10dfd4

thanks

@G3N-es
Copy link
Contributor Author

G3N-es commented May 15, 2023

I have tried to compile on ubuntu and fedora without success. I develop web applications (interpreted languages), but my knowledge of compiled language development is very very limited.

Without the experience to understand exactly what is going on, I give up.

I'm sorry I couldn't test it.

Thank you very much for everything.

@rncbc
Copy link
Owner

rncbc commented May 15, 2023

on ubuntu you can try and test from my ppa's; note that you probably will only need to add one of the "Applications" ppa's.

for other distros see the repos.
cheers

@G3N-es
Copy link
Contributor Author

G3N-es commented May 15, 2023

Now I do, hahaha. I didn't know you offered us this resource. It's great to have all your apps updated.

I'll take the opportunity to test it thoroughly.

In these days I will report the conclusions of the testing.

@G3N-es
Copy link
Contributor Author

G3N-es commented May 16, 2023

Versión: 0.9.33.18 on Zorin (Ubuntu)

Good news:
Buffer-size does not affect export now.

However, the result is still different from what you hear in the mix, even when exporting in 32 bit/float wav (which is the way audacity works and I think is also how Qtractor mixes).

Bad news:
The inserts on 0.9.33.18 are now broken and send a horribly distorted sound.

@G3N-es
Copy link
Contributor Author

G3N-es commented May 16, 2023

Correction:
"However, the result is still different from what you hear in the mix, even when exporting in 32 bit/float wav (which is the way audacity works and I think is also how Qtractor mixes)."

I have come to the conclusion that this is not a bug.

1_
I have recorded the same Master twice with Audacity via Jack, and got different results. So my hypothesis was wrong.

2_
I have exported twice the master of the same project, and although the results are closer to each other, they are not identical either.

The conclusion_
More effects and processes, more floating point. Although the final result is approximate, it is never exact.

The surprising thing is that now that I realise, every time we press play, the sound will necessarily be subtly different.

@rncbc
Copy link
Owner

rncbc commented May 16, 2023

maybe it's all a due effect of one or more of the plugins fx? reverbs are notorious in this regard; also having some fx that applies dithering based on some noise shape will certaily lead to ever slightly differences, moreover if it's amplified or processed in a later stage eg. limiter, compressor.

@rncbc
Copy link
Owner

rncbc commented May 16, 2023

Bad news:
The inserts on 0.9.33.18 are now broken and send a horribly distorted sound.

please try qtractor >= 0.9.33.20git.7f74de

@G3N-es
Copy link
Contributor Author

G3N-es commented May 16, 2023

maybe it's all a due effect of one or more of the plugins fx? reverbs are notorious in this regard; also having some fx that applies dithering based on some noise shape will certaily lead to ever slightly differences, moreover if it's amplified or processed in a later stage eg. limiter, compressor.

That makes sense to me

@G3N-es
Copy link
Contributor Author

G3N-es commented May 16, 2023

Bad news:
The inserts on 0.9.33.18 are now broken and send a horribly distorted sound.

please try qtractor >= 0.9.33.20git.7f74de

Provided that the return has a lower ID than the shipment:

1_ Between Tracks: returns to work with clean sound.

2_ Between Tracks and Buses:
Works as long as the send is made to the bus input:
[ OneTrack [ Inser2/Out] ---]--->[ OneBus/In_1] ;
[OneTrack [ Inser2/Out] ---]---[ OneBus/In_1 ---> [ Inser1/In] ] ;

No send and/or return on the Bus output.
[OneTrack [ Inser2/Out] ---]---[ OneBus/Out_1 ---> [ Inser1/In] ] ] ;

3_ Between Buses or Bus to Track: No send and/or return.

@rncbc
Copy link
Owner

rncbc commented May 16, 2023

please report your findings re.

horribly distorted sound.

alone.

most issues re. no sound or silence are most probably due to the order of the output buses and/or direct loops--as long known and stated briefly on #390 (comment)

@G3N-es
Copy link
Contributor Author

G3N-es commented May 16, 2023

Ok, but the 0.9.33 official app doesn't have these issues.
In it you can send between buses with inserts.

They are new. That's why I mention them.
As it is now it is impossible to interconnect buses, and that makes the bus functionality meaningless.
It's as if Qtractor is losing features instead of gaining them.

Maybe you mean I should have brought it up in the other thread.
But, as the issue has arisen with this fix....

I'm trying to help, but it's not easy. I understand it's a complex project and you're just trying to keep order. :-)

@rncbc
Copy link
Owner

rncbc commented May 17, 2023

so to make it clear:

Provided that the return has a lower ID than the shipment:

yes, correct; that is the way

1_ Between Tracks: returns to work with clean sound.

good. EDIT: but still, it shall obey the rule stated above.

2_ Between Tracks and Buses: Works as long as the send is made to the bus input: [ OneTrack [ Inser2/Out] ---]--->[ OneBus/In_1] ; [OneTrack [ Inser2/Out] ---]---[ OneBus/In_1 ---> [ Inser1/In] ] ;

No send and/or return on the Bus output. [OneTrack [ Inser2/Out] ---]---[ OneBus/Out_1 ---> [ Inser1/In] ] ] ;

this won't work for sure: send/return inserts are not supposed to ever work between tracks and output buses;
to make this kind of routing (track or bus -> output bus) use the other kind of inserts instead: Aux-Sends.

3_ Between Buses or Bus to Track: No send and/or return.

again, there's no way to workaround the internal routing from input buses to tracks in any way and with any kind of inserts; it won't work, period. by design

are you saying that it was working on v0.9.33 ? can you please check again ? thanks

@G3N-es
Copy link
Contributor Author

G3N-es commented May 17, 2023

Ummm
And yet it works.

https://youtu.be/KHveG2Y1L3o

(Official v0.9.33 App)

@rncbc
Copy link
Owner

rncbc commented May 17, 2023

Ummm And yet it works.

https://youtu.be/KHveG2Y1L3o

(Official v0.9.33 App)

that looks like between output buses, for which the first rule applies

you say that this works on "official" v0.9.33 but doesn't on git head v0.9.33.20 ?

@G3N-es
Copy link
Contributor Author

G3N-es commented May 17, 2023

Exactly, not in v0.9.33.20

@rncbc
Copy link
Owner

rncbc commented May 17, 2023

as said, try using aux-send for that, it's way more efficient and also doesn't add a period of delay/latency as send/return inserts certainly do (coz you're resorting to an external loop through the jack graph; aux-sends are purely internal)

@G3N-es
Copy link
Contributor Author

G3N-es commented May 17, 2023

The problem is that aux-sends are not available for busses.

An interesting workflow is to create a mix or premaster bus to mix, and from there send to the final master bus, where you only worry about mastering issues like compression, colour/saturation, eq and limiter.

The same applies if you want to create different busses for different effects, for specific tracks, or groups of tracks.
In the end you will always need to send all these audio sources to a single master.

Keeping the busses separate prevents you from mastering the final mix (like limiting etc etc).

@G3N-es
Copy link
Contributor Author

G3N-es commented May 17, 2023

I want to clarify again that the video sent are buses, not tracks.

@rncbc
Copy link
Owner

rncbc commented May 18, 2023

aux-sends may be inserted on tracks and buses.

@G3N-es
Copy link
Contributor Author

G3N-es commented May 18, 2023

On buses this option is deactivated.
In my memory, in all versions I used of Qtractor... it was always disabled on buses.
Sin nombre

I don't understand anything

@rncbc
Copy link
Owner

rncbc commented May 18, 2023

sorry: aux-sends are not allowed on output buses (doesn't really make sense there); but they are allowed on input buses and tracks.

@G3N-es
Copy link
Contributor Author

G3N-es commented May 18, 2023

There are always alternative ways to achieve these results. For me inserts is one of them.
Another is to duplicate tracks to get controllable effects in parallel.
Another one is Carla and her nodal editing that allows hybrid parallel/serial setups.

Also the issue that I opened this thread for, and turned out not to be such an issue, is becoming increasingly clear: inpust and delay effects (such as delays and reverbs), can add to those subtle audio differences when exporting.

Knowing this I'll stick to not including buss in my workflow.
Qtractor is still my favourite DAW. :-)

For me it's a fully-fledged DAW. The only functionality you can't get with Qtractor are the plug-in sends with sidechaim, but honestly I don't need them.

I'm very grateful for your great gift.

@rncbc
Copy link
Owner

rncbc commented May 18, 2023

thanks for kind feedback

cheers

ps. let me add that in case you TL;DR the above of #390 (comment), there's something to be clarified still:

the bad old news that you should be aware, is that connecting any qtractor outs directly into any of its own inputs (like send/returns to itself) was, and still is not an advisable thing to do, ever... to put it straight, it all relates to an old and infamous JACK zero-copy optimization feature and ruled out as a bug (in qtractor or JACK itself), yada, yada....

good news are, under PipeWire-JACK substitution, this shrodinger cat's bug/feature is a non-subject, thank goodness! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants