JNGL
Namespaces | Functions
shapes.hpp File Reference

Functions for drawing shapes. More...

#include "Color.hpp"
#include "Vec2.hpp"
Include dependency graph for shapes.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 jngl
 JNGL's main namespace.
 

Functions

void setColor (jngl::Color rgb)
 Sets the color which should be used to draw primitives. More...
 
void setColor (jngl::Color, unsigned char alpha)
 
void setColor (unsigned char red, unsigned char green, unsigned char blue)
 
void setColor (unsigned char red, unsigned char green, unsigned char blue, unsigned char alpha)
 
void setAlpha (uint8_t alpha)
 Sets the alpha value which should be used to draw primitives (0 = fully transparent, 255 = fully opaque)
 
void pushAlpha (unsigned char alpha)
 
void popAlpha ()
 
void setLineWidth (float width)
 
void drawLine (Vec2 start, Vec2 end)
 
void drawLine (double xstart, double ystart, double xend, double yend)
 
void drawEllipse (float xmid, float ymid, float width, float height, float startAngle=0)
 
void drawEllipse (Vec2, float width, float height, float startAngle=0)
 
void drawCircle (Vec2, float radius, float startAngle=0)
 
void drawPoint (double x, double y)
 
void drawTriangle (Vec2 a, Vec2 b, Vec2 c)
 
void drawTriangle (double A_x, double A_y, double B_x, double B_y, double C_x, double C_y)
 
void drawRect (double xposition, double yposition, double width, double height)
 
void drawRect (Vec2 position, Vec2 size)
 Draws a rectangle at position. More...
 
template<class Vect >
void drawRect (Vect pos, Vect size)
 

Detailed Description

Functions for drawing shapes.

Definition in file shapes.hpp.