Frequently Asked Questions, Hints & Tips



Exploding Hatches - Why do hatches explode / discombobulate / lose coherence?

Hatch pattern scaling - How to scale hatches?

Hatch collections - Where can I find other hatches?

Custom hatch creation

Hatch pattern organization

What are the limits on Revit pattern scale?

What's a good text editor for hatch patterns?

Why are some hatch pattern files so large? Does hatch efficiency matter?

What do hatch pattern layers do?

What is the difference between AutoCAD's Hatch and SuperHatch?

What limitations are there when pasting a Windows Metafile into HatchKit?





Exploding Hatches - Why do hatches explode / discombobulate / lose coherence?

Round-off error in calculations performed between the hatch origin and hatch location can progressively erode the relationship between individual elements. The more imprecise the hatch pattern definition, the faster the degradation.

For example this is a line taken from a standard GRAVEL pattern containing 5 digit precision:

0, 15.24, 11.43, 25.4, 25.4, 6.604, -18.796

HatchKit recomputes the element geometry to the maximum precision possible within available line length:

0,15.24,11.43,0,25.3940337696,6.604,-18.8019174775

These sample hatches made progressively further away from the hatch origin show how the standard GRAVEL pattern degrades while the HatchKit-generated version retains good appearance:

Location X=0,0
Standard
HatchKit

Location X=5000,5000
Standard
HatchKit

Location X=500000,500000
Standard
HatchKit

Location X=25000000,25000000
Standard
HatchKit



Hatch pattern scaling - How to scale hatches?

HatchKit provides a convenient scaling control:



Alternatively you can multiply all linear measurement items in a hatch pattern definition file by a scaling factor. In AutoCAD and similar pattern file formats the first item is an angle so should not be scaled. Other file formats differ - for instance DataCAD 12 precedes the angle with other unchanging information.

Excel can open the hatch pattern file (alternately Get External Data from the Data menu). Select comma as delimiter. Create a new worksheet with scaled linear measurements (B onwards for AutoCAD, D onwards for DataCAD). Save that worksheet as a .CSV file and ensure that all lines comply with the maximum allowable line length. Rename the file to suit your CAD system.

Rescaling hatch patterns for Revit requires extra care to ensure all pattern elements have repetition lengths within the limits for that pattern type.



Hatch collections - Where can I find other hatches?

Have a look at these websites linked to here.

Be prepared to spend some time looking.


HatchKit makes the perfect viewer and editor for most CAD hatch pattern files.



Custom hatch creation

"Developing a hatch pattern definition requires knowledge, practice, and patience." (from AutoCAD Help)

For the impatient, there are hatch generators. Some generators require AutoCAD or TurboCAD to operate, others are are self-standing. Some confine the pattern template within a unit square or a rectangular patch. Some generate compact patterns, others can create very large patterns.

None offers HatchKit's unique ability to reliably edit and rescale existing hatch patterns.



Hatch pattern organization

CAD systems vary.


HatchKit can insert hatch pattern definitions within the monolithic pattern files found in systems such as AutoCAD, Alibre or TurboCAD and also within DXF files for import to VectorWorks and ArchiCAD.



What are the limits on Revit pattern scale?

HatchKit integrates with the HatchKit Add-In for Revit to allow arbitarily large patterns to be loaded and used in Revit. This was not possible until the release of the of the HatchKit Add-in for Revit available from the Autodesk Revit Exchange and as part of the HatchKit for Revit Demonstration.

The following now applies only to patterns imported via Revit's Fill Patterns Manager bypassed by the HatchKit Add-In for Revit and may be of interest to users of Revit LT (which lacks add-in support).

Every line in a hatch pattern has two repetition distances. One measures the distance along the line direction to its next inline repetition, the other measures the distance to the next parallel instance of that pattern line.

The first is the sum of all values in the line's definition from its sixth item onwards:.

0, 15.24,11.43, 25.4,25.4, 6.604,-18.796

The second is the fifth value in its definition:

0, 15.24,11.43, 25.4,25.4, 6.604,-18.796

Revit limits both to a range depending on pattern type.

For imperial units:

MODEL patterns allow from 0.5 inch to 848.5 inches.
DRAFTING patterns allow 0.002 inch to 84.85 inches.

For metric patterns:

MODEL patterns from 12.7mm to 21552mm.
DRAFTING patterns 0.051mm to 2155mm.

HatchKit attempts to replace elements that fall outside an allowable range with a set of equivalent elements so the overall pattern can be imported to Revit at 1:1 scale.



What's a good text editor for hatch patterns?

While HatchKit can read most hatch patterns, some broken files require repair before loading.

For example this pattern lacks a crucial decimal point from the last number of the first line:

*lath,Lath, mesh, grating *
0,0,0,.5,.1666666667,.3333333333,-6666666667
135,0,0,.23570226,-.23570226,.23570226,-.4714045208
225,0,0,-.23570226,-.23570226,.23570226,-.4714045208

Notepad is fine for simple work but is not much help when there is a format problem within the pattern file. Checking that each line is within the maximum allowable line length, is properly terminated and does not contain unwanted characters are not easy tasks for Notepad.

Fortunately there are many fine programmers' text editors available. PSPad for example can show raw file format, a vertical line at 80 characters and enforce proper line termination - as well as providing other useful tools such as a text file compare.

Most systems use straight ASCII with each line terminated by a carriage return and a linefeed character. Earlier versions of AutoCAD did not enforce line termination quite as strictly as does ACAD2007 and later.

There are exceptions - for instance Alibre employs UTF-16. Later versions of TurboCAD employ ASCII within compressed XML.

The essential requirement is to keep the text recognisable by the CAD package. Avoid wordprocessors such as Word or Wordpad.



Why are some hatch pattern files so large? Does hatch efficiency matter?

Some patterns are very large to avoid obvious repetitions in natural materials such as stone or timber. Larger patterns result in larger, slower drawings and often that's the price paid for a desired result.

Other patterns are large because of their generator's inefficiency, containing many redundant lines with the same angle, length and repetition spacings:

0.185,41.691,6.76536,299.998,-0.969191,6.459,-3993014.378
0.185,41.691,81.7654,299.998,-0.969191,6.459,-3993014.378
0.185,41.691,156.765,299.998,-0.969191,6.459,-3993014.378
0.185,41.691,231.765,299.998,-0.969191,6.459,-3993014.378
...

Notice how only the line origin's Y value is changing.

Generators containing this inefficient algorithm are still available creating patterns that can contain many thousands of lines.

This batt insulation pattern contains 528 lines extending well beyond the zoomed-in screen in both directions:



Compare the above with this equivalent pattern containing only 14 lines built and checked in HatchKit:



The smaller pattern allows

The new HatchKit AutoArrange control analyses and reduces such patterns to their essentials.

What do hatch pattern layers do?

Layers contain portions of the complete hatch pattern sharing a common repetition arrangement and are built as a pattern is loaded into HatchKit.

Layers can also be added during hatch editing.

Most complete patterns contain just the one arrangement.

Some patterns contain more than one layer to provide a more random appearance.

Layers play no part in the finished pattern.

What is the difference between AutoCAD's Hatch and SuperHatch?

Hatches are constructed from straight line segments and can be clipped by straight and curved boundaries when inserted. Curved pattern elements are approximated by straight line segments.

Superhatches are rectangular tiled arrays of blocks or images clipped by straight boundary segments when inserted. Curved hatch boundaries are approximated by straight boundary segments.

HatchKit edits Hatches, not Superhatches.

What limitations are there when pasting a Windows Metafile into HatchKit?

Bitmapped portions such as Truetype text strings or raster backgrounds are ignored.