X-Git-Url: https://jasonwoof.com/gitweb/?p=vor.git;a=blobdiff_plain;f=debug.c;h=3153bf3ed2e07cbc73690984888d3fbdcc812d25;hp=20ee5c2fe25fe1502399978fff10a6a7b69976cc;hb=b7de8607ee49edb99979968d5149665bf5590087;hpb=2bea0659b8edff14f1554d2540780f54ccdc21c9 diff --git a/debug.c b/debug.c index 20ee5c2..3153bf3 100644 --- a/debug.c +++ b/debug.c @@ -23,3 +23,27 @@ printf_surface(SDL_Surface *s, char *name) printf("\tpitch = %d;\n", s->pitch); printf("};\n"); } + +void +printb(uint32_t n, int bits) +{ + int i; + + for(i=0; ih; i++) { + for(j=0; jmw-1; j++) printb(s->mask[s->mw*i+j], 32); + printb(s->mask[s->mw*i+j], s->w % 32); + putchar('\n'); + } + putchar('\n'); +}