Main > Software Forum
LED control from Mame--in over my head again?
headkaze:
--- Quote from: Howard_Casto on March 13, 2010, 09:49:09 pm ---Well I'm currently buttoning up the display files and getting their webpage ready. Then I need to setup an examples page.
Right now I'm currently trying to implement proper 7-segment display support for the display files like mame does. Having issues with the renderer though.
--- End quote ---
There are 7-segment fonts you can get for Windows in ttf format. Probably the easiest way to output numbers like that.
Howard_Casto:
Not really. The numbers mame outputs are the raw bits you would send to a digit controller via serial connection.
So you Don't get a "0" or a "1" you get a "63" and a "6" respectively. Now I've already looked at the mame source and figured out the parsing, and like most serial devices it's just a one byte value and increasing powers of 2 indicate the state of led bars 0-6 up until digit 128, in which all of the positions are repeated, but with the decimal point lit.
Now one might say "but isn't 0-9 all you need?" Wel for most games it is and that's why I still managed to release the display files I did, using traditional numbered images, but some games also use letters and even shapes. I have a dragon's lair scorebaord ready to go, but seeing as how it uses so many shapes and also text in the game it really makes more sense to try to at least make an image generator rather than using a font and a 255 position translation file.
Also I don't like the way fonts look... they look, well, like fonts! I made a very nice digit in photoshop added a subtle glow, and it looks photo-realistic. I even made it greyscale so that it can be colored, like mame's digits are. The problem is masking off the individual digits. Since they have those little points on the edges I can't just use a rectangle. Now I could make each segment a seperate image and layer them, but the idea was someone could take a picture of a scoreboard displaying an "8" and then take another picture with it off and make a font out of it. This could be used in the mame artwork files as well, seeing as you can hook the outputs up to a series of numbered images just as easily as you can the built in digit renderer.
Long story short, yeah you are right there are easier ways to do it, but I want to try to do a really nice job of it. I might end up puting this to the side for now though.
headkaze:
I'm not sure what drawing API you're using but I would imagine you could use rectangles if you have alpha channel support.
1UP:
Howard, I'm watching your site every day for a new release. You're going to kill me with this display stuff you know. Where am I going to find room for a second monitor on my cab? :D
Howard_Casto:
--- Quote from: headkaze on March 15, 2010, 11:24:05 am ---I'm not sure what drawing API you're using but I would imagine you could use rectangles if you have alpha channel support.
--- End quote ---
Well I'm trying not to use an alpha channel at all, that way if it's an odd scoreboard, (I've seen some with gel coloring half-way across the numbers ect...) It'll still work well. I'm still trying to determine the simplest way for the user to make a font, once I figure that out I'll proceed with getting it working.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version