MythTV
master
mythtv
libs
libmyth
mythavframe.h
Go to the documentation of this file.
1
#ifndef MYTHAVFRAME_H
2
#define MYTHAVFRAME_H
3
4
#include "
mythexp.h
"
5
6
extern
"C"
{
7
#include "libavcodec/avcodec.h"
8
}
26
class
MPUBLIC
MythAVFrame
27
{
28
public
:
29
MythAVFrame
(
void
) : m_frame(av_frame_alloc()) {}
30
~MythAVFrame
(
void
)
31
{
32
av_frame_free(&m_frame);
33
}
34
bool
operator !()
const
35
{
36
return
m_frame ==
nullptr
;
37
}
38
AVFrame
*
operator->
()
const
39
{
40
return
m_frame;
41
}
42
AVFrame
&
operator*
()
const
43
{
44
return
*m_frame;
45
}
46
operator
AVFrame
*()
const
47
{
48
return
m_frame;
49
}
50
operator
const
AVFrame
*()
const
51
{
52
return
m_frame;
53
}
54
55
private
:
56
AVFrame
*m_frame {
nullptr
};
57
};
58
59
#endif // MYTHAVFRAME_H
MPUBLIC
#define MPUBLIC
Definition:
mythexp.h:10
MythAVFrame::operator*
AVFrame & operator*() const
Definition:
mythavframe.h:42
mythexp.h
MythAVFrame
MythAVFrame little utility class that act as a safe way to allocate an AVFrame which can then be allo...
Definition:
mythavframe.h:26
MythAVFrame::operator->
AVFrame * operator->() const
Definition:
mythavframe.h:38
AVFrame
struct AVFrame AVFrame
Definition:
BorderDetector.h:15
MythAVFrame::~MythAVFrame
~MythAVFrame(void)
Definition:
mythavframe.h:30
MythAVFrame::MythAVFrame
MythAVFrame(void)
Definition:
mythavframe.h:29
Generated on Mon Aug 25 2025 03:15:50 for MythTV by
1.8.17