1 // 2 // Copyright 2016 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 // ShaderNULL.cpp: 7 // Implements the class methods for ShaderNULL. 8 // 9 10 #include "libANGLE/renderer/null/ShaderNULL.h" 11 12 #include "common/debug.h" 13 #include "libANGLE/Context.h" 14 #include "libANGLE/renderer/ContextImpl.h" 15 16 namespace rx 17 { 18 ShaderNULL(const gl::ShaderState & data)19ShaderNULL::ShaderNULL(const gl::ShaderState &data) : ShaderImpl(data) {} 20 ~ShaderNULL()21ShaderNULL::~ShaderNULL() {} 22 compile(const gl::Context * context,ShCompileOptions * options)23std::shared_ptr<ShaderTranslateTask> ShaderNULL::compile(const gl::Context *context, 24 ShCompileOptions *options) 25 { 26 const gl::Extensions &extensions = context->getImplementation()->getExtensions(); 27 if (extensions.shaderPixelLocalStorageANGLE) 28 { 29 options->pls = context->getImplementation()->getNativePixelLocalStorageOptions(); 30 } 31 return std::shared_ptr<ShaderTranslateTask>(new ShaderTranslateTask); 32 } 33 load(const gl::Context * context,gl::BinaryInputStream * stream)34std::shared_ptr<ShaderTranslateTask> ShaderNULL::load(const gl::Context *context, 35 gl::BinaryInputStream *stream) 36 { 37 return std::shared_ptr<ShaderTranslateTask>(new ShaderTranslateTask); 38 } 39 getDebugInfo() const40std::string ShaderNULL::getDebugInfo() const 41 { 42 return ""; 43 } 44 45 } // namespace rx 46