summaryrefslogtreecommitdiff
path: root/gst/wavparse/gstwavparse.c
diff options
context:
space:
mode:
Diffstat (limited to 'gst/wavparse/gstwavparse.c')
-rw-r--r--gst/wavparse/gstwavparse.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/gst/wavparse/gstwavparse.c b/gst/wavparse/gstwavparse.c
index 36747799c..0aa24c2c4 100644
--- a/gst/wavparse/gstwavparse.c
+++ b/gst/wavparse/gstwavparse.c
@@ -1827,12 +1827,16 @@ gst_wavparse_have_dts_caps (const GstCaps * caps, GstTypeFindProbability prob)
s = gst_caps_get_structure (caps, 0);
if (!gst_structure_has_name (s, "audio/x-dts"))
return FALSE;
- if (prob >= GST_TYPE_FIND_LIKELY)
+ /* typefind behavior for DTS:
+ * MAXIMUM: multiple frame syncs detected, certainly DTS
+ * LIKELY: single frame sync at offset 0. Maybe DTS?
+ * POSSIBLE: single frame sync, not at offset 0. Highly unlikely
+ * to be DTS. */
+ if (prob > GST_TYPE_FIND_LIKELY)
return TRUE;
- /* DTS at non-0 offsets and without second sync may yield POSSIBLE .. */
if (prob <= GST_TYPE_FIND_POSSIBLE)
return FALSE;
- /* .. in which case we want at least a valid-looking rate and channels */
+ /* for maybe, check for at least a valid-looking rate and channels */
if (!gst_structure_has_field (s, "channels"))
return FALSE;
/* and for extra assurance we could also check the rate from the DTS frame