Interface IConverter

  • All Known Implementing Classes:
    AConverter, ArgbConverter, BgrConverter

    public interface IConverter
    This interface describes a converter which can perform bidirectional translation between a given IVideoPicture type and a BufferedImage type. Converters are created by ConverterFactory. Each converter can translate between any supported IPixelFormat.Type and a single BufferedImage type. Converters can optionally resize images during the conversion process.
    • Method Detail

      • getImageType

        int getImageType()
        Get the image type, as defined by BufferedImage, which this converter recognizes.
        Returns:
        the image type of this converter.
        See Also:
        BufferedImage
      • toPicture

        IVideoPicture toPicture​(java.awt.image.BufferedImage image,
                                long timestamp)
        Converts a BufferedImage to an IVideoPicture.
        Parameters:
        image - the source buffered image.
        timestamp - the time stamp which should be attached to the the video picture (in microseconds).
        Throws:
        java.lang.IllegalArgumentException - if the passed BufferedImage is NULL;
        java.lang.IllegalArgumentException - if the passed BufferedImage is not the correct type. See getImageType().
        java.lang.IllegalArgumentException - if the underlying data buffer of the BufferedImage is composed elements other bytes or integers.
      • getDescription

        java.lang.String getDescription()
        Return a written description of the converter.
        Returns:
        a detailed description of what this converter does.
      • delete

        void delete()
        Release any resources used by this converter. Calls to the converter after this call are illegal and may fail in unspecified ways.