Skip to content

Most visited

Recently visited

navigation
Added in API level 1
Deprecated since API level 21

Camera.Size

public class Camera.Size
extends Object

java.lang.Object
   ↳ android.hardware.Camera.Size


This class was deprecated in API level 21.
We recommend using the new android.hardware.camera2 API for new applications.

Image size (width and height dimensions).

Summary

Fields

public int height

height of the picture

public int width

width of the picture

Public constructors

Camera.Size(int w, int h)

Sets the dimensions for pictures.

Public methods

boolean equals(Object obj)

Compares obj to this size.

int hashCode()

Returns an integer hash code for this object.

Inherited methods

From class java.lang.Object

Fields

height

Added in API level 1
int height

height of the picture

width

Added in API level 1
int width

width of the picture

Public constructors

Camera.Size

Added in API level 1
Camera.Size (int w, 
                int h)

Sets the dimensions for pictures.

Parameters
w int: the photo width (pixels)
h int: the photo height (pixels)

Public methods

equals

Added in API level 1
boolean equals (Object obj)

Compares obj to this size.

Parameters
obj Object: the object to compare this size with.
Returns
boolean true if the width and height of obj is the same as those of this size. false otherwise.

hashCode

Added in API level 1
int hashCode ()

Returns an integer hash code for this object. By contract, any two objects for which equals(Object) returns true must return the same hash code value. This means that subclasses of Object usually override both methods or neither method.

Note that hash values must not change over time unless information used in equals comparisons also changes.

See Writing a correct hashCode method if you intend implementing your own hashCode method.

Returns
int this object's hash code.
This site uses cookies to store your preferences for site-specific language and display options.

Hooray!

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.