[Grasshopper] How to use Model Hatch to create hatching

[Grasshopper] How to Use Model Hatch to Create Hatching Grasshopper component EN

This article explains how to use Model Hatch to create hatching.

Model Hatch1
Model Hatch2

On the Grasshopper, it is represented by either of the two above.


↑Youtube Channel

Create hatching

Using Model Hatch allows you to create hatching.

Create hatching from closed lines or surfaces on a plane

Create hatching from closed lines or surfaces on a plane

Components used: ① Rectangle ② Model Hatch

In Model Hatch, you can create hatches from closed lines on a plane or from surfaces.

As a first example, let’s create a square and then create hatching within that square.

正方形を作成

Enter the numerical value for the length of one side into the Rectangle(X and Y).

This time, we entered 10 and created a 10×10 square.

ハッチングが作成された

Next, connect the Rectangle(R) to the Model Hatch(B).

Then, hatching is created.

By default, Model Hatch uses a pattern fill.

surface

Additional Components: ① Surface

Earlier, we created hatching from a closed line on a plane, but you can also create hatching from a surface on a plane.

The image above shows an example of converting a rectangular line into a surface on Surface.

Set the pattern

You can set the hatching pattern from the Model Hatch(P).

Set the pattern

To set a pattern, right-click the P terminal and select “Set Hatch Patterns”.

Then, you can set various types of patterns.

In the initial settings state, you can configure the following nine types of patterns.

Solid

Solid

Solid pattern.

Hatch1

Hatch1

This is the pattern for Hatch1.

Hatch2

Hatch2
Hatch2

This is the pattern for Hatch2.

Hatch3

Hatch3
Hatch3

This is the pattern for Hatch3.

HatchDash

HatchDash

This is a HatchDash pattern.

Grid

Grid

This is a grid pattern.

Grid60

Grid60

This is a Grid60 pattern.

Plus

Plus

This is a Plus pattern.

Squares

Squares

It’s a squares pattern.

Connect pattern data

Connect pattern data

Additional Components: ①Query Model Hatch Patterns

You can also set patterns by connecting pattern data to the Model Hatch(P).

The image above shows entering a pattern name usable with the Query Model Hatch Patterns, acquiring the pattern data, and connecting it to the Model Hatch(P).

Set the reference point

Set the reference point

Additional Component: ① Construct Point

By entering point information or coordinate information into the Model Hatch(Bp), you can create the base point for hatching.

Using diagonal patterns makes it easier to notice changes.

base point

Initially, we set the Construct Point(X) to 0 and created a base point at the origin position of 0,0,0.

hatching looks like this

Then, the hatching looks like this.

origin position of 10,0,0

Next, we set the Construct Point(X) to 10 and created a base point at the origin position of 10,0,0.

the hatching looks like this

Then, the hatching looks like this.

hatching is also misaligned

Zooming in reveals that the hatching is also misaligned because the base point is off.

In this way, you can specify the base point position using the Bp terminal and adjust the hatching.

Change the angle

Change the angle

Additional Components: ①Pi ②Multiplication

By setting the angle of the Model Hatch(R), you can set the angle of the hatching.

The default setting for the Model Hatch(R) requires angle information to be entered in radians.

This time, values between 0 and 2.0 and Pi are connected to the Multiplication(A and B), creating values between 0 and 2.0 × π.

default

Setting the Number Slider value to 0 will make it the same as the default angle.

set the value

We set the value of the Number Slider to 0.5, which corresponds to 0.5π (π/2).

changed by 90 degrees

Then, as shown in the image above, the angle changed by 90 degrees.

angle change2

We set the value of the Number Slider to 0.2 and adjusted it to 0.2π.

hatching became diagonal

Then the hatching became diagonal.

degrees

To set in degrees, right-click the Model Hatch(R) and select Degrees.

a value between 0 and 360

Then, enter a value between 0 and 360.

This time, we entered 90.

set angles using degrees

Then, as entered, the angle changed by 90 degrees.

In this way, you can also set angles using degrees.

Set the scale

Set the scale

You can set the scale by entering a value into the Model Hatch(S).

This time, we entered the number 5.

default state

This is the default state before input.

the scale changed

When the number 5 was entered, the scale changed.

In this way, you can change the scale using the Model Hatch(S).

Determine whether to include borders

Determine whether to include borders

Additional Component: ① Boolean Toggle

Setting the Sb terminal allows you to determine whether to include frame lines in the hatching.

Input True or False to the Model Hatch(Sb).

This time, we’ll set True or False using a Boolean Toggle.

the frame line is included

When set to True, the frame line is included in the hatching.

False

I’ll set it to False.

the border will not be included

Then, the border will not be included like this.

In this way, you can decide whether to include a border in the hatching using the Model Hatch(Sb).

Set the color

Set the color

Additional Component: ①Color Swatch

The Model Hatch(Bc) and Model Hatch(Fs) allow you to set the color of the hatching.

You can set the background color for the Model Hatch(Bc).

The Model Hatch(Fs) allows you to set the color of the hatching lines.

ハッチングの背景と線の色を設定できた

This time, we set white for the Model Hatch(Bc) and pink for the Model Hatch(Fs) in the Color Swatch.

Then, as shown in the image above, you can set the background and line colors for the hatching.

Output data

Output data
Click to Zoom

Additional Components: ① Hatch ② Curve ③ Model Hatch Pattern ④ Point

Various data constituting the hatching are output from the terminal on the right.

H terminal outputs the created hatching data.

From terminal B, the line data for the frame lines used to create hatching is output.

The P terminal outputs the pattern data used for hatching.

Point data for the hatch base point is output from the Bp terminal.

Numerical data representing angles is output from the R terminal.

Numerical data from the scale is output via the S terminal.

The Sb terminal outputs either True or False to determine whether to include the frame border.

The Bc terminal outputs background color information.

The Fs terminal outputs the color information for the hatching lines.

List of Grasshopper articles using Model Hatch component↓

Comment

Translate »