matrix: unify API, don't use array pointers

This commit is contained in:
emersion 2018-03-15 11:10:56 +01:00
parent b6a3f240c7
commit d26b67cb06
No known key found for this signature in database
GPG key ID: 0FDE7BE0E88F5E48
18 changed files with 172 additions and 167 deletions

View file

@ -23,7 +23,7 @@ void wlr_renderer_end(struct wlr_renderer *r) {
r->impl->end(r);
}
void wlr_renderer_clear(struct wlr_renderer *r, const float (*color)[4]) {
void wlr_renderer_clear(struct wlr_renderer *r, const float color[static 4]) {
r->impl->clear(r, color);
}
@ -36,17 +36,18 @@ struct wlr_texture *wlr_render_texture_create(struct wlr_renderer *r) {
}
bool wlr_render_with_matrix(struct wlr_renderer *r,
struct wlr_texture *texture, const float (*matrix)[16], float alpha) {
struct wlr_texture *texture, const float matrix[static 16],
float alpha) {
return r->impl->render_with_matrix(r, texture, matrix, alpha);
}
void wlr_render_colored_quad(struct wlr_renderer *r,
const float (*color)[4], const float (*matrix)[16]) {
const float color[static 4], const float matrix[static 16]) {
r->impl->render_quad(r, color, matrix);
}
void wlr_render_colored_ellipse(struct wlr_renderer *r,
const float (*color)[4], const float (*matrix)[16]) {
const float color[static 4], const float matrix[static 16]) {
r->impl->render_ellipse(r, color, matrix);
}