From 001567c767132aec24471529a057ac7d74de70a1 Mon Sep 17 00:00:00 2001
From: Carl Eugen Hoyos <cehoyos@ag.or.at>
Date: Tue, 3 Jan 2012 23:05:54 +0100
Subject: [PATCH] Set bits_per_coded_sample when encoding Y41P.

This allows mplayer -vc bt411 to decode files
encoded with FFmpeg.

Reviewed-by: Paul B Mahol
---
 libavcodec/y41penc.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavcodec/y41penc.c b/libavcodec/y41penc.c
index aa32403a45d..e5905cf6e90 100644
--- a/libavcodec/y41penc.c
+++ b/libavcodec/y41penc.c
@@ -30,6 +30,7 @@ static av_cold int y41p_encode_init(AVCodecContext *avctx)
     }
 
     avctx->coded_frame = avcodec_alloc_frame();
+    avctx->bits_per_coded_sample = 12;
 
     if (!avctx->coded_frame) {
         av_log(avctx, AV_LOG_ERROR, "Could not allocate frame.\n");
-- 
GitLab