java.lang.Object
net.algart.json.PropertyChecker
net.algart.json.AbstractConvertibleToJson
net.algart.executors.modules.cv.matrices.camera.reflectance.ReflectanceSettings

public class ReflectanceSettings extends net.algart.json.AbstractConvertibleToJson
  • Field Details

  • Constructor Details

    • ReflectanceSettings

      public ReflectanceSettings()
    • ReflectanceSettings

      public ReflectanceSettings(jakarta.json.JsonObject json, Path file)
  • Method Details

    • read

      public static ReflectanceSettings read(Path reflectanceJsonFile) throws IOException
      Throws:
      IOException
    • write

      public void write(Path reflectanceJsonFile, OpenOption... options) throws IOException
      Throws:
      IOException
    • valueOf

      public static ReflectanceSettings valueOf(jakarta.json.JsonObject reflectanceJson)
    • valueOf

      public static ReflectanceSettings valueOf(String reflectanceJsonString)
    • isReflectanceJson

      public static boolean isReflectanceJson(jakarta.json.JsonObject reflectanceJson)
    • getReflectanceJsonFile

      public Path getReflectanceJsonFile()
    • getVersion

      public String getVersion()
    • setVersion

      public ReflectanceSettings setVersion(String version)
    • getType

      public ReflectanceTranslationType getType()
    • setType

    • getTranslation

      public ReflectanceSettings.Translation getTranslation()
    • setTranslation

      public ReflectanceSettings setTranslation(ReflectanceSettings.Translation translation)
    • intensityToReflectance

      public double intensityToReflectance(double intensity)
      Converts intensity of pixels to reflection coefficient.
      Parameters:
      intensity - intensity of pixels, from 0.0 (black) to 1.0 (white).
      Returns:
      reflection coefficient, usually from 0 (black) to 100 (ideal mirror).
    • reflectanceToIntensity

      public double reflectanceToIntensity(double reflectance)
      Converts reflection coefficient to intensity of pixels.
      Parameters:
      reflectance - reflection coefficient, usually from 0 (black) to 100 (ideal mirror).
      Returns:
      intensity of pixels, from 0.0 (black) to 1.0 (white).
    • intensity255ToReflectance

      public double intensity255ToReflectance(double intensity)
      An analog of intensityToReflectance(double), providing absolute precision when the translation parameters are specified in terms of 8-bit intensity 0..255, like in the method ReflectanceSettings.LinearTranslation.setA255(double).
      Parameters:
      intensity - intensity of pixels, from 0.0 (black) to 255.0 (white).
      Returns:
      reflection coefficient, usually from 0 (black) to 100 (ideal mirror).
    • reflectanceToIntensity255

      public double reflectanceToIntensity255(double reflectance)
      An analog of reflectanceToIntensity255(double), providing absolute precision when the translation parameters are specified in terms of 8-bit intensity 0..255, like in the method ReflectanceSettings.LinearTranslation.setA255(double).
      Parameters:
      reflectance - reflection coefficient, usually from 0 (black) to 100 (ideal mirror).
      Returns:
      intensity of pixels, from 0.0 (black) to 255.0 (white).
    • normalizedIntensityToReflectanceFunc

      public net.algart.math.functions.Func normalizedIntensityToReflectanceFunc()
    • intensityToReflectanceFunc

      public net.algart.math.functions.Func intensityToReflectanceFunc(Class<?> intensityElementType)
    • intensityToReflectanceFunc

      public net.algart.math.functions.Func intensityToReflectanceFunc(Class<?> intensityElementType, boolean maximalPrecision)
    • reflectanceToNormalizedIntensityFunc

      public net.algart.math.functions.Func reflectanceToNormalizedIntensityFunc()
    • reflectanceToIntensityFunc

      public net.algart.math.functions.Func reflectanceToIntensityFunc(Class<?> intensityElementType)
    • reflectanceToIntensityFunc

      public net.algart.math.functions.Func reflectanceToIntensityFunc(Class<?> intensityElementType, boolean maximalPrecision)
    • buildJson

      public void buildJson(jakarta.json.JsonObjectBuilder builder)
      Specified by:
      buildJson in class net.algart.json.AbstractConvertibleToJson
    • toString

      public String toString()
      Overrides:
      toString in class Object