Page 1 of 1

Thread Optimization

Posted: Mon Jan 23, 2012 7:55 pm
by SoranoGuardias
This program is nice. However, I must admit that using the included converter, while convenient, takes quite a while compared to my other software. The reason I use the included converter is because it completely strips out the embedded metadata that many services, such as iTunes includes. Other converters I have tried do not do that and, as a result, render the processed file unplayable.

Is there any way to setup the program so it has the capability to fully utilize the user-defined number of available cores? If not, how difficult would that implementation be?

Re: Thread Optimization

Posted: Mon Jan 23, 2012 8:23 pm
by Renegade
HLDJ is using libmad and libsamplerate which I don't think are thread safe. Threading may be possible, but the more likely the reason you're seeing for the slower operation is that it's unbuffered. The HLDJ converter reads from the file instead of faster applications that probably first read the file into memory. This was done for simplicity and to reduce memory constraints. The HLDJ converter wasn't really designed to be top-of-the-line, but to be used in conjunction with audio editors or as a reference for properly converting files. Since it's open source though, any one is free to modify or improve it. It should be fairly easy to at least buffer the input into memory first, though threading would depend on if the libraries are threadsafe.