Class MjpegFileWriter


  • public class MjpegFileWriter
    extends java.lang.Object
    Released under BSD License
    Author:
    monceaux, normenhansen, entrusC
    • Constructor Summary

      Constructors 
      Constructor Description
      MjpegFileWriter​(java.io.File aviFile, int width, int height, double framerate)  
      MjpegFileWriter​(java.io.File aviFile, int width, int height, double framerate, int numFrames)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addImage​(byte[] imagedata)  
      void addImage​(android.graphics.Bitmap image)  
      void addImage​(android.graphics.Bitmap image, float quality)  
      void finishAVI()  
      static byte[] intBytes​(int i)  
      static byte[] shortBytes​(short i)  
      static int swapInt​(int v)  
      static short swapShort​(short v)  
      byte[] writeImageToBytes​(android.graphics.Bitmap image, float quality)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MjpegFileWriter

        public MjpegFileWriter​(java.io.File aviFile,
                               int width,
                               int height,
                               double framerate)
                        throws java.lang.Exception
        Throws:
        java.lang.Exception
      • MjpegFileWriter

        public MjpegFileWriter​(java.io.File aviFile,
                               int width,
                               int height,
                               double framerate,
                               int numFrames)
                        throws java.lang.Exception
        Throws:
        java.lang.Exception
    • Method Detail

      • addImage

        public void addImage​(android.graphics.Bitmap image)
                      throws java.lang.Exception
        Throws:
        java.lang.Exception
      • addImage

        public void addImage​(android.graphics.Bitmap image,
                             float quality)
                      throws java.lang.Exception
        Throws:
        java.lang.Exception
      • addImage

        public void addImage​(byte[] imagedata)
                      throws java.lang.Exception
        Throws:
        java.lang.Exception
      • finishAVI

        public void finishAVI()
                       throws java.lang.Exception
        Throws:
        java.lang.Exception
      • swapInt

        public static int swapInt​(int v)
      • swapShort

        public static short swapShort​(short v)
      • intBytes

        public static byte[] intBytes​(int i)
      • shortBytes

        public static byte[] shortBytes​(short i)
      • writeImageToBytes

        public byte[] writeImageToBytes​(android.graphics.Bitmap image,
                                        float quality)
                                 throws java.lang.Exception
        Throws:
        java.lang.Exception