Project

General

Profile

Revision 307

working on dijkstra for zombies

View differences:

font.c
197 197
        }
198 198
    }
199 199
    // Draw text
200
    for(int16_t newy = 0; newy < newH; ++newy){
200
    for(int16_t x, y, newy = 0; newy < newH; ++newy){
201
        y = inity+newy;
201 202
        for(int16_t newx = 0; newx < newW; ++newx){
203
            x = initx+newx;
204
            if(!(0 <= x && x < graph_get_XRes() &&
205
                 0 <= y && y < graph_get_YRes())) continue;
202 206
            uint8_t a = *(alp_new_buf+newx+newy*newW);
203
            if(a < 0x7F) graph_set_pixel(initx+newx,inity+newy,p->color);
207
            if(a < ALPHA_THRESHOLD) graph_set_pixel(x,y,p->color);
204 208
        }
205 209
    }
206 210
    free(alp_new_buf);

Also available in: Unified diff