X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=font.h;h=20f6454558ca9535e908fc23d39eefae8f01b497;hb=53597f45307d8a2120e3a0bbe71797b216e8750b;hp=76e63c85bb11d16f970375253452073875d9d9ea;hpb=6190deb68aa1c9e92ede62ea05c2a755bf5516de;p=carveJwlIkooP6JGAAIwe30JlM.git diff --git a/font.h b/font.h index 76e63c8..20f6454 100644 --- a/font.h +++ b/font.h @@ -169,13 +169,6 @@ void font3d_begin( const char *text, shader_model_font_uMdl( transform ); } else if( render->shader == k_font_shader_world ){ - - - vg_info( "-----\n" ); - for( int i=0; i<4; i++ ){ - vg_info( PRINTF_v4f( prev_mtx[i] ) ); - } - shader_scene_font_uPvmPrev( prev_mtx ); shader_scene_font_uMdl( transform ); } @@ -287,8 +280,10 @@ float font3d_string_width( font3d *font, u32 variant_id, const char *text ) { if( !text ) return 0.0f; float width = 0.0f; + + const u8 *buf = (const u8 *)text; for( int i=0;; i++ ){ - u32 c = text[i]; + u32 c = buf[i]; if(!c) break; ent_glyph *glyph = font3d_glyph( font, variant_id, c );