skia2/resources/particles/warp.json
Brian Osman bdcdf1a7c3 Add SkParticleValue to allow further customization of curve behavior
All curves (and path affectors) are driven by an SkParticleValue. The
value can derive its value from the current defaults (age of particle
or effect), or explicitly choose the other one, a random value, or any
other particle value. Values can be range adjusted and support repeat,
clamp, and mirror tiling.

Also fixed some more issues related to resource path in the slide GUI.

Bug: skia:
Change-Id: I4755018d5b57ae2d5ec400d541055ca4fb542978
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/196760
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
2019-03-04 22:04:17 +00:00

115 lines
2.6 KiB
JSON

{
"MaxCount": 4096,
"Duration": 1,
"Rate": 90,
"Life": {
"Input": {
"Source": "Age",
"TileMode": "Repeat",
"Left": 0,
"Right": 1
},
"XValues": [],
"Segments": [
{
"Type": "Constant",
"Ranged": false,
"Bidirectional": false,
"A0": 30
}
]
},
"Drawable": {
"Type": "SkCircleDrawable",
"Radius": 2
},
"Spawn": [
{
"Type": "SkPositionInCircleAffector",
"Enabled": true,
"SetHeading": true,
"X": {
"Input": {
"Source": "Age",
"TileMode": "Repeat",
"Left": 0,
"Right": 1
},
"XValues": [],
"Segments": [
{
"Type": "Constant",
"Ranged": false,
"Bidirectional": false,
"A0": 0
}
]
},
"Y": {
"Input": {
"Source": "Age",
"TileMode": "Repeat",
"Left": 0,
"Right": 1
},
"XValues": [],
"Segments": [
{
"Type": "Constant",
"Ranged": false,
"Bidirectional": false,
"A0": 0
}
]
},
"Radius": {
"Input": {
"Source": "Age",
"TileMode": "Repeat",
"Left": 0,
"Right": 1
},
"XValues": [],
"Segments": [
{
"Type": "Constant",
"Ranged": false,
"Bidirectional": false,
"A0": 40
}
]
}
}
],
"Update": [
{
"Type": "SkPointForceAffector",
"Enabled": true,
"Point": { "x": 0, "y": 0 },
"Constant": -10,
"InvSquare": 0
},
{
"Type": "SkSizeAffector",
"Enabled": true,
"Curve": {
"Input": {
"Source": "Age",
"TileMode": "Repeat",
"Left": 0,
"Right": 1
},
"XValues": [],
"Segments": [
{
"Type": "Linear",
"Ranged": false,
"Bidirectional": false,
"A0": 0.25,
"D0": 3
}
]
}
}
]
}