Coverage Report

Created: 2026-09-14 08:00

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/ffmpeg/libavcodec/lcevc_parse.h
Line
Count
Source
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
19
#ifndef AVCODEC_LCEVC_PARSE_H
20
#define AVCODEC_LCEVC_PARSE_H
21
22
#include <stdint.h>
23
24
#include "get_bits.h"
25
26
2.52k
static inline uint64_t get_mb(GetBitContext *s) {
27
2.52k
    int more, i = 0;
28
2.52k
    uint64_t mb = 0;
29
30
8.98k
    do {
31
8.98k
        int byte = get_bits(s, 8);
32
8.98k
        unsigned bits = byte & 0x7f;
33
8.98k
        more = byte & 0x80;
34
8.98k
        mb = (mb << 7) | bits;
35
8.98k
        if (++i == 10)
36
534
            break;
37
8.98k
    } while (more);
38
39
2.52k
    return mb;
40
2.52k
}
extract_extradata.c:get_mb
Line
Count
Source
26
2.39k
static inline uint64_t get_mb(GetBitContext *s) {
27
2.39k
    int more, i = 0;
28
2.39k
    uint64_t mb = 0;
29
30
8.75k
    do {
31
8.75k
        int byte = get_bits(s, 8);
32
8.75k
        unsigned bits = byte & 0x7f;
33
8.75k
        more = byte & 0x80;
34
8.75k
        mb = (mb << 7) | bits;
35
8.75k
        if (++i == 10)
36
534
            break;
37
8.75k
    } while (more);
38
39
2.39k
    return mb;
40
2.39k
}
lcevc_parser.c:get_mb
Line
Count
Source
26
134
static inline uint64_t get_mb(GetBitContext *s) {
27
134
    int more, i = 0;
28
134
    uint64_t mb = 0;
29
30
237
    do {
31
237
        int byte = get_bits(s, 8);
32
237
        unsigned bits = byte & 0x7f;
33
237
        more = byte & 0x80;
34
237
        mb = (mb << 7) | bits;
35
237
        if (++i == 10)
36
0
            break;
37
237
    } while (more);
38
39
134
    return mb;
40
134
}
41
42
#endif /* AVCODEC_LCEVC_PARSE_H */