Gnash
0.8.11dev
libdevice
vaapi
VaapiGlobalContext.h
Go to the documentation of this file.
1
// VaapiGlobalContext.h: VA API global context
2
//
3
// Copyright (C) 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
4
//
5
// This program is free software; you can redistribute it and/or modify
6
// it under the terms of the GNU General Public License as published by
7
// the Free Software Foundation; either version 3 of the License, or
8
// (at your option) any later version.
9
//
10
// This program is distributed in the hope that it will be useful,
11
// but WITHOUT ANY WARRANTY; without even the implied warranty of
12
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
// GNU General Public License for more details.
14
//
15
// You should have received a copy of the GNU General Public License
16
// along with this program; if not, write to the Free Software
17
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18
//
19
20
#ifndef GNASH_VAAPIGLOBALCONTEXT_H
21
#define GNASH_VAAPIGLOBALCONTEXT_H
22
23
#include <vector>
24
25
#include "
log.h
"
26
#include "
vaapi_common.h
"
27
#include "
VaapiDisplay.h
"
28
#include "
VaapiImageFormat.h
"
29
30
namespace
gnash
{
31
33
class
DSOEXPORT
VaapiGlobalContext
{
34
std::unique_ptr<VaapiDisplay> _display;
35
std::vector<VAProfile> _profiles;
36
std::vector<VAImageFormat> _image_formats;
37
std::vector<VAImageFormat> _subpicture_formats;
38
39
bool
init();
40
41
public
:
42
VaapiGlobalContext
(std::unique_ptr<VaapiDisplay> display);
43
~
VaapiGlobalContext
();
44
46
//
48
static
VaapiGlobalContext
*
get
();
49
51
bool
hasProfile(VAProfile profile)
const
;
52
54
//
56
const
VAImageFormat *getImageFormat(
VaapiImageFormat
format)
const
;
57
59
//
61
std::vector<VaapiImageFormat> getImageFormats()
const
;
62
64
//
66
std::vector<VaapiImageFormat> getSubpictureFormats()
const
;
67
69
//
71
VADisplay
display
()
const
{
return
_display->get(); }
72
};
73
74
}
// gnash namespace
75
76
#endif // GNASH_VAAPIGLOBALCONTEXT_H
77
78
79
// local Variables:
80
// mode: C++
81
// indent-tabs-mode: nil
82
// End:
VaapiImageFormat
VaapiImageFormat
Image types.
Definition:
VaapiImageFormat.h:34
vaapi_common.h
gnash
Anonymous namespace for callbacks, local functions, event handlers etc.
Definition:
dbus_ext.cpp:40
VaapiDisplay.h
gnash::VaapiGlobalContext::display
VADisplay display() const
Get the VA display.
Definition:
VaapiGlobalContext.h:71
DSOEXPORT
#define DSOEXPORT
Definition:
dsodefs.h:55
VaapiImageFormat.h
log.h
gnash::VaapiGlobalContext
VA API global context.
Definition:
VaapiGlobalContext.h:33
Generated by
1.8.12