Author Topic: For a new project...  (Read 477 times)

Offline MrPlow

  • Prof. Inline
  • *****
  • Posts: 1456
    • View Profile
For a new project...
« on: 2019-Apr-26 »
I am looking to find the best way to have multicoloured fonts (programmically) in GLB without the need for multiple bitmap fonts.

My own idea is create the font like 8-bit character set or UDGs and re-colour as needed.

Anyone else try this or have an idea or tricks up-their-sleeves of how to go about?

Comp:
Speccy-48k, Speccy-128k, Amigas, PCs

Offline Schranz0r

  • Premium User :)
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 5014
  • O Rly?
    • View Profile
Re: For a new project...
« Reply #1 on: 2019-Apr-26 »
White Fontatlas and draw parts of it with polyvector and the color you need.
You can rescale and coloring it that way.
 
I <3 DGArray's :D

PC:
AMD RYzen 7 1700 @3.9Ghz, 16GB HyperX Fury 2666Mhz Ram, ASUS ROG GTX 1060 STRIX 6GB, Windows 10 Pro 64Bit, MSi Tomahawk B350 Mainboard

Offline dreamerman

  • Global Moderator
  • Dr. Type
  • *******
  • Posts: 288
    • View Profile
    • my personal website
Re: For a new project...
« Reply #2 on: 2019-Apr-26 »
I'm doing it as Schranzor described, additionally with PolyVector you have more freedom and can parse special chars differently - for multiline rendering and so on..
Check my source code editor for GLBasic - link

Offline Qedo

  • Mr. Polyvector
  • ***
  • Posts: 165
  • UNUS SED LEO
    • View Profile
Re: For a new project...
« Reply #3 on: 2019-Apr-27 »
MrPlow, see if the program works for you (maybe with some changes)

http://www.glbasic.com/forum/index.php?topic=9108.msg82633#msg82633


Offline MrPlow

  • Prof. Inline
  • *****
  • Posts: 1456
    • View Profile
Re: For a new project...
« Reply #4 on: 2019-Apr-27 »
Thanks guys! I will check that out!
Comp:
Speccy-48k, Speccy-128k, Amigas, PCs

Offline spacefractal

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 3611
    • View Profile
    • Space Fractal
Re: For a new project...
« Reply #5 on: 2019-May-01 »
im did a rutine using bitmap that can scaling in any site. im a that used a mac program to create those font.

Im thinks its was this thread:
http://www.glbasic.com/forum/index.php?topic=9981.0

im have allways used my own font system, so im could uses scaling.
Greedy Mouse - Karma Miwa - Spot Race - CatchOut - Android Extras - is on a vacation trip, home before end of few days in jan.

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10697
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Re: For a new project...
« Reply #6 on: 2019-May-02 »
V16 has true type fonts, and you can set a color, IIRC. However it is quite slow in comparison to bitmap fonts. I'll have to pre-render a bitmap when you load a TTF font.