1 /*
2 * This file is part of FFmpeg.
3 *
4 * FFmpeg is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * FFmpeg is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with FFmpeg; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17 */
18
25
27 {
29
30 memset(
dst, 0,
sizeof(*
dst));
32 return;
33
35 dst->progress = &
src->progress;
36
37 for (
i = 0;
i < 2;
i++) {
38 dst->motion_val[
i] =
src->motion_val[
i];
39 dst->ref_index[
i] =
src->ref_index[
i];
40 }
41
42 dst->mb_type =
src->mb_type;
43 dst->field_picture =
src->field_picture;
44 }
45
47 {
49
53
55
57 }
58
60 int (*
mv)[2][4][2],
int mb_x,
int mb_y,
61 int mb_intra, int mb_skipped)
62 {
64
66
69 s->mb_intra = mb_intra;
70 s->mb_skipped = mb_skipped;
74 memcpy(
s->mv,
mv,
sizeof(*
mv));
75
76 // The following disables unquantizing and the IDCT.
78 s->block_last_index[
i] = -1;
79
80 s->dest[0] =
s->cur_pic.data[0] +
81 s->mb_y * 16 *
s->linesize +
83 s->dest[1] =
s->cur_pic.data[1] +
84 s->mb_y * (16 >>
s->chroma_y_shift) *
s->uvlinesize +
85 s->mb_x * (16 >>
s->chroma_x_shift);
86 s->dest[2] =
s->cur_pic.data[2] +
87 s->mb_y * (16 >>
s->chroma_y_shift) *
s->uvlinesize +
88 s->mb_x * (16 >>
s->chroma_x_shift);
89
92 "Interlaced error concealment is not fully implemented\n");
94 }
95
97 {
99 int mb_array_size =
s->mb_height *
s->mb_stride;
100
102
109
111 er->
dc_val[1] = er->
dc_val[0] +
s->b8_stride * 2 *
s->buffer_pools.alloc_mb_height +
s->mb_stride;
112 er->
dc_val[2] = er->
dc_val[1] +
s->mb_stride * (
s->buffer_pools.alloc_mb_height + 1);
113
118
121
124
125 return 0;
130 }