When using libopus as audio encoder, OBS should perform normally as using other codecs.
Navigate to [Settings] -> [Output] -> Recording
-> Type:Custom Output(FFmpeg) -> Audio Encoder
When libopus or opus (libopus) is selected, OBS is unable to [Start Recording]. Giving a message box which says:
-----------------Recording error--------------------
An unspecified error occurred while recording.
Failed to open audio codec: Invalid argument.
---------------------------------------OK-------------
I have tried aac, ac3 and libvorbis, no error occurred.
[Audio encoder settings(if any)] is left empty, [Audio Bitrate] is 128kbps, [Audio Track] is 1. I do not think these parameters matter.
libopus-0.dll do exist in OBS/bin/64bit folder.
Please tell me to provide more information if this issue cannot be reproduced.
Thanks for your development!
Environment: Windows 10 19H2 amd64
Release: 24.03 and 25 RC6, tried both Portable and Installer versions.
Issues are for bugs only. For support please use discord support channels for trying to find appropriate settings for a configuration.
Specifically ffmpeg custom output is use at your own risk. It is not a bug that you can provide invalid arguments to the encoders or muxers.
the error is probably because you've set 44100 Hz which is not supported by opus. Select 48 kHz
the error is probably because you've set 44100 Hz which is not supported by opus. Select 48 kHz
Thank you! The problem has been solved.
Sorry I did not notice the sample rate requirement of opus, but sample rate is not listed in [output] configuration tab so I first consider it as a 'bug'.
It is not a bug that you can provide invalid arguments to the encoders or muxers.
I did not provided any extra arguments, just default. The error output is also not telling what problem has encountered, I think there is a place for some extra notices.
Again, thanks for your replies.
Issues are for bugs only. For support please use discord support channels for trying to find appropriate settings for a configuration.
Specifically ffmpeg custom output is use at your own risk. It is not a bug that you can provide invalid arguments to the encoders or muxers.
How is it not considered as there is no clear error message and it fails ?
The error messages are passed, unhelpfully, from ffmpeg. They do not provide a clear error message so there is not much we can do. The custom ffmpeg output mode is an advanced feature, and it is expected that you know what you are doing when using it. It is not feasible for us to implement sanity checking for all of ffmpeg. The error message in this case is "invalid argument" which is basically "you configured it wrong, these settings aren't valid" and is the only feedback we are able to provide as that is the only feedback ffmpeg provides.
Ok. I understand. It is just sad that opus the apparently most efficient audio coding format which is also an open format do not work by default in OBS.
Ok. I understand. It is just sad that opus the apparently most efficient audio coding format which is also an open format do not work by default in OBS.
the issue is moot; upcoming obs release will have 48 khz as default sample rate so opus will work oob without tuning