# Thumbnail

OvenMediaEngine은 라이브 스트림에서 썸네일을 생성할 수 있습니다. 이를 통해 웹사이트에서 방송 목록을 구성하거나 여러 스트림을 동시에 모니터링할 수 있습니다.

## Configuration

### Bind

썸네일은 HTTP(s)를 통해 퍼블리싱됩니다. 썸네일을 위한 포트를 다음과 같이 설정합니다. 썸네일 퍼블리셔는 HLS 및 DASH와 동일한 포트 번호를 사용할 수 있습니다.

```markup
<Bind>
    <Publishers>
      ...
        <Thumbnail>
            <Port>20080</Port>
            <!-- If you need TLS support, please uncomment below:
            <TLSPort>20081</TLSPort>
            -->
        </Thumbnail>
    </Publishers>
</Bind>
```

### Encoding

썸네일을 퍼블리싱하려면 인코딩 프로필을 설정해야 합니다. 포맷으로 JPG, PNG, WEBP를 선택할 수 있습니다. 프레임 레이트(Framerate)와 해상도(Resolution)를 설정할 수 있습니다. 아래의 샘플을 참조해 주십시오.

```markup
<OutputProfiles>
    <OutputProfile>
        <Name>default_stream</Name>
        <OutputStreamName>${OriginStreamName}_preview</OutputStreamName>
        <Encodes>
            <Image>
                <Codec>jpeg</Codec>
                <Framerate>1</Framerate>
                <Width>1280</Width>
                <Height>720</Height>
            </Image>
            <Image>
                <Codec>png</Codec>
                <Framerate>1</Framerate>
                <Width>1280</Width>
                <Height>720</Height>
            </Image>
            <Image>
                <Codec>webp</Codec>
                <Framerate>1</Framerate>
                <Width>1280</Width>
                <Height>720</Height>
            </Image>            
        </Encodes>
    </OutputProfile>
</OutputProfiles>
```

<table><thead><tr><th width="290">Property</th><th>Description</th></tr></thead><tbody><tr><td>Codec</td><td>사용할 이미지 코덱을 지정합니다.</td></tr><tr><td>Width</td><td>해상도의 너비(가로)</td></tr><tr><td>Height</td><td>해상도의 높이(세로)</td></tr><tr><td>Framerate</td><td>초당 프레임 수</td></tr></tbody></table>

#### Supported image codecs

<table><thead><tr><th width="149">Encode Type</th><th width="177.33333333333331">Codec</th><th>Codec of Configuration</th></tr></thead><tbody><tr><td>Image</td><td>JPEG</td><td>jpeg</td></tr><tr><td></td><td>PNG</td><td>png</td></tr><tr><td></td><td>WEBP</td><td>webp</td></tr></tbody></table>

{% hint style="warning" %}
이미지 인코딩 프로필은 썸네일 퍼블리셔에서만 사용되며, bypass 옵션은 지원되지 않습니다.
{% endhint %}

### Publisher

썸네일 퍼블리셔를 선언합니다. 크로스 도메인(Cross-domain) 설정은 세부 옵션으로 사용할 수 있습니다.

```markup
<Publishers>
    ...
    <Thumbnail>
        <CrossDomains>
            <Url>*</Url>
        </CrossDomains>	
    </Thumbnail>
</Publishers>
```

## Get thumbnails

썸네일에 대한 설정이 완료되고 스트림이 입력되면, 다음 URL을 통해 썸네일을 확인할 수 있습니다.

| Method | URL Pattern                                                                                        |
| ------ | -------------------------------------------------------------------------------------------------- |
| GET    | http(s)://\<ome\_hos&#x74;*>:\<port>/\<app\_name>/\<output\_stream\_name>/thumb.\<jpg\|png\|webp>* |

## Advanced&#x20;

### Keyframes Decoding Only

비디오 (재)인코딩이 필요 없는 사용 사례를 위해, OME는 수신되는 스트림의 키프레임만 디코딩하도록 설정할 수 있습니다. 썸네일을 생성하기 위한 목적으로만 인코더를 사용하는 경우, 이는 엄청난 성능 향상을 가져옵니다.

{% hint style="info" %}
*지원 버전: OvenMediaEngine 0.17.2 이상*
{% endhint %}

```xml
<OutputProfiles>
<!-- Common setting for decoders. Decodes is optional. -->
	<Decodes>
	<!-- 
	By default, OME decodes all video frames. 
	With OnlyKeyframes, only keyframes are decoded,
	massively improving performance.
	Thumbnails are generated only on keyframes,
	they may not generate at your requested fps!
	-->
		<OnlyKeyframes>true</OnlyKeyframes>
	</Decodes>

    <OutputProfile>
       <Encodes>
           <Video>
                <Bypass>true</Bypass>	
  		   </Video>
           <Image>
               <Codec>jpeg</Codec>
               <Width>1280</Width>
               <Height>720</Height>
               <Framerate>1</Framerate>
          </Image>
       </Encodes>
    </OutputProfile>
</OutputProfiles>
```

### CrossDomains

CrossDomains에 대한 자세한 정보는 [CrossDomains](/guide/ko-kr/features/operations-and-monitoring/crossdomains.md) 챕터를 참조해 주십시오.


---

# 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://ovenmediaengine-enterprise.gitbook.io/guide/ko-kr/features/transcoding-and-processing/thumbnail.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.
