Previous Thread
Next Thread
Print Thread
Page 2 of 2 1 2
Joined: Feb 2014
Posts: 927
Likes: 75
G
Senior Member
Offline
Senior Member
G
Joined: Feb 2014
Posts: 927
Likes: 75
>> GC: I gave you the first reason as a freebie: the paper doesn't care how the print position's being moved, so the steppers should've stayed in the Epson driver and just communicated fractions of an inch or whatever.

so then just have a bitmap representing the paper and not much else, that's cool.

Couldn't I have a dot matrix printer device that has steppers for the carriage, paper feed, ribbon and draws the printhead? Most of the dot matrix printers need those things and it can just use the paper class for the paper bitmap.

Joined: Feb 2021
Posts: 12
T
Member
OP Offline
Member
T
Joined: Feb 2021
Posts: 12
Does MAME have freetype library for handling fonts for daisywheels and mainframe line printers?

Yeah. I reviewed bitmap_printer.cpp but it need some additional coding for daisywheels/line printers. It may need to implement additional PDF routines for producing printouts in PDF file.

Hercules Studio (for IBM mainframe emulator) already do produces printouts in PDF file in line printer emulation. There is Hercules Studio repository on Sourceforge. May take a look on that.

Joined: Mar 2008
Posts: 220
Likes: 4
R
Senior Member
Online Content
Senior Member
R
Joined: Mar 2008
Posts: 220
Likes: 4
I've been scanning Amstrad PCW daisywheels, and I'm trying to make a ttf font out of one of them.

Let's see how it goes laugh

1 member likes this: exidyboy
Joined: Mar 2001
Posts: 16,989
Likes: 84
R
Very Senior Member
Online Content
Very Senior Member
R
Joined: Mar 2001
Posts: 16,989
Likes: 84
MAME does output printer output as a series of PNGs right now, one per page. So you really can get your Print Shop on as-is.

Joined: Feb 2008
Posts: 127
Likes: 5
G
Senior Member
Offline
Senior Member
G
Joined: Feb 2008
Posts: 127
Likes: 5
For initial development work there's plenty of mono-spaced daisywheel-like fonts out there already. For the purpose of emulation it doesn't matter which font is used. Anything close is fine for work in progress and it might be fun to substitute any font you want, selectable from a list of installed fonts. The main thing is use any mono-spaced font and get it working, then you could replace the font with one built from scans of an actual daisywheel or just use the freely available daisywheel font. It takes 3 seconds to find it (i.e. https://www.fonts4free.net/daisy-wheel-font.html). No point wasting days/weeks making new truetype fonts from scratch when the emulation of daisywheel printers isn't even implemented.

Joined: Feb 2021
Posts: 12
T
Member
OP Offline
Member
T
Joined: Feb 2021
Posts: 12
Originally Posted by R. Belmont
MAME does output printer output as a series of PNGs right now, one per page. So you really can get your Print Shop on as-is.


How do I save printouts into PNG file?

Joined: Feb 2014
Posts: 927
Likes: 75
G
Senior Member
Offline
Senior Member
G
Joined: Feb 2014
Posts: 927
Likes: 75
Code
void bitmap_printer_device::write_snapshot_to_file()
{
        machine().popmessage("writing printer snapshot");

        emu_file file(machine().options().snapshot_directory(), OPEN_FLAG_WRITE | OPEN_FLAG_CREATE | OPEN_FLAG_CREATE_PATHS);
        std::error_condition const filerr = machine().video().open_next(file, "png");

        if (!filerr)
        {
                static const rgb_t png_palette[] = { rgb_t::white(), rgb_t::black() };

                // save the paper into a png
                util::png_write_bitmap(file, nullptr, m_page_bitmap, 2, png_palette);
        }
}
you probably don't even need to have the png_palette stuff, I was cribbing from another driver.

Page 2 of 2 1 2

Link Copied to Clipboard
Who's Online Now
4 members (box, Pernod, 2 invisible), 22 guests, and 3 robots.
Key: Admin, Global Mod, Mod
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics9,171
Posts120,123
Members5,039
Most Online1,283
Dec 21st, 2022
Our Sponsor
These forums are sponsored by Superior Solitaire, an ad-free card game collection for macOS and iOS. Download it today!

Superior Solitaire
Forum hosted by www.retrogamesformac.com