in binding/SkiaSharp/SKRuntimeEffect.cs [323:362]
public IEnumerator<string> GetEnumerator () =>
((IEnumerable<string>)names).GetEnumerator ();
public void Dispose () =>
data.Dispose ();
private bool ValidateTypes (SKRuntimeEffectUniform.DataType valueType, SKRuntimeEffectUniformTypeNative uniformType, bool isArray, int arraySize) =>
valueType switch {
SKRuntimeEffectUniform.DataType.Float => uniformType switch {
SKRuntimeEffectUniformTypeNative.Float when !isArray => true,
_ => false,
},
SKRuntimeEffectUniform.DataType.FloatArray => uniformType switch {
SKRuntimeEffectUniformTypeNative.Float when isArray => true,
SKRuntimeEffectUniformTypeNative.Float2 => true,
SKRuntimeEffectUniformTypeNative.Float3 => true,
SKRuntimeEffectUniformTypeNative.Float4 => true,
SKRuntimeEffectUniformTypeNative.Float2x2 => true,
SKRuntimeEffectUniformTypeNative.Float3x3 => true,
SKRuntimeEffectUniformTypeNative.Float4x4 => true,
_ => false,
},
SKRuntimeEffectUniform.DataType.Int32 => uniformType switch {
SKRuntimeEffectUniformTypeNative.Int when !isArray => true,
_ => false,
},
SKRuntimeEffectUniform.DataType.Int32Array => uniformType switch {
SKRuntimeEffectUniformTypeNative.Int when isArray => true,
SKRuntimeEffectUniformTypeNative.Int2 => true,
SKRuntimeEffectUniformTypeNative.Int3 => true,
SKRuntimeEffectUniformTypeNative.Int4 => true,
_ => false,
},
SKRuntimeEffectUniform.DataType.Color => uniformType switch {
SKRuntimeEffectUniformTypeNative.Float3 => true,
SKRuntimeEffectUniformTypeNative.Float4 => true,
_ => false,
},
_ => false,
};