elementfactory: add ENCRYPTOR class defines
authorTim-Philipp Müller <tim@centricular.com>
Tue, 14 Apr 2015 16:47:08 +0000 (17:47 +0100)
committerTim-Philipp Müller <tim@centricular.com>
Tue, 14 Apr 2015 16:51:05 +0000 (17:51 +0100)
to go with DECRYPTOR.

gst/gstelementfactory.c
gst/gstelementfactory.h

index e25b071..486b9fe 100644 (file)
@@ -732,6 +732,9 @@ gst_element_factory_list_is_type (GstElementFactory * factory,
   if (!res && (type & GST_ELEMENT_FACTORY_TYPE_DECRYPTOR))
     res = (strstr (klass, "Decryptor") != NULL);
 
+  if (!res && (type & GST_ELEMENT_FACTORY_TYPE_ENCRYPTOR))
+    res = (strstr (klass, "Encryptor") != NULL);
+
   /* Filter by media type now, we only test if it
    * matched any of the types above or only checking the media
    * type was requested. */
index 3245d70..117d00e 100644 (file)
@@ -88,7 +88,8 @@ gboolean                gst_element_register                    (GstPlugin *plug
  * @GST_ELEMENT_FACTORY_TYPE_PARSER: Parser elements
  * @GST_ELEMENT_FACTORY_TYPE_PAYLOADER: Payloader elements
  * @GST_ELEMENT_FACTORY_TYPE_DEPAYLOADER: Depayloader elements
- * @GST_ELEMENT_FACTORY_TYPE_DECRYPTOR: Elements handling decryption
+ * @GST_ELEMENT_FACTORY_TYPE_DECRYPTOR: Elements handling decryption (Since: 1.6)
+ * @GST_ELEMENT_FACTORY_TYPE_ENCRYPTOR: Elements handling encryption (Since: 1.6)
  * @GST_ELEMENT_FACTORY_TYPE_MAX_ELEMENTS: Private, do not use
  * @GST_ELEMENT_FACTORY_TYPE_MEDIA_VIDEO: Elements handling video media types
  * @GST_ELEMENT_FACTORY_TYPE_MEDIA_AUDIO: Elements handling audio media types
@@ -117,6 +118,7 @@ typedef guint64 GstElementFactoryListType;
 #define  GST_ELEMENT_FACTORY_TYPE_DEPAYLOADER    (G_GUINT64_CONSTANT (1) << 8)
 #define  GST_ELEMENT_FACTORY_TYPE_FORMATTER      (G_GUINT64_CONSTANT (1) << 9)
 #define  GST_ELEMENT_FACTORY_TYPE_DECRYPTOR      (G_GUINT64_CONSTANT (1) << 10)
+#define  GST_ELEMENT_FACTORY_TYPE_ENCRYPTOR      (G_GUINT64_CONSTANT (1) << 11)
 
 #define  GST_ELEMENT_FACTORY_TYPE_MAX_ELEMENTS   (G_GUINT64_CONSTANT (1) << 48)
 
@@ -203,6 +205,7 @@ typedef guint64 GstElementFactoryListType;
 #define GST_ELEMENT_FACTORY_KLASS_DEPAYLOADER           "Depayloader"
 #define GST_ELEMENT_FACTORY_KLASS_FORMATTER             "Formatter"
 #define GST_ELEMENT_FACTORY_KLASS_DECRYPTOR             "Decryptor"
+#define GST_ELEMENT_FACTORY_KLASS_ENCRYPTOR             "Encryptor"
 
 #define GST_ELEMENT_FACTORY_KLASS_MEDIA_VIDEO           "Video"
 #define GST_ELEMENT_FACTORY_KLASS_MEDIA_AUDIO           "Audio"