Struct sdl2::rect::Point [] [src]

pub struct Point {
    // some fields omitted
}

Immutable point type, consisting of x and y.

Methods

impl Point
[src]

fn raw(&self) -> *const SDL_Point

fn raw_slice(slice: &[Point]) -> *const SDL_Point

fn from_ll(raw: SDL_Point) -> Point

fn new(x: i32, y: i32) -> Point

fn offset(&self, x: i32, y: i32) -> Point

fn xy(&self) -> (i32, i32)

fn x(&self) -> i32

fn y(&self) -> i32

Trait Implementations

impl Hash for Point
[src]

fn hash<__H: Hasher>(&self, __arg_0: &mut __H)

Feeds this value into the state given, updating the hasher as necessary.

fn hash_slice<H>(data: &[Self], state: &mut H) where H: Hasher
1.3.0

Feeds a slice of this type into the state provided.

impl Debug for Point
[src]

fn fmt(&self, __arg_0: &mut Formatter) -> Result

Formats the value using the given formatter.

impl PartialEq for Point
[src]

fn eq(&self, __arg_0: &Point) -> bool

This method tests for self and other values to be equal, and is used by ==. Read more

fn ne(&self, __arg_0: &Point) -> bool

This method tests for !=.

impl Eq for Point
[src]

impl Clone for Point
[src]

fn clone(&self) -> Point

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)
1.0.0

Performs copy-assignment from source. Read more

impl Copy for Point
[src]

impl From<(i32, i32)> for Point
[src]

fn from((x, y): (i32, i32)) -> Point

Performs the conversion.

impl Into<(i32, i32)> for Point
[src]

fn into(self) -> (i32, i32)

Performs the conversion.