Interface GlslExpr
- All Known Implementing Classes:
GlslExpr.Access,GlslExpr.Binary,GlslExpr.Clamp,GlslExpr.FunctionCall,GlslExpr.FunctionCall0,GlslExpr.RawLiteral,GlslExpr.Swizzle,GlslExpr.Variable
public interface GlslExpr
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final recordstatic final recordstatic final recordstatic final recordstatic final recordstatic final recordstatic final recordstatic final record -
Method Summary
Modifier and TypeMethodDescriptiondefault GlslExpr.AccessAccess the given member of this expression.default GlslExprand(int mask) static GlslExprboolLiteral(boolean expr) static GlslExpr.FunctionCall0static GlslExpr.FunctionCallstatic GlslExpr.FunctionCallcall(String functionName, Collection<? extends GlslExpr> args) default GlslExpr.FunctionCallcallFunction(String name) Call a one-parameter function with the given name on this expression.default GlslExpr.FunctionCalldefault GlslExprclamp(float from, float to) default GlslExprdiv(float v) static GlslExprfloatLiteral(float expr) static GlslExprintLiteral(int expr) default GlslExprrsh(int by) default GlslExprsub(int v) default GlslExpr.SwizzleSwizzle the components of this expression.default GlslExprCatchall method for applying external transformations to this expression.static GlslExpruintHexLiteral(int expr) static GlslExpruintLiteral(int expr) static GlslExpr.VariableCreate a glsl variable with the given name.default GlslExprxor(int mask)
-
Method Details
-
variable
Create a glsl variable with the given name.- Parameters:
name- The name of the variable.- Returns:
- A new variable expression.
-
call
-
call
-
call
-
intLiteral
-
uintLiteral
-
uintHexLiteral
-
boolLiteral
-
floatLiteral
-
callFunction
Call a one-parameter function with the given name on this expression.- Parameters:
name- The name of the function to call.- Returns:
- A new glsl function call expression.
-
cast
-
swizzle
Swizzle the components of this expression.- Parameters:
selection- The components to select. For example, "xyz", "zyx", or "zzzw".- Returns:
- A new glsl swizzle expression.
-
access
Access the given member of this expression.- Parameters:
member- The name of the member to access.- Returns:
- A new glsl member access expression.
-
transform
Catchall method for applying external transformations to this expression.- Parameters:
f- The transformation to apply.- Returns:
- A new expression.
-
div
-
sub
-
rsh
-
and
-
xor
-
clamp
-
prettyPrint
String prettyPrint()
-