michael@0: // michael@0: // Copyright (c) 2002-2013 The ANGLE Project Authors. All rights reserved. michael@0: // Use of this source code is governed by a BSD-style license that can be michael@0: // found in the LICENSE file. michael@0: // michael@0: michael@0: #include "compiler/TranslatorHLSL.h" michael@0: michael@0: // michael@0: // This function must be provided to create the actual michael@0: // compile object used by higher level code. It returns michael@0: // a subclass of TCompiler. michael@0: // michael@0: TCompiler* ConstructCompiler( michael@0: ShShaderType type, ShShaderSpec spec, ShShaderOutput output) michael@0: { michael@0: switch (output) michael@0: { michael@0: case SH_HLSL9_OUTPUT: michael@0: case SH_HLSL11_OUTPUT: michael@0: return new TranslatorHLSL(type, spec, output); michael@0: default: michael@0: return NULL; michael@0: } michael@0: } michael@0: michael@0: // michael@0: // Delete the compiler made by ConstructCompiler michael@0: // michael@0: void DeleteCompiler(TCompiler* compiler) michael@0: { michael@0: delete compiler; michael@0: }