Package ke.ric.renderer.api
Record Class VisibilityStatistics
java.lang.Object
java.lang.Record
ke.ric.renderer.api.VisibilityStatistics
- Record Components:
entities- visible entity-key counts produced by this rendermaterials- visible material-key counts produced by this renderstructures- visible structure-key counts produced by this renderbiomes- visible biome-key counts produced by this renderskyPixels- number of pixels classified as skytotalPixels- total number of frame pixels
public record VisibilityStatistics(Map<String,Integer> entities, Map<String,Integer> materials, Map<String,Integer> structures, Map<String,Integer> biomes, int skyPixels, int totalPixels)
extends Record
Immutable counts of visible semantic evidence and covered pixels in a completed frame.
Maps are defensive immutable snapshots.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbiomes()Returns the value of thebiomesrecord component.static VisibilityStatisticsempty(int pixels) Returns empty semantic maps and classifies all supplied frame pixels as sky.entities()Returns the value of theentitiesrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of thematerialsrecord component.intReturns the value of theskyPixelsrecord component.Returns the value of thestructuresrecord component.final StringtoString()Returns a string representation of this record class.intReturns the value of thetotalPixelsrecord component.
-
Constructor Details
-
VisibilityStatistics
public VisibilityStatistics(Map<String, Integer> entities, Map<String, Integer> materials, Map<String, Integer> structures, Map<String, Integer> biomes, int skyPixels, int totalPixels) Creates an instance of aVisibilityStatisticsrecord class.- Parameters:
entities- the value for theentitiesrecord componentmaterials- the value for thematerialsrecord componentstructures- the value for thestructuresrecord componentbiomes- the value for thebiomesrecord componentskyPixels- the value for theskyPixelsrecord componenttotalPixels- the value for thetotalPixelsrecord component
-
-
Method Details
-
empty
Returns empty semantic maps and classifies all supplied frame pixels as sky. -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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 '=='. -
entities
Returns the value of theentitiesrecord component.- Returns:
- the value of the
entitiesrecord component
-
materials
Returns the value of thematerialsrecord component.- Returns:
- the value of the
materialsrecord component
-
structures
Returns the value of thestructuresrecord component.- Returns:
- the value of the
structuresrecord component
-
biomes
Returns the value of thebiomesrecord component.- Returns:
- the value of the
biomesrecord component
-
skyPixels
public int skyPixels()Returns the value of theskyPixelsrecord component.- Returns:
- the value of the
skyPixelsrecord component
-
totalPixels
public int totalPixels()Returns the value of thetotalPixelsrecord component.- Returns:
- the value of the
totalPixelsrecord component
-