[cogl/cogl-1.14: 53/174] Make cogl_color_init_from_4fv take a const array
- From: Robert Bragg <rbragg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [cogl/cogl-1.14: 53/174] Make cogl_color_init_from_4fv take a const array
- Date: Tue, 22 Jan 2013 18:35:13 +0000 (UTC)
commit 7654c7cffc89ccba83247915bd111158dbc82d70
Author: Neil Roberts <neil linux intel com>
Date: Fri Oct 19 17:21:35 2012 +0100
Make cogl_color_init_from_4fv take a const array
The passed in array isn't written to so it's more convenient to use if
it is const.
Reviewed-by: Robert Bragg <robert linux intel com>
(cherry picked from commit 87c02670107f00008611cbb0a8cfc97c8b6ea956)
cogl/cogl-color.c | 2 +-
cogl/cogl-color.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/cogl/cogl-color.c b/cogl/cogl-color.c
index b23ef4a..1f9a01e 100644
--- a/cogl/cogl-color.c
+++ b/cogl/cogl-color.c
@@ -108,7 +108,7 @@ cogl_color_set_from_4f (CoglColor *color,
void
cogl_color_init_from_4fv (CoglColor *color,
- float *color_array)
+ const float *color_array)
{
_COGL_RETURN_IF_FAIL (color != NULL);
diff --git a/cogl/cogl-color.h b/cogl/cogl-color.h
index 5bd7936..97d6229 100644
--- a/cogl/cogl-color.h
+++ b/cogl/cogl-color.h
@@ -169,7 +169,7 @@ cogl_color_set_from_4f (CoglColor *color,
*/
void
cogl_color_init_from_4fv (CoglColor *color,
- float *color_array);
+ const float *color_array);
/**
* cogl_color_get_red_byte:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]