1
/****************************************************************************
3
** Copyright (C) 2012 Digia Plc and/or its subsidiary(-ies).
4
** Contact: http://www.qt-project.org/legal
6
** This file is part of the documentation of the Qt Toolkit.
8
** $QT_BEGIN_LICENSE:FDL$
9
** Commercial License Usage
10
** Licensees holding valid commercial Qt licenses may use this file in
11
** accordance with the commercial license agreement provided with the
12
** Software or, alternatively, in accordance with the terms contained in
13
** a written agreement between you and Digia. For licensing terms and
14
** conditions see http://qt.digia.com/licensing. For further information
15
** use the contact form at http://qt.digia.com/contact-us.
17
** GNU Free Documentation License Usage
18
** Alternatively, this file may be used under the terms of the GNU Free
19
** Documentation License version 1.3 as published by the Free Software
20
** Foundation and appearing in the file included in the packaging of
21
** this file. Please review the following information to ensure
22
** the GNU Free Documentation License version 1.3 requirements
23
** will be met: http://www.gnu.org/copyleft/fdl.html.
26
****************************************************************************/
29
\page qtopengl-index.html
31
\brief The QtOpenGL module offers classes that make it easy to
32
use OpenGL in Qt applications.
34
\warning Apart from the \l{QGLWidget} class, this module should not be used
35
anymore for new code. Please use the corresponding OpenGL classes in
38
OpenGL is a standard API for rendering 3D graphics. OpenGL only
39
deals with 3D rendering and provides little or no support for GUI
40
programming issues. The user interface for an OpenGL application
41
must be created with another toolkit, such as Cocoa on the Mac OS X
42
platform, Microsoft Foundation Classes (MFC) under Windows, or Qt
45
\note OpenGL is a trademark of Silicon Graphics, Inc. in
46
the United States and other countries.
48
The Qt OpenGL module makes it easy to use OpenGL in Qt applications.
49
It provides an OpenGL widget class that can be used just like any
50
other Qt widget, except that it opens an OpenGL display buffer where
51
you can use the OpenGL API to render the contents.
53
To include the definitions of the module's classes, use the
56
\snippet code/doc_src_qtopengl.cpp 0
58
To link against the module, add this line to your \l qmake \c
61
\snippet code/doc_src_qtopengl.pro 1
63
The Qt OpenGL module is implemented as a platform-independent Qt/C++
64
wrapper around the platform-dependent GLX (version 1.3 or later),
65
WGL, or AGL C APIs. Although the basic functionality provided is very
66
similar to Mark Kilgard's GLUT library, applications using the Qt
67
OpenGL module can take advantage of the whole Qt API for
68
non-OpenGL-specific GUI functionality.
70
The \l{Qt OpenGL C++ classes} page gives an overview over the available classes