]> git.mxchange.org Git - flightgear.git/commitdiff
obj.cxx: use more explicit parenthases.
authorcurt <curt>
Thu, 20 Aug 1998 15:16:43 +0000 (15:16 +0000)
committercurt <curt>
Thu, 20 Aug 1998 15:16:43 +0000 (15:16 +0000)
texload.[ch]: use const in function definitions where appropriate.

Scenery/obj.cxx
Scenery/texload.c
Scenery/texload.h

index 60fbea0b575dd4108d93456f16e8a973d66fd8eb..1a2e3d2657af7b5ea58a523338659f7d5ad557f1 100644 (file)
@@ -231,7 +231,7 @@ int fgObjLoad(char *path, fgTILE *t) {
                          "Ack! unknown usemtl name = %s in %s\n",
                          material, path);
            } else {
-               fragment.material_ptr = &(*myfind).second;
+               fragment.material_ptr = &((*myfind).second);
            }
 
            // initialize the fragment transformation matrix
@@ -490,6 +490,10 @@ int fgObjLoad(char *path, fgTILE *t) {
 
 
 // $Log$
+// Revision 1.23  1998/08/20 15:16:43  curt
+// obj.cxx: use more explicit parenthases.
+// texload.[ch]: use const in function definitions where appropriate.
+//
 // Revision 1.22  1998/08/20 15:12:03  curt
 // Used a forward declaration of classes fgTILE and fgMATERIAL to eliminate
 // the need for "void" pointers and casts.
index c3e62c1ecc8cc298253a91f4bc6bc1b3aa961412..e6ebbb137c935ff3251ffbdfea4cb636584544a2 100644 (file)
@@ -73,7 +73,7 @@ ConvertUint(unsigned *array, unsigned int length) {
     }
 }
 
-static ImageRec *ImageOpen(char *fileName)
+static ImageRec *ImageOpen(const char *fileName)
 {
      union {
        int testWord;
@@ -182,7 +182,7 @@ ImageGetRow(ImageRec *image, unsigned char *buf, int y, int z) {
 }
 
 GLubyte *
-read_alpha_texture(char *name, int *width, int *height)
+read_alpha_texture(const char *name, int *width, int *height)
 {
     unsigned char *base, *lptr;
     ImageRec *image;
@@ -215,7 +215,7 @@ read_alpha_texture(char *name, int *width, int *height)
 }
 
 GLubyte *
-read_rgb_texture(char *name, int *width, int *height)
+read_rgb_texture(const char *name, int *width, int *height)
 {
     unsigned char *base, *ptr;
     unsigned char *rbuf, *gbuf, *bbuf, *abuf;
index 3581102729955aa83555fe4c84a3bc481131889b..e15e025cfbad91a453ce9e8660482349516f8c1f 100644 (file)
@@ -18,8 +18,8 @@ extern "C" {
 #endif                                   
 
 
-extern GLubyte *read_alpha_texture(char *name, int *width, int *height);
-extern GLubyte * read_rgb_texture(char *name, int *width, int *height);
+extern GLubyte *read_alpha_texture(const char *name, int *width, int *height);
+extern GLubyte * read_rgb_texture(const char *name, int *width, int *height);
 
 
 #ifdef __cplusplus