Plane Tesselations

3DLDF can be used to make perspective projections of plane tesselations
and other two-dimensional patterns. These can be used for
drawing tiled floors and other architectural items, among other things.
While patterns can be generated by using the basic facilities of C++
and
3DLDF without any specially defined functions, it can be useful to
define such functions.

3DLDF currently contains only one function for drawing patterns based on
a plane tessellation. I plan to add more soon.

Draws a pattern consisting of hexagons forming a tesselation of the x-z
plane, with additional hexagons within them.

The arguments:

realdiameter_outer

Default: 5. The diameter of the outer hexagon in each set of three
hexagons. The outer hexagons form a tessellation of the plane.

realdiameter_middle

Default: 0. The diameter of the middle hexagon in a set of three
hexagons.

realdiameter_inner

Default: 0. The diameter of the inner hexagon in a set of three
hexagons.

unsigned shortfirst_row

Default: 5. The number of sets of hexagons in the first single row.
The second single row will have
first_row + 1 sets of hexagons.

unsigned shortdouble_rows

Default: 10. The number of double rows drawn.

unsigned shortrow_shift

Default: 2.
For row_shift
!= 0,
the number of sets of hexagons in each (single) row is
increased by 2 every row_shift rows. If row_shift ==
0, the number sets of hexagons remains constant.
The rows remain centered around the z-axis.

Colordraw_color_outer

Default: *Colors::default_color.
The Color used for drawing the outer hexagons.

Colorfill_color_outer

Default: *Colors::background_color.
The Color used for filling the outer hexagons.

Colordraw_color_middle

Default: *Colors::default_color.
The Color used for drawing the middle hexagon.

Color fill_color_middle

Default: *Colors::background_color.
The Color used for filling the middle hexagons.

Colordraw_color_inner

Default: *Colors::default_color.
The Color used for drawing the inner hexagons.

Colorfill_color_inner

Default: *Colors::background_color.
The Color used for filling the inner hexagons.

stringpen_outer

Default: "pencircle scaled .5mm".
The pen used for drawing the outer hexagons.

stringpen_middle

Default: "pencircle scaled .3mm".
The pen used for drawing the middle hexagons.

string pen_inner

Default: "pencircle scaled .3mm".
The pen used for drawing the inner hexagons.

Picture&picture

Default: current_picture.
The Picture onto which the pattern is put.

unsigned intmax_hexagons

Default: 1000.
The maximum number of hexagons that will be drawn.

Draws a pattern in the x-z plane consisting of hexagons. The outer
hexagons form a tessellation. The middle and inner hexagons fit
within the outer hexagons. The hexagons are drawn in double rows.
The tessellation can be repeated by copying a
double row and shifting the copy to lie directly behind the first double
row. If the Picture with the pattern is projected with the
Focus in front of the pattern, looking in the direction of the back
of the pattern,
the first row of hexagons will appear larger than the rows
behind it. Therefore, in order for the perspective projection of the
pattern to fill a rectangular area on the plane of projection,
it will generally be necessary to increase the number of sets of
hexagons in each double row. On the other hand, if the same number of
sets of hexagons were used in the front double row, as will be needed for the
back double row, many of them would probably be unprojectable.