# shz_vec3_distance_sqr

Source: https://sh4zam.com/api/vector/shz_vec3_distance_sqr/

```c
SHZ_INLINE float shz_vec3_distance_sqr(shz_vec3_t vec1, shz_vec3_t vec2) SHZ_NOEXCEPT;
```

Returns the squared-distance between the two given 3D vectors.

## Parameters

| Name | Type | Description |
| --- | --- | --- |
| `vec1` | `shz_vec3_t` |  |
| `vec2` | `shz_vec3_t` |  |

## Returns

`float`

## Availability

- **C++ equivalent:** [`shz::vec3::distance_sqr`](https://sh4zam.com/api/cpp/vec3/#distance_sqr)
- **Type-generic form:** [`shz_vec_distance_sqr()`](https://sh4zam.com/api/vector/shz_vec_distance_sqr/)
- **Back-ends:** SH4: shared C implementation · SW: portable C · SPU: shared C implementation
- **Defined in:** [`sh4zam/shz_vector.h:505`](https://github.com/gyrovorbis/sh4zam/blob/ba1e30c88d49df0311870b229e1dd860ef26c477/include/sh4zam/shz_vector.h#L505)
- **Module:** [Vector](https://sh4zam.com/api/vector/), section "Binary Operations"
