pub fn draw(self, drawer: &mut Drawer){
        let QuadDrawer{quad, pos: (x, y), sin_cos: (sin, cos)} = self;

        let uniforms = uniform! {
            h_size : drawer.graphics.h_size,
            matrix: [
                [ cos, sin, 0., 0.],
                [-sin, cos, 0., 0.],
                [  0.,  0., 1., 0.],
                [  x ,  y , 0., 1.],
            ]
        };

        // If this panics, it is a problem with korome
        drawer.draw(&quad.vertex_buffer, &drawer.graphics.indices, &drawer.graphics.colour_program, &uniforms, &drawer.graphics.params)
            .expect("draw failed")
    }
/// Consumes self and draws the rectangle to the screen with the given options
Consumes self and draws the rectangle to the screen with the given options
Consumes self and draws the rectangle to the screen with the given options
pub fn draw(self, drawer: &mut Drawer){
        let QuadDrawer{quad, pos: (x, y), sin_cos: (sin, cos)} = self;
        let uniforms = uniform! {
            h_size : drawer.graphics.h_size,
            matrix: [
                [ cos, sin, 0., 0.],
                [-sin, cos, 0., 0.],
                [  0.,  0., 1., 0.],
                [  x ,  y , 0., 1.],
            ]
        };
        // If this panics, it is a problem with korome
        drawer.draw(&quad.vertex_buffer, &drawer.graphics.indices, &drawer.graphics.colour_program, &uniforms, &drawer.graphics.params)
            .expect("draw failed")
    }
pub fn draw ( self , drawer : & mut Drawer ) { let QuadDrawer { quad , pos : ( x , y ) , sin_cos : ( sin , cos ) } = self ; let uniforms = uniform ! { h_size drawer graphics h_size matrix [ [ cos sin 0. 0. ] [ sin cos 0. 0. ] [ 0. 0. 1. 0. ] [ x y 0. 1. ] ] } ; // If this panics, it is a problem with korome drawer . draw ( & quad . vertex_buffer , & drawer . graphics . indices , & drawer . graphics . colour_program , & uniforms , & drawer . graphics . params ) . expect ( " " ) }
Consumes self and draws the rectangle to the screen with the given options
Consumes self and draws the rectangle to the screen with the given options
self
drawer
&mut Drawer
self
drawer
&mut Drawer