Auto Digitize Options Recipe: autodigitize_options XML Data

   width = “100”
   thread_file=”threadchart.tch”	// Thread chart file name, the file
                                        // content is in files element
   <threads>				// list of nominatied thread colors
      <thread... />
      <thread... />
      <thread... />


The autodigitize_options xml string is used in:

Both width and height are optional.

The image dpi will be used to calculate result design size if both are not provided. Be careful when using DPI, we have experience that some images have no DPI or DPI is hidden. Or DPI is different when opening it in different software like Irfanview, .NET library or ImageMagick.  EWA choose .NET library as standard which is same as the value seen in the file property dialog under windows. The default DPI is 96 is image has no DPI or DPI is hidden.

The other side will be calculated to maintain aspect ratio if either of them is provided. 

If both are provided, the result design will just fit in the appointed rectangle without losing aspect ratio.

Loss of precision is not possible to avoid when calculating between inch, DPI and millimetre, so the result design size is slightly different from appointed width and height parameter.

thread_file is optional. It specifies a thread chart file (.tch). API will use the colors in this chart when processing auto-digitizing. The thread chart file itself must be supplied in the list of files with same name.

<threads> is optional. It specifies nominated thread colors which will be used in result design. 

The <threads> takes precedence over the thread_file if both exist.

At first, EWA processes — like colors reduction, etc – the image artwork to make it available for auto digitizing. Then

  • If <threads> or thread_file has values, match the colors to the nominated thread colors.
  • If <threads> and thread_file are empty or absent, the API try to search the color RGB value of processed image in the default color palette. If the exact color is found use it otherwise append the color to the default palette without code, brand and description.

At last, generate the stitches.