renamed values and functions.

This commit is contained in:
hyzboy 2022-02-21 11:18:51 +08:00
parent 125bf163dc
commit eb30999133
4 changed files with 6 additions and 6 deletions

2
CMCore

@ -1 +1 @@
Subproject commit 676554bc86ef3bfa70a798e0d52672ab2ae2f034
Subproject commit 9376568d47e1195a71b67b43d15042765e90cccf

View File

@ -11,7 +11,7 @@ TileFont *GPUDevice::CreateTileFont(FontSource *fs,int limit_count)
{
if(!fs)return(nullptr);
const uint32_t height=hgl_align2(fs->GetCharHeight()+2,4); //上下左右各空一个象素并保证可以被4整除
const uint32_t height=hgl_align_pow2(fs->GetCharHeight()+2,4); //上下左右各空一个象素并保证可以被4整除
if(limit_count<=0)
{

View File

@ -118,8 +118,8 @@ namespace hgl
GetGlyphOutlineW(hdc,ch,ggo,&gm,DWORD(buffer.length()),buffer.data(),&mat);
bmp->metrics_info.w =((gm.gmBlackBoxX+3)>>2)<<2;
bmp->metrics_info.h =((gm.gmBlackBoxY+3)>>2)<<2;
bmp->metrics_info.w =hgl_align_pow2<uint>(gm.gmBlackBoxX,4);
bmp->metrics_info.h =hgl_align_pow2<uint>(gm.gmBlackBoxY,4);
bmp->metrics_info.x =gm.gmptGlyphOrigin.x;
bmp->metrics_info.y =gm.gmptGlyphOrigin.y;

View File

@ -38,7 +38,7 @@ namespace hgl
to_res.Stats(stats,chars_sets.GetData(),chars_sets.GetCount());
if(stats.non_existent>stats.can_free+tile_data->GetFreeCount()) //不存在的字符数量总量>剩余可释放的闲置项+剩余可用的空余tile
if(stats.not_found>stats.can_free+tile_data->GetFreeCount()) //不存在的字符数量总量>剩余可释放的闲置项+剩余可用的空余tile
return(false);
uv_map.ClearData();
@ -46,7 +46,7 @@ namespace hgl
TileObject *to;
FontBitmap *bmp;
if(stats.non_existent>0)
if(stats.not_found>0)
{
tile_data->BeginCommit();
for(const u32char cp:chars_sets)