Métodos para el tratamiento de imagen de salida. Más...
Métodos públicos estáticos | |
static Bitmap | writeBitmap (Pix pixs) |
Writes a Pix to an Android Bitmap object. The output Bitmap will always be in ARGB_8888 format, but the input Pixs may be any bit-depth. | |
static byte[] | writeBytes8 (Pix pixs) |
Write an 8bpp Pix to a flat byte array. | |
static int | writeBytes8 (Pix pixs, byte[] data) |
Write an 8bpp Pix to a flat byte array. | |
static boolean | writeFiles (Pixa pixas, File path, String prefix, int format) |
Writes all the images in a Pixa array to individual files using the specified format. The output file extension will be determined by the format. | |
static boolean | writeImpliedFormat (Pix pixs, File file) |
Writes a Pix to file using the file extension as the output format; supported formats are .jpg or .jpeg for JPEG and .bmp for bitmap. | |
static boolean | writeImpliedFormat (Pix pixs, File file, int quality, boolean progressive) |
Writes a Pix to file using the file extension as the output format; supported formats are .jpg or .jpeg for JPEG and .bmp for bitmap. | |
static byte[] | writeMem (Pix pixs, int format) |
Write a Pix to a byte array using the specified encoding from Constants.IFF_*. | |
Atributos públicos estáticos | |
static final boolean | DEFAULT_PROGRESSIVE = true |
Default JPEG progressive encoding. | |
static final int | DEFAULT_QUALITY = 85 |
Default JPEG quality. | |
Funciones estáticas del 'package' | |
[static initializer] | |
Métodos privados estáticos | |
static native boolean | nativeWriteBitmap (int nativePix, Bitmap bitmap) |
static native int | nativeWriteBytes8 (int nativePix, byte[] data) |
static native boolean | nativeWriteFiles (int nativePix, String rootname, int format) |
static native boolean | nativeWriteImpliedFormat (int nativePix, String fileName, int quality, boolean progressive) |
static native byte[] | nativeWriteMem (int nativePix, int format) |
Métodos para el tratamiento de imagen de salida.
Definición en la línea 36 del archivo WriteFile.java.
com.googlecode.leptonica.android.WriteFile.[static initializer] | ( | ) | [static, package] |
static native boolean com.googlecode.leptonica.android.WriteFile.nativeWriteBitmap | ( | int | nativePix, |
Bitmap | bitmap | ||
) | [static, private] |
static native int com.googlecode.leptonica.android.WriteFile.nativeWriteBytes8 | ( | int | nativePix, |
byte[] | data | ||
) | [static, private] |
static native boolean com.googlecode.leptonica.android.WriteFile.nativeWriteFiles | ( | int | nativePix, |
String | rootname, | ||
int | format | ||
) | [static, private] |
static native boolean com.googlecode.leptonica.android.WriteFile.nativeWriteImpliedFormat | ( | int | nativePix, |
String | fileName, | ||
int | quality, | ||
boolean | progressive | ||
) | [static, private] |
static native byte [] com.googlecode.leptonica.android.WriteFile.nativeWriteMem | ( | int | nativePix, |
int | format | ||
) | [static, private] |
static Bitmap com.googlecode.leptonica.android.WriteFile.writeBitmap | ( | Pix | pixs | ) | [static] |
Writes a Pix to an Android Bitmap object. The output Bitmap will always be in ARGB_8888 format, but the input Pixs may be any bit-depth.
pixs | The source image. |
null
on failure Definición en la línea 208 del archivo WriteFile.java.
static byte [] com.googlecode.leptonica.android.WriteFile.writeBytes8 | ( | Pix | pixs | ) | [static] |
Write an 8bpp Pix to a flat byte array.
pixs | The 8bpp source image. |
Definición en la línea 54 del archivo WriteFile.java.
static int com.googlecode.leptonica.android.WriteFile.writeBytes8 | ( | Pix | pixs, |
byte[] | data | ||
) | [static] |
Write an 8bpp Pix to a flat byte array.
pixs | The 8bpp source image. |
data | A byte array large enough to hold the pixels of pixs. |
Definición en la línea 82 del archivo WriteFile.java.
static boolean com.googlecode.leptonica.android.WriteFile.writeFiles | ( | Pixa | pixas, |
File | path, | ||
String | prefix, | ||
int | format | ||
) | [static] |
Writes all the images in a Pixa array to individual files using the specified format. The output file extension will be determined by the format.
Output file names will take the format <path>/<prefix><index>.<extension>
pixas | The source Pixa image array. |
path | The output directory. |
prefix | The prefix to give output files. |
format | The format to use for output files. |
true
on success Definición en la línea 115 del archivo WriteFile.java.
static boolean com.googlecode.leptonica.android.WriteFile.writeImpliedFormat | ( | Pix | pixs, |
File | file | ||
) | [static] |
Writes a Pix to file using the file extension as the output format; supported formats are .jpg or .jpeg for JPEG and .bmp for bitmap.
Uses default quality and progressive encoding settings.
pixs | Source image. |
file | The file to write. |
true
on success Definición en la línea 158 del archivo WriteFile.java.
static boolean com.googlecode.leptonica.android.WriteFile.writeImpliedFormat | ( | Pix | pixs, |
File | file, | ||
int | quality, | ||
boolean | progressive | ||
) | [static] |
Writes a Pix to file using the file extension as the output format; supported formats are .jpg or .jpeg for JPEG and .bmp for bitmap.
Notes:
pixs | Source image. |
file | The file to write. |
quality | (Only for lossy formats) Quality between 1 - 100, 0 for default. |
progressive | (Only for JPEG) Whether to encode as progressive. |
true
on success Definición en la línea 187 del archivo WriteFile.java.
static byte [] com.googlecode.leptonica.android.WriteFile.writeMem | ( | Pix | pixs, |
int | format | ||
) | [static] |
Write a Pix to a byte array using the specified encoding from Constants.IFF_*.
pixs | The source image. |
format | A format from Constants.IFF_*. |
Definición en la línea 138 del archivo WriteFile.java.
final boolean com.googlecode.leptonica.android.WriteFile.DEFAULT_PROGRESSIVE = true [static] |
Default JPEG progressive encoding.
Definición en la línea 45 del archivo WriteFile.java.
final int com.googlecode.leptonica.android.WriteFile.DEFAULT_QUALITY = 85 [static] |
Default JPEG quality.
Definición en la línea 42 del archivo WriteFile.java.