# Handle WebGL view & interaction

## MYTYSDKContext

{% embed url="<https://github.com/Off-Live/myty-sdk/blob/pre-release/dev/examples/react_2d_mp/react/src/context/MYTYSDKContext.tsx>" %}

A context to wrap <mark style="color:purple;">`ReactUnityWebGL`</mark> and provide states to the other parts of the application. It exposes multiple methods that implements [myty-sdk-interface](https://myty.gitbook.io/products/sdk/myty-sdk-interface "mention"). With this, you can send message to Unity and use contexts that are delievered from Unity

## MYTYSDKView

{% embed url="<https://github.com/Off-Live/myty-sdk/blob/pre-release/dev/examples/react_2d_mp/react/src/components/MYTYSDKView.tsx>" %}

A component that wraps <mark style="color:purple;">`Unity`</mark> component from <mark style="color:purple;">`ReactUnityWebGL`</mark> . This component also includes video element, since for HeadOnly(AR) mode, camera device stream needs to be shown in the screen


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://myty.gitbook.io/products/sdk/react-example/handle-webgl-view-and-interaction.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
