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

Side by Side Diff: src/utils/SkLua.cpp

Issue 2355483002: abstract name of clipping ops, to transtion to a more restricted set (Closed)
Patch Set: no need for ifdef for globals Created 4 years, 3 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
« no previous file with comments | « src/utils/SkDumpCanvas.cpp ('k') | src/utils/SkLuaCanvas.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 2013 Google Inc. 2 * Copyright 2013 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 #include "SkLua.h" 8 #include "SkLua.h"
9 9
10 #if SK_SUPPORT_GPU 10 #if SK_SUPPORT_GPU
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after
398 case SkClipStack::Element::kRect_Type: 398 case SkClipStack::Element::kRect_Type:
399 this->pushRect(element.getRect(), "rect"); 399 this->pushRect(element.getRect(), "rect");
400 break; 400 break;
401 case SkClipStack::Element::kRRect_Type: 401 case SkClipStack::Element::kRRect_Type:
402 this->pushRRect(element.getRRect(), "rrect"); 402 this->pushRRect(element.getRRect(), "rrect");
403 break; 403 break;
404 case SkClipStack::Element::kPath_Type: 404 case SkClipStack::Element::kPath_Type:
405 this->pushPath(element.getPath(), "path"); 405 this->pushPath(element.getPath(), "path");
406 break; 406 break;
407 } 407 }
408 this->pushString(region_op(element.getOp()), "op"); 408 this->pushString(region_op((SkRegion::Op)element.getOp()), "op");
409 this->pushBool(element.isAA(), "aa"); 409 this->pushBool(element.isAA(), "aa");
410 CHECK_SETFIELD(key); 410 CHECK_SETFIELD(key);
411 } 411 }
412 412
413 413
414 /////////////////////////////////////////////////////////////////////////////// 414 ///////////////////////////////////////////////////////////////////////////////
415 /////////////////////////////////////////////////////////////////////////////// 415 ///////////////////////////////////////////////////////////////////////////////
416 416
417 static SkScalar getfield_scalar(lua_State* L, int index, const char key[]) { 417 static SkScalar getfield_scalar(lua_State* L, int index, const char key[]) {
418 SkASSERT(lua_istable(L, index)); 418 SkASSERT(lua_istable(L, index));
(...skipping 1761 matching lines...) Expand 10 before | Expand all | Expand 10 after
2180 REG_CLASS(L, SkTextBlob); 2180 REG_CLASS(L, SkTextBlob);
2181 REG_CLASS(L, SkTypeface); 2181 REG_CLASS(L, SkTypeface);
2182 REG_CLASS(L, SkXfermode); 2182 REG_CLASS(L, SkXfermode);
2183 } 2183 }
2184 2184
2185 extern "C" int luaopen_skia(lua_State* L); 2185 extern "C" int luaopen_skia(lua_State* L);
2186 extern "C" int luaopen_skia(lua_State* L) { 2186 extern "C" int luaopen_skia(lua_State* L) {
2187 SkLua::Load(L); 2187 SkLua::Load(L);
2188 return 0; 2188 return 0;
2189 } 2189 }
OLDNEW
« no previous file with comments | « src/utils/SkDumpCanvas.cpp ('k') | src/utils/SkLuaCanvas.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698