Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
SkSL::RP::LValue Class Referenceabstract
Inheritance diagram for SkSL::RP::LValue:
SkSL::RP::DynamicIndexLValue SkSL::RP::ImmutableLValue SkSL::RP::ScratchLValue SkSL::RP::SwizzleLValue SkSL::RP::UnownedLValueSlice SkSL::RP::VariableLValue SkSL::RP::LValueSlice

Public Member Functions

virtual ~LValue ()=default
 
virtual bool isWritable () const =0
 
virtual SlotRange fixedSlotRange (Generator *gen)=0
 
virtual AutoStackdynamicSlotRange ()=0
 
virtual SkSpan< const int8_t > swizzle ()
 
virtual bool push (Generator *gen, SlotRange fixedOffset, AutoStack *dynamicOffset, SkSpan< const int8_t > swizzle)=0
 
virtual bool store (Generator *gen, SlotRange fixedOffset, AutoStack *dynamicOffset, SkSpan< const int8_t > swizzle)=0
 

Public Attributes

std::unique_ptr< ExpressionfScratchExpression
 

Detailed Description

Definition at line 673 of file SkSLRasterPipelineCodeGenerator.cpp.

Constructor & Destructor Documentation

◆ ~LValue()

virtual SkSL::RP::LValue::~LValue ( )
virtualdefault

Member Function Documentation

◆ dynamicSlotRange()

virtual AutoStack * SkSL::RP::LValue::dynamicSlotRange ( )
pure virtual

Returns a stack which holds a single integer, representing the dynamic offset of the lvalue. This value does not incorporate the fixed offset. If null is returned, the lvalue doesn't have a dynamic offset. evaluateDynamicIndices must be called before this is used.

Implemented in SkSL::RP::ScratchLValue, SkSL::RP::VariableLValue, SkSL::RP::ImmutableLValue, SkSL::RP::SwizzleLValue, SkSL::RP::UnownedLValueSlice, and SkSL::RP::DynamicIndexLValue.

◆ fixedSlotRange()

virtual SlotRange SkSL::RP::LValue::fixedSlotRange ( Generator gen)
pure virtual

Returns the fixed slot range of the lvalue, after it is winnowed down to the selected field/index. The range is calculated assuming every dynamic index will evaluate to zero.

Implemented in SkSL::RP::ScratchLValue, SkSL::RP::VariableLValue, SkSL::RP::ImmutableLValue, SkSL::RP::SwizzleLValue, SkSL::RP::UnownedLValueSlice, and SkSL::RP::DynamicIndexLValue.

◆ isWritable()

virtual bool SkSL::RP::LValue::isWritable ( ) const
pure virtual

Returns true if this lvalue is actually writable–temporaries and uniforms are not.

Implemented in SkSL::RP::ScratchLValue, SkSL::RP::VariableLValue, SkSL::RP::ImmutableLValue, SkSL::RP::SwizzleLValue, SkSL::RP::UnownedLValueSlice, and SkSL::RP::DynamicIndexLValue.

◆ push()

virtual bool SkSL::RP::LValue::push ( Generator gen,
SlotRange  fixedOffset,
AutoStack dynamicOffset,
SkSpan< const int8_t >  swizzle 
)
pure virtual

◆ store()

virtual bool SkSL::RP::LValue::store ( Generator gen,
SlotRange  fixedOffset,
AutoStack dynamicOffset,
SkSpan< const int8_t >  swizzle 
)
pure virtual

◆ swizzle()

virtual SkSpan< const int8_t > SkSL::RP::LValue::swizzle ( )
inlinevirtual

Returns the swizzle components of the lvalue, or an empty span for non-swizzle LValues.

Reimplemented in SkSL::RP::SwizzleLValue.

Definition at line 694 of file SkSLRasterPipelineCodeGenerator.cpp.

694{ return {}; }

Member Data Documentation

◆ fScratchExpression

std::unique_ptr<Expression> SkSL::RP::LValue::fScratchExpression

Some lvalues refer to a temporary expression; these temps can be held in the scratch-expression field to ensure that they exist for the lifetime of the lvalue.

Definition at line 711 of file SkSLRasterPipelineCodeGenerator.cpp.


The documentation for this class was generated from the following file: