Skip to content
com.iristick.smartglass.support.camera2

Class CameraFormat


Deprecated. 
Not maintained anymore. Please use the com.iristick.smartglass.core.camera package instead.

@Deprecated
public final class CameraFormat
extends Object
Constants describing input or output formats of a camera device. These constants have been chosen to not clash with either PixelFormat or ImageFormat, unless they describe the same format.

Field Summary

Modifier and Type Field and Description
static int JPEG
Deprecated. 
Compressed JPEG format.
static int OPAQUE
Deprecated. 
System chooses a format, no alpha bits required.
static int RAW_PRIVATE
Deprecated. 
Private raw camera sensor image format, a single channel image with implementation depedent pixel layout.
static int RGB
Deprecated. 
Uncompressed RGB (8 bits per channel, 24 bits per pixel)
static int RGB565
Deprecated. 
Uncompressed packed RGB (5 bits for red and blue channels, 6 bits for green channel)
static int RGBA
Deprecated. 
Uncompressed RGBA (8 bits per channel, 32 bits per pixel)
static int UNKNOWN
Deprecated. 
Unknown format
static int Y8
Deprecated. 
Single-channel luminance only (8 bits per pixel).
static int YCbCr
Deprecated. 
Uncompressed 4:4:4 interleaved YCbCr.
static int YUY2
Deprecated. 
Uncompressed YUYV (YUY2) format, i.e., 4:2:2 interleaved YCbCr.

Method Summary

Modifier and Type Method and Description
static int getBitsPerPixel(int format)
Deprecated. 
Use this function to retrieve the number of bits per pixel of a CameraFormat.

Methods inherited from class java.lang.Object

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail

UNKNOWN

public static final int UNKNOWN
Deprecated. 
Unknown format

OPAQUE

public static final int OPAQUE
Deprecated. 
System chooses a format, no alpha bits required.

RGB

public static final int RGB
Deprecated. 
Uncompressed RGB (8 bits per channel, 24 bits per pixel)

RGBA

public static final int RGBA
Deprecated. 
Uncompressed RGBA (8 bits per channel, 32 bits per pixel)

RGB565

public static final int RGB565
Deprecated. 
Uncompressed packed RGB (5 bits for red and blue channels, 6 bits for green channel)

Y8

public static final int Y8
Deprecated. 
Single-channel luminance only (8 bits per pixel).

YUY2

public static final int YUY2
Deprecated. 
Uncompressed YUYV (YUY2) format, i.e., 4:2:2 interleaved YCbCr.

YCbCr

public static final int YCbCr
Deprecated. 
Uncompressed 4:4:4 interleaved YCbCr.

JPEG

public static final int JPEG
Deprecated. 
Compressed JPEG format.

RAW_PRIVATE

public static final int RAW_PRIVATE
Deprecated. 

Private raw camera sensor image format, a single channel image with implementation depedent pixel layout.

RAW_PRIVATE is a format for unprocessed raw image buffers coming from an image sensor. The actual structure of buffers of this format is implementation-dependent.

Method Detail

getBitsPerPixel

public static int getBitsPerPixel(int format)
Deprecated. 
Use this function to retrieve the number of bits per pixel of a CameraFormat.
Parameters:
format - A format code.
Returns:
the number of bits per pixel of the given format or -1 if the format doesn't exist or is not supported.