Edit

kc3-lang/angle/src/libANGLE/Compiler.cpp

Branch :

  • Show log

    Commit

  • Author : Geoff Lang
    Date : 2014-11-05 13:27:06
    Hash : 492a7e43
    Message : Encapulate the ESSL compiler into a GL object that is per-context. * Allows for multiple contexts have to have different client versions, caps and extensions without causing shader compilation failures. BUG=angle:823 Change-Id: I523679e90be031b0b7fa385d46d6839b1cf3029f Reviewed-on: https://chromium-review.googlesource.com/227710 Reviewed-by: Jamie Madill <jmadill@chromium.org> Tested-by: Geoff Lang <geofflang@chromium.org>

  • src/libANGLE/Compiler.cpp
  • //
    // Copyright (c) 2014 The ANGLE Project Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style license that can be
    // found in the LICENSE file.
    //
    
    // Compiler.cpp: implements the gl::Compiler class.
    
    #include "libANGLE/Compiler.h"
    #include "libANGLE/renderer/CompilerImpl.h"
    
    #include "common/debug.h"
    
    namespace gl
    {
    
    Compiler::Compiler(rx::CompilerImpl *impl)
        : mCompiler(impl)
    {
        ASSERT(mCompiler);
    }
    
    Compiler::~Compiler()
    {
        SafeDelete(mCompiler);
    }
    
    Error Compiler::release()
    {
        return mCompiler->release();
    }
    
    rx::CompilerImpl *Compiler::getImplementation()
    {
        return mCompiler;
    }
    
    }