# ReactiveGridShaderEffect

Version: 0.5.0
Framework commit: d503df2befa756e681fcdc6250e9552dc7388bea
Canonical URL: /docs/0.5.0/api/ferroui-base/media/effects/library/struct-reactivegridshadereffect/

**struct** · [`ferroui-base`](/docs/0.5.0/api/ferroui-base/) · v0.5.0

```rust
struct ReactiveGridShaderEffect
```

Grid lines over the content and a halo under the pointer (Effector's
`ReactiveGridShaderEffect`): lines 5 percent of the cell wide along the
top and the left of each cell of `cell-size` (clamped to 8..64) from the
top left corner of the area, at the opacity `strength * 0.45`
(`strength` clamped to 0..1), and, while the pointer is over the host or
pressed, a halo around (`pointer-x`, `pointer-y`) fading to nothing at 0.18
of the area (0.28 while pressed), at the opacity 0.18 plus `press-boost`
while pressed; all times the colour and the alpha of the content, drawn
source over the content.

`reactive-grid(cell-size=22, strength=0.24, color=#64D6FF)`. An overlay
shader effect masked by the content; without strength and the pointer away
(the neutral value) the content is unchanged.
[`InteractiveReactiveGridEffect`](/docs/0.5.0/api/ferroui-base/media/effects/library/struct-interactivereactivegrideffect/) follows the pointer.

[View source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L608)

## Members

- [`pointer_x`](#struct_field-pointer_x)
- [`pointer_y`](#struct_field-pointer_y)
- [`is_pointer_over`](#struct_field-is_pointer_over)
- [`is_pressed`](#struct_field-is_pressed)
- [`cell_size`](#struct_field-cell_size)
- [`strength`](#struct_field-strength)
- [`press_boost`](#struct_field-press_boost)
- [`color`](#struct_field-color)
- [`LINE_WIDTH`](#assoc_const-line_width)

<a id="struct_field-pointer_x"></a>

### pointer_x

```rust
pointer_x: f64
```

The horizontal position of the pointer, 0 (left) to 1 (right)
(default 0.5).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L611)

<a id="struct_field-pointer_y"></a>

### pointer_y

```rust
pointer_y: f64
```

The vertical position of the pointer, 0 (top) to 1 (bottom) (default
0.5).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L614)

<a id="struct_field-is_pointer_over"></a>

### is_pointer_over

```rust
is_pointer_over: bool
```

Whether the pointer is over the host (default `false`).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L616)

<a id="struct_field-is_pressed"></a>

### is_pressed

```rust
is_pressed: bool
```

Whether the pointer is pressed (default `false`).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L618)

<a id="struct_field-cell_size"></a>

### cell_size

```rust
cell_size: f64
```

The side of a cell, in device independent pixels (default 22).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L620)

<a id="struct_field-strength"></a>

### strength

```rust
strength: f64
```

The strength of the lines, 0 to 1 (default 0.24).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L622)

<a id="struct_field-press_boost"></a>

### press_boost

```rust
press_boost: f64
```

The opacity the halo gains while pressed, 0 to 1 (default 0.36).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L624)

<a id="struct_field-color"></a>

### color

```rust
color: crate::media::Color
```

The colour of the lines and the halo (default #64D6FF).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L626)

<a id="assoc_const-line_width"></a>

### LINE_WIDTH

```rust
const LINE_WIDTH: f32
```

The width of a line, a fraction of the side of a cell (Effector's
`gridX < 0.05`).

[Source](https://github.com/wieslawsoltes/FerroUI/blob/d503df2befa756e681fcdc6250e9552dc7388bea/src/FerroUI.Base/media/effects/library/interactive.rs#L647)

## Trait implementations

- `Send`
- `Sync`
- `Freeze`
- `UnsafeUnpin`
- `Unpin`
- `UnwindSafe`
- `RefUnwindSafe`
- [`PropertyValue`](/docs/0.5.0/api/ferroui-base/trait-propertyvalue/)
- [`AnyValue`](/docs/0.5.0/api/ferroui-base/trait-anyvalue/)
- [`ClassDefaults`](/docs/0.5.0/api/ferroui-base/trait-classdefaults/)
- `Borrow<T>`
- `BorrowMut<T>`
- `CloneToUninit`
- `Into<U>`
- `From<T>`
- `TryInto<U>`
- `TryFrom<U>`
- `Any`
- `ToOwned`
- `ErasedDestructor`
- `IntoEither`
- `Clone`
- `Debug`
- `StructuralPartialEq`
- `PartialEq`
- `Default`
- [`CustomEffect`](/docs/0.5.0/api/ferroui-base/media/effects/trait-customeffect/)

## Availability

Extracted for `aarch64-apple-darwin`. Cargo features are listed in the [crate index](/docs/0.5.0/api/).
