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

Side by Side Diff: src/animator/SkScript.cpp

Issue 100803004: Changed maxInputCount for exact inputCount (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Fixed input count condition Created 7 years 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 | « include/core/SkImageFilter.h ('k') | src/core/SkImageFilter.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 /* 2 /*
3 * Copyright 2006 The Android Open Source Project 3 * Copyright 2006 The Android Open Source Project
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 9
10 #include "SkScript.h" 10 #include "SkScript.h"
(...skipping 1514 matching lines...) Expand 10 before | Expand all | Expand 10 after
1525 success = false; 1525 success = false;
1526 break; // error 1526 break; // error
1527 } 1527 }
1528 success = SkParse::FindScalar(operand.fString->c_str(), &operand .fScalar) != NULL; 1528 success = SkParse::FindScalar(operand.fString->c_str(), &operand .fScalar) != NULL;
1529 } 1529 }
1530 break; 1530 break;
1531 case SkType_String: { 1531 case SkType_String: {
1532 SkString* strPtr = new SkString(); 1532 SkString* strPtr = new SkString();
1533 SkASSERT(engine); 1533 SkASSERT(engine);
1534 engine->track(strPtr); 1534 engine->track(strPtr);
1535 if (type == SkType_Int) 1535 if (type == SkType_Int) {
1536 strPtr->appendS32(operand.fS32); 1536 strPtr->appendS32(operand.fS32);
1537 else if (type == SkType_Displayable) 1537 } else if (type == SkType_Displayable) {
1538 SkASSERT(0); // must call through instance version instead of st atic version 1538 SkASSERT(0); // must call through instance version instead of st atic version
1539 else { 1539 } else {
1540 if (type != SkType_Float) { 1540 if (type != SkType_Float) {
1541 success = false; 1541 success = false;
1542 break; 1542 break;
1543 } 1543 }
1544 strPtr->appendScalar(operand.fScalar); 1544 strPtr->appendScalar(operand.fScalar);
1545 } 1545 }
1546 operand.fString = strPtr; 1546 operand.fString = strPtr;
1547 } break; 1547 } break;
1548 case SkType_Array: { 1548 case SkType_Array: {
1549 SkTypedArray* array = new SkTypedArray(type); 1549 SkTypedArray* array = new SkTypedArray(type);
(...skipping 336 matching lines...) Expand 10 before | Expand all | Expand 10 after
1886 break; 1886 break;
1887 case SkType_String: 1887 case SkType_String:
1888 SkASSERT(strcmp(value.fOperand.fString->c_str(), scriptTests[ind ex].fStringAnswer) == 0); 1888 SkASSERT(strcmp(value.fOperand.fString->c_str(), scriptTests[ind ex].fStringAnswer) == 0);
1889 break; 1889 break;
1890 default: 1890 default:
1891 SkASSERT(0); 1891 SkASSERT(0);
1892 } 1892 }
1893 } 1893 }
1894 } 1894 }
1895 #endif 1895 #endif
OLDNEW
« no previous file with comments | « include/core/SkImageFilter.h ('k') | src/core/SkImageFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698