rawvideoparse: Revert last commit and actually remember the physically last plane
authorSebastian Dröge <sebastian@centricular.com>
Fri, 19 Aug 2016 11:19:38 +0000 (14:19 +0300)
committerSebastian Dröge <sebastian@centricular.com>
Fri, 19 Aug 2016 11:19:38 +0000 (14:19 +0300)
Instead of just always taking the last one as before.

gst/rawparse/gstrawvideoparse.c

index 7e3d2ef..acec6d2 100644 (file)
@@ -1176,10 +1176,10 @@ gst_raw_video_parse_update_info (GstRawVideoParseConfig * config)
   for (i = 0; i < n_planes; ++i) {
     gsize plane_offset = GST_VIDEO_INFO_PLANE_OFFSET (info, i);
     if (plane_offset >= last_plane_offset) {
+      last_plane = i;
       last_plane_offset = plane_offset;
     }
   }
-  last_plane = n_planes - 1;
 
   last_plane_size =
       GST_VIDEO_INFO_PLANE_STRIDE (info,