Home | History | Annotate | Download | only in animator

Lines Matching full:scriptvalue

195     SkScriptValue scriptValue;
196 scriptValue.fType = SkType_Unknown;
197 scriptValue.fOperand.fS32 = 0;
259 success = engine.evaluateScript(&script, &scriptValue);
266 if (scriptValue.fType == SkType_Displayable) {
269 maker.findKey(scriptValue.fOperand.fDisplayable, &charPtr);
270 scriptValue.fOperand.fString = new SkString(charPtr);
271 scriptValue.fType = SkType_String;
272 engine.SkScriptEngine::track(scriptValue.fOperand.fString);
277 displayable->setReference(this, scriptValue.fOperand.fDisplayable);
279 arrayStorage->begin()[0].fDisplayable = scriptValue.fOperand.fDisplayable;
282 if (type != scriptValue.fType) {
283 if (scriptValue.fType == SkType_Array) {
284 engine.forget(scriptValue.getArray());
289 success = engine.convertTo(SkType_String, &scriptValue);
293 success = engine.convertTo(SkType_Float, &scriptValue);
296 success = engine.convertTo(SkType_Int, &scriptValue);
299 success = engine.convertTo(arrayType(), &scriptValue);
300 // !!! incomplete; create array of appropriate type and add scriptValue to it
313 scriptValue.fOperand.fMSec = SkScalarMulRound(scriptValue.fOperand.fScalar, 1000);
314 scriptValue.fType = type;
320 SkScriptValue scriptValue;
321 scriptValue.fOperand.fString = &string;
322 scriptValue.fType = SkType_String;
323 displayable->setProperty(propertyIndex(), scriptValue);
345 untypedStorage, outType, scriptValue)) {
365 SkScriptValue& scriptValue) const
374 displayable->setProperty(propertyIndex(), scriptValue);
377 switch (scriptValue.fType) {
381 memcpy(&storage->fScalar, &scriptValue.fOperand.fScalar, sizeof(SkScalar));
384 memcpy(&storage->fScalar, scriptValue.fOperand.fArray->begin(), scriptValue.fOperand.fArray->count() * sizeof(SkScalar));
387 storage->fString->set(*scriptValue.fOperand.fString);
394 SkASSERT(scriptValue.fType == SkType_Array);
396 displayable->executeFunction(displayable, this, scriptValue.fOperand.fArray, NULL);
398 int count = scriptValue.fOperand.fArray->count();
406 memcpy(&(*arrayStorage)[storageOffset], scriptValue.fOperand.fArray->begin(), count * sizeof(SkOperand));
413 if (scriptValue.fType != SkType_Array) {
414 SkASSERT(type == scriptValue.fType);
417 (*destArray)[storageOffset] = scriptValue.fOperand;
420 scriptValue.fOperand.fArray->getType();
423 SkASSERT(type == scriptValue.fOperand.fArray->getType());
424 int count = scriptValue.fOperand.fArray->count();
427 memcpy(destArray->begin() + storageOffset, scriptValue.fOperand.fArray->begin(), sizeof(SkOperand) * count);
431 string->set(*scriptValue.fOperand.fString);
433 SkTypedArray* array = scriptValue.fOperand.fArray;
434 SkASSERT(scriptValue.fType == SkType_Int || scriptValue.fType == SkType_ARGB ||
435 scriptValue.fType == SkType_Array);
436 SkASSERT(scriptValue.fType != SkType_Array || (array != NULL &&
438 int numberOfColors = scriptValue.fType == SkType_Array ? array->count() : 1;
444 SkColor color = scriptValue.fType == SkType_Array ?
445 (SkColor) array->begin()[index].fS32 : (SkColor) scriptValue.fOperand.fS32;
453 if (scriptValue.fType != SkType_Array)
456 int count = scriptValue.fOperand.fArray->count();
459 memcpy(storage, scriptValue.fOperand.fArray->begin(), count * sizeof(SkOperand));
461 } else if (scriptValue.fType == SkType_Array) {
462 SkASSERT(scriptValue.fOperand.fArray->getType() == type);
463 SkASSERT(scriptValue.fOperand.fArray->count() == getCount());
464 memcpy(storage, scriptValue.fOperand.fArray->begin(), getCount() * sizeof(SkOperand));
466 memcpy(storage, &scriptValue.fOperand, sizeof(SkOperand));