CELL: improve twiddling/untwiddling error text
authorRobert Ellison <papillo@tungstengraphics.com>
Thu, 20 Nov 2008 17:00:51 +0000 (10:00 -0700)
committerRobert Ellison <papillo@tungstengraphics.com>
Thu, 20 Nov 2008 17:01:21 +0000 (10:01 -0700)
As suggested by Brian Paul: in the case of a twiddling error, instead
of reporting the bad format number (which is all but unusable), report
the more useful enum name.

src/gallium/drivers/cell/ppu/cell_texture.c

index 47cd9605c85a87577e91d3b0bd0c7f400ce70547..9f83ab8fa4cfc0f237e94403c723b497aa881456 100644 (file)
@@ -338,7 +338,7 @@ cell_twiddle_texture(struct pipe_screen *screen,
       }
       break;
    default:
-      printf("Cell: twiddle unsupported texture format 0x%x\n", ct->base.format);
+      printf("Cell: twiddle unsupported texture format %s\n", pf_name(ct->base.format));
       ;
    }
 
@@ -384,7 +384,7 @@ cell_untwiddle_texture(struct pipe_screen *screen,
    default:
       {
          ct->untiled_data[level] = NULL;
-         printf("Cell: untwiddle unsupported texture format 0x%x\n", ct->base.format);
+         printf("Cell: untwiddle unsupported texture format %s\n", pf_name(ct->base.format));
       }
    }