Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8)

Side by Side Diff: src/gpu/gl/GrGLSL.h

Issue 13852013: Fix gyp files to allow ninja to build 64 bit on Mac. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: fix build by handling kLineTypeCount in switch Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « gyp/common_conditions.gypi ('k') | src/gpu/gl/GrGpuGL.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef GrGLSL_DEFINED 8 #ifndef GrGLSL_DEFINED
9 #define GrGLSL_DEFINED 9 #define GrGLSL_DEFINED
10 10
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 static const int kVecLengths[] = { 47 static const int kVecLengths[] = {
48 0, // kVoid_GrSLType 48 0, // kVoid_GrSLType
49 1, // kFloat_GrSLType 49 1, // kFloat_GrSLType
50 2, // kVec2f_GrSLType 50 2, // kVec2f_GrSLType
51 3, // kVec3f_GrSLType 51 3, // kVec3f_GrSLType
52 4, // kVec4f_GrSLType 52 4, // kVec4f_GrSLType
53 1, // kMat33f_GrSLType 53 1, // kMat33f_GrSLType
54 1, // kMat44f_GrSLType 54 1, // kMat44f_GrSLType
55 1, // kSampler2D_GrSLType 55 1, // kSampler2D_GrSLType
56 }; 56 };
57 GrAssert((size_t) type < GR_ARRAY_COUNT(kVecLengths)); 57 GR_STATIC_ASSERT(kGrSLTypeCount == GR_ARRAY_COUNT(kVecLengths));
58 return kVecLengths[type]; 58 return kVecLengths[type];
59 } 59 }
60 60
61 static inline const char* GrGLSLOnesVecf(int count) { 61 static inline const char* GrGLSLOnesVecf(int count) {
62 static const char* kONESVEC[] = {"ERROR", "1.0", "vec2(1,1)", 62 static const char* kONESVEC[] = {"ERROR", "1.0", "vec2(1,1)",
63 "vec3(1,1,1)", "vec4(1,1,1,1)"}; 63 "vec3(1,1,1)", "vec4(1,1,1,1)"};
64 GrAssert(count >= 1 && count < (int)GR_ARRAY_COUNT(kONESVEC)); 64 GrAssert(count >= 1 && count < (int)GR_ARRAY_COUNT(kONESVEC));
65 return kONESVEC[count]; 65 return kONESVEC[count];
66 } 66 }
67 67
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
223 */ 223 */
224 GrSLConstantVec GrGLSLGetComponent4f(SkString* outAppend, 224 GrSLConstantVec GrGLSLGetComponent4f(SkString* outAppend,
225 const char* expr, 225 const char* expr,
226 GrColorComponentFlags component, 226 GrColorComponentFlags component,
227 GrSLConstantVec defaultExpr = kNone_GrSLCon stantVec, 227 GrSLConstantVec defaultExpr = kNone_GrSLCon stantVec,
228 bool omitIfConst = false); 228 bool omitIfConst = false);
229 229
230 #include "GrGLSL_impl.h" 230 #include "GrGLSL_impl.h"
231 231
232 #endif 232 #endif
OLDNEW
« no previous file with comments | « gyp/common_conditions.gypi ('k') | src/gpu/gl/GrGpuGL.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698