Class libxl.JxlBasicInfo

java.lang.Object
gov.nih.mipav.model.file.libxl.JxlBasicInfo
Enclosing class:
libxl

class libxl.JxlBasicInfo extends Object
Basic image information. This information is available from the file signature and first part of the codestream header.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    (package private) int
    Bit depth of the encoded alpha channel, or 0 if there is no alpha channel.
    (package private) int
    Alpha channel floating point exponent bits, or 0 if they are unsigned.
    (package private) boolean
    Whether the alpha channel is premultiplied.
    (package private) libxl.JxlAnimationHeader
    Animation header with global animation properties for all frames, only used if have_animation is JXL_TRUE.
    (package private) int
    Original image color channel bit depth.
    (package private) int
    Original image color channel floating point exponent bits, or 0 if they are unsigned integer.
    (package private) boolean
    Indicates animation frames exist in the codestream.
    (package private) boolean
    Whether the codestream is embedded in the container format.
    (package private) boolean
    Indicates a preview image exists near the beginning of the codestream.
    (package private) float
    Upper bound on the intensity level present in the image in nits.
    (package private) int
    Intrinsic width of the image.
    (package private) int
    Intrinsic height of the image.
    (package private) float
    The tone mapping will leave unchanged (linear mapping) any pixels whose brightness is strictly below this.
    (package private) float
    Lower bound on the intensity level present in the image.
    (package private) int
    Number of color channels encoded in the image, this is either 1 for grayscale data, or 3 for colored data.
    (package private) int
    Number of additional image channels.
    (package private) libxl.JxlOrientation
    Image orientation, value 1-8 matching the values used by JEITA CP-3451C (Exif version 2.3).
    (package private) byte[]
    Padding for forwards-compatibility, in case more fields are exposed in a future version of the library.
    (package private) libxl.JxlPreviewHeader
    Dimensions of encoded preview image, only used if have_preview is JXL_TRUE.
    (package private) boolean
    See the description of @see linear_below.
    (package private) boolean
    Whether the data in the codestream is encoded in the original color profile that is attached to the codestream metadata header, or is encoded in an internally supported absolute color space (which the decoder can always convert to linear or non-linear sRGB or to XYB).
    (package private) int
    Width of the image in pixels, before applying orientation.
    (package private) int
    Height of the image in pixels, before applying orientation.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • have_container

      boolean have_container
      Whether the codestream is embedded in the container format. If true, metadata information and extensions may be available in addition to the codestream.
    • xsize

      int xsize
      Width of the image in pixels, before applying orientation.
    • ysize

      int ysize
      Height of the image in pixels, before applying orientation.
    • bits_per_sample

      int bits_per_sample
      Original image color channel bit depth.
    • exponent_bits_per_sample

      int exponent_bits_per_sample
      Original image color channel floating point exponent bits, or 0 if they are unsigned integer. For example, if the original data is half-precision (binary16) floating point, bits_per_sample is 16 and exponent_bits_per_sample is 5, and so on for other floating point precisions.
    • intensity_target

      float intensity_target
      Upper bound on the intensity level present in the image in nits. For unsigned integer pixel encodings, this is the brightness of the largest representable value. The image does not necessarily contain a pixel actually this bright. An encoder is allowed to set 255 for SDR images without computing a histogram. Leaving this set to its default of 0 lets libjxl choose a sensible default value based on the color encoding.
    • min_nits

      float min_nits
      Lower bound on the intensity level present in the image. This may be loose, i.e. lower than the actual darkest pixel. When tone mapping, a decoder will map [min_nits, intensity_target] to the display range.
    • relative_to_max_display

      boolean relative_to_max_display
      See the description of @see linear_below.
    • linear_below

      float linear_below
      The tone mapping will leave unchanged (linear mapping) any pixels whose brightness is strictly below this. The interpretation depends on relative_to_max_display. If true, this is a ratio [0, 1] of the maximum display brightness [nits], otherwise an absolute brightness [nits].
    • uses_original_profile

      boolean uses_original_profile
      Whether the data in the codestream is encoded in the original color profile that is attached to the codestream metadata header, or is encoded in an internally supported absolute color space (which the decoder can always convert to linear or non-linear sRGB or to XYB). If the original profile is used, the decoder outputs pixel data in the color space matching that profile, but doesn't convert it to any other color space. If the original profile is not used, the decoder only outputs the data as sRGB (linear if outputting to floating point, nonlinear with standard sRGB transfer function if outputting to unsigned integers) but will not convert it to the original color profile. The decoder also does not convert to the target display color profile. To convert the pixel data produced by the decoder to the original color profile, one of the JxlDecoderGetColor* functions needs to be called with ::JXL_COLOR_PROFILE_TARGET_DATA to get the color profile of the decoder output, and then an external CMS can be used for conversion. Note that for lossy compression, this should be set to false for most use cases, and if needed, the image should be converted to the original color profile after decoding, as described above.
    • have_preview

      boolean have_preview
      Indicates a preview image exists near the beginning of the codestream. The preview itself or its dimensions are not included in the basic info.
    • have_animation

      boolean have_animation
      Indicates animation frames exist in the codestream. The animation information is not included in the basic info.
    • orientation

      Image orientation, value 1-8 matching the values used by JEITA CP-3451C (Exif version 2.3).
    • num_color_channels

      int num_color_channels
      Number of color channels encoded in the image, this is either 1 for grayscale data, or 3 for colored data. This count does not include the alpha channel or other extra channels. To check presence of an alpha channel, such as in the case of RGBA color, check alpha_bits != 0. If and only if this is 1, the @ref JxlColorSpace in the @ref JxlColorEncoding is ::JXL_COLOR_SPACE_GRAY.
    • num_extra_channels

      int num_extra_channels
      Number of additional image channels. This includes the main alpha channel, but can also include additional channels such as depth, additional alpha channels, spot colors, and so on. Information about the extra channels can be queried with @ref JxlDecoderGetExtraChannelInfo. The main alpha channel, if it exists, also has its information available in the alpha_bits, alpha_exponent_bits and alpha_premultiplied fields in this @ref JxlBasicInfo.
    • alpha_bits

      int alpha_bits
      Bit depth of the encoded alpha channel, or 0 if there is no alpha channel. If present, matches the alpha_bits value of the JxlExtraChannelInfo associated with this alpha channel.
    • alpha_exponent_bits

      int alpha_exponent_bits
      Alpha channel floating point exponent bits, or 0 if they are unsigned. If present, matches the alpha_bits value of the JxlExtraChannelInfo associated with this alpha channel. integer.
    • alpha_premultiplied

      boolean alpha_premultiplied
      Whether the alpha channel is premultiplied. Only used if there is a main alpha channel. Matches the alpha_premultiplied value of the JxlExtraChannelInfo associated with this alpha channel.
    • preview

      Dimensions of encoded preview image, only used if have_preview is JXL_TRUE.
    • animation

      Animation header with global animation properties for all frames, only used if have_animation is JXL_TRUE.
    • intrinsic_xsize

      int intrinsic_xsize
      Intrinsic width of the image. The intrinsic size can be different from the actual size in pixels (as given by xsize and ysize) and it denotes the recommended dimensions for displaying the image, i.e. applications are advised to resample the decoded image to the intrinsic dimensions.
    • intrinsic_ysize

      int intrinsic_ysize
      Intrinsic height of the image. The intrinsic size can be different from the actual size in pixels (as given by xsize and ysize) and it denotes the recommended dimensions for displaying the image, i.e. applications are advised to resample the decoded image to the intrinsic dimensions.
    • padding

      byte[] padding
      Padding for forwards-compatibility, in case more fields are exposed in a future version of the library.
  • Constructor Details

    • JxlBasicInfo

      JxlBasicInfo()