<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [@soulmachines/smwebsdk](./smwebsdk.md) &gt; [ContentAwareness](./smwebsdk.contentawareness.md)

## ContentAwareness class

ContentAwareness class

An instance of this class is used to enable CUE behaviors in the digital human. This is achived by measuring tagged HTML elements and sending their coordinates back to the server

See documentation on GitHub for further reference on how to use this API https://github.com/soulmachines/smwebsdk/blob/cue-content-awareness-api/guide/content-awareness.md

**Signature:**

```typescript
export declare class ContentAwareness 
```

## Constructors

|  Constructor | Modifiers | Description |
|  --- | --- | --- |
|  [(constructor)(scene, debounceTime, logger)](./smwebsdk.contentawareness._constructor_.md) |  | Constructs a new instance of the <code>ContentAwareness</code> class |

## Properties

|  Property | Modifiers | Type | Description |
|  --- | --- | --- | --- |
|  [contentCollection](./smwebsdk.contentawareness.contentcollection.md) |  | Record&lt;string, Element&gt; |  |
|  [debouncedMeasure](./smwebsdk.contentawareness.debouncedmeasure.md) |  | CallableFunction |  |
|  [debounceTime](./smwebsdk.contentawareness.debouncetime.md) |  | number |  |
|  [resizeObserver](./smwebsdk.contentawareness.resizeobserver.md) |  | ResizeObserver |  |
|  [videoFrame](./smwebsdk.contentawareness.videoframe.md) |  | Element \| null |  |

## Methods

|  Method | Modifiers | Description |
|  --- | --- | --- |
|  [buildUpdateContentAwarenessRequest(viewWidth, viewHeight, videoFrame, content)](./smwebsdk.contentawareness.buildupdatecontentawarenessrequest.md) |  | Builds the required UpdateContentAwareness message that gets sent to the server |
|  [disconnect()](./smwebsdk.contentawareness.disconnect.md) |  | Publicly accessible function to disconnect observers and event listeners |
|  [getMinLogLevel()](./smwebsdk.contentawareness.getminloglevel.md) |  | Check minimal log level of content awareness. |
|  [isLoggingEnabled()](./smwebsdk.contentawareness.isloggingenabled.md) |  | Check if the content awareness logging is enabled. |
|  [measure()](./smwebsdk.contentawareness.measure.md) |  | Publicly accessible function to trigger measurement of CUE-relevant elements in the DOM and send an updateContentAwareness message |
|  [measureDebounced()](./smwebsdk.contentawareness.measuredebounced.md) |  |  |
|  [mutationCallback(mutations)](./smwebsdk.contentawareness.mutationcallback.md) |  | Takes an array of MutationRecords and measures the ones marked with content awareness attributes |
|  [reconnect()](./smwebsdk.contentawareness.reconnect.md) |  | Publicly accessible function to reconnect observers and event listeners |
|  [setLogging(enable)](./smwebsdk.contentawareness.setlogging.md) |  | Enable/disable content awareness logging |
|  [setMinLogLevel(level)](./smwebsdk.contentawareness.setminloglevel.md) |  | Set minimal log level of content awareness logging. |
|  [setupEventListeners()](./smwebsdk.contentawareness.setupeventlisteners.md) |  |  |

