Created attachment 227779 [details]
This library contains a logic that will attempting to lower the scheduling priority of the encoding thread, if multi-threading is enabled. However it is flawed as it will lower the priority of the entire process (by calling nice(3)), not only that specific thread; in fact in will lower the process scheduling priority every time when a encoding thread is created, the priority of whole process will be set to the lowest (nice=20) as a result.
This behavior is highly undesirable because it may result in losing real-time proformance of other threads of the library consumer, such as ffmpeg(1); libx264, as a library, shouldn't change the process priority, affecting the entire process of any program that may using this library.
Another issue is that under some scenarios, lowering the scheduling priority of encoding threads isn't preferable at all, because the video source or target could be a live stream, thus requiring real-time proformance to encode it.
A patch is attached that disables this behavior.
Created attachment 227780 [details]
Clean up parent directory names in the diff file.