KR20240062731A - Method for synchronizing subtitles data and av data - Google Patents

Method for synchronizing subtitles data and av data Download PDF

Info

Publication number
KR20240062731A
KR20240062731A KR1020220144566A KR20220144566A KR20240062731A KR 20240062731 A KR20240062731 A KR 20240062731A KR 1020220144566 A KR1020220144566 A KR 1020220144566A KR 20220144566 A KR20220144566 A KR 20220144566A KR 20240062731 A KR20240062731 A KR 20240062731A
Authority
KR
South Korea
Prior art keywords
data
subtitle
video stream
screen
show timestamp
Prior art date
Application number
KR1020220144566A
Other languages
Korean (ko)
Inventor
윤선희
Original Assignee
주식회사 케이티
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 주식회사 케이티 filed Critical 주식회사 케이티
Priority to KR1020220144566A priority Critical patent/KR20240062731A/en
Publication of KR20240062731A publication Critical patent/KR20240062731A/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/4302Content synchronisation processes, e.g. decoder synchronisation
    • H04N21/4307Synchronising the rendering of multiple content streams or additional data on devices, e.g. synchronisation of audio on a mobile phone with the video output on the TV screen
    • H04N21/43072Synchronising the rendering of multiple content streams or additional data on devices, e.g. synchronisation of audio on a mobile phone with the video output on the TV screen of multiple content streams on the same device
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/431Generation of visual interfaces for content selection or interaction; Content or additional data rendering
    • H04N21/4312Generation of visual interfaces for content selection or interaction; Content or additional data rendering involving specific graphical features, e.g. screen layout, special fonts or colors, blinking icons, highlights or animations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/47End-user applications
    • H04N21/488Data services, e.g. news ticker
    • H04N21/4884Data services, e.g. news ticker for displaying subtitles
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/83Generation or processing of protective or descriptive data associated with content; Content structuring
    • H04N21/845Structuring of content, e.g. decomposing content into time segments
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/85Assembly of content; Generation of multimedia applications
    • H04N21/854Content authoring
    • H04N21/8547Content authoring involving timestamps for synchronizing content

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

영상 재생 장치의 동작 방법으로서, 네트워크를 통해 연결된 서버로부터 영상 스트림을 수신하는 단계, 상기 영상 스트림을 AV(AudioVideo) 데이터와 복수개의 자막 데이터로 분리하는 단계, 상기 AV 데이터를 설정된 쇼 타임스탬프(Show Timestamp) 단위로 분할하는 단계, 상기 복수개의 자막 데이터를 상기 쇼 타임스탬프 단위로 그룹핑하는 단계, 그리고 동일한 쇼 타임스탬프 구간에 속하는 분할된 AV 데이터와 적어도 하나의 자막 데이터가 동일한 화면에 출력되도록 제어하는 단계를 포함한다.A method of operating a video playback device, comprising: receiving a video stream from a server connected through a network; separating the video stream into AV (AudioVideo) data and a plurality of subtitle data; storing the AV data with a set show timestamp (Show Timestamp) unit, grouping the plurality of subtitle data into the show timestamp unit, and controlling the divided AV data and at least one subtitle data belonging to the same show timestamp section to be output on the same screen. Includes steps.

Figure P1020220144566
Figure P1020220144566

Description

AV 데이터와 자막 데이터의 동기화 방법{METHOD FOR SYNCHRONIZING SUBTITLES DATA AND AV DATA}Method for synchronizing AV data and subtitle data {METHOD FOR SYNCHRONIZING SUBTITLES DATA AND AV DATA}

본 개시는 AV(AudioVideo) 데이터와 자막 데이터의 동기화 방법에 관한 것이다.This disclosure relates to a method of synchronizing AV (AudioVideo) data and subtitle data.

지상파 방송 등과 같이 실시간 채널 서비스에서는 AV 데이터와 자막 데이터가 별개로 셋톱박스에 수신되고, 셋톱박스는 정해진 방식에 의해 AV 데이터와 자막 데이터를 하나의 실시간 채널 데이터로 출력한다.In real-time channel services such as terrestrial broadcasting, AV data and subtitle data are received separately by a set-top box, and the set-top box outputs AV data and subtitle data as one real-time channel data according to a designated method.

그런데, 종래에는 AV 스트림(Stream)과 자막 데이터를 하나의 쓰레드 사이클(Thread Cycle)로 처리한다. 자막 데이터가 수신되는 대로 영상 위에 그래픽으로 자막을 그리는 구조이므로, 글자의 띄어쓰기, 줄 바꿈 등 가독성에 문제가 발생한다. However, conventionally, the AV stream and subtitle data are processed in one thread cycle. Since the structure is to draw subtitles graphically on the video as subtitle data is received, problems with readability such as spacing and line breaks occur.

하나의 쓰레드 사이클로 처리하게 되면, 하나의 시간 로직에 따라 순차적으로 AV 스트림과 자막 스트림이 제어되므로, AV 데이터와 자막 데이터의 동기가 잘 맞지 않을 수 있다. 왜냐하면, 자막 데이터 자체가 청각 장애인의 이해를 돕기 위해 만들어졌기 때문이다. 따라서, AV 화면 상의 사람의 입모양과 자막 데이터의 내용이 서로 맞지 않을 수 있다. When processed with one thread cycle, the AV stream and subtitle stream are controlled sequentially according to one time logic, so the AV data and subtitle data may not be well synchronized. This is because the subtitle data itself was created to help hearing impaired people understand. Therefore, the shape of the person's mouth on the AV screen and the content of the subtitle data may not match each other.

또한, 자막 그래픽을 그리면서 발생되는 지연(Delay) 시간으로 인해 영상/음성과의 동기화가 틀어져 시청이 어려울 정도로 사용하기에 매우 불편하다. 자막 데이터인 closed caption은 음성을 텍스트로 변환하는데, 변환 시간이 대략 2~3초 이상 소요되므로, AV 송출 시점과 자막 데이터의 송출 시점에 차이가 발생한다. 자막 데이터와 AV 데이터의 동기화를 위해서는 영상 스트림을 수신하여 인코딩 서버에 의해 동기화를 시키고, 동기화된 영상 스트림을 서버에 저장한 후, 서버에서 다시 스트리밍해야 하지만, 이렇게 되면 여러 실시간 채널의 스트림을 일정시간 버퍼에 저장할 수 있도록 서버 증설 등이 필요하다. 하지만, 이는 IPTV(Internet Protocol Television) 사업자마다 서버 증설로 인한 막대한 비용 문제가 있어, 실질적으로 구현하기 어려운 실정이다. In addition, the delay time that occurs while drawing subtitle graphics causes synchronization with video/audio, making viewing difficult, making it very inconvenient to use. Closed caption, which is subtitle data, converts voice to text, and the conversion time takes approximately 2 to 3 seconds, so there is a difference between the time of AV transmission and the time of transmission of the subtitle data. In order to synchronize subtitle data and AV data, it is necessary to receive a video stream, synchronize it by an encoding server, store the synchronized video stream on the server, and then stream it again from the server. It is necessary to expand the server so that it can be stored in the buffer. However, this is difficult to implement in practice because each IPTV (Internet Protocol Television) operator faces enormous cost problems due to server expansion.

따라서, 종래에는 청각장애인을 위한 자막을 제공하는 것으로 제한을 두고 서비스를 제공하고 있다. 정부 가이드인 청각장애인 시청 권리 보장 등의 이유로, 필수로 자막 기능을 이네이블(enable)하여 IPTV 단말에 적용시켰다. 하지만, 전술한 여러 불편함 때문에 IPTV 사업자는 디폴트로 자막을 오프(Off)시키고, 사용자가 자막 기능을 온(On)하면, 자막 서비스를 제공하고 있다. Therefore, conventional services are limited to providing subtitles for the hearing impaired. For reasons such as the government's guide to guaranteeing the viewing rights of the hearing impaired, the subtitle function was mandatory and applied to IPTV devices. However, due to the various inconveniences mentioned above, IPTV operators turn off subtitles by default and provide subtitle services when the user turns on the subtitle function.

하지만, 자막 기능을 온하는 경우, 자막과 영상의 동기가 맞지 않거나, 자막의 가독성이 떨어져 보통 사용자들은 자막 기능을 오프 하는 경우가 많다. 이처럼, 종래의 자막 서비스는 일반 고객이 사용하기에는 다소 불편함이 있어, 이용률도 떨어진다.However, when turning on the subtitle function, users often turn off the subtitle function because the synchronization between the subtitles and the video is not correct or the readability of the subtitles is poor. As such, the conventional subtitle service is somewhat inconvenient for general customers to use, and the utilization rate is low.

본 개시는 AV(AudioVideo) 데이터와 자막 데이터를 모두 처리하는 영상 쓰레드(thread)와 자막 데이터만을 처리하는 자막 쓰레드로 구분하여 2개의 쓰레드를 병렬 처리하고, 화면 설정 및/또는 자막 설정을 기초로 설정한 쇼 타임스탬프(Show TimeStamp)를 기준으로 복수의 자막 데이터를 그룹핑하고, 쇼 타임스탬프를 기준으로 AV 데이터를 분할하여 그룹핑하여, 동일 그룹에 속하는 AV 데이터와 복수의 자막 데이터를 동기화하여 하나의 화면에 출력하는 방법을 제공하는 것이다. The present disclosure processes two threads in parallel by dividing them into a video thread that processes both AV (AudioVideo) data and subtitle data and a subtitle thread that processes only subtitle data, and sets them based on screen settings and/or subtitle settings. Multiple subtitle data are grouped based on a Show TimeStamp, AV data is divided and grouped based on the show timestamp, and AV data belonging to the same group and multiple subtitle data are synchronized to display one screen. It provides a method of printing to .

하나의 특징에 따르면, 영상 재생 장치의 동작 방법으로서, 네트워크를 통해 연결된 서버로부터 영상 스트림을 수신하는 단계, 상기 영상 스트림을 AV(AudioVideo) 데이터와 복수개의 자막 데이터로 분리하는 단계, 상기 AV 데이터를 설정된 쇼 타임스탬프(Show Timestamp) 단위로 분할하는 단계, 상기 복수개의 자막 데이터를 상기 쇼 타임스탬프 단위로 그룹핑 하는 단계, 그리고 화면에 출력되는 상기 AV 데이터의 현재 쇼 타임스탬프에 맞춰, 상기 현재 쇼 타임스탬프에 속하는 자막 데이터를 상기 화면에 출력하는 단계를 포함한다.According to one feature, a method of operating a video playback device includes the steps of receiving a video stream from a server connected through a network, separating the video stream into AV (AudioVideo) data and a plurality of subtitle data, and dividing the AV data into dividing into units of set show timestamps, grouping the plurality of subtitle data into units of show timestamps, and matching the current show timestamp of the AV data output on the screen to the current show time. It includes the step of outputting subtitle data belonging to the stamp on the screen.

상기 분할하는 단계 이전에, 글자 크기, 화면 비율, 해상도 중 적어도 하나를 이용하여 한 줄에 출력할 최대 글자 개수를 산정하고, 산정한 최대 글자 개수를 쇼 타임스탬프 크기로 설정하는 단계를 더 포함할 수 있다.Before the dividing step, it may further include calculating the maximum number of characters to be output on one line using at least one of character size, screen ratio, and resolution, and setting the calculated maximum number of characters as the show timestamp size. You can.

상기 설정하는 단계 이전에, 사용자 입력에 따른 화면 비율, 해상도 및 글자 크기 레벨을 확인하는 단계를 더 포함하고, 상기 설정하는 단계는, 화면 비율, 해상도, 그리고 글자 크기 레벨에 각각의 최대 글자 개수를 맵핑한 테이블로부터 상기 확인한 화면 비율, 해상도 및 글자 크기 레벨에 대응하는 최대 글자 개수를 확인하고, 확인한 최대 글자 개수를 쇼 타임스탬프 크기로 설정할 수 있다. Before the setting step, it further includes the step of checking the screen ratio, resolution, and font size level according to the user input, and the setting step includes setting the maximum number of characters for each screen ratio, resolution, and font size level. From the mapped table, you can check the maximum number of characters corresponding to the confirmed screen ratio, resolution, and font size level, and set the confirmed maximum number of characters as the show timestamp size.

상기 설정하는 단계 이전에, PTS(Presentation Time Stamp) 계산시 사용하는 STC(System Time Clock)를 이용하여 쇼 타임스탬프 크기를 설정하는 단계를 더 포함할 수 있다. Before the setting step, a step of setting the show timestamp size using the STC (System Time Clock) used when calculating the PTS (Presentation Time Stamp) may be further included.

상기 분리하는 단계 이전에, 상기 영상 스트림이 수신된 채널 번호 또는 콘텐츠 식별자에 기초하여 상기 영상 스트림이 멀티 쓰레드 대상인지 판단하는 단계를 더 포함하고, 상기 분리하는 단계는, 상기 멀티 쓰레드 대상으로 판단된 영상 스트림을 복수의 자막 데이터와 AV 데이터로 분리할 수 있다.Before the separating step, it further includes the step of determining whether the video stream is a multi-thread target based on a channel number or content identifier through which the video stream is received, and the separating step includes determining whether the video stream is a multi-thread target. The video stream can be separated into multiple subtitle data and AV data.

실시예에 따르면, 화면에 가장 효율적으로 보여줄 수 있는 쇼 타임스탬프를 설정하므로, 실시간 채널에서의 자막 가독성이 좋아진다.According to the embodiment, the show timestamp that can be most efficiently displayed on the screen is set, thereby improving subtitle readability in real-time channels.

또한, 쇼 타임스탬프에 따라, AV 출력과 자막이 함께 동기화하여 보여줌으로써, AV 시청에 불편함이 개선된다.Additionally, AV output and subtitles are synchronized and displayed together according to the show timestamp, thereby improving inconvenience in AV viewing.

또한, 음소거로 설정 후 TV를 보는 사용자, 단어 청취력 높이기 위해 자막 서비스를 이용해야 하는 사용자 등과 같은 다양한 자막 서비스에 유용하게 적용할 수 있다.In addition, it can be usefully applied to various subtitle services, such as users who watch TV after setting it to mute and users who need to use the subtitle service to improve their ability to hear words.

또한, 게임, 실시간 VR(Virtual Reality) 등과 같은 다양한 분야 및 다양한 AI(Artificial Intelligence) 단말에 폭넓게 이용이 가능한 것으로 예상된다.In addition, it is expected to be widely used in various fields such as games, real-time VR (Virtual Reality), and various AI (Artificial Intelligence) terminals.

또한, 자막 데이터의 상태 여부에 관계없이, 그리고 서비스 사업자별 IPTV 서버 증설 등의 물리적 비용 없이도 종단인 IPTV 단말에서 사용 편의성 높일 수 있다.In addition, convenience of use can be improved at the endpoint IPTV terminal regardless of the status of the subtitle data and without physical costs such as expansion of IPTV servers for each service provider.

도 1은 한 실시예에 따른 자막 동기화를 수행하는 영상 재생 장치의 구성을 나타낸 블록도이다.
도 2는 한 실시예에 따른 자막 동기화를 설명하는 개념도이다.
도 3은 도 2의 실시예에 따른 자막 동기화를 적용한 화면 예시도이다.
도 4는 도 2의 본 발명의 실시예와 비교하기 위한 종래의 자막 동기화를 설명하는 개념도이다.
도 5는 도 4의 자막 동기화에 따르면 화면 예시도이다.
도 6은 한 실시예에 따른 영상 재생 장치의 자막 동기화 방법을 나타낸 순서도이다.
도 7은 한 실시예에 따른 영상 재생 장치의 하드웨어 구성을 나타낸 블록도이다.
Figure 1 is a block diagram showing the configuration of a video playback device that performs subtitle synchronization according to an embodiment.
Figure 2 is a conceptual diagram explaining subtitle synchronization according to an embodiment.
Figure 3 is an example screen showing subtitle synchronization applied according to the embodiment of Figure 2.
FIG. 4 is a conceptual diagram illustrating conventional subtitle synchronization for comparison with the embodiment of the present invention in FIG. 2.
Figure 5 is an example screen according to subtitle synchronization in Figure 4.
Figure 6 is a flowchart showing a subtitle synchronization method of a video playback device according to an embodiment.
Figure 7 is a block diagram showing the hardware configuration of a video playback device according to an embodiment.

아래에서는 첨부한 도면을 참고로 하여 본 개시의 실시예에 대하여 본 개시가 속하는 기술 분야에서 통상의 지식을 가진 자가 용이하게 실시할 수 있도록 상세히 설명한다. 그러나 본 개시는 여러 가지 상이한 형태로 구현될 수 있으며 여기에서 설명하는 실시예에 한정되지 않는다. 그리고 도면에서 본 개시를 명확하게 설명하기 위해서 설명과 관계없는 부분은 생략하였으며, 명세서 전체를 통하여 유사한 부분에 대해서는 유사한 도면 부호를 붙였다.Below, with reference to the attached drawings, embodiments of the present disclosure will be described in detail so that those skilled in the art can easily practice them. However, the present disclosure may be implemented in many different forms and is not limited to the embodiments described herein. In order to clearly explain the present disclosure in the drawings, parts that are not related to the description are omitted, and similar parts are given similar reference numerals throughout the specification.

명세서 전체에서, 어떤 부분이 어떤 구성요소를 "포함"한다고 할 때, 이는 특별히 반대되는 기재가 없는 한 다른 구성요소를 제외하는 것이 아니라 다른 구성요소를 더 포함할 수 있는 것을 의미한다. Throughout the specification, when a part is said to “include” a certain element, this means that it may further include other elements rather than excluding other elements, unless specifically stated to the contrary.

또한, 명세서에 기재된 "…부", "…기", "…모듈" 등의 용어는 적어도 하나의 기능이나 동작을 처리하는 단위를 의미하며, 이는 하드웨어나 소프트웨어 또는 하드웨어 및 소프트웨어의 결합으로 구현될 수 있다.In addition, terms such as “…unit”, “…unit”, and “…module” used in the specification refer to a unit that processes at least one function or operation, which may be implemented through hardware or software or a combination of hardware and software. You can.

본 발명에서 설명하는 장치들은 적어도 하나의 프로세서, 메모리 장치, 통신 장치 등을 포함하는 하드웨어로 구성되고, 지정된 장소에 하드웨어와 결합되어 실행되는 프로그램이 저장된다. 하드웨어는 본 발명의 방법을 실행할 수 있는 구성과 성능을 가진다. 프로그램은 도면들을 참고로 설명한 본 발명의 동작 방법을 구현한 명령어(instructions)를 포함하고, 프로세서와 메모리 장치 등의 하드웨어와 결합하여 본 발명을 실행한다.The devices described in the present invention are composed of hardware including at least one processor, a memory device, a communication device, etc., and a program that is executed in conjunction with the hardware is stored in a designated location. The hardware has a configuration and performance capable of executing the method of the present invention. The program includes instructions that implement the operating method of the present invention described with reference to the drawings, and executes the present invention by combining it with hardware such as a processor and memory device.

본 명세서에서 "전송 또는 제공"은 직접적인 전송 또는 제공하는 것뿐만 아니라 다른 장치를 통해 또는 우회 경로를 이용하여 간접적으로 전송 또는 제공도 포함할 수 있다.In this specification, “transmission or provision” may include not only direct transmission or provision, but also indirect transmission or provision through another device or using a circuitous route.

본 명세서에서 단수로 기재된 표현은 "하나" 또는 "단일" 등의 명시적인 표현을 사용하지 않은 이상, 단수 또는 복수로 해석될 수 있다.In this specification, expressions described as singular may be interpreted as singular or plural, unless explicit expressions such as “one” or “single” are used.

본 명세서에서 도면에 관계없이 동일한 도면번호는 동일한 구성요소를 지칭하며, "및/또는" 은 언급된 구성 요소들의 각각 및 하나 이상의 모든 조합을 포함한다.In this specification, the same reference numbers refer to the same elements regardless of the drawings, and “and/or” includes each and all combinations of one or more of the mentioned elements.

본 명세서에서, 제1, 제2 등과 같이 서수를 포함하는 용어들은 다양한 구성요소들을 설명하는데 사용될 수 있지만, 상기 구성요소들은 상기 용어들에 의해 한정되지는 않는다. 상기 용어들은 하나의 구성요소를 다른 구성요소로부터 구별하는 목적으로만 사용된다. 예를 들어, 본 개시의 권리 범위를 벗어나지 않으면서 제1 구성요소는 제2 구성요소로 명명될 수 있고, 유사하게 제2 구성요소도 제1 구성요소로 명명될 수 있다.In this specification, terms including ordinal numbers, such as first, second, etc., may be used to describe various components, but the components are not limited by the terms. The above terms are used only for the purpose of distinguishing one component from another. For example, a first component may be referred to as a second component, and similarly, the second component may be referred to as a first component without departing from the scope of the present disclosure.

본 명세서에서 도면을 참고하여 설명한 흐름도에서, 동작 순서는 변경될 수 있고, 여러 동작들이 병합되거나, 어느 동작이 분할될 수 있고, 특정 동작은 수행되지 않을 수 있다. In the flowchart described herein with reference to the drawings, the order of operations may be changed, several operations may be merged, certain operations may be divided, and certain operations may not be performed.

도 1은 한 실시예에 따른 자막 동기화를 수행하는 영상 재생 장치의 구성을 나타낸 블록도이고, 도 2는 한 실시예에 따른 자막 동기화를 설명하는 개념도이고, 도 3은 도 2의 실시예에 따른 자막 동기화를 적용한 화면 예시도이고, 도 4는 도 2의 본 발명의 실시예와 비교하기 위한 종래의 자막 동기화를 설명하는 개념도이며, 도 5는 도 4의 자막 동기화에 따르면 화면 예시도이다.FIG. 1 is a block diagram showing the configuration of a video playback device that performs subtitle synchronization according to an embodiment, FIG. 2 is a conceptual diagram explaining subtitle synchronization according to an embodiment, and FIG. 3 is a block diagram according to the embodiment of FIG. 2. This is an example screen with subtitle synchronization applied. FIG. 4 is a conceptual diagram explaining conventional subtitle synchronization for comparison with the embodiment of the present invention in FIG. 2, and FIG. 5 is an example screen according to subtitle synchronization in FIG. 4.

먼저, 도 1을 참조하면, 영상 재생 장치(100)는 네트워크(200)를 통해 서버(300)와 통신한다. 영상 재생 장치(100)는 서버(300)로부터 AV(AudioVideo) 데이터 및 AV 데이터와 관련된 복수의 자막 데이터가 포함된 영상 스트림을 수신한다.First, referring to FIG. 1, the video playback device 100 communicates with the server 300 through the network 200. The video playback device 100 receives a video stream including AudioVideo (AV) data and a plurality of subtitle data related to the AV data from the server 300.

영상 스트림은 실시간 방송 채널 스트림일 수 있다. 혹은 영상 스트림은 TV 다시보기 VOD 서비스와 같이 실시간 폐쇄자막 방송(Real-time Closed caption) 스트림일 수 있다.The video stream may be a real-time broadcast channel stream. Alternatively, the video stream may be a real-time closed caption broadcast, such as a TV replay VOD service.

영상 재생 장치(100)는 영상 스트림 수신부(110), 자막 처리부(120), 영상 처리부(130), 재생 처리부(140), 디스플레이 장치(150), 자막 관리부(160), 자막 설정부(170), 및 화면 설정부(180)를 포함할 수 있다.The video playback device 100 includes a video stream receiver 110, a subtitle processing unit 120, an image processing unit 130, a playback processing unit 140, a display device 150, a subtitle management unit 160, and a subtitle setting unit 170. , and a screen setting unit 180.

영상 재생 장치(100)와 디스플레이 장치(150)는 별개의 하드웨어 장치일 수도 있고, 도 1에서와 같이 동일한 하드웨어 장치로 구현될 수 있다.The video playback device 100 and the display device 150 may be separate hardware devices or may be implemented as the same hardware device as shown in FIG. 1 .

영상 재생 장치(100)는 셋톱박스, 차량 단말 등일 수 있다.The video playback device 100 may be a set-top box, a vehicle terminal, etc.

영상 스트림 수신부(110)는 네트워크(200)를 통해 서버(300)로부터 영상 스트림을 수신한다. 수신하는 영상 스트림은 AV 데이터 및 복수의 자막 데이터를 포함한다.The video stream receiver 110 receives a video stream from the server 300 through the network 200. The received video stream includes AV data and a plurality of subtitle data.

영상 스트림 수신부(110)는 수신한 영상 스트림이 멀티 쓰레드 적용 대상인지, 즉, 본 발명의 실시예 적용 대상인지 판단할 수 있다.The video stream receiver 110 may determine whether the received video stream is subject to multi-threading, that is, whether it is subject to the embodiment of the present invention.

한 예시에 따르면, 영상 스트림 수신부(110)는 IPTV(Internet Protocol Television) 편성표를 기초로, 수신한 영상 스트림의 채널 번호가 실시간 채널 방송인지 확인하고, 실시간 채널 방송으로 확인되면, 멀티 쓰레드 적용 대상으로 판단할 수 있다. 또한, 자막 데이터는 모든 실시간 채널에 적용되지 않고, 보통 지상파 등과 같은 일부 방송 채널에서만 제공되므로, 자막 서비스를 제공하는 실시간 채널 방송이면, 멀티 쓰레드 적용 대상으로 판단할 수 있다.According to one example, the video stream receiver 110 checks whether the channel number of the received video stream is a real-time channel broadcast based on the IPTV (Internet Protocol Television) schedule, and if confirmed to be a real-time channel broadcast, multi-threading is applied. You can judge. In addition, subtitle data is not applied to all real-time channels and is usually provided only on some broadcasting channels such as terrestrial channels, so if it is a real-time channel broadcast that provides a subtitle service, it can be determined to be subject to multi-threading.

또한, 영상 스트림 수신부(110)는 영상 스트림의 콘텐츠 식별자 등을 토대로 자막 데이터가 제공되는 VOD(Video On Demand) 서비스일 경우, 멀티 쓰레드 적용 대상으로 판단할 수 있다.Additionally, the video stream receiver 110 may determine that multi-threading is applicable in the case of a VOD (Video On Demand) service in which subtitle data is provided based on the content identifier of the video stream.

영상 스트림 수신부(110)는 수신된 영상 스트림이 멀티 쓰레드 적용 대상으로 판단되면, 영상 스트림을 AV 데이터 및 자막 데이터로 분리한다. 영상 스트림 수신부(110)는 AV 데이터를 영상 쓰레드에 할당하고, 자막 데이터를 자막 쓰레드에 할당한다. 이때, 자막 쓰레드는 자막 처리부(120)에 의해 처리되고, 영상 쓰레드는 영상 처리부(130)에 의해 처리된다.If the video stream receiver 110 determines that the received video stream is subject to multi-threading, it separates the video stream into AV data and subtitle data. The video stream receiver 110 allocates AV data to the video thread and subtitle data to the subtitle thread. At this time, the subtitle thread is processed by the subtitle processing unit 120, and the video thread is processed by the image processing unit 130.

일반적으로, 쓰레드는 프로세서 내에서 실행되는 흐름의 단위 또는 작업의 수행 단위를 의미할 수 있다. In general, a thread may refer to a unit of flow or task performance that runs within a processor.

자막 처리부(120)는 자막 쓰레드를 처리한다. The subtitle processing unit 120 processes the subtitle thread.

자막 처리부(120)는 자막 관리부(160)에게 자막 데이터를 제공한다. 자막 관리부(160)는 자막 데이터에 화면 설정 및/또는 자막 설정을 수행한 후, 화면 설정 및/또는 자막 설정된 자막 데이터를 자막 처리부(120)에게 제공한다. The subtitle processing unit 120 provides subtitle data to the subtitle management unit 160. The subtitle management unit 160 performs screen settings and/or subtitle settings on the subtitle data and then provides the subtitle data with the screen settings and/or subtitle settings to the subtitle processing unit 120.

자막 처리부(120)는 화면 설정 및/또는 자막 설정된 자막 데이터를 쇼 타임스탬프(Show TimeStamp)를 기준으로 그룹핑 한다. The subtitle processing unit 120 groups screen settings and/or subtitle set subtitle data based on a show timestamp.

자막 처리부(120)는 자막 데이터 그룹들을 시간에 따라 순차적으로 재생 처리부(140)로 출력한다.The subtitle processing unit 120 sequentially outputs subtitle data groups to the reproduction processing unit 140 according to time.

영상 처리부(130)는 영상 쓰레드를 처리한다. 영상 처리부(130)는 자막 관리부(160)로부터 전달받은 쇼 타임스탬프를 기준으로 AV 데이터를 분할하여 복수개의 AV 데이터 그룹을 생성한다. 영상 처리부(130)는 시간에 따라 순차적으로 AV 데이터 그룹들을 재생 처리부(140)로 출력한다.The image processing unit 130 processes image threads. The video processing unit 130 divides the AV data based on the show timestamp received from the subtitle management unit 160 to create a plurality of AV data groups. The image processing unit 130 sequentially outputs AV data groups to the playback processing unit 140 according to time.

재생 처리부(140)는 동일 그룹에 속하는 복수개의 자막 데이터 및 AV 데이터를 합성한 영상 스트림 화면을 생성하고, 생성한 영상 스트림 화면을 디스플레이 장치(150)에 출력한다.The playback processing unit 140 generates a video stream screen by combining a plurality of subtitle data and AV data belonging to the same group, and outputs the generated video stream screen to the display device 150.

이때, 실시예에 따른 영상 재생 장치(100)는 안드로이드 TV 구조를 사용한다. 따라서, 영상 재생 장치(100)는 구글 OS의 안드로이드 프레임워크(Android Framework)에서 제공하는 방송 스트림 처리를 위한 미디어 플레이어(Media Player)와 칩사 플레이어 2가지를 사용할 수 있다. 칩사 플레이어의 예시로서, Synaptics의 Synaplayer, Hisilicon의 Hiplayer가 있다.At this time, the video playback device 100 according to the embodiment uses the Android TV structure. Therefore, the video playback device 100 can use two types of media player and Chipsa player for broadcast stream processing provided by the Android Framework of Google OS. Examples of chip players include Synaptics' Synaplayer and Hisilicon's Hiplayer.

자막 처리부(120)는 칩사 플레이어에서 동작하고, 영상 처리부(130)와 재생 처리부(140)는 미디어 플레이어에서 동작할 수 있다.The subtitle processing unit 120 may operate in a Chipsa player, and the image processing unit 130 and playback processing unit 140 may operate in a media player.

종래에 리눅스(Linux), AOSP(Android Open Source Project)에서 방송 스트림을 처리할 수 있는 플레이어는 칩사 플레이어 하나뿐이므로, 하나의 쓰레드만 처리할 수 있다. 종래와 같이 쓰레드가 하나일 경우, 하나의 시간 로직에 따라 순차적으로 영상 스트림을 제어하기 때문에 AV 데이터, 자막 데이터의 출력만을 제어하게 되고, 별도의 타임 스탬프(Time Stamp) 또는 동기 지연 시간(sync delay time) 등을 계산할 수 없다. 왜냐하면, 하나의 쓰레드 사이클(Thread cycle)에서 AV 데이터와 자막 데이터를 처리하려면 병렬적으로 진행할 수밖에 없는데 이 경우, 시퀀스(sequence)가 꼬이는 상황이 빈번하게 발생될 수 있고, 복호화, 디코딩, 채널 튜닝 등의 타이밍에 영향을 줄 수 있다. 이로 인해, 화면 블랙, 신호 없음, 미가입 채널 오류 팝업, CAS 오류 등의 이슈가 발생될 수 있다.Conventionally, the only player that can process broadcast streams in Linux and AOSP (Android Open Source Project) is the Chipsa player, so only one thread can process it. As in the past, when there is only one thread, the video stream is controlled sequentially according to one time logic, so only the output of AV data and subtitle data is controlled, and a separate time stamp or sync delay is required. time) cannot be calculated. This is because, in order to process AV data and subtitle data in one thread cycle, there is no choice but to proceed in parallel, but in this case, situations in which the sequence is twisted can frequently occur, and decoding, decoding, channel tuning, etc. may affect the timing of. As a result, issues such as black screen, no signal, unsubscribed channel error pop-up, and CAS error may occur.

하지만, 안드로이드 TV 구조를 사용하는 본 발명의 실시예에서는 이종 미디어 플레이어를 통해 멀티 쓰레드를 처리할 수 있게 되었으므로, 종래와 같은 이슈를 발생시키지 않으면서 AV 데이터와 자막 데이터를 병렬로 처리할 수 있다.However, in the embodiment of the present invention using the Android TV structure, multi-thread processing is possible through heterogeneous media players, so AV data and subtitle data can be processed in parallel without causing the same issues as before.

이와 같이, 본 발명의 실시예에 따르면, 멀티 쓰레드 방식으로 AV 데이터와 자막 데이터를 동기화 시켜 출력하게 된다.As such, according to an embodiment of the present invention, AV data and subtitle data are synchronized and output in a multi-threaded manner.

종래와 같이, 하나의 쓰레드로 동작하는 경우, 자막이 표시되는 줄에 상관없이 바로 화면에 자막을 표시하고 일정 시간(예, 2~3초)이 지나면 해당 자막을 삭제하는 단순 구조이다. 반면, 본 발명에서와 같이 멀티 쓰레드로 동작하는 경우, 쇼 타임스탬프를 기준으로 정해진 자막 개수를 AV 데이터와 동기화 시켜 출력할 수 있게 된다.As in the past, when operating as a single thread, the subtitle is displayed on the screen immediately regardless of the line on which the subtitle is displayed, and the subtitle is deleted after a certain period of time (e.g., 2 to 3 seconds). On the other hand, when operating with multi-threading as in the present invention, the number of subtitles determined based on the show timestamp can be output in synchronization with AV data.

기본적으로, AV보다 자막이 상대적으로 수초간 지연되어 수신되는데, 재생 처리부(140)는 자막 쓰레드 사이클(Thread Cycle)을 통해서 텍스트 데이터(Text data)의 구문의 시작과 AV에서 말소리 음성 시작 부분의 시간 차이만큼의 지연 시간값을 계산할 수 있다. 방송사 스트림 및 콘텐츠 스트림마다 AV와 자막 시점 동기화 지연 시간(sync delay time)이 다르기 때문에 자막이 포함된 채널로 전환될 때마다 동기화 지연 시간의 계산이 필요하다. 즉, 재생 처리부(140)는 AV 쓰레드 사이클(Thread cycle)에서 스트림을 수신되는 대로 바로 HDMI(High-Definition Multimedia Interface) 출력하지 않고, 자막 쓰레드 사이클(Caption Thread cycle)에서 계산된 자막 데이터 수신 시간에 맞춰서 AV를 버퍼에 저장하고 HDMI 출력한다. 따라서, AV 데이터를 버퍼에 쌓아두는 시간만큼 지연하여 출력하고 자막 데이터는 유입되자마자 출력한다. Basically, subtitles are received with a relative delay of several seconds compared to AV, and the playback processing unit 140 determines the start of the phrase of the text data and the time of the beginning of the spoken voice in AV through the subtitle thread cycle. The delay time value equal to the difference can be calculated. Since the sync delay time between AV and subtitle points is different for each broadcaster stream and content stream, it is necessary to calculate the synchronization delay time every time the channel switches to a channel containing subtitles. That is, the playback processing unit 140 does not output the stream to HDMI (High-Definition Multimedia Interface) immediately as it is received in the AV thread cycle, but at the subtitle data reception time calculated in the caption thread cycle. Accordingly, the AV is stored in the buffer and output to HDMI. Therefore, the AV data is output delayed by the time it is stored in the buffer, and the subtitle data is output as soon as it is received.

자막 기능이 온되면 자막 데이터가 없는 일반 채널 이동시에는 이상이 없지만, 자막 데이터가 있는 일부 채널(지상파 등)로 이동시 채널 전환 속도가 5초 이내의 지연 시간이 발생할 수 있다. 재생 처리부(140)는 실제 방송 시점보다 몇 초간 늦게 방송될 수 있음을 안내하는 화면을 디스플레이 장치(150)를 통해 팝업 할 수 있다.When the subtitle function is turned on, there is no problem when moving to a general channel without subtitle data, but when moving to some channels (terrestrial, etc.) with subtitle data, a delay of less than 5 seconds may occur in the channel switching speed. The playback processing unit 140 may pop up a screen through the display device 150 informing that the broadcast may be several seconds later than the actual broadcast time.

또한, 자막 그래픽을 생성하면서 발생되는 지연 시간은 수 ms 정도에 불과하다. 따라서, 자막 그래픽의 지연 시간으로 인해 AV와 자막 간의 동기화 실패보다는 AV와 자막이 서로 매칭되지 않아 이로 인한 수 초의 비동기화(unsync) 구간으로 인한 동기화 실패가 더 많다. 그러나, 본 발명의 실시예에서는 자막과 AV를 쇼 타임스탬프 기준으로 맵핑하므로 동기화 성능을 개선할 수 있다.Additionally, the delay time that occurs while generating subtitle graphics is only a few ms. Therefore, there are more synchronization failures due to unsynchronization intervals of several seconds due to AV and subtitles not matching each other than synchronization failures between AV and subtitles due to the delay time of subtitle graphics. However, in the embodiment of the present invention, synchronization performance can be improved because subtitles and AV are mapped based on the show timestamp.

추가로, 자막 그래픽을 생성하면서 발생되는 지연 시간(예, 수 ms)은 단말의 CPU/GPU 성능에 따라 다를 수 있는데, 이 부분은 동기화 지연 시간(sync delay time)에 추가할 수 있으므로, 그래픽 성능이 떨어지는 단말의 경우도 커버할 수 있다.Additionally, the delay time (e.g., several ms) that occurs while generating subtitle graphics may vary depending on the CPU/GPU performance of the terminal, and this part can be added to the sync delay time, so graphics performance This case of falling terminals can also be covered.

자막 관리부(160)는 자막 설정부(170)로부터 입력 받은 자막 설정 데이터 및/또는 화면 설정부(180)로부터 입력 받은 화면 설정 데이터에 기초하여 쇼 타임스탬프(Show TimeStamp) 크기를 설정한다. The subtitle management unit 160 sets the Show TimeStamp size based on the subtitle setting data input from the subtitle setting unit 170 and/or the screen setting data input from the screen setting unit 180.

자막 설정 데이터 및 화면 설정 데이터는 사용자 입력에 따라 설정되거나 서비스 사업자에 의해 설정될 수 있다.Subtitle setting data and screen setting data may be set according to user input or may be set by the service provider.

자막 설정 데이터는 자막 온(On)/오프(Off), 자막 언어(영어, 한국어), 자막 크기(작게, 중간, 크게), 자막 크기, 글자 수, 띄어쓰기, 줄 바꿈 등을 포함할 수 있다.Subtitle setting data may include subtitle on/off, subtitle language (English, Korean), subtitle size (small, medium, large), subtitle size, number of characters, spacing, line breaks, etc.

화면 설정 데이터는 화면 해상도(720p, 1080p, 2160p)와 화면 비율(16:9, 4:3 등)을 포함할 수 있다.Screen setting data may include screen resolution (720p, 1080p, 2160p) and screen ratio (16:9, 4:3, etc.).

자막 설정부(170)는 영상 재생 장치(100)에 설치된 앱으로써, 사용자가 자막 설정을 할 수 있도록 사용자 인터페이스를 제공할 수 있다.The subtitle setting unit 170 is an app installed on the video playback device 100 and can provide a user interface so that the user can set subtitles.

화면 설정부(180)는 영상 재생 장치(100)에 설치된 앱으로써, 사용자가 화면 설정을 할 수 있도록 사용자 인터페이스를 제공할 수 있다.The screen setting unit 180 is an app installed on the video playback device 100 and can provide a user interface so that the user can set the screen.

자막 관리부(160)는 PTS(Presentation Time Stamp) 계산시 사용하는 STC(System Time Clock)를 토대로 쇼 타임스탬프를 지정할 수 있다. 즉, 자막 관리부(160)에 의해 계산된 다음 쇼 타임스탬프 크기에 따라 해당되는 STC 시점을 계산할 수 있다.The subtitle management unit 160 can specify a show timestamp based on the System Time Clock (STC) used when calculating the Presentation Time Stamp (PTS). That is, the corresponding STC point can be calculated according to the size of the next show timestamp calculated by the subtitle management unit 160.

자막 관리부(160)는 복수의 자막 데이터가 매핑되는 AV의 타임 인덱스에 기초하여 쇼 타임스탬프 크기를 설정할 수 있다.The subtitle management unit 160 may set the show timestamp size based on the time index of the AV to which a plurality of subtitle data is mapped.

이때, 자막 설정부(170)를 통해 글자 크기(작게, 중간, 크게)가 설정되고, 화면 설정부(180)를 통해 화면 비율, 해상도가 설정될 수 있다. At this time, the font size (small, medium, large) can be set through the subtitle setting unit 170, and the screen ratio and resolution can be set through the screen setting unit 180.

자막 관리부(160)는 자막 설정부(170)와 화면 설정부(180)의 설정에 맞게 한 줄에 출력할 최대 글자 개수를 산정하고, 자막 데이터를 줄 단위로 나누어 쇼 타임스탬프 크기를 설정할 수 있다. 즉, 최대 글자 개수를 쇼 타임스탬프 크기로 설정할 수 있다.The subtitle management unit 160 calculates the maximum number of characters to be output in one line according to the settings of the subtitle setting unit 170 and the screen setting unit 180, and sets the show timestamp size by dividing the subtitle data by line. . In other words, the maximum number of characters can be set to the show timestamp size.

여기서, 한 줄에 출력할 수 있는 최대 글자 수는 칩(CPU(Central Processing Unit)/GPU(Graphic Processing Unit))의 그래픽 성능과 글자의 선명함 정도, 사업자의 셋팅 정보(예, 글자 크기 등)에 따라 달라질 수 있기 때문에 수동으로 입력된 값이 이용될 수 있다. 자막 관리부(160)는 수동 입력에 따라 예를 들어, 해상도 720p이고, 화면 비율 16:9이고, 글자 크기 작게로 설정된 경우, 한 줄에 출력할 최대 글자수는 21개로 설정할 수 있다.Here, the maximum number of characters that can be printed on one line depends on the graphics performance of the chip (CPU (Central Processing Unit)/GPU (Graphic Processing Unit)), the degree of clarity of the characters, and the operator's setting information (e.g., font size, etc.). Since it may vary depending on the value, manually entered values may be used. Depending on manual input, for example, when the resolution is 720p, the screen ratio is 16:9, and the font size is set to small, the subtitle management unit 160 can set the maximum number of characters to be output on one line to 21.

자막 관리부(160)는 사전에 해상도, 화면 비율, 글자 크기에 따라 한 줄에 출력할 글자 개수를 지정해둘 수 있으며, 이를 표 1, 표 2와 같이 화면 비율 별로 해상도와 글자 크기를 맵핑한 테이블 형태로 구성하여 저장할 수 있다.The subtitle management unit 160 can specify in advance the number of characters to be output on one line according to resolution, screen ratio, and font size, and this is in the form of a table mapping resolution and font size for each screen ratio, as shown in Tables 1 and 2. It can be configured and saved.

화면 비율
16:9
screen ratio
16:9
글자 크기font size
작게small 보통commonly 크게big 해상도resolution 720p720p 2121 1717 1515 1080i1080i 2323 1919 1717 1080p1080p 2323 1919 1717 2160 30p2160 30p 2525 2121 1919 2160 60p2160 60p 2525 2121 1919

화면 비율
4:3
screen ratio
4:3
글자 크기font size
작게small 보통commonly 크게big 해상도resolution 720p720p 1919 1515 1313 1080i1080i 2121 1717 1515 1080p1080p 2121 1717 1515 2160 30p2160 30p 2323 1919 1717 2160 60p2160 60p 2323 1919 1717

자막 관리부(160)가 쇼 타임스탬프를 영상 스트림 수신부자막 처리부(120) 및 영상 처리부(130)에게 제공한다. 그러면, 자막 처리부(120)는 쇼 타임스탬프를 기준으로 복수의 자막 데이터를 그룹핑 하고, 쇼 타임스탬프 순서대로 동일 그룹 단위로 복수의 자막 데이터를 재생 처리부(140)로 출력한다. 영상 처리부(130)는 쇼 타임 스탬프를 기준으로 AV 데이터를 분할하여 그룹핑 하고, 쇼 타임스탬프 순서대로 분할된 AV 데이터를 재생 처리부(140)로 출력한다.The subtitle management unit 160 provides the show timestamp to the video stream receiving subtitle processing unit 120 and the video processing unit 130. Then, the subtitle processing unit 120 groups the plurality of subtitle data based on the show timestamp and outputs the plurality of subtitle data to the playback processing unit 140 in the same group unit in the order of the show timestamp. The video processing unit 130 divides and groups the AV data based on the show time stamp, and outputs the divided AV data in the order of the show time stamp to the playback processing unit 140.

분할한 AV 데이터는 전체 심리스한 AV를 쇼 타임스탬프를 기초로 구간을 나눈 데이터를 의미한다.Segmented AV data refers to data that divides the entire seamless AV into sections based on the show timestamp.

도 2를 참조하면, 영상 스트림 수신부(110)는 9개의 자막 데이터와 하나의 AV 데이터를 수신할 수 있다. Referring to FIG. 2, the video stream receiver 110 can receive nine subtitle data and one AV data.

영상 스트림 수신부(110)는 9개의 자막 데이터를 처리하는 자막 쓰레드와 9개의 자막 데이터 및 하나의 AV 데이터를 처리하는 영상 쓰레드를 생성한다.The video stream receiver 110 creates a subtitle thread that processes nine subtitle data and a video thread that processes nine subtitle data and one AV data.

자막 쓰레드는 자막 처리부(120)에 의해 처리되고, 영상 쓰레드는 영상 처리부(130)에 의해 처리된다.The subtitle thread is processed by the subtitle processing unit 120, and the video thread is processed by the video processing unit 130.

자막 처리부(120)는 자막 관리부(160)로부터 제공받은 쇼 타임스탬프들을 기준으로 9개의 자막 데이터를 3개의 그룹으로 분할할 수 있다. 즉, 자막 쓰레드 사이클에 따르면, 자막 1, 2, 3, 4는 쇼 타임스탬프(Show TimsStamp) 1 구간에 맵핑되고, 자막 5, 6, 7은 쇼 타임스탬프 2 구간에 맵핑되며, 자막 8, 9는 쇼 타임스탬프 3 구간에 맵핑 된다. The subtitle processing unit 120 may divide nine subtitle data into three groups based on show timestamps provided from the subtitle management unit 160. That is, according to the subtitle thread cycle, subtitles 1, 2, 3, and 4 are mapped to Show TimsStamp 1 section, subtitles 5, 6, and 7 are mapped to Show Timestamp 2 section, and subtitles 8 and 9. is mapped to section 3 of the show timestamp.

영상 처리부(130)는 자막 관리부(160)로부터 제공받은 쇼 타임스탬프들에 기초하여 하나의 AV 데이터를 3개의 AV 데이터로 분할한다. AV 쓰레드 싸이클에 따르면, AV 1은 쇼 타임스탬프 1 구간에 맵핑되고, AV 2는 쇼 타임스탬프 2 구간에 맵핑되고, AV 3는 쇼 타임스탬프 3 구간에 맵핑된다.The image processing unit 130 divides one AV data into three AV data based on the show timestamps provided from the subtitle management unit 160. According to the AV thread cycle, AV 1 is mapped to the show timestamp 1 section, AV 2 is mapped to the show timestamp 2 section, and AV 3 is mapped to the show timestamp 3 section.

재생 처리부(140)는 동일한 쇼 타임스탬프 구간에 맵핑된 자막과 AV를 동기화 시켜 쇼 타임스탬프의 시간 순서대로 한 화면에 출력한다. 즉, 가장 빠른 시간인 쇼 타임스탬프 1에 속하는 AV 1과 자막 1, 2, 3, 4를 동기화 시켜 한 화면에 출력한다.The playback processing unit 140 synchronizes the subtitles and AV mapped to the same show timestamp section and outputs them on one screen in chronological order of the show timestamp. In other words, AV 1, which belongs to the earliest show timestamp 1, and subtitles 1, 2, 3, and 4 are synchronized and displayed on one screen.

재생 처리부(140)는 다음 시간인 쇼 타임스탬프 2에 속하는 AV 2와 자막 5, 6, 7을 동기화 시켜 한 화면에 출력한다.The playback processing unit 140 synchronizes AV 2 and subtitles 5, 6, and 7 belonging to show timestamp 2, which is the next time, and outputs them on one screen.

재생 처리부(140)는 다음 시간인 쇼 타임스탬프 3에 속하는 AV 3과 자막 8, 9, 10, 11을 동기화 시켜 한 화면에 출력한다.The playback processing unit 140 synchronizes AV 3 and subtitles 8, 9, 10, and 11 belonging to show timestamp 3, which is the next time, and outputs them on one screen.

이와 같은 방식으로 영상 스트림을 제어하면, 도 3과 같이 한 화면에 가독성이 좋은 자막 데이터를 표시할 수 있게 된다. By controlling the video stream in this way, it is possible to display easily readable subtitle data on one screen, as shown in FIG. 3.

즉, 도 3의 (a)에 따르면, 뉴스 시작 멘트(시청자 여러분 안녕하십니까 8시 뉴스 곧 시작하겠습니다)가 표시된 자막과 그에 대응하는 AV가 한 화면에 표시된다. That is, according to (a) of Figure 3, a subtitle with a news start comment (Hello viewers, the 8 o'clock news will start soon) and the corresponding AV are displayed on one screen.

도 3의 (b)에 따르면, 첫번째 뉴스 멘트(첫번째 뉴스입니다. 비만 면역 백신 소식입니다.)와 같은 자막과 그에 대응하는 AV가 한 화면에 표시된다. 이때, 쇼 타임스탬프는 한 줄에 표시할 글자 수를 고려하여 설정될 수 있으므로, 도 3과 같이 가독성이 좋은 자막 표시가 가능하다.According to (b) of Figure 3, a subtitle such as the first news comment (this is the first news. It is news about an obesity immunity vaccine) and the corresponding AV are displayed on one screen. At this time, the show timestamp can be set considering the number of characters to be displayed in one line, so subtitles can be displayed with good readability as shown in FIG. 3.

이와 달리, 종래에는 도 4와 같이, 자막 데이터는 수신되는 순서대로, 혹은 정해진 타임 인덱스대로 순차적으로 출력되고, AV 데이터는 동일하게 표시된다. In contrast, conventionally, as shown in FIG. 4, subtitle data is sequentially output in the order in which it is received or according to a determined time index, and AV data is displayed in the same manner.

즉, 동일한 AV 화면에 자막 데이터가 순차적으로 반복 출력되는 방식이므로, 자막과 화면의 동기화에 실패할 수 있다. In other words, since subtitle data is sequentially and repeatedly output on the same AV screen, synchronization of the subtitles and the screen may fail.

도 5의 (a), (b), (c)에 따르면, AV 화면은 동일하고 자막만 순차적으로 출력되고 일정 시간이 경과하면 표시된 자막이 사라지는 방식이다. According to Figures 5 (a), (b), and (c), the AV screen is the same, only subtitles are output sequentially, and the displayed subtitles disappear after a certain period of time.

따라서, 도 5의 (a)와 같이, '시청자'가 표시되고, 도 5의 (b)와 같이, '시청자'에 이어 '여러분'이 표시되고, 도 5의 (c)와 같이, '시청자'는 사라지고, '안녕하십니까'라는 자막이 표시된다. 따라서, 동일한 화면에서 여러 번의 자막이 표시되었다가 사라지므로, AV 화면과 동기화가 안맞을 수 있고, 일부 자막은 사라지므로 자막 가독성이 좋지 않을 수 있다.Therefore, as shown in Figure 5(a), 'viewer' is displayed, as shown in Figure 5(b), 'viewer' is followed by 'you', and as shown in Figure 5(c), 'viewer' is displayed. ' disappears, and the subtitle 'Hello' is displayed. Therefore, subtitles may appear and disappear multiple times on the same screen, which may cause them to be out of synchronization with the AV screen, and some subtitles may disappear, resulting in poor subtitle readability.

그러나, 본 발명의 실시예에서는 자막과 AV를 그룹핑하여 한번에 출력하므로, 동기화된 화면을 제공할 수 있게 된다.However, in an embodiment of the present invention, subtitles and AV are grouped and output at once, making it possible to provide a synchronized screen.

도 6은 한 실시예에 따른 영상 재생 장치의 자막 동기화 방법을 나타낸 순서도로서, 도 1 ~ 도 5의 구성과 연계하여 설명한다.FIG. 6 is a flowchart showing a subtitle synchronization method of a video playback device according to an embodiment, which is explained in connection with the configuration of FIGS. 1 to 5.

도 6을 참조하면, 영상 스트림 수신부(110)가 서버(300)로부터 AV 데이터 및 AV 데이터와 관련된 복수의 자막 데이터를 포함하는 영상 스트림을 수신한다(S101).Referring to FIG. 6, the video stream receiver 110 receives a video stream including AV data and a plurality of subtitle data related to the AV data from the server 300 (S101).

영상 스트림 수신부(110)는 채널 번호 또는 콘텐츠 식별자 등에 기초하여, 영상 스트림이 멀티 쓰레드 대상으로 판단(S102)되면, 영상 스트림으로부터 AV 데이터와 복수의 자막 데이터를 분리한다(S103).If the video stream receiver 110 determines that the video stream is a multi-thread target based on a channel number or content identifier (S102), it separates AV data and a plurality of subtitle data from the video stream (S103).

이때, 영상 스트림이 멀티 쓰레드 대상이 아니면, 멀티 쓰레드 대상인 영상 스트림 수신 대기 상태가 되거나, 아니면, 해당 영상 스트림에 대한 기본 동작(본 발명의 실시예를 적용하지 않은 단말 동작)을 수행한다(S104).At this time, if the video stream is not a multi-thread target, the video stream that is a multi-thread target is put into a waiting state, or a basic operation (terminal operation without applying the embodiment of the present invention) for the video stream is performed (S104) .

영상 스트림 수신부(110)는 분리한 AV 데이터를 영상 처리부(130)에 의해 실행되는 영상 쓰레드에 할당하고, 분리한 복수의 자막 데이터를 자막 처리부(120)에 의해 실행되는 자막 쓰레드에 할당한다(S105).The video stream receiver 110 allocates the separated AV data to the video thread executed by the video processing unit 130, and assigns a plurality of separated subtitle data to the subtitle thread executed by the subtitle processing unit 120 (S105) ).

자막 관리부(160)는 자막 설정부(170)를 통해 입력 받은 자막 설정 데이터 및/또는 화면 설정부(180)를 통해 입력 받은 화면 설정 데이터를 토대로, 쇼 타임스탬프 크기를 설정한다(S106).The subtitle management unit 160 sets the show timestamp size based on the subtitle setting data input through the subtitle setting unit 170 and/or the screen setting data input through the screen setting unit 180 (S106).

자막 처리부(120)는 자막 관리부(160)로부터 제공받은 쇼 타임스탬프 크기 단위로, 복수의 자막 데이터를 그룹핑하고, 영상 처리부(130)는 자막 관리부(160)로부터 제공받은 쇼 타임스탬프 크기 단위로, AV 데이터를 복수개로 분할하여 그룹핑한다(S107).The subtitle processing unit 120 groups a plurality of subtitle data in units of show timestamp size provided from the subtitle management unit 160, and the video processing unit 130 groups the subtitle data in units of show timestamp size provided from the subtitle management unit 160, The AV data is divided into multiple pieces and grouped (S107).

재생 처리부(140)는 동일 그룹에 속하는 AV 데이터 및 복수의 자막 데이터를 하나의 화면에 출력되도록 제어한다(S108). 즉, 재생 처리부(140)는 동일한 쇼 타임스탬프 구간에 속하는 AV 데이터와 복수의 자막 데이터를 합성하여 하나의 화면으로 구성하여 디스플레이 장치(150)에 출력한다.The playback processing unit 140 controls AV data and multiple subtitle data belonging to the same group to be output on one screen (S108). That is, the playback processing unit 140 combines AV data and a plurality of subtitle data belonging to the same show timestamp section to form one screen and outputs it to the display device 150.

한편, 도 7은 실시예에 따른 자막 동기화를 수행하는 영상 재생 장치의 하드웨어 구성을 나타낸 블록도이다.Meanwhile, Figure 7 is a block diagram showing the hardware configuration of a video playback device that performs subtitle synchronization according to an embodiment.

도 7을 참조하면, 도 1 ~ 도 6에서 설명한 영상 재생 장치(100)는 적어도 하나의 프로세서에 의해 동작하는 컴퓨팅 장치(400)로서, 적어도 하나의 프로세서(410), 메모리(420), 스토리지(430), 통신 장치(440), 입력 장치(450), 디스플레이 장치(460)를 포함할 수 있고, 버스(470)를 통해 연결될 수 있다. Referring to FIG. 7, the video playback device 100 described in FIGS. 1 to 6 is a computing device 400 operated by at least one processor, including at least one processor 410, memory 420, and storage ( 430), a communication device 440, an input device 450, and a display device 460, and may be connected through a bus 470.

하드웨어 장치에 의해 제공되는 물리적인 컴퓨팅 자원은 가상화될 수 있다.Physical computing resources provided by hardware devices can be virtualized.

프로세서(410)는 컴퓨팅 장치의 동작을 제어하는 장치로서, 컴퓨터 프로그램에 포함된 명령들을 처리하는 다양한 형태의 프로세서일 수 있고, 예를 들면, CPU(Central Processing Unit), MPU(Micro Processor Unit), MCU(Micro Controller Unit), GPU(Graphic Processing Unit) 등 일 수 있다. 또한, 프로세서(410)는 도 1 ~ 도 6에서 설명한 방법을 실행하기 위한 컴퓨터 프로그램에 대한 연산을 수행할 수 있다.The processor 410 is a device that controls the operation of a computing device and may be various types of processors that process instructions included in a computer program, for example, a Central Processing Unit (CPU), a Micro Processor Unit (MPU), It may be an MCU (Micro Controller Unit), GPU (Graphics Processing Unit), etc. Additionally, the processor 410 may perform operations on a computer program to execute the methods described in FIGS. 1 to 6 .

메모리(420)는 각종 데이터, 명령 및/또는 정보를 저장한다. 메모리(420)는 본 개시의 동작을 실행하도록 기술된 명령어들이 프로세서(410)에 의해 처리되도록 해당 컴퓨터 프로그램을 스토리지(430)로부터 로드할 수 있다. 메모리(420)는 예를 들면, ROM(read only memory), RAM(random access memory) 등 일 수 있다. The memory 420 stores various data, commands and/or information. Memory 420 may load a corresponding computer program from storage 430 so that instructions described to execute operations of the present disclosure are processed by processor 410. The memory 420 may be, for example, read only memory (ROM), random access memory (RAM), etc.

프로세서(410)는 도 1 ~ 도 6에서 설명한 영상 스트림 수신부(110), 자막 처리부(120), 영상 처리부(130), 재생 처리부(140), 자막 관리부(160), 자막 설정부(170), 및 화면 설정부(180)의 동작을 실행하도록 기술된 명령어들을 메모리(420)에 로드하여 구동할 수 있다.The processor 410 includes the video stream receiving unit 110, the subtitle processing unit 120, the video processing unit 130, the playback processing unit 140, the subtitle management unit 160, and the subtitle setting unit 170 described in FIGS. 1 to 6. And instructions described to execute the operations of the screen setting unit 180 can be loaded into the memory 420 and driven.

스토리지(430)는 본 개시의 동작을 실행하는데 요구되는 각종 데이터, 컴퓨터 프로그램 등을 저장할 수 있다. 스토리지(430)는 컴퓨터 프로그램을 비임시적으로 저장할 수 있다. 스토리지(430)는 비휘발성 메모리로 구현될 수 있다. The storage 430 can store various data, computer programs, etc. required to execute the operations of the present disclosure. Storage 430 may non-temporarily store computer programs. Storage 430 may be implemented as non-volatile memory.

통신 장치(440)는 유/무선 통신 모듈일 수 있다. 입력 장치(450)에 의해 입력된 정보는 프로세서(410)로 전달되고, 프로세서(410)의 구동에 따른 정보를 디스플레이 장치(460)에 출력할 수 있다.The communication device 440 may be a wired/wireless communication module. Information input by the input device 450 is transmitted to the processor 410, and information according to the operation of the processor 410 may be output to the display device 460.

이상에서 설명한 본 개시의 실시예는 장치 및 방법을 통해서만 구현이 되는 것은 아니며, 본 개시의 실시예의 구성에 대응하는 기능을 실현하는 프로그램 또는 그 프로그램이 기록된 기록 매체를 통해 구현될 수도 있다.The embodiments of the present disclosure described above are not only implemented through devices and methods, but may also be implemented through programs that implement functions corresponding to the configurations of the embodiments of the present disclosure or recording media on which the programs are recorded.

이상에서 본 개시의 실시예에 대하여 상세하게 설명하였지만 본 개시의 권리범위는 이에 한정되는 것은 아니고 다음의 청구범위에서 정의하고 있는 본 개시의 기본 개념을 이용한 당업자의 여러 변형 및 개량 형태 또한 본 개시의 권리범위에 속하는 것이다.Although the embodiments of the present disclosure have been described in detail above, the scope of the rights of the present disclosure is not limited thereto, and various modifications and improvements made by those skilled in the art using the basic concept of the present disclosure defined in the following claims are also possible. It falls within the scope of rights.

Claims (5)

영상 재생 장치의 동작 방법으로서,
네트워크를 통해 연결된 서버로부터 영상 스트림을 수신하는 단계,
상기 영상 스트림을 AV(AudioVideo) 데이터와 복수개의 자막 데이터로 분리하는 단계,
상기 AV 데이터를 설정된 쇼 타임스탬프(Show Timestamp) 단위로 분할하는 단계,
상기 복수개의 자막 데이터를 상기 쇼 타임스탬프 단위로 그룹핑 하는 단계, 그리고
화면에 출력되는 상기 AV 데이터의 현재 쇼 타임스탬프에 맞춰, 상기 현재 쇼 타임스탬프에 속하는 자막 데이터를 상기 화면에 출력하는 단계
를 포함하는, 방법.
As a method of operating a video playback device,
Receiving a video stream from a server connected through a network,
Separating the video stream into AV (AudioVideo) data and a plurality of subtitle data,
Dividing the AV data into set Show Timestamp units,
Grouping the plurality of subtitle data by the show timestamp, and
A step of outputting subtitle data belonging to the current show timestamp on the screen according to the current show timestamp of the AV data displayed on the screen.
Method, including.
제1항에서,
상기 분할하는 단계 이전에,
글자 크기, 화면 비율, 해상도 중 적어도 하나를 이용하여 한 줄에 출력할 최대 글자 개수를 산정하고, 산정한 최대 글자 개수를 쇼 타임스탬프 크기로 설정하는 단계
를 더 포함하는, 방법.
In paragraph 1:
Before the dividing step,
Calculating the maximum number of characters to be displayed on one line using at least one of character size, screen ratio, and resolution, and setting the calculated maximum number of characters as the show timestamp size.
A method further comprising:
제2항에서,
상기 설정하는 단계 이전에,
사용자 입력에 따른 화면 비율, 해상도 및 글자 크기 레벨을 확인하는 단계를 더 포함하고,
상기 설정하는 단계는,
화면 비율, 해상도, 그리고 글자 크기 레벨에 각각의 최대 글자 개수를 맵핑한 테이블로부터 상기 확인한 화면 비율, 해상도 및 글자 크기 레벨에 대응하는 최대 글자 개수를 확인하고, 확인한 최대 글자 개수를 쇼 타임스탬프 크기로 설정하는 방법.
In paragraph 2,
Before the setting step,
Further comprising the step of checking the screen ratio, resolution, and font size level according to user input,
The setting step is,
From a table that maps the maximum number of characters to each aspect ratio, resolution, and font size level, check the maximum number of characters corresponding to the confirmed screen ratio, resolution, and font size level, and use the confirmed maximum number of characters as the show timestamp size. How to set it up.
제1항에서,
상기 설정하는 단계 이전에,
PTS(Presentation Time Stamp) 계산시 사용하는 STC(System Time Clock)를 이용하여 쇼 타임스탬프 크기를 설정하는 단계
를 더 포함하는, 방법.
In paragraph 1:
Before the setting step,
Step to set the show timestamp size using STC (System Time Clock), which is used when calculating PTS (Presentation Time Stamp)
A method further comprising:
제1항에서,
상기 분리하는 단계 이전에,
상기 영상 스트림이 수신된 채널 번호 또는 콘텐츠 식별자에 기초하여 상기 영상 스트림이 멀티 쓰레드 대상인지 판단하는 단계를 더 포함하고,
상기 분리하는 단계는,
상기 멀티 쓰레드 대상으로 판단된 영상 스트림을 복수의 자막 데이터와 AV 데이터로 분리하는, 방법.
In paragraph 1:
Before the separation step,
Further comprising determining whether the video stream is a multi-threaded target based on the channel number or content identifier through which the video stream was received,
The separating step is,
A method of separating the video stream determined to be a multi-thread target into a plurality of subtitle data and AV data.
KR1020220144566A 2022-11-02 2022-11-02 Method for synchronizing subtitles data and av data KR20240062731A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020220144566A KR20240062731A (en) 2022-11-02 2022-11-02 Method for synchronizing subtitles data and av data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020220144566A KR20240062731A (en) 2022-11-02 2022-11-02 Method for synchronizing subtitles data and av data

Publications (1)

Publication Number Publication Date
KR20240062731A true KR20240062731A (en) 2024-05-09

Family

ID=91075575

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020220144566A KR20240062731A (en) 2022-11-02 2022-11-02 Method for synchronizing subtitles data and av data

Country Status (1)

Country Link
KR (1) KR20240062731A (en)

Similar Documents

Publication Publication Date Title
US7460173B2 (en) Method and apparatus for synchronizing audio and video data
CN110278474B (en) Receiving method, transmitting method, receiving device and transmitting device
JP4871635B2 (en) Digital broadcast receiving apparatus and control method thereof
US20160066055A1 (en) Method and system for automatically adding subtitles to streaming media content
US8640180B2 (en) Apparatus and method for client-side compositing of video streams
US20030002578A1 (en) System and method for timeshifting the encoding/decoding of audio/visual signals in real-time
CN112601101B (en) Subtitle display method and device, electronic equipment and storage medium
US10945020B2 (en) Electronic apparatus and method of operating the same
CN112616062B (en) Subtitle display method and device, electronic equipment and storage medium
WO2020134791A1 (en) Method and apparatus for mixing streaming media data, storage medium, and computer device
US6384870B1 (en) Method for synchronizing HDTV format change with on screen display
US20040250293A1 (en) System and method for providing alternate program services
TWI770583B (en) Method, non-transitory computer-readable storage medium, and computing system for using broadcast-schedule data to facilitate performing a content-modification operation
CN115623264A (en) Live stream subtitle processing method and device and live stream playing method and device
CN102413335A (en) Manual adjustment device and method for program audio and video synchronization
KR20240062731A (en) Method for synchronizing subtitles data and av data
CN114189737A (en) Digital television and rapid channel switching method thereof
JP6399686B2 (en) Receiving machine
CN108769768B (en) DVB subtitle synchronization method and system
KR100430876B1 (en) Apparatus and Method for Margin Adjustment in Digital Television Set
US9930403B2 (en) Data stream processing apparatus
KR100539521B1 (en) Apparatus for processing audio information in Digital Television
KR100461540B1 (en) Apparatus and Method for Buffering Sychronized Non_streaming Data
Sivakumar Encoding of Closed Caption in a Video Using Matlab
KR20060098793A (en) Digital broadcast terminal and the method of broadcast display using the terminal