+ if (!strcmp (mimetype, "video/x-wmv")) {
+ gint wmvversion = 0;
+
+ if (gst_structure_get_int (str, "wmvversion", &wmvversion)) {
+ switch (wmvversion) {
+ case 1:
+ g_strlcpy(codec_name, "wmv1", 32);
+ break;
+ case 2:
+ g_strlcpy(codec_name, "wmv2", 32);
+ break;
+ case 3:
+ {
+ guint32 fourcc;
+
+ g_strlcpy(codec_name, "wmv3", 32);
+
+ if (gst_structure_get_fourcc (str, "format", &fourcc)) {
+ if ((fourcc == GST_MAKE_FOURCC ('W', 'V', 'C', '1')) ||
+ (fourcc == GST_MAKE_FOURCC ('W', 'M', 'V', 'A'))) {
+ g_strlcpy(codec_name, "vc1", 32);
+ }
+ }
+ }
+ break;
+ }
+ }
+ }
+
+#if 0 // check other types if it needs.
+ } else if () {
+ }
+#endif
+
+#if 0
+ if (context != NULL) {
+ if (video == TRUE) {
+ context->codec_type = CODEC_TYPE_VIDEO;
+ } else if (audio == TRUE) {
+ context->codec_type = CODEC_TYPE_AUDIO;
+ } else {
+ context->codec_type = CODEC_TYPE_UNKNOWN;
+ }
+ context->codec_id = id;
+ gst_maru_caps_with_codecname (name, context->codec_type, caps, context);
+ }
+#endif
+
+ if (codec_name != NULL) {
+ GST_DEBUG ("The %s belongs to the caps %" GST_PTR_FORMAT, codec_name, caps);
+ } else {
+ GST_WARNING ("Couldn't figure out the name for caps %" GST_PTR_FORMAT, caps);
+ }