Closed jelmansouri-legion closed 3 years ago
This is fantastic, thanks!
About compile behavior, I haven't thought it through but ideally I'd want the crate
OPENH264_FORCE_NASM
) that instead makes compilation fail if nasm can't be found.That way most downstream users would transparently get the best code without any compile hiccups, while people who want to really enforce nasm get an escape hatch to fail compilation early.
Can confirm this works on Windows, Linux with similar performance gains.
Published as 0.2.5.
Adding assembly support for openh264-sys2 by relying on nasm-rs on x86/x86_64. Currently if nasm is missing we do not fail the build, we issue a warning, (I had an error originally but though that might be enough if the feature is enabled by default). The feature is not enabled by default.
Here are the bench results on my machine (11th Gen Intel(R) Core(TM) i9-11950H @ 2.60GHz 2.61 GHz):
with the feature enabled
Note that I only tested the following targets:
x86_64-pc-windows-msvc
andx86_64-unknown-linux-gnu
.