1 // 2 // Copyright 2019 The ANGLE Project Authors. All rights reserved. 3 // Use of this source code is governed by a BSD-style license that can be 4 // found in the LICENSE file. 5 // 6 // ShaderMtl.h: 7 // Defines the class interface for ShaderMtl, implementing ShaderImpl. 8 // 9 #ifndef LIBANGLE_RENDERER_METAL_SHADERMTL_H_ 10 #define LIBANGLE_RENDERER_METAL_SHADERMTL_H_ 11 12 #include <map> 13 14 #include "libANGLE/renderer/ShaderImpl.h" 15 #include "libANGLE/renderer/metal/mtl_msl_utils.h" 16 17 namespace rx 18 { 19 class ShaderMtl : public ShaderImpl 20 { 21 public: 22 ShaderMtl(const gl::ShaderState &state); 23 ~ShaderMtl() override; 24 25 std::shared_ptr<ShaderTranslateTask> compile(const gl::Context *context, 26 ShCompileOptions *options) override; 27 getCompiledState()28 const SharedCompiledShaderStateMtl &getCompiledState() const { return mCompiledState; } 29 30 std::string getDebugInfo() const override; 31 32 private: 33 SharedCompiledShaderStateMtl mCompiledState; 34 }; 35 36 } // namespace rx 37 38 #endif /* LIBANGLE_RENDERER_METAL_SHADERMTL_H_ */ 39