Hash :
4d59f3c6
Author :
Date :
2015-05-28T17:33:53
Make false blocks produced by RewriteElseBlocks sequence nodes All child nodes of selection should be sequence nodes, so that they will output braces and extra braces can be removed from HLSL output. Also make RewriteElseBlocks to reuse common IntermTraverser functionality to simplify the code. TEST=WebGL conformance tests on D3D9 BUG=angleproject:1013 Change-Id: Iafdc05468b22d110abcd020cf52c646dd98fb4a0 Reviewed-on: https://chromium-review.googlesource.com/273608 Tested-by: Olli Etuaho <oetuaho@nvidia.com> Reviewed-by: Jamie Madill <jmadill@chromium.org> Reviewed-by: Zhenyao Mo <zmo@chromium.org>
//
// 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.
//
// RewriteElseBlocks.h: Prototype for tree transform to change
// all if-else blocks to if-if blocks.
//
#ifndef COMPILER_TRANSLATOR_REWRITEELSEBLOCKS_H_
#define COMPILER_TRANSLATOR_REWRITEELSEBLOCKS_H_
#include "compiler/translator/IntermNode.h"
namespace sh
{
void RewriteElseBlocks(TIntermNode *node, unsigned int *temporaryIndex);
}
#endif // COMPILER_TRANSLATOR_REWRITEELSEBLOCKS_H_