disable ffmpeg ram codec temporarily (#6927)

Signed-off-by: 21pages <pages21@163.com>
This commit is contained in:
21pages
2024-01-20 17:19:30 +08:00
committed by GitHub
parent 9e3633f1e4
commit 267342e7e6
3 changed files with 13 additions and 4 deletions

View File

@@ -708,10 +708,17 @@ impl Decoder {
#[cfg(any(feature = "hwcodec", feature = "mediacodec"))]
pub fn enable_hwcodec_option() -> bool {
if let Some(v) = Config2::get().options.get("enable-hwcodec") {
return v != "N";
#[cfg(feature = "hwcodec")]
{
return false;
}
#[cfg(feature = "mediacodec")]
{
if let Some(v) = Config2::get().options.get("enable-hwcodec") {
return v != "N";
}
return true; // default is true
}
return true; // default is true
}
#[cfg(feature = "gpucodec")]
pub fn enable_gpucodec_option() -> bool {

View File

@@ -381,6 +381,7 @@ pub fn check_available_hwcodec() {
}
pub fn hwcodec_new_check_process() {
/*
use std::sync::Once;
let f = || {
// Clear to avoid checking process errors
@@ -423,4 +424,5 @@ pub fn hwcodec_new_check_process() {
ONCE.call_once(|| {
std::thread::spawn(f);
});
*/
}