Browse Source

fix compile error on gcc/clang

rdb 11 years ago
parent
commit
cd8c6ee37f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      panda/src/gobj/texture.cxx

+ 1 - 1
panda/src/gobj/texture.cxx

@@ -4472,7 +4472,7 @@ do_get_clear_data(const CData *cdata, unsigned char *into) const {
     nassertr(cdata->_num_components == 1, 0);
     nassertr(cdata->_num_components == 1, 0);
     *((unsigned int *)into) =
     *((unsigned int *)into) =
       ((unsigned int)(cdata->_clear_color[0] * 16777215) << 8) +
       ((unsigned int)(cdata->_clear_color[0] * 16777215) << 8) +
-       (unsigned int)max(min(cdata->_clear_color[1], 255), 0);
+       (unsigned int)max(min(cdata->_clear_color[1], (PN_stdfloat)255), (PN_stdfloat)0);
     break;
     break;
 
 
   case T_int:
   case T_int: