Package icyllis.arc3d.granite.geom
Class CircleProcessor
java.lang.Object
icyllis.arc3d.granite.GeometryStep
icyllis.arc3d.granite.geom.CircleProcessor
The output of this effect is a modulation of the input color and coverage for a circle. It
operates in a space normalized by the circle radius (outer radius in the case of a stroke)
with origin at the circle center. Three vertex/instance attributes are used:
- vec2 : position in local space of the bounding geometry vertices
- vec4 : (p.xy, outerRad, innerRad) p is the position in the normalized local space. outerRad is the outerRadius in local space. innerRad is the innerRadius in normalized local space (ignored if not stroking).
- vec4 : color
-
Nested Class Summary
Nested classes/interfaces inherited from class icyllis.arc3d.granite.GeometryStep
GeometryStep.ProgramImpl
-
Field Summary
Modifier and TypeFieldDescriptionstatic final VertexInputLayout.Attribute
static final VertexInputLayout.Attribute
Per-instance attributes (optional).static final VertexInputLayout.Attribute
Per-instance attributes.static final VertexInputLayout.AttributeSet
static final VertexInputLayout.Attribute
Per-instance attributes (optional).static final VertexInputLayout.Attribute
static final VertexInputLayout.Attribute
Per-vertex attributes.static final VertexInputLayout.Attribute
Per-instance attributes (optional).static final VertexInputLayout.Attribute
Per-instance attributes (optional).static final VertexInputLayout.AttributeSet
Fields inherited from class icyllis.arc3d.granite.GeometryStep
DEPTH, FLAG_EMIT_COVERAGE, FLAG_EMIT_PRIMITIVE_COLOR, FLAG_HANDLE_SOLID_COLOR, FLAG_HAS_TEXTURES, FLAG_OUTSET_BOUNDS_FOR_AA, FLAG_PERFORM_SHADING, SOLID_COLOR
-
Constructor Summary
ConstructorDescriptionCircleProcessor
(boolean stroke, boolean clipPlane, boolean isectPlane, boolean unionPlane, boolean roundCaps) -
Method Summary
Modifier and TypeMethodDescriptionvoid
Appends a key on the KeyBuilder that reflects any variety in the code that the geometry processor subclass can emit.makeProgramImpl
(ShaderCaps caps) Returns a new instance of the appropriate implementation class for the given GeometryProcessor.Methods inherited from class icyllis.arc3d.granite.GeometryStep
appendAttributesToKey, depthStencilFlags, depthStencilSettings, emitFragmentColorCode, emitFragmentCoverageCode, emitSamplers, emitsCoverage, emitsPrimitiveColor, emitUniforms, emitVaryings, emitVertexGeomCode, getInputLayout, handlesSolidColor, hasInstanceAttributes, hasVertexAttributes, instanceAttributes, instanceBinding, instanceStride, makeColorAttribute, name, numInstanceAttributes, numInstanceLocations, numTextureSamplers, numVertexAttributes, numVertexLocations, performsShading, primitiveType, textureSamplerState, textureSamplerSwizzle, uniqueID, vertexAttributes, vertexBinding, vertexStride, writeMesh, writeUniformsAndTextures
-
Field Details
-
POSITION
Per-vertex attributes. -
CIRCLE_EDGE
-
COLOR
Per-instance attributes. -
CLIP_PLANE
Per-instance attributes (optional). -
ISECT_PLANE
Per-instance attributes (optional). -
UNION_PLANE
Per-instance attributes (optional). -
ROUND_CAP_CENTERS
Per-instance attributes (optional). -
MODEL_VIEW
-
VERTEX_FORMAT
-
INSTANCE_FORMAT
-
-
Constructor Details
-
CircleProcessor
public CircleProcessor(boolean stroke, boolean clipPlane, boolean isectPlane, boolean unionPlane, boolean roundCaps)
-
-
Method Details
-
appendToKey
Description copied from class:GeometryStep
Appends a key on the KeyBuilder that reflects any variety in the code that the geometry processor subclass can emit.- Specified by:
appendToKey
in classGeometryStep
- See Also:
-
makeProgramImpl
Description copied from class:GeometryStep
Returns a new instance of the appropriate implementation class for the given GeometryProcessor. This method is called only when the specified key does not exist in the program cache.- Specified by:
makeProgramImpl
in classGeometryStep
- See Also:
-