Record Class GuiClipPath.Circle
java.lang.Object
java.lang.Record
com.render.api.gui.effects.GuiClipPath.Circle
- Record Components:
radius- radius relative to the smaller reference-box dimensioncenterX- horizontal center relative to the reference boxcenterY- vertical center relative to the reference boxreferenceBox- box used to resolve the normalized values
- All Implemented Interfaces:
GuiClipPath
- Enclosing interface:
GuiClipPath
public static record GuiClipPath.Circle(float radius, float centerX, float centerY, GuiClipPath.ReferenceBox referenceBox)
extends Record
implements GuiClipPath
Circle values are normalized to the reference box. A radius of
0.5 reaches half the smaller box dimension.-
Nested Class Summary
Nested classes/interfaces inherited from interface GuiClipPath
GuiClipPath.Circle, GuiClipPath.Ellipse, GuiClipPath.Inset, GuiClipPath.Path, GuiClipPath.Point, GuiClipPath.Polygon, GuiClipPath.ReferenceBox -
Constructor Summary
ConstructorsConstructorDescriptionCircle(float radius, float centerX, float centerY, GuiClipPath.ReferenceBox referenceBox) Creates an instance of aCirclerecord class. -
Method Summary
Modifier and TypeMethodDescriptionfloatcenterX()Returns the value of thecenterXrecord component.floatcenterY()Returns the value of thecenterYrecord component.conservativeBounds(GuiRect reference) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.floatradius()Returns the value of theradiusrecord component.Returns the value of thereferenceBoxrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from interface GuiClipPath
contains, inputExact, portableExact
-
Constructor Details
-
Circle
Creates an instance of aCirclerecord class.- Parameters:
radius- the value for theradiusrecord componentcenterX- the value for thecenterXrecord componentcenterY- the value for thecenterYrecord componentreferenceBox- the value for thereferenceBoxrecord component
-
-
Method Details
-
conservativeBounds
- Specified by:
conservativeBoundsin interfaceGuiClipPath
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
radius
-
centerX
-
centerY
-
referenceBox
Returns the value of thereferenceBoxrecord component.- Specified by:
referenceBoxin interfaceGuiClipPath- Returns:
- the value of the
referenceBoxrecord component
-