Commit bd3d17c6 authored by Robert Menzel's avatar Robert Menzel

reduced compiler warnings in RGBE loader

parent ecbe0c85
......@@ -8,7 +8,7 @@ Included third-party software:
* Includes OpenGL loader code created by a modified glLoadGen by Jason McKesson.
* Includes GLM by Christophe Riccio.
* Includes data type definitions from libspnav header originally by John Tsiombikas (see mini_spnav.h for details).
* Includes RGBE/Radiance image import by Bruce Walter (code provided 'as-is').
* Includes RGBE/Radiance image import by Bruce Walter (code provided 'as-is') minimally adjusted to reduce compiler warnings.
See LICENSE.TXT for licensing information.
......
......@@ -22,6 +22,9 @@
feel free to modify it to suit your needs.
(Place notice here if you modified the code.)
Ok: Made minimal changes (char* -> const char*) to reduce compiler warnings.
- Robert Menzel mail@renderingpipeline.com
posted to http://www.graphics.cornell.edu/~bjw/
written by Bruce Walter (bjw@graphics.cornell.edu) 5/26/95
based on code written by Greg Ward
......@@ -44,7 +47,7 @@ enum rgbe_error_codes {
};
/* default error routine. change this to change error handling */
static int rgbe_error(int rgbe_error_code, char *msg)
static int rgbe_error(int rgbe_error_code, const char *msg)
{
switch (rgbe_error_code) {
case rgbe_read_error:
......@@ -107,7 +110,7 @@ rgbe2float(float *red, float *green, float *blue, unsigned char rgbe[4])
/* default minimal header. modify if you want more information in header */
int RGBE_WriteHeader(FILE *fp, int width, int height, rgbe_header_info *info)
{
char *programtype = "RGBE";
const char *programtype = "RGBE";
if (info && (info->valid & RGBE_VALID_PROGRAMTYPE))
programtype = info->programtype;
......@@ -133,11 +136,11 @@ int RGBE_WriteHeader(FILE *fp, int width, int height, rgbe_header_info *info)
int RGBE_ReadHeader(FILE *fp, int *width, int *height, rgbe_header_info *info)
{
char buf[128];
int found_format;
//int found_format;
float tempf;
int i;
size_t i;
found_format = 0;
//found_format = 0;
if (info) {
info->valid = 0;
info->programtype[0] = 0;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment