Changes cogl_rectangle to take x1, y1, x2, y2 args not x1, y1, width, height

This makes it consistent with cogl_rectangle_with_{multi,}texture_coords.
Notably the reason cogl_rectangle_with_{multi,}texture_coords wasn't changed
instead is that the former approach lets you describe back facing rectangles.
(though technically you could pass negative width/height values to achieve
 this; it doesn't seem as neat.)
This commit is contained in:
Robert Bragg
2009-01-28 14:47:03 +00:00
parent 1d86b04e06
commit c4b4500059
5 changed files with 31 additions and 26 deletions

View File

@ -45,14 +45,13 @@ void _cogl_path_fill_nodes ();
void _cogl_path_stroke_nodes ();
void
cogl_rectangle (float x,
float y,
float width,
float height)
cogl_rectangle (float x1,
float y1,
float x2,
float y2)
{
cogl_rectangle_with_multitexture_coords (x, y,
x+width,
y+height,
cogl_rectangle_with_multitexture_coords (x1, y1,
x2, y2,
NULL,
0);
}