summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/radeon/radeon_vce_40_2_2.c
diff options
context:
space:
mode:
authorLeo Liu <leo.liu@amd.com>2015-09-18 15:51:26 -0400
committerLeo Liu <leo.liu@amd.com>2015-09-25 18:47:14 -0400
commit1e97b41893a4f53a71ee141a5e8a046fed7b49cd (patch)
tree143cb6903ec0f5c521800e7f13043a66d5744ddd /src/gallium/drivers/radeon/radeon_vce_40_2_2.c
parent1dd943d7fb5bd374e871436ccf6546327687c761 (diff)
downloadexternal_mesa3d-1e97b41893a4f53a71ee141a5e8a046fed7b49cd.zip
external_mesa3d-1e97b41893a4f53a71ee141a5e8a046fed7b49cd.tar.gz
external_mesa3d-1e97b41893a4f53a71ee141a5e8a046fed7b49cd.tar.bz2
radeon/vce: fix vui time_scale zero error
if app pass 0 as frame_rate_num, it should not be encoded to the VUI. Signed-off-by: Leo Liu <leo.liu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Cc: "10.6 11.0" <mesa-stable@lists.freedesktop.org>
Diffstat (limited to 'src/gallium/drivers/radeon/radeon_vce_40_2_2.c')
-rw-r--r--src/gallium/drivers/radeon/radeon_vce_40_2_2.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/drivers/radeon/radeon_vce_40_2_2.c b/src/gallium/drivers/radeon/radeon_vce_40_2_2.c
index e64fbc7..c005659 100644
--- a/src/gallium/drivers/radeon/radeon_vce_40_2_2.c
+++ b/src/gallium/drivers/radeon/radeon_vce_40_2_2.c
@@ -233,6 +233,9 @@ static void vui(struct rvce_encoder *enc)
{
int i;
+ if (!enc->pic.rate_ctrl.frame_rate_num)
+ return;
+
RVCE_BEGIN(0x04000009); // vui
RVCE_CS(0x00000000); //aspectRatioInfoPresentFlag
RVCE_CS(0x00000000); //aspectRatioInfo.aspectRatioIdc