This is an automated email from the ASF dual-hosted git repository. desruisseaux pushed a commit to branch geoapi-4.0 in repository https://gitbox.apache.org/repos/asf/sis.git
The following commit(s) were added to refs/heads/geoapi-4.0 by this push: new 5413eb996a Fix a NullPointerException caused by null ColorModel at rendering time in JavaFX application. 5413eb996a is described below commit 5413eb996aaa124deed69f290f85c2e41fd0e95d Author: Martin Desruisseaux <martin.desruisse...@geomatys.com> AuthorDate: Wed Sep 28 18:04:18 2022 +0200 Fix a NullPointerException caused by null ColorModel at rendering time in JavaFX application. --- .../org/apache/sis/internal/coverage/j2d/ColorModelType.java | 9 +++++---- .../java/org/apache/sis/internal/coverage/j2d/package-info.java | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/core/sis-feature/src/main/java/org/apache/sis/internal/coverage/j2d/ColorModelType.java b/core/sis-feature/src/main/java/org/apache/sis/internal/coverage/j2d/ColorModelType.java index 4c535650a6..dec0255e18 100644 --- a/core/sis-feature/src/main/java/org/apache/sis/internal/coverage/j2d/ColorModelType.java +++ b/core/sis-feature/src/main/java/org/apache/sis/internal/coverage/j2d/ColorModelType.java @@ -27,7 +27,7 @@ import java.awt.image.IndexColorModel; * for performance reasons. * * @author Martin Desruisseaux (Geomatys) - * @version 1.1 + * @version 1.3 * @since 1.1 * @module */ @@ -47,15 +47,16 @@ public enum ColorModelType { INDEXED(true, false), /** - * Color model use colors computed on the fly from floating point values. + * Color model uses colors computed on the fly from floating point values. * This model is inefficient and should be changed if possible. */ SCALED(true, true), /** - * Unrecognized color model. + * Unrecognized color model. Includes the case where the color model is null. + * Must be flagged as "slow" for forcing the creation of a new color model. */ - OTHER(false, false); + OTHER(false, true); /** * Whether the color model uses a color palette. diff --git a/core/sis-feature/src/main/java/org/apache/sis/internal/coverage/j2d/package-info.java b/core/sis-feature/src/main/java/org/apache/sis/internal/coverage/j2d/package-info.java index c98ff3f480..b3a3a342e2 100644 --- a/core/sis-feature/src/main/java/org/apache/sis/internal/coverage/j2d/package-info.java +++ b/core/sis-feature/src/main/java/org/apache/sis/internal/coverage/j2d/package-info.java @@ -27,7 +27,7 @@ * may change in incompatible ways in any future version without notice. * * @author Johann Sorel (Geomatys) - * @version 1.2 + * @version 1.3 * @since 1.0 * @module */