How to set color depth when converting HTML to BMP?

Well, if you click the following website, you can find there are two versions of the HTML converter: VeryPDF HTML Converter v2.0 (GUI Version) and VeryPDF HTML Converter Command Line Version v2.1. The GUI (graphical user interface) version is more user-friendly. But the command line version can help you save more time, for the command line version only requires three steps to convert documents.

If you want to set color depth and convert HTML to BMP, you should give attention to the command -bitcount <int>, which can be used to set color depth. This article will take three steps to introduce how to set color depth and convert HTML to BMP via command line.

1. Run the command prompt window

You can select either of the following two ways to run the command prompt window:

  • The first one requires four steps, but most people tend to run the command prompt window in this way: click “Start”; > click “Run” on the home menu; > enter “cmd” in the “Run” dialog box;>click on “OK” in the “Run” dialog box. Then the black and white command prompt window will pop out.

clip_image002[4]

  • The second one requires two steps, you should click “Start”; > click the icon of the command prompt on the home menu as illustrated as below.

clip_image003[4]

2. Enter a command line

After the command prompt window is opened, you can enter a command line according to the following pattern in it.

htmltools -bitcount <int> <EMF file> <BMP file>

This command pattern concludes four factors: the command for color depth setting and four files:

  • htmltools refers to the executable file htmltools.exe, which is always placed in the folder htmltools after the install file is decompressed.
  • -bitcount <int> represents the command that can be used to set color depth. int means integer, so the number following -bitcount must be an integer. As for this command, three parameter values are allowed: 1, 8 and 24. You can select any of them as the color depth value. The angle brackets mark essential contents, but never appear in the command prompt window. As the color depth becomes higher, the more the colors are allowed in an image. For instance, if the command is -bitcount 24, the result image file will become colorful, and is capable of storing 224 possible colors.
  • <EMF file> stands for the input file in EMF format
  • <BMP file> denotes to the output file in BMP format

The command line pattern above can generally show what elements should be included. However, when you enter a command line in the command prompt window, you should enter the whole directories rather than only the names of the executable file, the input file and output file. Look at the command line as illustrated below,

D:\htmltools\htmltools.exe -bitcount 1 D:\in\rose.emf D:\out\rose.bmp

In the example above, the whole directories of the executable file, the input file and the output file, rather than their bare names, appear in the command line.

  • D:\htmltools\htmltools.exe is the directory of the executable file htmltools.exe. The directory shows that the folder containing the executable file is on disc D. You can change the directory, according to the place where the executable file is stored.
  • -bitcount 8 is the command specifying 8-bit as the color depth for the output BMP file. 8 can be replaced by 24 or 8, depending on your requirements.
  • D:\in\rose.emf denotes the directory of the input EMF file, leading the computer to find the input file rose in the folder in on disk D. Again, it can be replaced, according to the file you select.
  • D:\out\rose.bmp represents the directory of the output file, showing that the output format must be BMP, the name should be rose, and it should be placed in the folder out on disk D.

3. Press “Enter”

Press the “Enter” key, and VeryPDF HTML Converter Command Line will prompt to convert HTML to BMP. You can view the effect of the output files in a second. The images below are the original EMF file, and the files converted from HTML to BMP in different color depth.

The original EMF file

clip_image005[4]

1-bit BMP file

clip_image007[4]

8-bit BMP file

clip_image009[4]

24-bit BMP file

clip_image011[4]

clip_image012[4]

VN:F [1.9.20_1166]
Rating: 0.0/10 (0 votes cast)
VN:F [1.9.20_1166]
Rating: 0 (from 0 votes)

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *


Verify Code   If you cannot see the CheckCode image,please refresh the page again!