/****************************************************************************
**
** Copyright (C) 2016 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of the documentation of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:FDL$
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The Qt Company. For licensing terms
** and conditions see https://www.qt.io/terms-conditions. For further
** information use the contact form at https://www.qt.io/contact-us.
**
** GNU Free Documentation License Usage
** Alternatively, this file may be used under the terms of the GNU Free
** Documentation License version 1.3 as published by the Free Software
** Foundation and appearing in the file included in the packaging of
** this file. Please review the following information to ensure
** the GNU Free Documentation License version 1.3 requirements
** will be met: https://www.gnu.org/licenses/fdl-1.3.html.
** $QT_END_LICENSE$
**
****************************************************************************/

/*!
    \example deferred-renderer-cpp
    \title Qt 3D: Deferred Renderer C++ Example
    \ingroup qt3d-examples-cpp
    \brief A C++ application that demonstrates rendering to an intermediate
    G-buffer.

    \e {Deferred Renderer} demonstrates using a two pass rendering method.
    First, all the meshes in the scene are drawn using the same shader that will
    output the following values for each fragment: world normal vector, color,
    depth, and world position vector.

    Each of these values will be stored in a texture, which together form what
    is called the G-buffer. Nothing is drawn onscreen during the first pass, but
    rather drawn into the G-buffer ready for later use.

    Once all the meshes have been drawn, the G-buffer is filled with all the
    meshes that can currently be seen by the camera. The second render pass is
    then used to render the scene to the back buffer with the final color
    shading by reading the values from the G-buffer textures and outputting a
    color onto a full screen quad.

    For more information, see \l{Deferred Renderer}.

    \include examples-run.qdocinc
*/
