/**@class android.graphics.YuvImage @extends java.lang.Object YuvImage contains YUV data and provides a method that compresses a region of the YUV data to a Jpeg. The YUV data should be provided as a single byte array irrespective of the number of image planes in it. Currently only ImageFormat.NV21 and ImageFormat.YUY2 are supported. To compress a rectangle region in the YUV data, users have to specify the region by left, top, width and height. */ var YuvImage = { /**Compress a rectangle region in the YuvImage to a jpeg. Only ImageFormat.NV21 and ImageFormat.YUY2 are supported for now. @param {Object {Rect}} rectangle The rectangle region to be compressed. The medthod checks if rectangle is inside the image. Also, the method modifies rectangle if the chroma pixels in it are not matched with the luma pixels in it. @param {Number} quality Hint to the compressor, 0-100. 0 meaning compress for small size, 100 meaning compress for max quality. @param {Object {OutputStream}} stream OutputStream to write the compressed data. @return {Boolean} True if the compression is successful. @throws IllegalArgumentException if rectangle is invalid; quality is not within [0, 100]; or stream is null. */ compressToJpeg : function( ) {}, /** @return {Number} the YUV data. */ getYuvData : function( ) {}, /** @return {Number} the YUV format as defined in {@link ImageFormat}. */ getYuvFormat : function( ) {}, /** @return {Number} the number of row bytes in each image plane. */ getStrides : function( ) {}, /** @return {Number} the width of the image. */ getWidth : function( ) {}, /** @return {Number} the height of the image. */ getHeight : function( ) {}, };