8package org.skia.jetski;
10import androidx.annotation.Nullable;
13 private long mNativeInstance;
16 mNativeInstance = nCreate();
20 nSetColor(mNativeInstance, c.
r(), c.
g(), c.
b(), c.
a());
25 nSetColor(mNativeInstance, r, g,
b,
a);
30 nSetColorFilter(mNativeInstance, filter !=
null ? filter.getNativeInstance() : 0);
35 nSetShader(mNativeInstance, shader !=
null ? shader.getNativeInstance() : 0);
40 nSetImageFilter(mNativeInstance, filter !=
null ? filter.getNativeInstance() : 0);
45 nSetStroke(mNativeInstance,
stroke);
50 nSetStrokeWidth(mNativeInstance,
w);
59 private Cap(
int nativeInt) {
60 this.nativeInt = nativeInt;
65 nSetStrokeCap(mNativeInstance, cap.
nativeInt);
75 private Join(
int nativeInt) {
76 this.nativeInt = nativeInt;
81 nSetStrokeJoin(mNativeInstance,
join.nativeInt);
86 nSetStrokeMiter(mNativeInstance, limit);
94 nRelease(mNativeInstance);
106 private static native
long nCreate();
107 private static native
void nRelease(
long nativeInstance);
109 private static native
void nSetColor(
long nativeInstance,
float r,
float g,
float b,
float a);
110 private static native
void nSetStroke(
long nativeInstance,
boolean stroke);
111 private static native
void nSetStrokeWidth(
long nativeInstance,
float w);
112 private static native
void nSetStrokeCap(
long nativeInstance,
int native_cap);
113 private static native
void nSetStrokeJoin(
long nativeInstance,
int native_join);
114 private static native
void nSetStrokeMiter(
long nativeInstance,
float limit);
115 private static native
void nSetColorFilter(
long nativeInstance,
long nativeCF);
116 private static native
void nSetShader(
long nativeInstance,
long nativeShader);
117 private static native
void nSetImageFilter(
long nativeInstance,
long nativeFilter);
Paint setStrokeJoin(Join join)
Paint setColor(float r, float g, float b, float a)
Paint setColorFilter(@Nullable ColorFilter filter)
Paint setStrokeCap(Cap cap)
Paint setStrokeMiter(float limit)
Paint setShader(@Nullable Shader shader)
Paint setImageFilter(@Nullable ImageFilter filter)
Paint setStrokeWidth(float w)
Paint setStroke(boolean stroke)
static SkString join(const CommandLineFlags::StringArray &)