Skip to content

Commit

Permalink
调整轮廓算法中是否为像素点的判断逻辑
Browse files Browse the repository at this point in the history
  • Loading branch information
TakWolf committed Dec 25, 2023
1 parent 8b121ac commit b8f8abb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pixel_font_builder/opentype.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ def _create_outlines(glyph_data: list[list[int]], px_to_units: int) -> list[list
point_group_list = []
for y, glyph_data_row in enumerate(glyph_data):
for x, alpha in enumerate(glyph_data_row):
if alpha > 0:
if alpha != 0:
new_point_group = {(x, y)}
for i, point_group in enumerate(reversed(point_group_list)):
# 遍历方向为右下,因此只需检查左上
Expand Down

0 comments on commit b8f8abb

Please sign in to comment.