Phosphor
Qt6 / Wayland library suite for window-management tools
 
Loading...
Searching...
No Matches
ShaderIncludeResolver.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: 2026 fuddlesworth
2// SPDX-License-Identifier: LGPL-2.1-or-later
3
4#pragma once
5
6#include <PhosphorShaders/phosphorshaders_export.h>
7
8#include <QString>
9#include <QStringList>
10
11namespace PhosphorShaders {
12
18class PHOSPHORSHADERS_EXPORT ShaderIncludeResolver
19{
20public:
21 static constexpr int MaxIncludeDepth = 10;
22
35 static QString expandIncludes(const QString& source, const QString& currentFileDir, const QStringList& includePaths,
36 QString* outError = nullptr, QStringList* outIncludedPaths = nullptr);
37};
38
39} // namespace PhosphorShaders
Resolves #include directives in GLSL shader source.
Definition ShaderIncludeResolver.h:19
static QString expandIncludes(const QString &source, const QString &currentFileDir, const QStringList &includePaths, QString *outError=nullptr, QStringList *outIncludedPaths=nullptr)
Expand #include directives in source.
Definition ShaderEffect.h:28