Coverage Report

Created: 2026-05-16 07:42

next uncovered line (L), next uncovered region (R), next uncovered branch (B)
/src/vlc/contrib/x86_64-unknown-linux-gnu/include/matroska/KaxBlockData.h
Line
Count
Source
1
/****************************************************************************
2
** libmatroska : parse Matroska files, see http://www.matroska.org/
3
**
4
** <file/class description>
5
**
6
** Copyright (C) 2002-2010 Steve Lhomme.  All rights reserved.
7
**
8
** This library is free software; you can redistribute it and/or
9
** modify it under the terms of the GNU Lesser General Public
10
** License as published by the Free Software Foundation; either
11
** version 2.1 of the License, or (at your option) any later version.
12
**
13
** This library is distributed in the hope that it will be useful,
14
** but WITHOUT ANY WARRANTY; without even the implied warranty of
15
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16
** Lesser General Public License for more details.
17
**
18
** You should have received a copy of the GNU Lesser General Public
19
** License along with this library; if not, write to the Free Software
20
** Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
21
**
22
** See http://www.gnu.org/licenses/lgpl-2.1.html for LGPL licensing information.**
23
** Contact license@matroska.org if any conditions of this licensing are
24
** not clear to you.
25
**
26
**********************************************************************/
27
28
/*!
29
  \file
30
  \version \$Id: KaxBlockData.h,v 1.10 2004/04/14 23:26:17 robux4 Exp $
31
  \author Steve Lhomme     <robux4 @ users.sf.net>
32
*/
33
#ifndef LIBMATROSKA_BLOCK_ADDITIONAL_H
34
#define LIBMATROSKA_BLOCK_ADDITIONAL_H
35
36
#include "matroska/KaxTypes.h"
37
#include "ebml/EbmlMaster.h"
38
#include "ebml/EbmlUInteger.h"
39
#include "ebml/EbmlSInteger.h"
40
#include "matroska/KaxDefines.h"
41
#include "matroska/KaxBlock.h"
42
43
using namespace libebml;
44
45
namespace libmatroska {
46
47
/*!
48
  \brief element used for B frame-likes
49
*/
50
DECLARE_MKX_SINTEGER_CONS(KaxReferenceBlock)
51
  public:
52
        ~KaxReferenceBlock() override;
53
    /*!
54
      \brief override this method to compute the timecode value
55
    */
56
    filepos_t UpdateSize(bool bSaveDefault = false, bool bForceRender = false) override;
57
58
    const KaxBlockBlob & RefBlock() const;
59
    void SetReferencedBlock(const KaxBlockBlob * aRefdBlock);
60
    void SetReferencedBlock(const KaxBlockGroup & aRefdBlock);
61
    void SetParentBlock(const KaxBlockGroup & aParentBlock) {ParentBlock = &aParentBlock;}
62
0
    void SetReferencedTimecode(int64 refTimecode) {*static_cast<EbmlSInteger*>(this) = refTimecode; bTimecodeSet = true;};
63
64
  protected:
65
    const KaxBlockBlob * RefdBlock{nullptr};
66
    const KaxBlockGroup * ParentBlock{nullptr};
67
    bool bTimecodeSet{false};
68
        bool bOurBlob{false};
69
        void FreeBlob();
70
};
71
72
} // namespace libmatroska
73
74
#endif // LIBMATROSKA_BLOCK_ADDITIONAL_H