Class ReflectanceSettings
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
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classstatic class -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbuildJson(jakarta.json.JsonObjectBuilder builder) getType()doubleintensity255ToReflectance(double intensity) An analog ofintensityToReflectance(double), providing absolute precision when the translation parameters are specified in terms of 8-bit intensity 0..255, like in the methodReflectanceSettings.LinearTranslation.setA255(double).doubleintensityToReflectance(double intensity) Converts intensity of pixels to reflection coefficient.net.algart.math.functions.FuncintensityToReflectanceFunc(Class<?> intensityElementType) net.algart.math.functions.FuncintensityToReflectanceFunc(Class<?> intensityElementType, boolean maximalPrecision) static booleanisReflectanceJson(jakarta.json.JsonObject reflectanceJson) net.algart.math.functions.Funcstatic ReflectanceSettingsdoublereflectanceToIntensity(double reflectance) Converts reflection coefficient to intensity of pixels.doublereflectanceToIntensity255(double reflectance) An analog ofreflectanceToIntensity255(double), providing absolute precision when the translation parameters are specified in terms of 8-bit intensity 0..255, like in the methodReflectanceSettings.LinearTranslation.setA255(double).net.algart.math.functions.FuncreflectanceToIntensityFunc(Class<?> intensityElementType) net.algart.math.functions.FuncreflectanceToIntensityFunc(Class<?> intensityElementType, boolean maximalPrecision) net.algart.math.functions.FuncsetTranslation(ReflectanceSettings.Translation translation) setVersion(String version) toString()static ReflectanceSettingsvalueOf(jakarta.json.JsonObject reflectanceJson) static ReflectanceSettingsvoidwrite(Path reflectanceJsonFile, OpenOption... options) Methods inherited from class net.algart.json.AbstractConvertibleToJson
checkCompleteness, checkNull, checkNull, jsonString, toJsonMethods inherited from class net.algart.json.PropertyChecker
doubleOrDefault, doubleOrNegativeInfinity, doubleOrNull, doubleOrPositiveInfinity, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, greaterThan, inRange, inRange, inRange, inRange, inRange, inRange, intOrDefault, intOrNull, longOrDefault, longOrNull, nonEmpty, nonEmpty, nonEmptyTrimmed, nonEmptyTrimmed, nonLessThan, nonLessThan, nonLessThan, nonLessThan, nonLessThan, nonLessThan, nonNegative, nonNegative, nonNegative, nonNegative, nonNegative, nonNegative, nonNull, nonNull, positive, positive, positive, positive, positive, positive, propertyName
-
Field Details
-
APP_NAME
- See Also:
-
CURRENT_VERSION
- See Also:
-
-
Constructor Details
-
ReflectanceSettings
public ReflectanceSettings() -
ReflectanceSettings
-
-
Method Details
-
read
- Throws:
IOException
-
write
- Throws:
IOException
-
valueOf
-
valueOf
-
isReflectanceJson
public static boolean isReflectanceJson(jakarta.json.JsonObject reflectanceJson) -
getReflectanceJsonFile
-
getVersion
-
setVersion
-
getType
-
setType
-
getTranslation
-
setTranslation
-
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 ofintensityToReflectance(double), providing absolute precision when the translation parameters are specified in terms of 8-bit intensity 0..255, like in the methodReflectanceSettings.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 ofreflectanceToIntensity255(double), providing absolute precision when the translation parameters are specified in terms of 8-bit intensity 0..255, like in the methodReflectanceSettings.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
-
intensityToReflectanceFunc
public net.algart.math.functions.Func intensityToReflectanceFunc(Class<?> intensityElementType, boolean maximalPrecision) -
reflectanceToNormalizedIntensityFunc
public net.algart.math.functions.Func reflectanceToNormalizedIntensityFunc() -
reflectanceToIntensityFunc
-
reflectanceToIntensityFunc
public net.algart.math.functions.Func reflectanceToIntensityFunc(Class<?> intensityElementType, boolean maximalPrecision) -
buildJson
public void buildJson(jakarta.json.JsonObjectBuilder builder) - Specified by:
buildJsonin classnet.algart.json.AbstractConvertibleToJson
-
toString
-