Commit f2d1c9b0 authored by Stefan Kost's avatar Stefan Kost
Browse files

ffmpegcolorspace: add perf-log-category and log suboptimal operation

Log if we use an intermediate colorspace for conversion.
parent 2b579aaa
......@@ -41,6 +41,7 @@
GST_DEBUG_CATEGORY (ffmpegcolorspace_debug);
#define GST_CAT_DEFAULT ffmpegcolorspace_debug
GST_DEBUG_CATEGORY (GST_CAT_PERFORMANCE);
/* elementfactory information */
static const GstElementDetails ffmpegcsp_details =
......@@ -488,6 +489,7 @@ gst_ffmpegcolorspace_register (GstPlugin * plugin)
GST_DEBUG_CATEGORY_INIT (ffmpegcolorspace_debug, "ffmpegcolorspace", 0,
"FFMPEG-based colorspace converter");
GST_DEBUG_CATEGORY_GET (GST_CAT_PERFORMANCE, "GST_PERFORMANCE");
/* template caps */
caps = gst_ffmpegcsp_codectype_to_caps (CODEC_TYPE_VIDEO, NULL);
......
......@@ -35,6 +35,8 @@
#include <string.h>
#include <stdlib.h>
GST_DEBUG_CATEGORY_EXTERN (GST_CAT_PERFORMANCE);
#define xglue(x, y) x ## y
#define glue(x, y) xglue(x, y)
......@@ -3121,6 +3123,8 @@ img_convert (AVPicture * dst, int dst_pix_fmt,
return 0;
}
no_chroma_filter:
GST_CAT_INFO (GST_CAT_PERFORMANCE, "no direct path to convert colorspace "
"from %s -> %s", src_pix->name, dst_pix->name);
/* try to use an intermediate format */
if (src_pix_fmt == PIX_FMT_YUV422 || dst_pix_fmt == PIX_FMT_YUV422) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment