Package icyllis.arc3d.granite
Class FragmentHelpers
java.lang.Object
icyllis.arc3d.granite.FragmentHelpers
Build
PaintParamsKey
and collect
uniform data and texture sampler desc.- See Also:
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
static final int
static final ColorSpace.Rgb.TransferParameters
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
appendAlphaOnlyPaintColorBlock
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer) static void
appendBlendMode
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, BlendMode bm) static void
appendColorSpaceUniforms
(ColorSpace srcCS, int srcAT, ColorSpace dstCS, int dstAT, UniformDataGatherer uniformDataGatherer) Compute color space transform parameters and add uniforms, seePixelUtils
.static void
appendDitherShaderBlock
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, float range) static void
appendFixedBlendMode
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, BlendMode bm) static void
appendGradientShaderBlock
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, FragmentHelpers.GradientData gradData) static void
appendImageShaderBlock
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, Rect2fc subset, int tileModeX, int tileModeY, SamplingOptions sampling, int imageWidth, int imageHeight, int srcAT, @SharedPtr ImageViewProxy view) static void
appendLocalMatrixShaderBlock
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, Matrixc localMatrix) static void
appendPrimitiveColorBlock
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer) static void
appendRGBOpaquePaintColorBlock
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer) static void
appendSolidColorShaderBlock
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, float r, float g, float b, float a) static void
appendToKey
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, @RawPtr Blender blender) static void
appendToKey
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, @RawPtr ColorFilter colorFilter) static void
appendToKey
(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, @RawPtr Shader shader) Add implementation details, for the specified backend, of this Shader to the provided key.
-
Field Details
-
LINEAR_TRANSFER_PARAMETERS
-
kCubicClampUnpremul
public static final int kCubicClampUnpremul- See Also:
-
kCubicClampPremul
public static final int kCubicClampPremul- See Also:
-
-
Constructor Details
-
FragmentHelpers
public FragmentHelpers()
-
-
Method Details
-
appendColorSpaceUniforms
public static void appendColorSpaceUniforms(@Nullable ColorSpace srcCS, int srcAT, @Nullable ColorSpace dstCS, int dstAT, UniformDataGatherer uniformDataGatherer) Compute color space transform parameters and add uniforms, seePixelUtils
. -
appendSolidColorShaderBlock
public static void appendSolidColorShaderBlock(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, float r, float g, float b, float a) -
appendRGBOpaquePaintColorBlock
public static void appendRGBOpaquePaintColorBlock(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer) -
appendAlphaOnlyPaintColorBlock
public static void appendAlphaOnlyPaintColorBlock(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer) -
appendDitherShaderBlock
public static void appendDitherShaderBlock(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, float range) -
appendLocalMatrixShaderBlock
public static void appendLocalMatrixShaderBlock(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, Matrixc localMatrix) -
appendImageShaderBlock
public static void appendImageShaderBlock(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, Rect2fc subset, int tileModeX, int tileModeY, SamplingOptions sampling, int imageWidth, int imageHeight, int srcAT, @SharedPtr @SharedPtr ImageViewProxy view) -
appendGradientShaderBlock
public static void appendGradientShaderBlock(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, FragmentHelpers.GradientData gradData) -
appendBlendMode
public static void appendBlendMode(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, BlendMode bm) -
appendFixedBlendMode
public static void appendFixedBlendMode(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, BlendMode bm) -
appendPrimitiveColorBlock
public static void appendPrimitiveColorBlock(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer) -
appendToKey
public static void appendToKey(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, @RawPtr @RawPtr Shader shader) Add implementation details, for the specified backend, of this Shader to the provided key.- Parameters:
keyContext
- backend context for key creationkeyBuilder
- builder for creating the key for this SkShadershader
- This function is a no-op if shader is null.
-
appendToKey
public static void appendToKey(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, @RawPtr @RawPtr ColorFilter colorFilter) -
appendToKey
public static void appendToKey(KeyContext keyContext, KeyBuilder keyBuilder, UniformDataGatherer uniformDataGatherer, TextureDataGatherer textureDataGatherer, @RawPtr @RawPtr Blender blender)
-