MCPcopy Create free account
hub / github.com/HumbleUI/Skija / flattenArray

Method flattenArray

shared/java/Color4f.java:40–49  ·  view source on GitHub ↗
(Color4f[] colors)

Source from the content-addressed store, hash-verified

38 }
39
40 public static float[] flattenArray(Color4f[] colors) {
41 float[] arr = new float[colors.length * 4];
42 for (int i = 0; i < colors.length; ++i) {
43 arr[i * 4] = colors[i]._r;
44 arr[i * 4 + 1] = colors[i]._g;
45 arr[i * 4 + 2] = colors[i]._b;
46 arr[i * 4 + 3] = colors[i]._a;
47 }
48 return arr;
49 }
50
51 public Color4f premultiply() {
52 if (_a == 1f)

Callers 11

makeLinearGradientMethod · 0.95
makeRadialGradientMethod · 0.95
makeSweepGradientMethod · 0.95
drawPointsMethod · 0.80
drawLinesMethod · 0.80
drawPolygonMethod · 0.80
drawTrianglesMethod · 0.80
drawTriangleStripMethod · 0.80
drawTriangleFanMethod · 0.80
drawPatchMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected