Class ImageFactory

java.lang.Object
com.flir.thermalsdk.image.ImageFactory

public class ImageFactory extends Object
A factory used to create thermal or visual images instances based on provided path or URI.
  • Method Details

    • createImage

      public static ImageBase createImage(@NotNull @NotNull String absolutePath) throws IOException
      Creates an instance of a class basing on the provided path.
      Parameters:
      absolutePath - an absolute path to the image which will be created
      Returns:
      Returns a created instance of a subclass of ImageBase relevant for provided path.
      Throws:
      IOException - when unable to open file with the specified path
    • createImage

      public static ImageBase createImage(@NotNull @NotNull InputStream stream) throws IOException
      Creates an instance of a class basing on the provided InputStream.
      Parameters:
      stream - an InputStream representing the image which will be created
      Returns:
      Returns a created instance of a subclass of ImageBase relevant for provided stream.
      Throws:
      IOException - when unable to create image from given InputStream
    • createImage

      public static ImageBase createImage(@NotNull @org.jetbrains.annotations.NotNull byte[] data) throws IOException
      Creates an instance of a class basing on the provided byte array.
      Parameters:
      data - a byte array representing the image which will be created
      Returns:
      Returns a created instance of a subclass of ImageBase relevant for provided byte array.
      Throws:
      IOException - when unable to create image from given InputStream