Subversion Repositories Kolibri OS

Rev

Rev 5237 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5237 Rev 5242
Line 321... Line 321...
321
//    float clamp1[4] = { 0.8, 0.75, 0.65, 0.87 }; // 0.8 to 0.86
321
//    float clamp1[4] = { 0.8, 0.75, 0.65, 0.87 }; // 0.8 to 0.86
322
//    float clamp2[4] = { 0.85, 0.85, 0.85, 0.92 };
322
//    float clamp2[4] = { 0.85, 0.85, 0.85, 0.92 };
323
//    float radiuses[4] = { 1.0, 1.1, 1.2, 0.87 };
323
//    float radiuses[4] = { 1.0, 1.1, 1.2, 0.87 };
Line 324... Line 324...
324
    
324
    
325
    
325
    
326
    float scales[4] = { 0.5, 2.0, 0.2, 2 }; // 2,1,1,1
326
    float scales[4] = { 0.69, 2.0, 0.2, 0.5 }; // 2,1,1,1
327
    //float pows[4] = { 45.0, 100.0, 200.0, 22.0 };
327
    //float pows[4] = { 45.0, 100.0, 200.0, 22.0 };
328
    float pows[4] = { 3.0, 7.0, 15.0, 22.0 };
328
    float pows[4] = { 8.0, 7.0, 15.0, 22.0 };
329
    float ks1[4] = { 0.01, 0.05, 1.2, 0.90 }; // 0.75 straight
329
    float ks1[4] = { 0.01, 0.05, 1.2, 0.90 }; // 0.75 straight
330
    float ks2[4] = { -3.75, -2.75, -1.0, -1.0 };
330
    float ks2[4] = { -3.75, -2.75, -1.0, -1.0 };
331
    float pows1[4] = { 1.0, 1.0, 1.0, 1.0 };
331
    float pows1[4] = { 1.0, 1.0, 1.0, 1.0 };
332
    float pows2[4] = { 0.6,  0.6, 1.0, 1.0 };
332
    float pows2[4] = { 0.6,  0.6, 1.0, 1.0 };
333
    float clamp1[4] = { 0.45, 0.69, 0.65, 0.87 }; // 0.8 to 0.86
333
    float clamp1[4] = { 0.65, 0.69, 0.65, 0.87 }; // 0.8 to 0.86
Line 334... Line 334...
334
    float clamp2[4] = { 0.90, 0.75, 0.85, 0.92 };
334
    float clamp2[4] = { 0.85, 0.75, 0.85, 0.92 };
335
    float radiuses[4] = { 0.9667, 0.997, 1.2, 0.87 };
335
    float radiuses[4] = { 0.9667, 0.997, 1.2, 0.87 };
336
    
336
    
337
    float colors_r[4] = { 0.3, 0.997, 1.0, 0.9 };
337
    float colors_r[4] = { 0.15, 0.997, 1.0, 0.4 };
Line 338... Line 338...
338
    float colors_g[4] = { 0.2, 0.875, 1.0, 0.5 };
338
    float colors_g[4] = { 0.10, 0.875, 1.0, 0.6 };
Line 339... Line 339...
339
    float colors_b[4] = { 0.1, 0.763, 1.0, 0.1 };
339
    float colors_b[4] = { 0.05, 0.763, 1.0, 0.8 };
Line 384... Line 384...
384
                }
384
                }
385
            }
385
            }
386
            rs_gen_func_clamp(32+ch, (ch+ch/8)%2 ? 0.0 : 0.0, 1.0);
386
            rs_gen_func_clamp(32+ch, (ch+ch/8)%2 ? 0.0 : 0.0, 1.0);
387
    //        rs_gen_func_set(32+ch, (ch+ch/8)%2 ? 0.5 : 0.0);
387
    //        rs_gen_func_set(32+ch, (ch+ch/8)%2 ? 0.5 : 0.0);
Line -... Line 388...
-
 
388
 
-
 
389
            rs_gen_func_set(96, 1.0);
388
    
390
            
389
            rs_gen_tex_out_rgba_set(0.0, 0.0, 0.0, 0.0);
391
            rs_gen_tex_out_rgba_set(0.0, 0.0, 0.0, 0.0);
-
 
392
            //rs_gen_tex_out_rgba(32+ch, 32+ch, 32+ch, 32+ch, colors_b[font_index_color], colors_g[font_index_color], colors_r[font_index_color], 1.0);
Line 390... Line 393...
390
            rs_gen_tex_out_rgba(32+ch, 32+ch, 32+ch, 32+ch, colors_b[font_index_color], colors_g[font_index_color], colors_r[font_index_color], 1.0);
393
            rs_gen_tex_out_rgba(96, 96, 96, 32+ch, colors_b[font_index_color], colors_g[font_index_color], colors_r[font_index_color], 1.0);
391
            
394
            
Line 392... Line 395...
392
            texture_init(&game.tex_font[font_index_color*64 + ch], char_tex_size, char_tex_size);
395
            texture_init(&game.tex_font[font_index_color*64 + ch], char_tex_size, char_tex_size);
Line 463... Line 466...
463
 
466
 
464
void game_textout(int x, int y, int font_index, char* s) {
467
void game_textout(int x, int y, int font_index, char* s) {
465
    game_textout_adv(&game.framebuffer, x, y, font_index, DRAW_MODE_ALPHA, s);
468
    game_textout_adv(&game.framebuffer, x, y, font_index, DRAW_MODE_ALPHA, s);
Line -... Line 469...
-
 
469
};
-
 
470
 
-
 
471
void game_textout_at_center(int x, int y, int font_index, char *s) {
-
 
472
    x += (GAME_WIDTH - game.tex_font[font_index*64].w*strlen(s))/2; 
-
 
473
    game_textout_adv(&game.framebuffer, x, y, font_index, DRAW_MODE_ALPHA, s);
466
};
474
};
Line -... Line 475...
-
 
475
 
467
 
476
void game_textout_adv(rs_texture_t *dest, int x, int y, int font_index, int draw_mode, char* s) {
468
void game_textout_adv(rs_texture_t *dest, int x, int y, int font_index, int draw_mode, char* s) {
477
    
469
 
478
 
470
    int i = 0;
479
    int i = 0;
471
    while (*s) {
480
    while (*s) {