Flutter Engine
The Flutter Engine
Public Member Functions | Public Attributes | List of all members
SkSL::ModuleLoader::Impl Struct Reference

Public Member Functions

 Impl ()
 
void makeRootSymbolTable ()
 

Public Attributes

SkMutex fMutex
 
const BuiltinTypes fBuiltinTypes
 
std::unique_ptr< const ModulefRootModule
 
std::unique_ptr< const ModulefSharedModule
 
std::unique_ptr< const ModulefGPUModule
 
std::unique_ptr< const ModulefVertexModule
 
std::unique_ptr< const ModulefFragmentModule
 
std::unique_ptr< const ModulefComputeModule
 
std::unique_ptr< const ModulefGraphiteVertexModule
 
std::unique_ptr< const ModulefGraphiteFragmentModule
 
std::unique_ptr< const ModulefGraphiteVertexES2Module
 
std::unique_ptr< const ModulefGraphiteFragmentES2Module
 
std::unique_ptr< const ModulefPublicModule
 
std::unique_ptr< const ModulefRuntimeShaderModule
 

Detailed Description

Definition at line 90 of file SkSLModuleLoader.cpp.

Constructor & Destructor Documentation

◆ Impl()

SkSL::ModuleLoader::Impl::Impl ( )

Definition at line 143 of file SkSLModuleLoader.cpp.

143 {
144 this->makeRootSymbolTable();
145}

Member Function Documentation

◆ makeRootSymbolTable()

void SkSL::ModuleLoader::Impl::makeRootSymbolTable ( )

Definition at line 381 of file SkSLModuleLoader.cpp.

381 {
382 auto rootModule = std::make_unique<Module>();
383 rootModule->fSymbols = std::make_unique<SymbolTable>(/*builtin=*/true);
384
385 for (BuiltinTypePtr rootType : kRootTypes) {
386 rootModule->fSymbols->addWithoutOwnershipOrDie((fBuiltinTypes.*rootType).get());
387 }
388
389 for (BuiltinTypePtr privateType : kPrivateTypes) {
390 rootModule->fSymbols->addWithoutOwnershipOrDie((fBuiltinTypes.*privateType).get());
391 }
392
393 // sk_Caps is "builtin", but all references to it are resolved to Settings, so we don't need to
394 // treat it as builtin (ie, no need to clone it into the Program).
395 rootModule->fSymbols->addOrDie(Variable::Make(/*pos=*/Position(),
396 /*modifiersPosition=*/Position(),
397 Layout{},
400 "sk_Caps",
401 /*mangledName=*/"",
402 /*builtin=*/false,
404 fRootModule = std::move(rootModule);
405}
const std::unique_ptr< Type > fSkCaps
const Module * rootModule()
static std::unique_ptr< Variable > Make(Position pos, Position modifiersPosition, const Layout &layout, ModifierFlags flags, const Type *type, std::string_view name, std::string mangledName, bool builtin, Storage storage)
const std::unique_ptr< Type > BuiltinTypes::* BuiltinTypePtr
static constexpr BuiltinTypePtr kPrivateTypes[]
static constexpr BuiltinTypePtr kRootTypes[]
const BuiltinTypes fBuiltinTypes
std::unique_ptr< const Module > fRootModule
std::unique_ptr< SymbolTable > fSymbols
Definition: SkSLCompiler.h:58

Member Data Documentation

◆ fBuiltinTypes

const BuiltinTypes SkSL::ModuleLoader::Impl::fBuiltinTypes

Definition at line 98 of file SkSLModuleLoader.cpp.

◆ fComputeModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fComputeModule

Definition at line 107 of file SkSLModuleLoader.cpp.

◆ fFragmentModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fFragmentModule

Definition at line 106 of file SkSLModuleLoader.cpp.

◆ fGPUModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fGPUModule

Definition at line 103 of file SkSLModuleLoader.cpp.

◆ fGraphiteFragmentES2Module

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fGraphiteFragmentES2Module

Definition at line 111 of file SkSLModuleLoader.cpp.

◆ fGraphiteFragmentModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fGraphiteFragmentModule

Definition at line 109 of file SkSLModuleLoader.cpp.

◆ fGraphiteVertexES2Module

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fGraphiteVertexES2Module

Definition at line 110 of file SkSLModuleLoader.cpp.

◆ fGraphiteVertexModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fGraphiteVertexModule

Definition at line 108 of file SkSLModuleLoader.cpp.

◆ fMutex

SkMutex SkSL::ModuleLoader::Impl::fMutex

Definition at line 97 of file SkSLModuleLoader.cpp.

◆ fPublicModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fPublicModule

Definition at line 113 of file SkSLModuleLoader.cpp.

◆ fRootModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fRootModule

Definition at line 100 of file SkSLModuleLoader.cpp.

◆ fRuntimeShaderModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fRuntimeShaderModule

Definition at line 115 of file SkSLModuleLoader.cpp.

◆ fSharedModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fSharedModule

Definition at line 102 of file SkSLModuleLoader.cpp.

◆ fVertexModule

std::unique_ptr<const Module> SkSL::ModuleLoader::Impl::fVertexModule

Definition at line 105 of file SkSLModuleLoader.cpp.


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