Jump to content
  • Advertisement
  • entries
  • comments
  • views

Finished something? What!?

Sign in to follow this  


Ethereal Darkness Interactive Update

I have been drained all day so I took the day off, but never fear! I'll be back on top of things come tomorrow.

Edit: This made it sound like I wasn't doing anything on Project2, but I am, I just didn't do anything earlier. I'm working on some storyline stuff at the moment, trying to get some stuff done to show Raymond.

DragonForge Technology

Thats right, I actually started a project today AND finished it! Well, not totally finished, but it works and I could use it. I decided that I wanted to try to make a bitmap font generator and I did. Its a horrible hack but it lets me choose my fonts, displays a preview, and then lets me save it to a texture (generates alpha channel for me) and stores the x,y coordinates as well as the width and height of the character.

Heres a little screeny for you -

ScreenCap did not add the text, I did that by hand because I may use this screenshot on another website and ScreenCap is awesome

The yellow grid isn't drawn onto the file and the alpha channel is generated using the average of the current pixel's RGB value.

But, now I'm putting it away and sticking with LMNOPC since it isn't a total hack. Mines not entirely finished, but it would be useable in a game, so thats good enough for me (pretty much the only thing not finished is the saving; ATM it just saves to font_texture.png and font_info.txt. Also there is a major bug in the rendering, but it still comes out right so I'm not going to worry about it.)

If anybody is interested in seeing the code just say so and I'll upload it for download. As I said its VERY hacked since I'm new to C# and have absolutely no idea what I'm doing. Also not that you'll probably want to gouge your eyes out soon afterwards because of the awfulness.

I plan to have something nice finished by tomorrow night, depending on what I start for Project2 tonight and if I work or not tomorrow.

That is all.


Other news

Sign in to follow this  


Recommended Comments

What are you writing that with? Judging by the icon me-smells some .NET. [smile]

Share this comment

Link to comment
Yup, I wrote it in .NET. It took around an hour and a half since I had my rendering code messed up (I was rendering to the picturebox instead of the image in the picturebox.)

C# = teh awesomeness when it comes to tool development.

I'll be back home in about an hour and a half, I'm at my brother's now. I've wrote something pretty simple but fun since I forgot my freaking code base at home =/.

Share this comment

Link to comment
Not too bad - have you written the code to import the generated fonts? Additionally, what range of characters does your generated font supply? My framework does something similar at load-time (uses SDL_TTF to generate a complete font texture), but it doesn't really generate a complete character set - just stuff it assumes you'll need.

But yeah. I hate fonts </3

Share this comment

Link to comment
I hacked together an demo earlier just to see if it was outputting it right (and it was), but I didn't code any classes or anything.

I just hardcoded the space to ~ sequence, another reason I'm sticking with LMNOPC. I plan on doing something special with the unused characters on my font's bitmap and I'm too lazy to code my writer so that it arranges things right and uses a properly sized texture. I might attempt it again at a later date (when I've had more practice with C#), but for now LMNOPC will do.

Yea, variable width fonts suck. I don't mind fixed width other than it looks utterly attrocious =/.

@The simple fun thing I wrote - Yea, I'm rewriting this now because me == retarded and coded <snip>revealing statement</snip> something wrong. I'm going to code until I have it done, so you'll see it up here before the morning (unless I'm an utter failure, which I probably am.)

Share this comment

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!