Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / A free Bitmap font for you to use with AGK.

Author
Message
=PRoF=
21
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 26th Aug 2011 19:10 Edited at: 27th Aug 2011 18:36


blue_font.zip

The image and extra data text file are both included in the zip file linked above.

It was created using a free app I wrote in Dark Basic Pro. It's been listed on the Work in progress board for a while, but I thought I'd post this here to draw your attention to it.

It would be good to hear feed back as to how fonts generated with the Bitmap Font Creator work in AGK.

Thank you all.

>Edit<

To fix download link in main text.

Attachments

Login to view attachments
Rich Dersheimer
AGK Developer
14
Years of Service
User Offline
Joined: 1st Jul 2009
Location: Inside the box
Posted: 26th Aug 2011 19:51 Edited at: 26th Aug 2011 19:52
Excellent! Here's a test run, including using the AppGameKit command for spacing out text lines.



Attachments

Login to view attachments
Rich Dersheimer
AGK Developer
14
Years of Service
User Offline
Joined: 1st Jul 2009
Location: Inside the box
Posted: 26th Aug 2011 20:03 Edited at: 26th Aug 2011 20:04
Uh, oh. Here's a screen shot off my iPad running the same programs...



Looks like there's a problem somewhere between my PC and iPad.

Attachments

Login to view attachments
Mike Johnson
TGC Developer
21
Years of Service
User Offline
Joined: 13th Sep 2002
Location: United Kingdom
Posted: 26th Aug 2011 21:30
Rich, have you included the font and its text file in your media folder?
Rich Dersheimer
AGK Developer
14
Years of Service
User Offline
Joined: 1st Jul 2009
Location: Inside the box
Posted: 26th Aug 2011 21:39 Edited at: 26th Aug 2011 21:53
Mike, yes, they are in my media folder. And the .png file is obviously making it across the wifi, you can see pieces of it in the iPad screenshot. When I use the default fixed-width font included in AppGameKit, it shows up just fine on both the Mac and iPad players. I'd like to try it with the ariel font that comes with AppGameKit, but I'm not sure where it is.

EDIT: Hmmm, the custom "fun" font that comes with AppGameKit makes it across, but with a bit of black fringing that is not apparent in the windows player. Maybe it has something to do with custom fonts that are not plain white images?



Attachments

Login to view attachments
DVader
20
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 27th Aug 2011 17:49
I tried to download the font to try, but it appears to have been removed.. One thought, I assume the text file included with it is the same as any made in image joiner? In fact, was it made in that or was it made in DB? I have had annoying problems with text files in the past using DB as it put the return feed at the end without me realizing.
I doubt it is that but seems odd one image works ok and another doesn't. I also noticed in the help file it says it has to be a white font, it doesn't mention colourful fonts like the one above. Although again, I can't see why this would cause any problems.

Rich Dersheimer
AGK Developer
14
Years of Service
User Offline
Joined: 1st Jul 2009
Location: Inside the box
Posted: 27th Aug 2011 18:19 Edited at: 27th Aug 2011 18:30
@DVader - the salient point is that the problem only shows up in the program when it's been broadcast on my iPad and not when I'm running the windows executable or when I use the player on my Mac.

EDIT:

I just tried it on my Mac, and the font looks fine, so apparently the problem is only on my iPad. Since I'm using a player that I compiled myself, it's entirely possible that I did it wrong, and the actual AppGameKit player made by TGC could very well have no problem at all with this.

=PRoF=
21
Years of Service
User Offline
Joined: 17th Mar 2003
Location: Milton Keynes, UK
Posted: 27th Aug 2011 18:52 Edited at: 27th Aug 2011 19:00
Firstly, let me apologise for the broken link in the 1st post. The download button in the bottom right worked, but I had missed a zero when I'd copied the link (d'oh!) It's fixed now.

@Rich Dersheimer:
Thanks for this, sadly I don't have anything even vaguely apple flavoured to test this on; although I suppose AppGameKit gives me a valid reason to buy myself a Mac and an iOS device.

@DVader:
I cannot find it in the help section where it says it has to be a white font? I have checked and double checked the page linked to me by KISTech in the other thread which details the specifics of the font format.

The font was created with my Bitmap Font Creator, which has been made using Dark Basic Pro.

Rich Dersheimer
AGK Developer
14
Years of Service
User Offline
Joined: 1st Jul 2009
Location: Inside the box
Posted: 27th Aug 2011 19:02 Edited at: 27th Aug 2011 19:04
=PRoF=, the help file for it is here.

Hmmm... it also says

Quote: "Fully transparent pixels should also contain white in their RGB components."


Not sure what that's about, though.

DVader
20
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 27th Aug 2011 19:19
It also says "The image should contain all white characters surrounded by a transparent alpha channel". I have no idea why, as I would have thought it was being cut up via the text file settings and wouldn't need any specific colour on the text.
It of course could be down to a problem/bug in the ipad player rather than AppGameKit itself, or as you say something you have missed when you compiled it. I couldn't say as I have not looked into that yet, it sounds a little complicated from the little I have read, and I only have windows based systems. I'm not an apple fan, I consider them too restrictive. For instance, if you wrote an app on a mac using AppGameKit and used that to make a windows app, I'm sure Microsoft would have no problems with allowing it for sale.. But I digress.

Rich Dersheimer
AGK Developer
14
Years of Service
User Offline
Joined: 1st Jul 2009
Location: Inside the box
Posted: 27th Aug 2011 20:05
@DVader - I believe the reason for making the characters all white is so that you can color them with the SetTextColor commands. But that really shouldn't stop us from using colored characters to start with.

Paul Johnston
TGC Developer
21
Years of Service
User Offline
Joined: 16th Nov 2002
Location: United Kingdom
Posted: 30th Aug 2011 18:31
The white color requirement is only if you want to use the text color commands, as they can only work properly if the text is white to begin with. The alpha channel is the best way to draw the font over a background, but again is not strictly required.

The iPad error seems to be that the "output subimages.txt" file is not being found, or not transfered, and is assuming the font image is fixed width instead.

To load the arial font simply use LoadImage( "Arial.png" )
Rich Dersheimer
AGK Developer
14
Years of Service
User Offline
Joined: 1st Jul 2009
Location: Inside the box
Posted: 30th Aug 2011 20:31
So, if the "output subimages.txt" file is not being found, or not transferred, is this a bug?

Paul Johnston
TGC Developer
21
Years of Service
User Offline
Joined: 16th Nov 2002
Location: United Kingdom
Posted: 30th Aug 2011 22:07
Took a bit of tracking down but found a bug in non-power of 2 font images on iOS. The fix has been uploaded for a future build.

To work around this you can make your font image a power of 2 pixels in width and height, e.g. 128, 256, 512, or 1024.
Rich Dersheimer
AGK Developer
14
Years of Service
User Offline
Joined: 1st Jul 2009
Location: Inside the box
Posted: 30th Aug 2011 22:38
Thanks, Paul. That's an easy enough work around.

jonaSoft
12
Years of Service
User Offline
Joined: 17th Aug 2011
Location:
Posted: 1st Sep 2011 22:54
It is also possible to do this in ttf AppGameKit?

I saw that I could read dark basic pro sources by ttf files.
DVader
20
Years of Service
User Offline
Joined: 28th Jan 2004
Location:
Posted: 2nd Sep 2011 00:29 Edited at: 2nd Sep 2011 00:29
I'd just like to add this doesn't appear to be ipad specific. I sent my project over to the artist to try, and he got the same problem on his windows 7 PC.


Attachments

Login to view attachments
Rich Dersheimer
AGK Developer
14
Years of Service
User Offline
Joined: 1st Jul 2009
Location: Inside the box
Posted: 2nd Sep 2011 00:45 Edited at: 2nd Sep 2011 12:53
And I could have sworn I saw the problem on my Mac, but then not.

Since Paul gave us the info on powers of two, though - I could have just been accidently testing with a grapic that WAS sized in powers of two, and then with one that wasn't.

I will do some more testing though. And yah, DVader, good catch, it could be the same on all the transmissions.

EDIT: Well, it seems to have worked! I increased the size of the image to 1024 x 1024 and my iPad and iTouch display the characters correctly. And since I just added some empty space, the file size barely increased at all.

Login to post a reply

Server time is: 2024-04-26 19:48:59
Your offset time is: 2024-04-26 19:48:59