caps: Optimize gst_caps_is_subset()
authorSebastian Dröge <sebastian.droege@collabora.co.uk>
Fri, 27 May 2011 11:38:51 +0000 (13:38 +0200)
committerSebastian Dröge <sebastian.droege@collabora.co.uk>
Fri, 27 May 2011 11:38:51 +0000 (13:38 +0200)
commitd98e9acb0fc595dc5afa5af8b4103cc5b7755aab
tree3f425b5e10518fdbd4c8b5aa25f858051acd0fcb
parent0cf2dfd0ba7dc835a43c05d1b043e59021c18852
caps: Optimize gst_caps_is_subset()

..and as a result gst_caps_is_equal() and others.

This now only checks if for every subset structure there is
a superset structure in the superset caps. Previously we were
subtracting one from another, creating completely new caps
and then even simplified them.

The new implemention now is about 1.27 times faster and doesn't
break the -base unit tests are anything anymore.
gst/gstcaps.c
tests/check/gst/gstcaps.c