Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 1 | commit 88d253ea23b06289df40401160b606323f16c910 |
| 2 | Author: Song Bing <b06498@freescale.com> |
| 3 | Date: Mon Dec 15 09:34:35 2014 +0800 |
| 4 | |
| 5 | videopool: update video alignment after video alignment |
| 6 | |
| 7 | Video buffer pool will update video alignment to respect stride alignment |
| 8 | requirement. But haven't update it to video alignment in configure. |
| 9 | Which will cause user get wrong video alignment. |
| 10 | |
| 11 | https://bugzilla.gnome.org/show_bug.cgi?id=741501 |
| 12 | |
| 13 | Upstream-Status: Backport [1.5.1] |
| 14 | |
| 15 | Signed-off-by: Song Bing <b06498@freescale.com> |
| 16 | diff --git a/gst-libs/gst/video/gstvideopool.c b/gst-libs/gst/video/gstvideopool.c |
| 17 | index 4475f45..acef594 100644 |
| 18 | --- a/gst-libs/gst/video/gstvideopool.c |
| 19 | +++ b/gst-libs/gst/video/gstvideopool.c |
| 20 | @@ -167,6 +167,7 @@ video_buffer_pool_set_config (GstBufferPool * pool, GstStructure * config) |
| 21 | /* get an apply the alignment to the info */ |
| 22 | gst_buffer_pool_config_get_video_alignment (config, &priv->video_align); |
| 23 | gst_video_info_align (&info, &priv->video_align); |
| 24 | + gst_buffer_pool_config_set_video_alignment (config, &priv->video_align); |
| 25 | } |
| 26 | priv->info = info; |
| 27 | |
| 28 | diff --git a/sys/ximage/ximagepool.c b/sys/ximage/ximagepool.c |
| 29 | index 6cc2cfa..6a1cbc9 100644 |
| 30 | --- a/sys/ximage/ximagepool.c |
| 31 | +++ b/sys/ximage/ximagepool.c |
| 32 | @@ -597,6 +597,8 @@ ximage_buffer_pool_set_config (GstBufferPool * pool, GstStructure * config) |
| 33 | /* do padding and alignment */ |
| 34 | gst_video_info_align (&info, &priv->align); |
| 35 | |
| 36 | + gst_buffer_pool_config_set_video_alignment (config, &priv->align); |
| 37 | + |
| 38 | /* we need the video metadata too now */ |
| 39 | priv->add_metavideo = TRUE; |
| 40 | } else { |
| 41 | diff --git a/sys/xvimage/xvimagepool.c b/sys/xvimage/xvimagepool.c |
| 42 | index 244a51a..34b1ab2 100644 |
| 43 | --- a/sys/xvimage/xvimagepool.c |
| 44 | +++ b/sys/xvimage/xvimagepool.c |
| 45 | @@ -124,6 +124,8 @@ xvimage_buffer_pool_set_config (GstBufferPool * pool, GstStructure * config) |
| 46 | /* do padding and alignment */ |
| 47 | gst_video_info_align (&info, &priv->align); |
| 48 | |
| 49 | + gst_buffer_pool_config_set_video_alignment (config, &priv->align); |
| 50 | + |
| 51 | /* we need the video metadata too now */ |
| 52 | priv->add_metavideo = TRUE; |
| 53 | } else { |