2 * Copyright 2014 Google Inc.
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
8 #ifndef GrGLSLVertexShader_DEFINED
9 #define GrGLSLVertexShader_DEFINED
11 #include "GrGLSLShaderBuilder.h"
12 #include "GrGeometryProcessor.h"
16 // Enough precision to represent 1 / 2048 accurately in printf
17 #define GR_SIGNIFICANT_POW2_DECIMAL_DIG 11
19 class GrGLSLVertexBuilder : public GrGLSLShaderBuilder {
21 GrGLSLVertexBuilder(GrGLSLProgramBuilder* program);
23 void transformToNormalizedDeviceSpace(const GrShaderVar& posVar);
25 void onFinalize() override;
27 const char* fRtAdjustName;
29 friend class GrGLProgramBuilder;
31 typedef GrGLSLShaderBuilder INHERITED;