[−][src]Struct piston_window::CircleArc
A curved line
Fields
color: [f32; 4]
The arcs color
radius: f64
The radius of the arc (Thickness of the drawing, not the radius of the circle)
start: f64
The start of the arc in radians
end: f64
The end of the arc in radians
resolution: u32
The resolution for the arc.
Implementations
impl CircleArc
[src]
pub fn new(color: [f32; 4], radius: f64, start: f64, end: f64) -> CircleArc
[src]
Creates a new arc
pub fn color(self, value: [f32; 4]) -> CircleArc
[src]
Sets the arcs color.
pub fn radius(self, value: f64) -> CircleArc
[src]
Sets the radius of the arc (Thickness of the arc, not the radius of the circle it wraps)
pub fn start(self, value: f64) -> CircleArc
[src]
Sets the start of the arc (in radians).
pub fn end(self, value: f64) -> CircleArc
[src]
Sets the end of the arc (in radians).
pub fn resolution(self, value: u32) -> CircleArc
[src]
Sets the resolution of the arcs smoothness.
pub fn draw<R, G>(
&self,
rectangle: R,
draw_state: &DrawState,
transform: [[f64; 3]; 2],
g: &mut G
) where
R: Into<[f64; 4]>,
G: Graphics,
[src]
&self,
rectangle: R,
draw_state: &DrawState,
transform: [[f64; 3]; 2],
g: &mut G
) where
R: Into<[f64; 4]>,
G: Graphics,
Draws circle arc using default method.
pub fn draw_tri<R, G>(
&self,
rectangle: R,
draw_state: &DrawState,
transform: [[f64; 3]; 2],
g: &mut G
) where
R: Into<[f64; 4]>,
G: Graphics,
[src]
&self,
rectangle: R,
draw_state: &DrawState,
transform: [[f64; 3]; 2],
g: &mut G
) where
R: Into<[f64; 4]>,
G: Graphics,
Draws circle arc using triangulation.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for CircleArc
[src]
impl Send for CircleArc
[src]
impl Sync for CircleArc
[src]
impl Unpin for CircleArc
[src]
impl UnwindSafe for CircleArc
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Pointable for T
pub const ALIGN: usize
type Init = T
The type for initializers.
pub unsafe fn init(init: <T as Pointable>::Init) -> usize
pub unsafe fn deref<'a>(ptr: usize) -> &'a T
pub unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T
pub unsafe fn drop(ptr: usize)
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,