Font upscaling

Posted on
  • Hi!

    I've just been having a quick play at trying to sort out the font situation on Bangle.js.

    Basically, it's almost impossible to get a bitmap font in the same style and different sizes, so right now we have different types of fonts for each size, and it doesn't look great. Many folks seem to resort to just upscaling 6x8 to a bigger blocky font.

    It was suggested before that a font could be upscaled, and I thought I'd give it a try with the AdvMAME scale algorithms:

       ###   ###                                                                    
      #   # #   #    ######      ######                                             
        ##      #   ########    ########       #########         #########          
          #  ###   ###     ##  ###    ###      #########         #########          
      #   # #      ##      ##  ##      ##     ###########       ###########         
       ###  #####      ####            ##   #####       ###   #####     #####       
                       ####           ###   ###         ###   ###        ####       
                          ###    #######    ###         ###   ###         ###       
                           ##   #######           ######                  ###       
                   ##      ##  ##                 ######                 ####       
                   ###    ###  ##                 ######                #####       
                    ########   ##########             #####      ##########         
                     ######     #########              ####      #########          
                                                        ###     ##########          
                                            ###         ###   ###                   
                                            ###        ####   ###                   
                                            #####     #####   ###                   
                                              ###########     ###############       
                                               #########       ##############       
                                               #########        #############       
    

    This isn't ideal, but it seems like it could be a possibility - specifically if I made a custom font in higher detail than 6x8 (maybe 8x12) then that would likely upscale a lot better, and we could have acceptable quality 12, 24 and 36 pixel high fonts in the same style.

    Any thoughts?

  • Looks pretty good! If it becomes available I'll try it in my personal flavor of BW Clock. 👍

    I don't really have any more constructive feedback I'm afraid. 😛

    Off topic: Personally I would be interested to try storing custom fonts in storage as mentioned in this GitHub comment to see how that affects loading times.

  • Definitely interested. Even if we ended up with an alternative Vector font it would be worthwhile.
    As you are probably aware, I'm a great fan of the Lato font as I find it attractive and clear.

    Even though I wear prescription glasses anything less than 20 height is fairly difficult for me to read. I used to have 20/20 vision 20 years ago.

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

Font upscaling

Posted by Avatar for Gordon @Gordon

Actions