Parcelablepublic final class DummySurface extends Surface
Surface.Parcelable.ClassLoaderCreator<T extends Object>, Parcelable.Creator<T extends Object>Surface.OutOfResourcesException| Modifier and Type | Field | Description |
|---|---|---|
boolean |
secure |
Whether the surface is secure.
|
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUECREATOR, FRAME_RATE_COMPATIBILITY_DEFAULT, FRAME_RATE_COMPATIBILITY_FIXED_SOURCE, ROTATION_0, ROTATION_180, ROTATION_270, ROTATION_90| Modifier and Type | Method | Description |
|---|---|---|
static boolean |
isSecureSupported(Context context) |
Returns whether the device supports secure dummy surfaces.
|
static DummySurface |
newInstanceV17(Context context,
boolean secure) |
Returns a newly created dummy surface.
|
void |
release() |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, waitdescribeContents, finalize, isValid, lockCanvas, lockHardwareCanvas, readFromParcel, setFrameRate, toString, unlockCanvas, unlockCanvasAndPost, writeToParcelpublic static boolean isSecureSupported(Context context)
context - Any Context.public static DummySurface newInstanceV17(Context context, boolean secure)
release()
when it's no longer required.
Must only be called if Util.SDK_INT is 17 or higher.
context - Any Context.secure - Whether a secure surface is required. Must only be requested if isSecureSupported(Context) returns true.IllegalStateException - If a secure surface is requested on a device for which isSecureSupported(Context) returns false.