MythTV  master
nvdeccontext.h
Go to the documentation of this file.
1 // Copyright (c) 2017 MythTV Developers <mythtv-dev@mythtv.org>
3 //
4 // This is part of MythTV (https://www.mythtv.org)
5 //
6 // This program is free software; you can redistribute it and/or modify
7 // it under the terms of the GNU General Public License as published by
8 // the Free Software Foundation; either version 2 of the License, or
9 // (at your option) any later version.
10 //
11 // This program is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
15 //
16 // You should have received a copy of the GNU General Public License
17 // along with this program; if not, write to the Free Software
18 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19 //
20 // You should have received a copy of the GNU General Public License
21 // along with this program. If not, see <http://www.gnu.org/licenses/>.
22 //
24 
25 
26 #ifndef NVDECCONTEXT_H
27 #define NVDECCONTEXT_H
28 
29 #include "mythtvexp.h"
30 #include "mythcodecid.h"
31 #include "mythcodeccontext.h"
32 
33 extern "C" {
34  #include "libavcodec/avcodec.h"
35 }
36 
38 {
39  public:
40  NvdecContext(void) = default;
41  static MythCodecID GetBestSupportedCodec(AVCodec **ppCodec,
42  const QString &decoder,
43  uint stream_type,
44  AVPixelFormat &pix_fmt);
45  int HwDecoderInit(AVCodecContext *ctx) override; // MythCodecContext
46  bool isValidDeinterlacer(QString /*name*/ ) override; // MythCodecContext
47  QStringList GetDeinterlacers(void) override; // MythCodecContext
48 
49  protected:
50  int SetDeinterlace(AVCodecContext *ctx);
51  QString GetDeinterlaceMode(bool &dropSecondFld);
52 
53 
54 };
55 
56 #endif // NVDECCONTEXT_H
MythCodecID
Definition: mythcodecid.h:10
unsigned int uint
Definition: compat.h:140
#define MTV_PUBLIC
Definition: mythtvexp.h:15
virtual bool isValidDeinterlacer(QString)
virtual QStringList GetDeinterlacers(void)
virtual int HwDecoderInit(AVCodecContext *)