78 {
79
80
82 proj.
setRC(3, 2, -1.f / 800.f);
83
84 for (int pass = 0; pass < 2; ++pass) {
85
86
87
88
89 bool drawFront = pass > 0;
90
91 for (
int y = 0;
y < 3; ++
y) {
92 float ringY = (
y - 1) * (kPosterSize + 10.f);
93 for (
int i = 0;
i < kNumAngles; ++
i) {
94
95
98 360.f *
SkScalarMod(fTime / yDuration, yDuration), 360.f);
99
100 static constexpr SkScalar kBackMinAngle = 70.f;
101 static constexpr SkScalar kBackMaxAngle = 290.f;
102 if (drawFront) {
103 if (yRotation >= kBackMinAngle && yRotation <= kBackMaxAngle) {
104
105 continue;
106 }
107 } else {
108 if (yRotation < kBackMinAngle || yRotation > kBackMaxAngle) {
109
110 continue;
111 }
112 }
113
115
116
117
119 * proj
124
126 0.5f * kPosterSize, 0.5f * kPosterSize);
132
134 }
135 }
136 }
137 }
#define SkDegreesToRadians(degrees)
#define SkScalarMod(x, y)
void drawImageRect(const SkImage *, const SkRect &src, const SkRect &dst, const SkSamplingOptions &, const SkPaint *, SrcRectConstraint)
void concat(const SkMatrix &matrix)
static SkM44 Rotate(SkV3 axis, SkScalar radians)
static SkM44 Translate(SkScalar x, SkScalar y, SkScalar z=0)
void setRC(int r, int c, SkScalar value)
void setAntiAlias(bool aa)
SkSamplingOptions(SkFilterMode::kLinear))
static constexpr SkRect MakeLTRB(float l, float t, float r, float b)