BALL
1.4.79
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
include
BALL
VIEW
RENDERING
glOffscreenTarget.h
Go to the documentation of this file.
1
// -*- Mode: C++; tab-width: 2; -*-
2
// vi: set ts=2:
3
//
4
5
#ifndef BALL_VIEW_RENDERING_GLOFFSCREENTARGET_H
6
#define BALL_VIEW_RENDERING_GLOFFSCREENTARGET_H
7
8
#ifndef BALL_COMMON_GLOBAL_H
9
# include <
BALL/COMMON/global.h
>
10
#endif
11
12
#ifndef BALL_VIEW_RENDERING_RENDERWINDOW_H
13
# include <
BALL/VIEW/RENDERING/renderWindow.h
>
14
#endif
15
16
#ifndef BALL_VIEW_RENDERING_GLRENDERWINDOW_H
17
# include <
BALL/VIEW/RENDERING/glRenderWindow.h
>
18
#endif
19
20
21
#include <QtGui/QPaintDevice>
22
23
#include <boost/shared_ptr.hpp>
24
25
class
QGLPixelBuffer;
26
27
namespace
BALL
28
{
29
namespace
VIEW
30
{
36
class
BALL_VIEW_EXPORT
GLOffscreenTarget
37
:
public
RenderWindow
,
38
public
QPaintDevice
39
{
40
public
:
43
GLOffscreenTarget
(
GLRenderWindow
* share_from,
const
String
& filename);
44
45
virtual
void
prepareRendering();
46
virtual
void
prepareUpscaling(
Size
final_width,
Size
final_height);
47
48
virtual
bool
resize(
const
unsigned
int
width,
const
unsigned
int
height);
49
virtual
void
refresh();
50
51
void
tryUsePixelBuffer(
bool
use_pbo =
true
);
52
53
QImage getImage();
54
void
updateImageTile(
Size
x_lower,
Size
y_lower,
Size
x_upper,
Size
y_upper);
55
56
virtual
QPaintEngine* paintEngine()
const
;
57
virtual
int
metric(PaintDeviceMetric metric)
const
;
58
59
protected
:
60
String
filename_
;
61
62
GLRenderWindow
*
share_from_
;
63
64
boost::shared_ptr<QGLPixelBuffer>
pixel_buffer_
;
65
66
bool
use_pixel_buffer_
;
67
68
QImage
current_image_
;
69
};
70
71
}
72
}
73
#endif // BALL_VIEW_RENDERING_GLOFFSCREENTARGET_H
BALL::String
Definition:
string.h:61
glRenderWindow.h
BALL::VIEW::GLOffscreenTarget
Definition:
glOffscreenTarget.h:36
BALL::VIEW::GLOffscreenTarget::current_image_
QImage current_image_
Definition:
glOffscreenTarget.h:68
BALL::VIEW::GLOffscreenTarget::share_from_
GLRenderWindow * share_from_
Definition:
glOffscreenTarget.h:62
QPaintDevice
BALL::VIEW::GLRenderWindow
Definition:
glRenderWindow.h:37
BALL_VIEW_EXPORT
#define BALL_VIEW_EXPORT
Definition:
COMMON/global.h:52
BALL::VIEW::TRenderWindow
Definition:
renderWindow.h:33
BALL::VIEW::GLOffscreenTarget::filename_
String filename_
Definition:
glOffscreenTarget.h:60
BALL::VIEW::GLOffscreenTarget::use_pixel_buffer_
bool use_pixel_buffer_
Definition:
glOffscreenTarget.h:66
BALL::VIEW::GLOffscreenTarget::pixel_buffer_
boost::shared_ptr< QGLPixelBuffer > pixel_buffer_
Definition:
glOffscreenTarget.h:64
BALL_SIZE_TYPE
global.h
renderWindow.h
Generated by
1.8.7