|
|
|
@ -33,8 +33,8 @@ static const uint32_t rgb444_masks[] = { 0x0F00, 0x00F0, 0x000F }; |
|
|
|
|
static av_cold int bmp_encode_init(AVCodecContext *avctx){ |
|
|
|
|
BMPContext *s = avctx->priv_data; |
|
|
|
|
|
|
|
|
|
avcodec_get_frame_defaults((AVFrame*)&s->picture); |
|
|
|
|
avctx->coded_frame = (AVFrame*)&s->picture; |
|
|
|
|
avcodec_get_frame_defaults(&s->picture); |
|
|
|
|
avctx->coded_frame = &s->picture; |
|
|
|
|
|
|
|
|
|
switch (avctx->pix_fmt) { |
|
|
|
|
case PIX_FMT_BGR24: |
|
|
|
@ -68,7 +68,7 @@ static int bmp_encode_frame(AVCodecContext *avctx, AVPacket *pkt, |
|
|
|
|
const AVFrame *pict, int *got_packet) |
|
|
|
|
{ |
|
|
|
|
BMPContext *s = avctx->priv_data; |
|
|
|
|
AVFrame * const p= (AVFrame*)&s->picture; |
|
|
|
|
AVFrame * const p = &s->picture; |
|
|
|
|
int n_bytes_image, n_bytes_per_row, n_bytes, i, n, hsize, ret; |
|
|
|
|
const uint32_t *pal = NULL; |
|
|
|
|
int pad_bytes_per_row, pal_entries = 0, compression = BMP_RGB; |
|
|
|
|