Skip to main content
Topic: New, excellent method for GIF images from NWC (Read 5990 times) previous topic - next topic

New, excellent method for GIF images from NWC

This notice will be of interest to Windows 95/98 users of NWC who want to make sharp GIF images of simple sheet music for display on Internet web pages. I realize that this topic is not new. But what I have here is new. The hyperlink to the necessary software is given below.

The method is free, fast once installed, and relatively no-brainer. It does not require Ghostscript. It is specifically intended to produce images with sharp line art and text from NWC when seen at computer monitor resolution. It would be useful for small compositions, or portions of them, such as church hymns or folk songs. Monitor resolution is just too coarse for complicated compositions.

This method has nothing to do with transmitting MIDI files or NWC compositions intended to be printed as sheet music. Nor does it have anything to do with using a WMF as a placed object within a program such as MS Word. It is strictly about creating GIF images for monitor display via the Internet.

Here is the concept: NWC can export a placeable Windows Metafile (WMF) via File>Print Preview>Copy. The WMF can be directly opened as an image in the free "Irfan View" software, then converted to another format such as GIF. Those of you who regularly follow the NWC Forum already know this.

However, the WMF resolution (dpi) depends upon the resolution of whichever printer has been set up for use by NWC. Typical printer resolutions are multiples of 300 dpi. As a result, the WMF image is too large for display on the Internet, and so it must be scaled down. The end result of starting with a file at the wrong resolution, then scaling it to the correct resolution, results in a fuzzy-looking final product. Small details are often hard to read.

My method is simple: I have created a free "dummy printer" that is installed by the usual method in Windows 95/98. The resolution of this device is optimized for the purpose of creating a web-ready image. Within NWC, the "dummy printer" is set prior to going to Print Preview to create the WMF. The resulting WMF is at monitor resolution and does not need to be re-scaled. All you need to do is open it in Irfan View, crop it if you wish, and save as GIF. The "dummy printer" does allow a wide range of resolutions to be selected, to achieve different effects. However, it cannot be used as a real printer. It is strictly a means of manipulating WMF resolution.

The resulting GIF image has line art that is very sharp, and text that is also very sharp. Some of you may find it a bit jaggedy, but artistic mellowness is not the goal. In many cases, the spacing between staff lines will not be perfectly uniform, but this may happen even when using expensive image processing software.

If you want to try it on a "beta test" basis, then it can be downloaded at:

http://www.scshop.com/~joemusic/dummyres.htm

You will see a sample image on the web page. Remember, "beta test" is not for everybody. But I haven't found any difficulties yet. It is for Windows 95/98, not 3.1. I have no idea whether it would work on NT or ME.


Re: New, excellent method for GIF images from NWC

Reply #2
Joe,

Thanks for an interesting toy. A nice, lateral solution. However, as I reported earlier, this is one problem I haven't been able to reproduce. Indeed, I WANT to get a higher resolution WMF file, but I cannot get it more than screen resolution. What am I doing wrong? I've tried your printer at several resolutions, but still I get exactly the same sized image every time. I even added 600 and 1200 DPI, still no change in the size or resolution of the WMF file generated. What am I doing wrong? Even with real printers capable of 1200 DPI, I can't get Noteworthy to generate a WMF file larger than my screen.

Can someone give me a click by click description of how to get this problem?

Re: New, excellent method for GIF images from NWC

Reply #3
I wouldn't know how to solve the problem of *higher* resolution on WMF. In fact, for all I know the limitation is in the WMF format itself. My solution was to get *lower* resolution.

If you happen to own a high-quality drawing program, it may be able to open the WMF as a drawing object. For example, Adobe Illustrator will do this. Presumably the resulting file can then be manipulated within the drawing application, and saved or printed at a higher resolution.

As for Irfan View, there is a maximum limit on the pixel dimensions it will handle. If you attempt to exceed the size (which would happen at high resolutions) it seems that irfan View downscales the image somehow. I do not know the details.

Remember, folks, my "dummy resolution" is ONLY intended for those of you who wish to make sharp GIF images of line art, such as from NWC. I have tried it within Adobe Illustrator and it also works very nicely for obtaining images (rather than drawings) at screen resolution.

Re: New, excellent method for GIF images from NWC

Reply #4
John,

When you say the image is always the same size - do you mean on your monitor or in a Word document or in a graphics package.

The beauty of WMF is the ability to rescale without distortion (as long as the resolution is suitable).
How does the resolution appear when the image is stretched ( in Word or whatever).

Re: New, excellent method for GIF images from NWC

Reply #5
Joe, that looks like exactly what the doctor ordered for dealing with NWC .wmf files. But I can't seem to get it installed on my system, it finds the .inf file and is obviously reading it since it comes up with "Dummy Resolution" as a printer to install, but when I click Next it tells me "Windows is unable to gather file information for this printer." I've tried different locations for the .inf and the .ppd printer definition files, even tried installing from within the windows/system directory, but no go. Could it be because I already have another printer on the system that uses pscript.drv and psmon.dll? (And no, making it not the default printer doesn't help either.)

Re: New, excellent method for GIF images from NWC

Reply #6
John, why are you wanting to create GIF files -- oh, I understand to be visible from a web browser; but PDF files are smallers, display better, and are just as editable (i.e. practically speaking, not.) PDF files are, I think, about as portable -- who doesn't have and can't get Adobe Acrobat reader and/or Ghostscript? PDF files can be displayed or printed at whatever resolution, and appear sharp but non-jagged.

I've been generating PDF files for the sake of people who don't have NWC (mac / unix users, for instance) -- I publish NWC, PDF, and MIDI files. If someone can't get to _any_ of those, um, it's time to trade the TRS-80 in on a computer.

Re: New, excellent method for GIF images from NWC

Reply #7
John, what are you using to determine the "resolution" of the WMF files that you create. As I explained in another thread, WMF files do not really have resolution, but do have a coordinate system. The actual resolution used to display a WMF file is purely a decision made by the displaying application.

The utility introduced in this thread simply allows you to specify the coordinate system that would be used by NWC when the WMF file is created (since NWC bases the coordinate system on the printer metrics). Whatever you are using to display the WMF, it might just always make the resolution match the screen size.

Re: New, excellent method for GIF images from NWC

Reply #8
Fred: I will contact you by E-mail to discuss installation of the Dummy Resolution device. No doubt there are variations in installation on systems other than my own, and no doubt this problem can be fixed.

Stephen: Indeed, PDF is the right way to transmit sheet music intended for printing, ar larger compositions. The only reason to use GIF is to show an "immediate" music graphic on a web page. But if you size the graphic well, and if it is only one page, the GIF should be readable enough if printed (for something simple such as a folk song or hymn).

John: Noteworthy Support knows what they are talking about regarding what you are trying to do. I can only guess that maybe you are trying to print at higher resolution than is supported by whatever kind of (real) printer you are using. The choices of resolution offered by a printer are determined by the printer driver. For example, I have a (commercial) printer driver that offers up to 2400 dpi resolution, but that's because the actual printer, which is designed for commercial art, will do that. It's useful for magazine-quality color separations, but I cannot see what benefit such resolution would offer for NWC sheet music: 300 dpi is just fine.

Generally, the WMF format is a vector drawing file. When a WMF is opened in a drawing program such as Adobe Illustrator, it remains a vector drawing file. But when opened in Irfan View, the WMF is rasterized to a bitmap image and no longer retains its identity as vector drawing. It is the process of conversion from vector to raster that underlies the usage of "Dummy Resolution."

Re: New, excellent method for GIF images from NWC

Reply #9
Thanks for the suggestions. My "real" target printer is 1200dpi.

The display program I'm using is IrfanView. I follow the directions of saving a WMF file, then open it in IrfanView. No matter what I do it comes out 652x940 pixels. I thought this peculiar as descriptions elsewhere had described the image as being much larger than the screen and having to resample downwards. That Joe found it necessary to dream up his inventive hack to "fix" this problem that I can't reproduce just makes me more curious.

What I was trying to achieve was to import the WMF file into IrfanView at fairly high resolution, export in some other format (maybe TIFF) so I could then import it into a graphic editor to manipulate it.

I've had similar issues with IrfanView importing high resolution images, but that was my mistake, I had "Fit image to Window" selected. I'm using IrfanView V3.25, but I've also tried a few versions back to 3.05 with the same results. It seems to always do "Best fit to desktop" with these files.

Aha! Just tried 60dpi and I now get an image 559x807, so it looks like it's IrfanView doing the resizing. That's odd because I have other large images in different formats (TIFF and JPG) which open at their "correct" size. I've been through the options lots of times but can't find anything which would affect this.

Re: New, excellent method for GIF images from NWC

Reply #10
Yes, there is a downampling issue, but think of the user base. If you own a good drawing program, try importing your WMF there.

In any case, my method for creating "dummy resolution" merely involved hacking a generic Postscript printer description file (editable in Notepad) to allow different resolutions other than the original choices offered. Since there doesn't seem to be much need for this except among those of you who have the samrts to do it yourself, I will remove the software and description of its usage from my web page in the near future.

Re: New, excellent method for GIF images from NWC

Reply #11
It has been discussed elsewhere that importing into Word gives a satisfactory image. If you then save the page as HTML, it automatically converts the image to a GIF. You can then right-click on the image to save the image by itself.

Re: New, excellent method for GIF images from NWC

Reply #12
True. However, I have found that the exported GIF from MS Word (save as HTML) does not have the correct resolution for my needs. Perhaps this is user-definable, but it never gave me the control I wanted. Actually, I have many high-priced image processing programs that suit my own needs just fine, without the need for hacking or work-arounds. But I thought that my "free advice for the low-budgeted" might be useful. If not, ignore it!

Re: New, excellent method for GIF images from NWC

Reply #13
John - rather than speculate on how Irfanview handles .wmf importation, I dropped a line to the author. Here's the scoop (his reference to "height/width info in the header" presumably means that the exporting program puts that there, based on current printer resolution; which explains the interdependance between printer resolution and observed import size of the raster image).

>Hi Irfan,
>
>How does Irfanview deal with .wmf vector files? What determines which
>"resolution" it uses when opening the file? Is there a way of "telling"
>it what the dimensions of the imported raster-based file should be?
>
>Sorry if this has been answered, I did look through the Help and FAQ
>sections and am none the wiser....
> [...]

Hi,

WMF: in most cases is there a width/height info in the header ...
If not, maximal desktop size ...