@UnstableApi
public final class SurfaceInfo


Immutable value class for a Surface and supporting information.

Summary

Public fields

final int

The height of frames rendered to the surface, in pixels.

final boolean

Whether the surface is an encoder input surface.

final int

A counter-clockwise rotation to apply to frames before rendering them to the surface.

final Surface

The Surface.

final int

The width of frames rendered to the surface, in pixels.

Public constructors

SurfaceInfo(Surface surface, int width, int height)

Creates a new instance.

SurfaceInfo(
    Surface surface,
    int width,
    int height,
    int orientationDegrees
)

Creates a new instance.

SurfaceInfo(
    Surface surface,
    int width,
    int height,
    int orientationDegrees,
    boolean isEncoderInputSurface
)

Creates a new instance.

Public methods

boolean
int

Public fields

height

public final int height

The height of frames rendered to the surface, in pixels.

isEncoderInputSurface

public final boolean isEncoderInputSurface

Whether the surface is an encoder input surface.

orientationDegrees

public final int orientationDegrees

A counter-clockwise rotation to apply to frames before rendering them to the surface.

Must be 0, 90, 180, or 270 degrees. Default is 0.

surface

public final Surface surface

The Surface.

width

public final int width

The width of frames rendered to the surface, in pixels.

Public constructors

SurfaceInfo

public SurfaceInfo(Surface surface, int width, int height)

Creates a new instance.

SurfaceInfo

public SurfaceInfo(
    Surface surface,
    int width,
    int height,
    int orientationDegrees
)

Creates a new instance.

SurfaceInfo

public SurfaceInfo(
    Surface surface,
    int width,
    int height,
    int orientationDegrees,
    boolean isEncoderInputSurface
)

Creates a new instance.

Public methods

equals

public boolean equals(@Nullable Object o)

hashCode

public int hashCode()