mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-02 05:28:48 +00:00
pad-monitor: do not enforce caps querying rules for converters
Some encoders/decoders can also be converters, do not enforce caps proxying rules for them
This commit is contained in:
parent
163d286f5b
commit
db67a92b3f
3 changed files with 6 additions and 2 deletions
|
@ -181,6 +181,7 @@ gst_validate_element_monitor_inspect (GstValidateElementMonitor * monitor)
|
|||
monitor->is_decoder = strstr (klassname, "Decoder") != NULL;
|
||||
monitor->is_encoder = strstr (klassname, "Encoder") != NULL;
|
||||
monitor->is_demuxer = strstr (klassname, "Demuxer") != NULL;
|
||||
monitor->is_converter = strstr (klassname, "Converter") != NULL;
|
||||
} else
|
||||
GST_ERROR_OBJECT (element, "no klassname");
|
||||
}
|
||||
|
|
|
@ -42,6 +42,7 @@ G_BEGIN_DECLS
|
|||
#define GST_VALIDATE_ELEMENT_MONITOR_ELEMENT_IS_DECODER(m) (GST_VALIDATE_ELEMENT_MONITOR_CAST (m)->is_decoder)
|
||||
#define GST_VALIDATE_ELEMENT_MONITOR_ELEMENT_IS_ENCODER(m) (GST_VALIDATE_ELEMENT_MONITOR_CAST (m)->is_encoder)
|
||||
#define GST_VALIDATE_ELEMENT_MONITOR_ELEMENT_IS_DEMUXER(m) (GST_VALIDATE_ELEMENT_MONITOR_CAST (m)->is_demuxer)
|
||||
#define GST_VALIDATE_ELEMENT_MONITOR_ELEMENT_IS_CONVERTER(m) (GST_VALIDATE_ELEMENT_MONITOR_CAST (m)->is_converter)
|
||||
|
||||
typedef struct _GstValidateElementMonitor GstValidateElementMonitor;
|
||||
typedef struct _GstValidateElementMonitorClass GstValidateElementMonitorClass;
|
||||
|
@ -63,6 +64,7 @@ struct _GstValidateElementMonitor {
|
|||
gboolean is_decoder;
|
||||
gboolean is_encoder;
|
||||
gboolean is_demuxer;
|
||||
gboolean is_converter;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
@ -530,8 +530,9 @@ gst_validate_pad_monitor_pad_should_proxy_othercaps (GstValidatePadMonitor *
|
|||
return FALSE;
|
||||
|
||||
/* We only know how to handle othercaps checks for codecs so far */
|
||||
return GST_VALIDATE_ELEMENT_MONITOR_ELEMENT_IS_DECODER (parent) ||
|
||||
GST_VALIDATE_ELEMENT_MONITOR_ELEMENT_IS_ENCODER (parent);
|
||||
return (GST_VALIDATE_ELEMENT_MONITOR_ELEMENT_IS_DECODER (parent) ||
|
||||
GST_VALIDATE_ELEMENT_MONITOR_ELEMENT_IS_ENCODER (parent)) &&
|
||||
!GST_VALIDATE_ELEMENT_MONITOR_ELEMENT_IS_CONVERTER (parent);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue