aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/sksl/ir/SkSLProgram.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/sksl/ir/SkSLProgram.h')
-rw-r--r--src/sksl/ir/SkSLProgram.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/sksl/ir/SkSLProgram.h b/src/sksl/ir/SkSLProgram.h
index 9f140877b7..59c91229f8 100644
--- a/src/sksl/ir/SkSLProgram.h
+++ b/src/sksl/ir/SkSLProgram.h
@@ -39,6 +39,10 @@ struct Program {
: fKind(kInt_Kind)
, fValue(i) {}
+ Value(unsigned int i)
+ : fKind(kInt_Kind)
+ , fValue(i) {}
+
std::unique_ptr<Expression> literal(const Context& context, int offset) const {
switch (fKind) {
case Program::Settings::Value::kBool_Kind:
@@ -192,7 +196,7 @@ struct Program {
kVertex_Kind,
kGeometry_Kind,
kFragmentProcessor_Kind,
- kCPU_Kind
+ kPipelineStage_Kind
};
Program(Kind kind,
@@ -252,10 +256,13 @@ struct Program {
// because destroying elements can modify reference counts in symbols
std::shared_ptr<SymbolTable> fSymbols;
Inputs fInputs;
+ bool fIsOptimized = false;
private:
std::vector<std::unique_ptr<ProgramElement>>* fInheritedElements;
std::vector<std::unique_ptr<ProgramElement>> fElements;
+
+ friend class Compiler;
};
} // namespace