summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2022-08-02 11:08:09 +0200
committerAnton Khirnov <anton@khirnov.net>2022-08-08 16:20:58 +0200
commit04b340e6b8f8d1000ad66077a00e792e7cd9d30d (patch)
tree39c627379a8e600bb9a785a317bc7f8581c776e5
parent20ba49c1a4dcda982d4674b100e524f59db096e9 (diff)
fftools/ffmpeg_hw: stop logging to the decoder context
Only the decoder itself should do that. Use NULL as is done by all other logging code in ffmpeg.
-rw-r--r--fftools/ffmpeg_hw.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/fftools/ffmpeg_hw.c b/fftools/ffmpeg_hw.c
index 14e702bd92..8acfeaf08f 100644
--- a/fftools/ffmpeg_hw.c
+++ b/fftools/ffmpeg_hw.c
@@ -339,7 +339,7 @@ int hw_device_setup_for_decode(InputStream *ist)
if (ist->hwaccel_id == HWACCEL_AUTO) {
ist->hwaccel_device_type = dev->type;
} else if (ist->hwaccel_device_type != dev->type) {
- av_log(ist->dec_ctx, AV_LOG_ERROR, "Invalid hwaccel device "
+ av_log(NULL, AV_LOG_ERROR, "Invalid hwaccel device "
"specified for decoder: device %s of type %s is not "
"usable with hwaccel %s.\n", dev->name,
av_hwdevice_get_type_name(dev->type),
@@ -390,7 +390,7 @@ int hw_device_setup_for_decode(InputStream *ist)
type = config->device_type;
dev = hw_device_get_by_type(type);
if (dev) {
- av_log(ist->dec_ctx, AV_LOG_INFO, "Using auto "
+ av_log(NULL, AV_LOG_INFO, "Using auto "
"hwaccel type %s with existing device %s.\n",
av_hwdevice_get_type_name(type), dev->name);
}
@@ -408,12 +408,12 @@ int hw_device_setup_for_decode(InputStream *ist)
continue;
}
if (ist->hwaccel_device) {
- av_log(ist->dec_ctx, AV_LOG_INFO, "Using auto "
+ av_log(NULL, AV_LOG_INFO, "Using auto "
"hwaccel type %s with new device created "
"from %s.\n", av_hwdevice_get_type_name(type),
ist->hwaccel_device);
} else {
- av_log(ist->dec_ctx, AV_LOG_INFO, "Using auto "
+ av_log(NULL, AV_LOG_INFO, "Using auto "
"hwaccel type %s with new default device.\n",
av_hwdevice_get_type_name(type));
}
@@ -421,7 +421,7 @@ int hw_device_setup_for_decode(InputStream *ist)
if (dev) {
ist->hwaccel_device_type = type;
} else {
- av_log(ist->dec_ctx, AV_LOG_INFO, "Auto hwaccel "
+ av_log(NULL, AV_LOG_INFO, "Auto hwaccel "
"disabled: no device found.\n");
ist->hwaccel_id = HWACCEL_NONE;
return 0;
@@ -429,7 +429,7 @@ int hw_device_setup_for_decode(InputStream *ist)
}
if (!dev) {
- av_log(ist->dec_ctx, AV_LOG_ERROR, "No device available "
+ av_log(NULL, AV_LOG_ERROR, "No device available "
"for decoder: device type %s needed for codec %s.\n",
av_hwdevice_get_type_name(type), ist->dec->name);
return err;