44 void writeScopeOpen(
bool compact =
false,
bool endWithSemicolon =
false,
bool useBraces =
true);
Definition CodeWriter.hpp:57
Definition Generator.hpp:24
bool isFragmentShader() const
void pushOptions(const CodeWriter::Options &options)
RawFlags mWarnings
Definition Generator.hpp:106
Program * mProgram
Definition Generator.hpp:103
bool isTessEvaluationShader() const
bool mAllowBlanks
Definition Generator.hpp:108
bool mAllowLineSeparation
Definition Generator.hpp:109
void pushWritePrefix(const String &text)
void writeLn(const String &text)
ReportHandler mReportHandler
Definition Generator.hpp:101
void flushWritePrefixes()
bool isTessControlShader() const
ShaderTarget mShaderTarget
Definition Generator.hpp:105
void popWritePrefix(const String &text="")
bool isWarningEnabled(UInt32 flags) const
void writeScopeContinue()
String getTimePoint() const
bool generateCode(Program &program, const ShaderInput &inputDesc, const ShaderOutput &outputDesc, Log *log=nullptr)
ShaderTarget getShaderTarget() const
Definition Generator.hpp:75
bool isVertexShader() const
void write(const String &text)
virtual void generateCodePrimary(Program &program, const ShaderInput &inputDesc, const ShaderOutput &outputDesc)=0
void warning(const String &msg, const AST *ast=nullptr)
bool isGeometryShader() const
void error(const String &msg, const AST *ast=nullptr, bool breakWithException=true)
Program * getProgram() const
Definition Generator.hpp:72
bool isComputeShader() const
CodeWriter mWriter
Definition Generator.hpp:100
void writeScopeOpen(bool compact=false, bool endWithSemicolon=false, bool useBraces=true)
bool isTopWritePrefix() const
Vector< WritePrefix > mWritePrefixStack
Definition Generator.hpp:111
Log base class.
Definition Log.hpp:19
Definition ReportHandler.hpp:31
Definition VisitorTracker.hpp:18
ShaderTarget
Shader target enumeration.
Definition Targets.hpp:16
@ VertexShader
Vertex shader.
std::vector< T, ScopedAllocatorAdaptor< StdAllocator< T, RawAllocator > > > Vector
Vector is a sequence container that encapsulates dynamic size arrays.
Definition Vector.hpp:17
std::uint32_t UInt32
Definition DataTypes.hpp:23
constexpr size_t hash(const T &v)
Generates a hash for the provided type.
Definition Hash.hpp:25
Definition CodeWriter.hpp:59
Prefix text that can be written in front of the text of the next "Write"/"WriteLn" call.
Definition Generator.hpp:92
bool written
Definition Generator.hpp:94
String text
Definition Generator.hpp:93
Shader output descriptor structure.
Definition ShaderCompiler.hpp:293