> For the complete documentation index, see [llms.txt](https://docs.augelab.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.augelab.com/function-blocks/sockets.md).

# Sockets

## Socket Colors and Types <a href="#socket-colors-and-types" id="socket-colors-and-types"></a>

AugeLab Studio provides different colors in sockets to indicate what kind of data is transferred through a socket. These colors show which class or data type the input/output belongs to. Read the descriptions below to learn which colors are associated with which data types.

{% hint style="info" %}
For more additional information on socket data types, refer to [Coding Reference](/key-features/create-plugins-with-designer-window/coding-reference.md).
{% endhint %}

### Light Green (Any Image) <a href="#light-green" id="light-green"></a>

<details>

<summary>Light Green (Any Image)</summary>

This socket color corresponds to a mixed image data type and only image data should be connected.

**Camera USB** block below has one green output socket and outputs a colored image it received from the camera.

{% hint style="info" %}
Light Green sockets output BGR and GRAY format data.
{% endhint %}

<figure><img src="https://63608322-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbH8gla5D8g5pQAK8IzR8%2Fuploads%2Fgit-blob-6255bbc78b3e6b8f03dfff4afe0d7c4e7d8be891%2FEkran%20g%C3%B6r%C3%BCnt%C3%BCs%C3%BC%202023-06-30%20000120.png?alt=media" alt=""><figcaption></figcaption></figure>

</details>

<details>

<summary>Purple (Gray Image)</summary>

Purple sockets correspond to grayscale image type. Color image data cannot be connected to this socket.

{% hint style="info" %}
Purple sockets output grayscale, single-channel image data. This data type may not be used by Light Green sockets. To convert it, use [**Color Space**](/function-blocks/blocks-reference/image-transformations/transformation-filters/color-space.md) function block.
{% endhint %}

<figure><img src="https://63608322-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbH8gla5D8g5pQAK8IzR8%2Fuploads%2Fgit-blob-e451b87e7d525f1af79b7cab06836eb0127bddc5%2FEkran%20g%C3%B6r%C3%BCnt%C3%BCs%C3%BC%202023-06-29%20235854.png?alt=media" alt=""><figcaption></figcaption></figure>

</details>

<details>

<summary>Blue (Colored Image)</summary>

Blue-colored sockets correspond to colored image data types. These guarantee a colored image output, unlike [Light Green](#light-green) sockets.

{% hint style="info" %}
Colored Image consists of 3 different arrays, Blue-Green-Red. These also can be split with [Split ](/function-blocks/blocks-reference/image-transformations/operations/split-image.md)[Image](/function-blocks/blocks-reference/image-transformations/operations/split-image.md) block.
{% endhint %}

<figure><img src="https://63608322-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbH8gla5D8g5pQAK8IzR8%2Fuploads%2Fgit-blob-47982d5b0c6a99946630d47381fd0c68d41b3162%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

</details>

<details>

<summary>Light Blue (Boolean)</summary>

Lift Blue colored sockets correspond to logic data types, which are either **True** or **False**.

For example, the camera block above has blue input sockets and only takes True or False values.

{% hint style="info" %}
Logic expressions consist of only two states; **True** and **False**.
{% endhint %}

<figure><img src="https://63608322-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbH8gla5D8g5pQAK8IzR8%2Fuploads%2Fgit-blob-4fa00a728f8b855e94907b36928cb386aaf0603c%2Fimage%20(62).png?alt=media" alt=""><figcaption></figcaption></figure>

</details>

<details>

<summary>Yellow (Number)</summary>

Yellow sockets correspond to integer data type. The following function block has yellow sockets and takes only integer values.

{% hint style="info" %}
Integer basically means whole numbers.
{% endhint %}

<figure><img src="https://63608322-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbH8gla5D8g5pQAK8IzR8%2Fuploads%2Fgit-blob-0ac171662412c05bd29bd648c1ed59d162055324%2FEkran%20g%C3%B6r%C3%BCnt%C3%BCs%C3%BC%202023-06-30%20001502.png?alt=media" alt=""><figcaption></figcaption></figure>

</details>

### Purple (Position) <a href="#purple-position" id="purple-position"></a>

<details>

<summary>Purple (Position)</summary>

Pink sockets output as position/point data type. For example ((x1,y1),(x2,y2)) you can get the position of any object.

{% hint style="info" %}
Point data type consists of two numbers, first is the horizontal position and the second is the vertical position.
{% endhint %}

<figure><img src="https://63608322-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbH8gla5D8g5pQAK8IzR8%2Fuploads%2Fgit-blob-37ca21d7ddbd78f538ca79da3f1d0daf9b0c0ec0%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

</details>

<details>

<summary>Orange (Shape)</summary>

Orange sockets correspond to the shape data type.

{% hint style="info" %}
Shape data type consists of multiple points, which also consist of two numbers representing where they reside in two-dimensional space.
{% endhint %}

<figure><img src="https://63608322-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbH8gla5D8g5pQAK8IzR8%2Fuploads%2Fgit-blob-71e5b0df10b71e50ae0b067ed4b201a1312a2f54%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

</details>

<details>

<summary>Dark Green (Undefined)</summary>

Green sockets are sockets corresponding to undefined data types. These color sockets can contain any variant type and can be connected with other sockets.

{% hint style="warning" %}
Be careful when working with green type sockets and make sure data flow is safe.
{% endhint %}

</details>

<details>

<summary>Gray (Text)</summary>

The gray sockets correspond to the text data type.

{% hint style="info" %}
Texts are strings and can be modified to represent results.
{% endhint %}

<figure><img src="https://63608322-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbH8gla5D8g5pQAK8IzR8%2Fuploads%2Fgit-blob-989cf416e78a048a474be623a55254896fb0ee7c%2FEkran%20g%C3%B6r%C3%BCnt%C3%BCs%C3%BC%202023-06-30%20002425.png?alt=media" alt=""><figcaption></figcaption></figure>

</details>
