Board index FlightGear Development Aircraft

Use fonts from Aircraft Directory

Questions and discussion about creating aircraft. Flight dynamics, 3d models, cockpits, systems, animation, textures.

Use fonts from Aircraft Directory

Postby Octal450 » Thu Oct 13, 2016 5:40 pm

I have found some nice custom fonts which is GPL, and wants to use in my aircraft. Is it possible to put him inside the aircraft's folder, and use it from there?
Thanks,
Josh
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Use fonts from Aircraft Directory

Postby erik » Fri Oct 14, 2016 10:33 am

As far as I know there are no restrictions regarding using a custom font.
Just use the relative path including "Aircraft/<aircraft-name>" and you should be fine.

Erik
Current: Parachutist, Paraglider, Pterosaur, Pilatus PC-9M and variants, ERCO Ercoupe, Fokker Dr.1, Fokker 50, Fokker 100
Less active: Cessna T-37, T-38, Santa Claus. Previous: General Dynamics F-16. Worked on: Wright Flyer
erik
 
Posts: 2248
Joined: Thu Nov 01, 2007 2:41 pm

Re: Use fonts from Aircraft Directory

Postby Octal450 » Fri Oct 14, 2016 5:10 pm

Awesome stuff, thanks
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Use fonts from Aircraft Directory

Postby Gijs » Fri Oct 14, 2016 6:21 pm

What kind of font is it? If it's something useful for other aircraft (like a font used on an instrument) it'd make sense to add it to the main Fonts/ in fgdata.
Airports: EHAM, EHLE, KSFO
Aircraft: 747-400
User avatar
Gijs
Moderator
 
Posts: 9549
Joined: Tue Jul 03, 2007 3:55 pm
Location: Delft, the Netherlands
Callsign: PH-GYS
Version: Git
OS: Windows 10

Re: Use fonts from Aircraft Directory

Postby Octal450 » Fri Oct 14, 2016 7:56 pm

It's 16segment display all chacaters
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Use fonts from Aircraft Directory

Postby wkitty42 » Fri Oct 14, 2016 9:37 pm

there was some (digital display) segment fonts added to the system sometime in the last 6 to 8 months... have you looked at them? i don't recall their name and have no clue as to how to load and use them in a craft...
"You get more air close to the ground," said Angalo. "I read that in a book. You get lots of air low down, and not much when you go up."
"Why not?" said Gurder.
"Dunno. It's frightened of heights, I guess."
User avatar
wkitty42
 
Posts: 9165
Joined: Fri Feb 20, 2015 4:46 pm
Location: central NC, USA
Callsign: wk42
Version: git next
OS: Kubuntu 22.04

Re: Use fonts from Aircraft Directory

Postby erik » Fri Oct 14, 2016 11:02 pm

That was for 7 and 14 segment fonts:
https://sourceforge.net/p/flightgear/fg ... onts/DSEG/

Erik
Current: Parachutist, Paraglider, Pterosaur, Pilatus PC-9M and variants, ERCO Ercoupe, Fokker Dr.1, Fokker 50, Fokker 100
Less active: Cessna T-37, T-38, Santa Claus. Previous: General Dynamics F-16. Worked on: Wright Flyer
erik
 
Posts: 2248
Joined: Thu Nov 01, 2007 2:41 pm

Re: Use fonts from Aircraft Directory

Postby Octal450 » Sat Oct 15, 2016 4:05 am

I'll take a look.
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Use fonts from Aircraft Directory

Postby Hooray » Sat Oct 15, 2016 10:40 am

I agree with Gijs, please do add useful stuff to the base package, and maybe add an example to the wiki explaining how to use such new fonts
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: Use fonts from Aircraft Directory

Postby Octal450 » Sat Oct 15, 2016 1:43 pm

Don't you use them the same way you use other fonts?
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Use fonts from Aircraft Directory

Postby Octal450 » Fri Nov 04, 2016 8:15 pm

Hi,
This is not working. It goes back to a default font.

Code: Select all
    <text>
        <name>pitch-c1</name>
        <offsets>
            <x-m>0.0015</x-m>
            <y-m>0</y-m>
            <z-m>0.001</z-m>
        </offsets>
        <alignment>center-center</alignment>
        <axis-alignment>yz-plane</axis-alignment>
        <type type="string">text-value</type>
        <format type="string">%s</format>
        <truncate type="bool">false</truncate>
        <font type="string">Aircraft/MD-88/Fonts/MD80FMA.ttf</font>
        <property>/fma/pitch/c1</property>
        <draw-text type="bool">true</draw-text>
        <draw-alignment type="bool">false</draw-alignment>
        <draw-boundingbox type="bool">false</draw-boundingbox>
        <character-size>0.014</character-size>
        <font-resolution>
            <width type="int">32</width>
            <height type="int">32</height>
        </font-resolution>
    </text>


Josh
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Use fonts from Aircraft Directory

Postby erik » Sat Nov 05, 2016 12:53 pm

it0uchpods wrote in Fri Nov 04, 2016 8:15 pm: <font type="string">Aircraft/MD-88/Fonts/MD80FMA.ttf</font>

That's odd, the code for the TextAnimation is no different than the code for text handling in Canvas.

Could you, for a test, try if setting it to DSEG/DSEG7/Classic/DSEG7Classic-BoldItalic.ttf works?
I know for sure that works for Canvas.

Erik
Current: Parachutist, Paraglider, Pterosaur, Pilatus PC-9M and variants, ERCO Ercoupe, Fokker Dr.1, Fokker 50, Fokker 100
Less active: Cessna T-37, T-38, Santa Claus. Previous: General Dynamics F-16. Worked on: Wright Flyer
erik
 
Posts: 2248
Joined: Thu Nov 01, 2007 2:41 pm

Re: Use fonts from Aircraft Directory

Postby Hooray » Sat Nov 05, 2016 9:11 pm

It is a different beast actually - Torsten introduced this several years prior to Canvas (see README.osgtext) - back then, we talked about generalizing the whole idea to support arbitrary textures (for runway skid marks back then), but it never really caught fire until 2012 - so it's definitely a different piece of SG/FG glue that is used, even though it is correct that internally both end up using OSG - but it's not the same code under the hood. In fact, a number of people actually suggested unifying the whole shebang to get rid of old legacy code doing pretty much the same thing (think GUI, 2D panels, HUD, TextAnimation).
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: Use fonts from Aircraft Directory

Postby Octal450 » Sun Nov 06, 2016 12:10 am

@Hooray
No offence, but the whole get rid of everything and switch to Canvas speed is getting irritating.

Canvas is very difficult, and I am just beginning to learn it.

For simple things such as this simple FMA, I don't really want to make the whole thing Canvas, when I can do it easier with OSGtext/AC3D.

I might just fallback and use FlightGears font if I HAVE to. There's got to be a way to this!
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Re: Use fonts from Aircraft Directory

Postby Octal450 » Mon Nov 07, 2016 4:59 pm

I dropped the Fonts into the FlightGear Fonts folder, and They work.

If they can be added to FGdata, it would be nice!

They are both GPL, and are a sixteen segment display font, and a dot matrix font.
Skillset: JSBsim Flight Dynamics, Systems, Canvas, Autoflight/Control, Instrumentation, Animations
Aircraft: A320-family, MD-11, MD-80, Contribs in a few others

Octal450's GitHub|Launcher Catalog
|Airbus Dev Discord|Octal450 Hangar Dev Discord
User avatar
Octal450
 
Posts: 5601
Joined: Tue Oct 06, 2015 1:51 pm
Location: Huntsville, AL
Callsign: WTF411
Version: next
OS: Windows 11

Next

Return to Aircraft

Who is online

Users browsing this forum: No registered users and 17 guests