Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qssgrenderskymaterial.cpp File Reference

(a1735e464fc2f6b0211efe6f1a6681b8cd8c98ee)

#include "qssgrendercontextcore.h"
#include <QtQuick3DRuntimeRender/private/qssgrenderskymaterial_p.h>
#include <QtQuick3DRuntimeRender/private/qssgrendererimplshaders_p.h>
#include <QtQuick3DRuntimeRender/private/qssgrhieffectsystem_p.h>
#include <QtQuick3DRuntimeRender/private/qssgshadermaterialadapter_p.h>
#include <QtCore/qhash.h>
#include <QtCore/qspan.h>
#include <QtGui/qvector4d.h>
#include <rhi/qshaderbaker.h>
#include <algorithm>
Include dependency graph for qssgrenderskymaterial.cpp:

Go to the source code of this file.

Functions

static bool skyShaderTexturesReady (const QList< QSSGBaseTypeProperty > &propertyUniforms, QSSGBufferManager &bufferManager)
static void appendCustomTextureBindings (QSSGRhiShaderPipeline *pipeline, QSSGRhiShaderResourceBindingList &bindings, QSSGRhiContext *rhiCtx)

Variables

static QT_BEGIN_NAMESPACE const char * vertexShaderStr
static const char * vertexShaderStrScreen
static const char * mainFragmentSnippet
static const char * mainFragmentSnippetScreen
static const char * debugFragStr

Function Documentation

◆ appendCustomTextureBindings()

void appendCustomTextureBindings ( QSSGRhiShaderPipeline * pipeline,
QSSGRhiShaderResourceBindingList & bindings,
QSSGRhiContext * rhiCtx )
static

Definition at line 184 of file qssgrenderskymaterial.cpp.

◆ skyShaderTexturesReady()

bool skyShaderTexturesReady ( const QList< QSSGBaseTypeProperty > & propertyUniforms,
QSSGBufferManager & bufferManager )
static

Definition at line 169 of file qssgrenderskymaterial.cpp.

Variable Documentation

◆ debugFragStr

const char * debugFragStr
static

Definition at line 76 of file qssgrenderskymaterial.cpp.

◆ mainFragmentSnippet

const char * mainFragmentSnippet
static
Initial value:
= R"(
void main()
{
qt_customMain();
}
)"

Definition at line 53 of file qssgrenderskymaterial.cpp.

◆ mainFragmentSnippetScreen

const char * mainFragmentSnippetScreen
static
Initial value:
= R"(
void main()
{
qt_customMain();
FRAGCOLOR = vec4(qt_tonemap(qt_exposure(FRAGCOLOR.rgb, qt_skyExposure)), 1.0);
}
)"

Definition at line 66 of file qssgrenderskymaterial.cpp.

◆ vertexShaderStr

QT_BEGIN_NAMESPACE const char * vertexShaderStr
static
Initial value:
= R"(
void main()
{
vec4 qt_vertPosition = vec4(attr_pos, 1.0);
qt_eyeDir = qt_vertPosition.xyz;
gl_Position = qt_projectionMatrix * qt_viewMatrix * vec4(qt_eyeDir, 1.0);
}
)"

Definition at line 22 of file qssgrenderskymaterial.cpp.

◆ vertexShaderStrScreen

const char * vertexShaderStrScreen
static
Initial value:
= R"(
void main()
{
gl_Position = vec4(attr_pos, 1.0);
#if QSHADER_VIEW_COUNT >= 2
vec3 qt_unprojected = (qt_inverseProjection[gl_ViewIndex] * gl_Position).xyz;
qt_eyeDir = (qt_viewMatrix[gl_ViewIndex] * vec4(qt_unprojected, 0.0)).xyz;
#else
vec3 qt_unprojected = (qt_inverseProjection * gl_Position).xyz;
qt_eyeDir = (qt_viewMatrix * vec4(qt_unprojected, 0.0)).xyz;
#endif
gl_Position.y *= qt_adjustY;
}
)"

Definition at line 37 of file qssgrenderskymaterial.cpp.