KR102313323B1 - Video incoding device and video incoding method - Google Patents

Video incoding device and video incoding method Download PDF

Info

Publication number
KR102313323B1
KR102313323B1 KR1020200044241A KR20200044241A KR102313323B1 KR 102313323 B1 KR102313323 B1 KR 102313323B1 KR 1020200044241 A KR1020200044241 A KR 1020200044241A KR 20200044241 A KR20200044241 A KR 20200044241A KR 102313323 B1 KR102313323 B1 KR 102313323B1
Authority
KR
South Korea
Prior art keywords
video
time
time value
playback
pts
Prior art date
Application number
KR1020200044241A
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 KR1020200044241A priority Critical patent/KR102313323B1/en
Application granted granted Critical
Publication of KR102313323B1 publication Critical patent/KR102313323B1/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/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/234Processing of video elementary streams, e.g. splicing of video streams, manipulating MPEG-4 scene graphs
    • H04N21/2343Processing of video elementary streams, e.g. splicing of video streams, manipulating MPEG-4 scene graphs involving reformatting operations of video signals for distribution or compliance with end-user requests or end-user device requirements
    • H04N21/234345Processing of video elementary streams, e.g. splicing of video streams, manipulating MPEG-4 scene graphs involving reformatting operations of video signals for distribution or compliance with end-user requests or end-user device requirements the reformatting operation being performed only on part of the stream, e.g. a region of the image or a time segment
    • 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/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/44004Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving video buffer management, e.g. video decoder buffer or video display buffer
    • 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/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/4402Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display
    • H04N21/440245Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display the reformatting operation being performed only on part of the stream, e.g. a region of the image or a time segment
    • 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

Abstract

The present invention relates to a moving image encoding device and to a moving image encoding method. The moving image encoding device uses three time values (PCR, DTS, and PTS) of video and audio in Mpeg-TS to realize a technology which maintains a buffering role while minimizing the delay of initial video playback.

Description

동영상 인코딩장치 및 동영상 인코딩방법{VIDEO INCODING DEVICE AND VIDEO INCODING METHOD}Video encoding device and video encoding method

본 발명은, 동영상을 재생하는 기술에 관한 것으로, 보다 구체적으로는 동영상 전송 기술인 Mpeg-TS(Transport Stream)에서 동영상 초기 재생의 지연을 최소화시키기 위한 것이다.The present invention relates to a technology for reproducing a moving picture, and more particularly, to minimize the delay of an initial reproduction of a moving picture in Mpeg-TS (Transport Stream), which is a moving picture transmission technology.

동영상 전송 기술인 Mpeg-TS(Transport Stream)에서는, 3가지 즉 PCR(Program Clock Reference), DTS(Decoding Time Stamp), PTS(Presentation Time Stamp) 시간값을 가지고 비디오 및 오디오가 출력된다. In Mpeg-TS (Transport Stream), which is a moving picture transmission technology, video and audio are output with three time values: Program Clock Reference (PCR), Decoding Time Stamp (DTS), and Presentation Time Stamp (PTS).

PCR은, Mpeg-2 TS 내 하나의 프로그램(PMT 테이블에 할당된 특정 PID)에 적용되는 시간기준값이며, Player가 동영상 재생을 위한 기준 시간을 잡기 위해 사용한다.PCR is a time reference value applied to one program (a specific PID assigned to the PMT table) in the Mpeg-2 TS, and is used by the Player to set the reference time for video playback.

DTS는, 디코딩 순서가 오류 없이 유지되도록 하기 위한 시간값(이하, 디코딩시간값)으로서, 영상의 각 비디오 및 오디오 마다 출력 전 디코딩(Decoding)을 처리하는 시간을 나타낸다.The DTS is a time value (hereinafter, referred to as a decoding time value) for maintaining the decoding order without errors, and indicates a time for processing decoding before output for each video and audio of an image.

MPEG 시스템에서는 비디오의 부호화된 비트열(스트림)의 송출 순서가 다소 특별하기 때문에, Player가 영상의 각 비디오 및 오디오에 정해져 있는 디코딩시간값(DTS)를 사용하여 디코딩 순서를 바르게 유지할 수 있다.In the MPEG system, since the transmission order of the encoded bit string (stream) of the video is somewhat special, the player can maintain the decoding order correctly by using the decoding time value (DTS) determined for each video and audio of the image.

PTS는, 재생순서가 오류 없이 유지되도록 하기 위한 시간값(이하, 재생시간값)으로서, 디코딩된 비디오 및 오디오를 화면에 출력하는 시간을 나타낸다.The PTS is a time value (hereinafter, referred to as a playback time value) for maintaining a playback order without errors, and indicates a time for outputting decoded video and audio to the screen.

이에, MPEG 시스템에서 Player가 동영상을 재생하면, Player는 시간기준값(PCR)에 정의된 시간으로 Player를 셋팅(Setting)하여 시간이 경과되며, 각 비디오 및 오디오는 디코딩시간값(DTS) 및 재생시간값(PTS)를 가지므로 Player는 시간기준값(PCR)으로 정의된 시간이 흘러 해당 시간이 되면 해당 비디오 및 오디오를 디코딩 및 재생(화면 출력)하게 된다.Accordingly, when the player plays a moving picture in the MPEG system, the player sets the player to the time defined in the time reference value (PCR) and time elapses, and each video and audio has a decoding time value (DTS) and playback time Since it has a value (PTS), the player decodes and plays the video and audio (screen output) when the time defined as the time reference value (PCR) passes and the time comes.

이와 같이, Mpeg-TS에서는, 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여 디코딩 및 재생(화면 출력)하는 방식으로, 실제 동영상 재생 후 영상이 노출되기 전에 일정 수의 영상(비디오/오디오)을 미리 준비함으로써, 동영상의 끊김 없는 재생을 위한 버퍼링 역할을 실현할 수 있다.As described above, in Mpeg-TS, decoding and playback (screen output) are performed using three time values (PCR, DTS, PTS) of video and audio. By preparing (video/audio) in advance, it is possible to realize a buffering role for seamless playback of moving pictures.

하지만, 동영상 전송 기술인 Mpeg-TS에서는, 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여 디코딩 및 재생(화면 출력)하는 방식 때문에, 동영상을 재생한 후 첫 영상(비디오/오디오)가 노출되기까지 첫 영상(비디오/오디오)의 재생시간값(PTS)이 될 때까지의 재생 지연이 발생하는 단점이 있다.However, in Mpeg-TS, a video transmission technology, the first video (video / audio ), there is a disadvantage in that the playback delay occurs until the playback time value (PTS) of the first image (video/audio) is exposed.

이에, 본 발명에서는, Mpeg-TS에서 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여, 동영상 초기 재생의 지연을 최소화하면서 버퍼링 역할도 유지할 수 있는 방안을 제안하고자 한다.Accordingly, in the present invention, by using three time values (PCR, DTS, and PTS) of video and audio in Mpeg-TS, it is intended to propose a method that minimizes the delay of the initial video playback while maintaining the buffering role.

본 발명은 상기한 사정을 감안하여 창출된 것으로서, 본 발명에서 도달하고자 하는 목적은, 동영상 전송 기술인 Mpeg-TS에서 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여, 동영상 초기 재생의 지연을 최소화하면서 버퍼링 역할도 유지할 수 있는 새로운 방안(기술)을 제공하는데 있다.The present invention was created in consideration of the above circumstances, and the object of the present invention is to use three time values (PCR, DTS, PTS) of video and audio in Mpeg-TS, which is a moving image transmission technology, to start a moving picture. The goal is to provide a new method (technology) that can minimize the delay of playback while maintaining the buffering role.

상기 목적을 달성하기 위한 본 발명의 일 실시예에 따른 동영상 인코딩장치는, 동영상의 특정 패킷에 대하여, 상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩 순서를 위한 시간값(DTS: Decoding Time Stamp) 및 재생 시각을 알려주는 시간값(PTS: Presentation Time Stamp) 중 적어도 하나를 조정하여, 상기 특정 패킷의 재생 지연을 감소시키는 시간값조정부; 및 상기 동영상의 각 패킷을 인코딩 처리하는 인코딩부를 포함한다.A video encoding apparatus according to an embodiment of the present invention for achieving the above object, for a specific packet of a moving picture, a time value (DTS: Decoding Time Stamp) for a decoding order determined for each video and audio of the specific packet and a time value adjusting unit for reducing a reproduction delay of the specific packet by adjusting at least one of a presentation time stamp (PTS) indicating a reproduction time. and an encoding unit for encoding each packet of the moving picture.

구체적으로, 상기 특정 패킷은, 상기 동영상의 재생 시 초기 재생구간에 속하는 패킷이며, 상기 시간값조정부는, 상기 동영상의 초기 재생구간 이후 재생구간에 속하는 패킷에 대해서는, 상기 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS) 중 적어도 하나를 재 조정하여, 상기 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 할 수 있다.Specifically, the specific packet is a packet belonging to an initial playback section when the video is reproduced, and the time value adjusting unit is configured to, for a packet belonging to a playback section after the initial playback section of the video, apply the video and audio data of the packet to each of the packets. By re-adjusting at least one of the determined decoding time value (DTS) and the playback time value (PTS), the playback delay of the packet may be utilized as buffering.

구체적으로, 상기 시간조정부는, 상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 상기 특정 패킷에 정해지는 시간기준값(PCR: Program Clock Reference)에 근접하도록 조정하여, 상기 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 상기 특정 패킷의 재생 지연을 감소시킬 수 있다.Specifically, the time adjusting unit is configured to approximate a decoding time value (DTS) and a reproduction time value (PTS) determined for each video and audio of the specific packet to a time reference value (PCR: Program Clock Reference) determined for the specific packet. Thus, the playback delay of the specific packet due to the separation between the time reference value PCR and the playback time value PTS can be reduced.

구체적으로, 상기 시간값조정부는, 상기 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 상기 패킷에 정해지는 시간기준값(PCR)으로부터 일정 간격을 갖도록 재 조정하여, 상기 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 상기 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 할 수 있다.Specifically, the time value adjusting unit readjusts a decoding time value (DTS) and a playback time value (PTS) determined for each video and audio of the packet to have a predetermined interval from a time reference value (PCR) determined for the packet Accordingly, the playback delay of the packet according to the separation between the time reference value PCR and the playback time value PTS can be utilized as buffering.

구체적으로, 상기 시간값조정부는, 상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 근접하도록 조정하는 근접 정도를, 상기 초기 재생구간에 속하는 가장 앞선 특정 패킷에 대해 가장 근접하게 하고 마지막 특정 패킷까지 순차적으로 멀게 할 수 있다.Specifically, the time value adjusting unit adjusts a degree of proximity for adjusting a decoding time value (DTS) and a reproduction time value (PTS) determined for each video and audio of the specific packet to be close to a time reference value (PCR), the initial It is possible to make the closest to the earliest specific packet belonging to the playback section and to sequentially further away from the last specific packet.

구체적으로, 상기 동영상은, Mpeg-TS(Transport Stream)로 생성된 파일을 포함할 수 있다.Specifically, the video may include a file generated by Mpeg-TS (Transport Stream).

상기 목적을 달성하기 위한 본 발명의 일 실시예에 따른 동영상 인코딩방법은, 동영상의 특정 패킷에 대하여, 상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩 순서를 위한 시간값(DTS: Decoding Time Stamp) 및 재생 시각을 알려주는 시간값(PTS: Presentation Time Stamp) 중 적어도 하나를 조정하여, 상기 특정 패킷의 재생 지연을 감소시키는 시간값조정단계; 및 상기 동영상의 각 패킷을 인코딩 처리하는 인코딩단계를 포함한다.In a moving picture encoding method according to an embodiment of the present invention for achieving the above object, with respect to a specific packet of a moving picture, a time value (DTS: Decoding Time Stamp) for a decoding order determined for each video and audio of the specific packet and a time value adjusting step of adjusting at least one of a presentation time stamp (PTS) indicating a playback time to reduce the playback delay of the specific packet. and an encoding step of encoding each packet of the video.

구체적으로, 상기 특정 패킷은, 상기 동영상의 재생 시 초기 재생구간에 속하는 패킷이며, 상기 시간값조정단계는, 상기 동영상의 초기 재생구간 이후 재생구간에 속하는 패킷에 대해서는, 상기 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS) 중 적어도 하나를 재 조정하여, 상기 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 할 수 있다.Specifically, the specific packet is a packet belonging to an initial playback section when the moving picture is reproduced, and the time value adjusting step includes, for a packet belonging to a playback section after the initial playback section of the moving picture, the video and audio of the packet, respectively. By re-adjusting at least one of the decoding time value (DTS) and the playback time value (PTS) determined in , the playback delay of the packet may be utilized as buffering.

구체적으로, 상기 시간조정단계는, 상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 상기 특정 패킷에 정해지는 시간기준값(PCR: Program Clock Reference)에 근접하도록 조정하여, 상기 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 상기 특정 패킷의 재생 지연을 감소시킬 수 있다.Specifically, in the time adjustment step, a decoding time value (DTS) and a playback time value (PTS) determined for each video and audio of the specific packet are set to a time reference value (PCR: Program Clock Reference) determined for the specific packet. By adjusting to be close to each other, it is possible to reduce the reproduction delay of the specific packet due to the separation between the time reference value PCR and the reproduction time value PTS.

구체적으로, 상기 시간값조정단계는, 상기 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 상기 패킷에 정해지는 시간기준값(PCR)으로부터 일정 간격을 갖도록 재 조정하여, 상기 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 상기 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 할 수 있다.Specifically, in the step of adjusting the time value, the decoding time value (DTS) and the playback time value (PTS) determined for each of the video and audio of the packet are reset to have a predetermined interval from the time reference value (PCR) specified for the packet. By adjusting, the playback delay of the packet according to the separation between the time reference value (PCR) and the playback time value (PTS) can be utilized as buffering.

구체적으로, 상기 시간값조정단계는, 상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 근접하도록 조정하는 근접 정도를, 상기 초기 재생구간에 속하는 가장 앞선 특정 패킷에 대해 가장 근접하게 하고 마지막 특정 패킷까지 순차적으로 멀게 할 수 있다.Specifically, in the step of adjusting the time value, the degree of proximity of adjusting the decoding time value (DTS) and the playback time value (PTS) determined for each video and audio of the specific packet to be close to the time reference value (PCR), It is possible to make the closest to the earliest specific packet belonging to the initial playback section and to sequentially further away from the last specific packet.

본 발명의 동영상 인코딩장치 및 동영상 인코딩방법에 따르면, 동영상의 인코딩 시 초기 재생구간에서 비디오 및 오디오의 DTS 및 PTS를 조정하여 인코딩함으로써, 동영상의 초기 재생구간에서만 버퍼링 역할의 재생 지연을 최소화할 수 있다.According to the video encoding apparatus and the video encoding method of the present invention, by adjusting the DTS and PTS of the video and audio in the initial playback section during encoding of the video and encoding, the playback delay of the buffering role can be minimized only in the initial playback section of the video. .

이로 인해, 본 발명에 따르면, 동영상 전송 기술인 Mpeg-TS에서 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여, 동영상 초기 재생의 지연은 최소화하면서 초기 재생구간 이후에는 버퍼링 역할도 유지할 수 있는 효과를 도출한다.For this reason, according to the present invention, by using three time values (PCR, DTS, PTS) of video and audio in Mpeg-TS, which is a moving picture transmission technology, the delay of the initial playback of the video is minimized and the buffering role is also performed after the initial playback section achieve sustainable effects.

도 1은 Mpeg-TS에서 영상의 PCR, DTS, PTS을 이용하여 디코딩 및 재생(화면 출력)하는 방식을 설명하기 위한 그래프이다.
도 2는 본 발명의 일 실시예에 따른 동영상 인코디장치의 구성을 보여주는 블록도이다.
도 3은 본 발명이 적용되는 경우 Mpeg-TS에서 영상의 PCR, DTS, PTS을 이용하여 디코딩 및 재생(화면 출력)하는 방식을 보여주는 그래프이다.
도 4는 본 발명의 일 실시예에 따른 동영상 인코딩방법을 보여주는 제어 흐름도이다.
1 is a graph for explaining a method of decoding and reproducing (screen output) using PCR, DTS, and PTS of an image in Mpeg-TS.
2 is a block diagram showing the configuration of a video encoding apparatus according to an embodiment of the present invention.
3 is a graph showing a method of decoding and reproducing (screen output) using PCR, DTS, and PTS of an image in Mpeg-TS when the present invention is applied.
4 is a control flowchart illustrating a video encoding method according to an embodiment of the present invention.

이하, 첨부된 도면을 참조하여 본 발명의 일 실시예에 대하여 설명한다.Hereinafter, an embodiment of the present invention will be described with reference to the accompanying drawings.

본 발명은, 동영상 전송 기술인 Mpeg-TS(Transport Stream)에서 동영상 초기 재생의 지연을 최소화시키기 위한 것과 관련이 있다.The present invention relates to minimizing the delay of the initial playback of a moving picture in Mpeg-TS (Transport Stream), which is a moving picture transmission technology.

동영상 전송 기술인 Mpeg-TS에서는, 3가지 즉 PCR(Program Clock Reference), DTS(Decoding Time Stamp), PTS(Presentation Time Stamp) 시간값을 가지고 비디오 및 오디오가 출력된다. In Mpeg-TS, a moving picture transmission technology, video and audio are output with three time values: PCR (Program Clock Reference), DTS (Decoding Time Stamp), and PTS (Presentation Time Stamp).

PCR은, Mpeg-2 TS 내 하나의 프로그램(PMT 테이블에 할당된 특정 PID)에 적용되는 시간기준값이며, Player가 동영상 재생을 위한 기준 시간을 잡기 위해 사용한다.PCR is a time reference value applied to one program (a specific PID assigned to the PMT table) in the Mpeg-2 TS, and is used by the Player to set the reference time for video playback.

DTS는, 디코딩 순서가 오류 없이 유지되도록 하기 위한 시간값(이하, 디코딩시간값)으로서, 영상의 각 비디오 및 오디오 마다 출력 전 디코딩(Decoding)을 처리하는 시간을 나타낸다.The DTS is a time value (hereinafter, referred to as a decoding time value) for maintaining the decoding order without errors, and indicates a time for processing decoding before output for each video and audio of an image.

MPEG 시스템에서는 비디오의 부호화된 비트열(스트림)의 송출 순서가 다소 특별하기 때문에, Player가 영상의 각 비디오 및 오디오에 정해져 있는 디코딩시간값(DTS)를 사용하여 디코딩 순서를 바르게 유지할 수 있다.In the MPEG system, since the transmission order of the encoded bit string (stream) of the video is somewhat special, the player can maintain the decoding order correctly by using the decoding time value (DTS) determined for each video and audio of the image.

PTS는, 재생순서가 오류 없이 유지되도록 하기 위한 시간값(이하, 재생시간값)으로서, 디코딩된 비디오 및 오디오를 화면에 출력하는 시간을 나타낸다.The PTS is a time value (hereinafter, referred to as a playback time value) for maintaining a playback order without errors, and indicates a time for outputting decoded video and audio to the screen.

이러한 디코딩시간값(DTS) 및 재생시간값(PTS)는, 시간기준값(PCR)을 기준으로 일정 간격을 갖는 시간값으로 생성된다.The decoding time value (DTS) and the reproduction time value (PTS) are generated as time values having a predetermined interval based on the time reference value (PCR).

이에, MPEG 시스템에서 Player가 동영상을 재생하면, Player는 시간기준값(PCR)에 정의된 시간으로 Player를 셋팅(Setting)하여 동영상 재생과 관련되는 시간이 흘러 경과하게 된다.Accordingly, when the player plays a moving picture in the MPEG system, the player sets the player to the time defined in the time reference value (PCR), and the time related to the moving picture playback elapses.

그리고, 각 비디오 및 오디오는 디코딩시간값(DTS) 및 재생시간값(PTS)를 가지므로, Player는 시간기준값(PCR)으로 정의된 시간이 흘러 디코딩시간값(DTS)에 의한 해당 시간이 되면 해당 비디오 및 오디오를 디코딩하고 재생시간값(PTS)에 의한 해당 시간이 되면 해당 비디오 및 오디오를 재생(화면 출력)하게 된다.And, since each video and audio has a decoding time value (DTS) and a playback time value (PTS), the player becomes the corresponding time according to the decoding time value (DTS) after the time defined by the time reference value (PCR) passes. The video and audio are decoded, and when the corresponding time is reached according to the playback time value (PTS), the corresponding video and audio are played (screen output).

도 1은, Mpeg-TS에서 영상의 PCR, DTS, PTS을 이용하여 디코딩 및 재생(화면 출력)하는 기존 방식을 보여주고 있다.1 shows an existing method of decoding and reproducing (screen output) using PCR, DTS, and PTS of an image in Mpeg-TS.

도 1에 도시된 바와 같이, Player에서는 동영상이 재생되면(실제 재생 시작) 시간기준값(PCR)에 정의된 시간을 기준으로 하여, 동영상의 영상1을 영상1의 각 비디오 및 오디오에 정해져 있는 디코딩시간값(DTS)의 시간에 디코딩(Decoding)하고 재생시간값(PTS)의 시간에 재생(화면 출력)하며, 동영상의 영상2를 영상2의 각 비디오 및 오디오에 정해져 있는 디코딩시간값(DTS)의 시간에 디코딩(Decoding)하고 재생시간값(PTS)의 시간에 재생(화면 출력)하게 된다.As shown in FIG. 1 , when a video is played (actual playback starts) in the Player, the decoding time determined for each video and audio of Video 1 for Video 1 of Video 1 is based on the time defined in the time reference value (PCR). It decodes at the time of the value (DTS) and plays (outputs on the screen) at the time of the playback time value (PTS). Decoding is performed at the time, and reproduction (screen output) is performed at the time of the reproduction time value (PTS).

이와 같이, Player에서 동영상 재생 시 영상(비디오/오디오)의 시간값(PCR, DTS, PTS)을 이용하여 디코딩 및 재생(화면 출력)하는 방식으로, 각 영상 관점에서 PCR 기준 실제 재생 시작 시점부터 PTS 기준 화면 출력 시점까지 PTS-PCR 만큼의 재생 지연이 발생하게 된다.In this way, when playing a video in the player, decoding and playback (screen output) using the time values (PCR, DTS, PTS) of the video (video/audio) are used from the viewpoint of each video from the actual playback start time based on PCR. There is a playback delay as much as PTS-PCR until the reference screen is output.

이에, Mpeg-TS에서는, 실제 동영상 재생 후, 각 영상 관점에서 발생하는 재생 지연을 통해 영상이 화면에 노출되기 전에 일정 수의 영상(비디오/오디오)을 미리 준비할 수 있게 되고, 이를 동영상의 끊김 없는 재생을 위한 버퍼링 역할로 활용할 수 있다.Therefore, in Mpeg-TS, a certain number of images (video/audio) can be prepared in advance before the image is exposed to the screen through the playback delay occurring from each image point of view after the actual video is played, which causes the video to be interrupted. It can be used as a buffering role for non-existent playback.

반면, Mpeg-TS에서는, 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여 디코딩 및 재생(화면 출력)하는 방식 때문에, 동영상을 재생한 후 첫 영상(예: 도 1의 영상1)가 노출되기까지 첫 영상(예: 영상1)의 재생시간값(PTS)이 될 때까지의 시간 만큼 노출되는 화면이 없는 초기 재생 지연이 발생하는 단점이 있다.On the other hand, in Mpeg-TS, because of the method of decoding and playing (screen output) using three time values (PCR, DTS, PTS) of video and audio, the first image (eg, the image of There is a disadvantage in that there is an initial playback delay in which there is no exposed screen for the time until the playback time value (PTS) of the first image (eg, image 1) until 1) is exposed.

이에, 본 발명에서는, 동영상 전송 기술인 Mpeg-TS에서 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여, 동영상 초기 재생의 지연을 최소화하면서 버퍼링 역할도 유지할 수 있는 새로운 방안(기술)을 제안하고자 한다.Accordingly, in the present invention, by using three time values (PCR, DTS, PTS) of video and audio in Mpeg-TS, which is a moving picture transmission technology, a new method (technology) that can minimize the delay of the initial playback of the moving picture while maintaining the buffering role (technology) ) is proposed.

이하에서는, 도 2를 참조하여, 본 발명의 새로운 방안(기술)을 실현하기 위한 동영상 인코딩장치(100)의 구성을 구체적으로 설명하겠다.Hereinafter, with reference to FIG. 2, the configuration of the video encoding apparatus 100 for realizing the new method (technology) of the present invention will be described in detail.

도 2에 도시된 바와 같이, 본 발명의 일 실시예에 따른 동영상 인코딩장치(100)는, 시간값조정부(110), 인코딩부(120)를 포함한다.As shown in FIG. 2 , the video encoding apparatus 100 according to an embodiment of the present invention includes a time value adjusting unit 110 and an encoding unit 120 .

더 나아가, 본 발명의 일 실시예에 따른 동영상 인코딩장치(100)는, Demux(10), Mux(20)를 더 포함할 수 있다.Furthermore, the video encoding apparatus 100 according to an embodiment of the present invention may further include a Demux 10 and a Mux 20 .

결국, 본 발명의 일 실시예에 따른 동영상 인코딩장치(100)는, 전술한 구성을 통해, Mpeg-TS에서 동영상 초기 재생의 지연을 최소화하면서 버퍼링 역할도 유지할 수 있는 본 발명의 기술(이하, 초기 재생 지연 최소화 인코딩 방안)을 실현하는 것이다.As a result, the video encoding apparatus 100 according to an embodiment of the present invention can maintain a buffering role while minimizing the delay of the initial video playback in Mpeg-TS through the above-described configuration (hereinafter referred to as "initial"). It is to realize encoding scheme to minimize playback delay).

이하에서는, 본 발명의 초기 재생 지연 최소화 인코딩 방안을 실현하기 위한 동영상 인코딩장치(100) 내 각 구성에 대해 보다 구체적으로 설명하기로 한다.Hereinafter, each configuration in the video encoding apparatus 100 for realizing the encoding method for minimizing the initial reproduction delay of the present invention will be described in more detail.

시간값조정부(110)는, 동영상의 특정 패킷에 대하여, 상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩 순서를 위한 시간값(DTS: Decoding Time Stamp) 및 재생 시각을 알려주는 시간값(PTS: Presentation Time Stamp) 중 적어도 하나를 조정하여, 상기 특정 패킷의 재생 지연을 감소시키는 기능을 담당한다.The time value adjustment unit 110, for a specific packet of a moving picture, a time value (PTS: Decoding Time Stamp) for a decoding order determined for each video and audio of the specific packet and a playback time (PTS: Presentation Time Stamp) by adjusting at least one of the following functions to reduce the playback delay of the specific packet.

이때, 상기 특정 패킷은, 상기 동영상의 재생 시 초기 재생구간에 속하는 패킷을 의미할 수 있다.In this case, the specific packet may mean a packet belonging to an initial playback section when the video is reproduced.

그리고, 상기 동영상은, Mpeg-TS(Transport Stream)로 생성된 파일을 포함할 수 있으며, 이 경우 패킷은 인코딩 단위의 영상(비디오/오디오)을 구성하는 TS 패킷을 의미할 것이다.In addition, the moving picture may include a file generated by Mpeg-TS (Transport Stream). In this case, the packet may mean a TS packet constituting an image (video/audio) of an encoding unit.

즉, 시간값조정부(110)는, 동영상의 초기 재생구간에 속하는 특정 TS 패킷에 대하여, 특정 TS 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS) 중 적어도 하나를 조정하여, 해당되는 특정 TS 패킷의 재생 지연을 감소시킬 수 있다.That is, the time value adjusting unit 110, with respect to a specific TS packet belonging to the initial playback section of the moving picture, at least one of a decoding time value (DTS) and a playback time value (PTS) determined for video and audio of the specific TS packet, respectively. By adjusting , it is possible to reduce the playback delay of a specific TS packet.

더 나아가, 시간값조정부(110)는, 동영상의 초기 재생구간 이후 재생구간에 속하는 TS 패킷에 대해서는, TS 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS) 중 적어도 하나를 재 조정하여, 해당되는 TS 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 한다.Furthermore, the time value adjusting unit 110, for the TS packets belonging to the playback section after the initial playback section of the moving picture, among the decoding time value (DTS) and the playback time value (PTS) determined for each video and audio of the TS packet, By re-adjusting at least one, the reproduction delay of the corresponding TS packet can be utilized as buffering.

그리고, 인코딩부(120)는, 상기 동영상의 각 TS 패킷(특정 TS 패킷 및 특정 TS 패킷 이후의 TS 패킷)을 인코딩 처리하는 기능을 담당한다.The encoding unit 120 is responsible for encoding each TS packet (a specific TS packet and a TS packet after the specific TS packet) of the moving picture.

이상, 본 발명의 동영상 인코딩장치(100, 특히 시간값조정부(110))는, 동영상의 인코딩 시, 동영상의 초기 재생구간에 속하는 비디오 및 오디오와 이후 재생구간에 속하는 비디오 및 오디오의 DTS 및 PTS를 다르게 조정한 후 인코딩하는 방식으로, 동영상의 초기 재생구간에서는 버퍼링 역할의 재생 지연을 최소화하고 이후 재생구간에서는 재생 지연을 어느 정도 발생시켜 이를 버퍼링 역할로 활용하고자 한다.As described above, the video encoding apparatus 100 of the present invention (in particular, the time value adjusting unit 110), when encoding a video, converts the video and audio belonging to the initial playback section of the video and the DTS and PTS of the video and audio belonging to the subsequent playback section when encoding the video. In a method of encoding after adjusting differently, it is intended to minimize the playback delay of the buffering role in the initial playback section of the video and generate a certain amount of playback delay in the subsequent playback section to utilize this as the buffering role.

이하에서는, 본 발명에서 TS 패킷의 비디오 및 오디오에 대해 DTS 및 PTS를 조정하는 구체적인 실시예를 설명하겠다.Hereinafter, a specific embodiment of adjusting DTS and PTS for video and audio of a TS packet in the present invention will be described.

설명에 앞서, 본 발명에서 정의하는 동영상의 초기 재생구간은, 시간으로 정할 수 있고, 패킷(또는, 영상)의 개수(N-1번째)로 정할 수도 있다.Prior to the description, the initial playback section of a moving picture defined in the present invention may be determined by time, or may be determined by the number of packets (or images) (N-1 th).

다만, 본 발명에서 정의하는 동영상의 초기 재생구간은, 현재 또는 향후 개선될 수 있는 Mpeg-TS 기술에 준하여, 해당 동영상이 Player에서 재생되는 경우 정상 재생될 수 있는 범위 내에서 정해져야 할 것이다.However, in accordance with the Mpeg-TS technology that can be improved now or in the future, the initial playback section of the moving picture defined in the present invention should be determined within the range that can be normally played when the corresponding moving picture is played in the player.

초기 재생 구간에서는 필요한 양 만큼 더 많은 데이터를 보내야하기 때문에 일정 구간에 비트레이트(bitrate)가 올라가게 된다. 이점에 기인하여, 초기 재생 구간의 최대 비트레이트를 통해 초기 재생 구간의 시간 또는 영상의 개수를 정할 수 있다.In the initial playback section, since more data needs to be transmitted as much as necessary, the bitrate is increased in a certain section. Due to this, the time of the initial playback section or the number of images can be determined through the maximum bit rate of the initial playback section.

예를 들면, 초기 재생구간은, 인코딩 대상의 동영상에 정의되는 비트 레이트와 초기 재생 구간의 최대 비트 레이트를 기반으로 결정될 수 있다.For example, the initial playback section may be determined based on a bit rate defined in a video to be encoded and a maximum bit rate of the initial playback section.

예컨대, 현재 Mpeg-TS 기술에서 인코딩 대상의 동영상에 정의되는 비트레이트(bitrate)가 1Mbps 이며, 초기 재생 구간의 최대 비트레이트(최대bitrate)를 1.2Mbps, 동영상의 최초 시간기준값(최초PCR) 및 재생시간값(최초PTS)의 간격(최초PTS - 최초PCR)이 100ms, 패킷의 재생 지연을 버퍼링으로 활용하기 위해 기 결정되는 시간기준값(PCR) 및 재생시간값(PTS)의 간격(PTS - PCR)이 600ms인 경우로 가정하면, 본 발명에서 초기 재생 구간은, 다음 수학식 1에 따라 계산되는 시간 범위 이내에서 최소값의 재생구간 또는 계산되는 시간 범위 이내에서 최소값에 해당되는 영상(N-1번째 영상)으로 결정될 수 있다.For example, in the current Mpeg-TS technology, the bitrate defined for the video to be encoded is 1Mbps, the maximum bitrate (maximum bitrate) of the initial playback section is 1.2Mbps, and the initial time reference value (initial PCR) and playback of the video The interval between the time value (initial PTS) (initial PTS - initial PCR) is 100 ms, and the interval between the predetermined time reference value (PCR) and the playback time value (PTS) to utilize the packet playback delay as buffering (PTS - PCR) Assuming that this is 600 ms, in the present invention, the initial playback section is the playback section of the minimum value within the time range calculated according to the following equation (1) or the video corresponding to the minimum value within the time range calculated (N-1th video) ) can be determined.

Figure 112020037704030-pat00001
Figure 112020037704030-pat00001

물론, 본 발명에서 정의하는 동영상의 초기 재생구간은, 운영자에 의해 설정되는 것도 가능할 것이다.Of course, the initial playback section of the moving picture defined in the present invention may be set by the operator.

시간값조정부(110)는, 동영상의 초기 재생구간에 속하는 특정 TS 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 특정 TS 패킷에 정해지는 시간기준값(PCR)에 근접하도록 조정하여, 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 해당 특정 TS 패킷의 재생 지연을 최소로 감소시킬 수 있다.The time value adjusting unit 110 sets the decoding time value (DTS) and the playback time value (PTS) determined for each video and audio of a specific TS packet belonging to the initial playback section of the moving picture to a time reference value ( PCR), it is possible to minimize the reproduction delay of the specific TS packet due to the separation of the time reference value (PCR) and the reproduction time value (PTS).

도 2에 도시된 바와 같이, 인코딩 대상의 동영상(파일)은 Demux(10)를 통해 영상(패킷) 단위의 비디오 및 오디오로 분리되어 시간값조정부(110)에 전달될 수 있다.As shown in FIG. 2 , a moving picture (file) to be encoded may be separated into video and audio in units of images (packets) through the Demux 10 and transmitted to the time value adjusting unit 110 .

이 경우, 시간값조정부(110)는, 전달되는 비디오 및 오디오가 동영상의 초기 재생구간에 속하는 경우(특정 TS 패킷), 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 특정 TS 패킷에 정해지는 시간기준값(PCR)에 근접하도록 조정하여, 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 해당 특정 TS 패킷의 재생 지연을 최소로 감소시킬 수 있다.In this case, when the transmitted video and audio belong to the initial playback section of the moving picture (a specific TS packet), the time value adjusting unit 110 may include a decoding time value (DTS) and a playback time value (PTS) determined for each of the video and audio. ) to be close to the time reference value (PCR) determined for the specific TS packet, the playback delay of the specific TS packet due to the separation between the time reference value (PCR) and the playback time value (PTS) can be reduced to a minimum. .

Mpeg-TS(Transport Stream)로 이미 생성된 동영상 파일의 각 영상 단위 비디오/오디오에는, 시간기준값(PCR)이 정해지며, 시간기준값(PCR)을 기준으로 일정 간격을 갖는 디코딩시간값(DTS) 및 재생시간값(PTS)이 기 정해져 있을 것이다.A time reference value (PCR) is determined for each video unit video/audio of a moving picture file already created with Mpeg-TS (Transport Stream), and a decoding time value (DTS) having a predetermined interval based on the time reference value (PCR) and The playback time value (PTS) may be predetermined.

이에, 시간값조정부(110)는, 전달되는 비디오 및 오디오가 동영상의 초기 재생구간에 속하는 경우(특정 TS 패킷), 비디오 및 오디오 각각에 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 특정 TS 패킷에 정해지는 시간기준값(PCR)에 근접한 시간값으로 변경하는 방식으로, 디코딩시간값(DTS) 및 재생시간값(PTS)을 조정할 수 있다.Accordingly, when the transmitted video and audio belong to the initial playback section of the moving picture (a specific TS packet), the time value adjusting unit 110 may include a decoding time value (DTS) and a playback time value (PTS) predetermined for each of the video and audio. ) to a time value close to the time reference value (PCR) determined for the specific TS packet, the decoding time value (DTS) and the playback time value (PTS) can be adjusted.

일 실시예를 들면, 시간값조정부(110)는, 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 최대한 근접한 시간값으로 변경하기 위한 오프셋값을 설정하고 이를 반영하여 변경하는 방식을 채택할 수 있다.For example, the time value adjustment unit 110 sets an offset value for changing the predetermined decoding time value (DTS) and the reproduction time value (PTS) to a time value closest to the time reference value (PCR) as much as possible. A method of reflecting this change may be adopted.

다른 실시예를 들면, 시간값조정부(110)는, 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)과 최대한 동일한 시간값으로 변경하는 방식을 채택할 수 있다.In another embodiment, the time value adjustment unit 110 may adopt a method of changing the predetermined decoding time value (DTS) and the reproduction time value (PTS) to the same time value as the time reference value (PCR) as much as possible. .

만약, 비디오 및 오디오 각각에 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)가 존재하지 않는 경우라면, 시간값조정부(110)는, 비디오 및 오디오 각각에 정해져야 하는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 특정 TS 패킷에 정해지는 시간기준값(PCR)에 근접한 시간값으로 결정할 수도 있을 것이다. If the decoding time value (DTS) and the playback time value (PTS) that are predetermined for each of the video and audio do not exist, the time value adjusting unit 110 sets the decoding time value ( DTS) and the reproduction time value (PTS) may be determined as time values close to the time reference value (PCR) determined for the specific TS packet.

시간값조정부(110)에서 DTS 및 PTS가 조정(변경 또는 결정)된 비디오 및 오디오는 Mux(20)를 통해 먹싱된 후(특정 TS 패킷), 인코딩부(120)에서 인코딩 처리되어, 동영상 파일로서 저장될 것이다.Video and audio of which DTS and PTS are adjusted (changed or determined) by the time value adjustment unit 110 are muxed through the Mux 20 (a specific TS packet), and then encoded in the encoding unit 120 and processed as a moving picture file. will be saved

한편, 시간값조정부(110)는, 전달되는 비디오 및 오디오가 동영상의 초기 재생구간 이후 재생구간에 속하는 경우(TS 패킷), 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 TS 패킷에 정해지는 시간기준값(PCR)으로부터 일정 간격을 갖도록 재 조정하여, 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 해당 TS 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 한다.On the other hand, the time value adjusting unit 110, when the transmitted video and audio belong to the playback section after the initial playback section of the moving picture (TS packet), the decoding time value (DTS) and the playback time value ( PTS) is readjusted to have a certain interval from the time reference value (PCR) determined for the TS packet, so that the playback delay of the TS packet according to the separation between the time reference value (PCR) and the playback time value (PTS) is used as buffering. make it possible

앞서 언급한 바와 같이, Mpeg-TS(Transport Stream)로 이미 생성된 동영상 파일의 각 영상 단위 비디오/오디오에는, 시간기준값(PCR)이 정해지며, 시간기준값(PCR)을 기준으로 일정 간격을 갖는 디코딩시간값(DTS) 및 재생시간값(PTS)이 기 정해져 있을 것이다.As mentioned above, a time reference value (PCR) is determined for each video unit video/audio of a moving picture file already created with Mpeg-TS (Transport Stream), and decoding having a predetermined interval based on the time reference value (PCR) The time value DTS and the playback time value PTS may be predetermined.

이에, 시간값조정부(110)는, 전달되는 비디오 및 오디오가 동영상의 초기 재생구간 이후 재생구간에 속하는 경우(TS 패킷), 비디오 및 오디오 각각에 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 TS 패킷에 정해지는 시간기준값(PCR)에 근접한 시간값으로 변경하지 않고 유지하는 방식으로, 디코딩시간값(DTS) 및 재생시간값(PTS)을 재 조정할 수 있다.Accordingly, when the transmitted video and audio belong to the playback section after the initial playback section of the moving picture (TS packet), the time value adjusting unit 110 is configured to perform a decoding time value (DTS) and a playback time value predetermined for each of the video and audio. The decoding time value (DTS) and the playback time value (PTS) can be readjusted in a manner that maintains (PTS) as a time value close to the time reference value (PCR) determined in the corresponding TS packet without changing it.

일 실시예를 들면, 시간값조정부(110)는, 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 최대한 근접한 시간값으로 변경하기 위해 설정한 오프셋값을 0로 재 설정하고 이를 반영하여, 변경 방식 대신 유지 방식을 채택할 수 있다.For example, the time value adjusting unit 110 may change the predetermined decoding time value (DTS) and the reproduction time value (PTS) to a time value closest to the time reference value (PCR) as much as possible. By resetting it to 0 and reflecting this, the maintenance method can be adopted instead of the change method.

다른 실시예를 들면, 시간값조정부(110)는, 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)을 변경 없이 통과시켜, 변경 방식 대신 유지 방식을 채택할 수 있다.In another embodiment, the time value adjusting unit 110 may adopt the sustain method instead of the change method by passing the predetermined decoding time value DTS and the reproduction time value PTS without change.

만약, 비디오 및 오디오 각각에 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)가 존재하지 않는 경우라면, 시간값조정부(110)는, 비디오 및 오디오 각각에 정해져야 하는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 TS 패킷에 정해지는 시간기준값(PCR)으로부터 일정 간격을 갖는 시간값으로 결정할 수도 있을 것이다.If the decoding time value (DTS) and the playback time value (PTS) that are predetermined for each of the video and audio do not exist, the time value adjusting unit 110 sets the decoding time value ( DTS) and the reproduction time value (PTS) may be determined as time values having a predetermined interval from the time reference value (PCR) determined in the corresponding TS packet.

시간값조정부(110)에서 DTS 및 PTS가 재 조정(유지 또는 결정)된 비디오 및 오디오는 Mux(20)를 통해 먹싱된 후(TS 패킷), 인코딩부(120)에서 인코딩 처리되어, 동영상 파일로서 저장될 것이다.The video and audio of which the DTS and PTS are readjusted (maintained or determined) in the time value adjustment unit 110 are muxed through the Mux 20 (TS packets), and then encoded in the encoding unit 120 and processed as a moving picture file. will be saved

이상, 본 발명에서는, 동영상의 인코딩 시, 동영상의 초기 재생구간에 속하는 비디오 및 오디오에 대해서는 DTS 및 PTS를 PCR에 근접하게 조정(변경 또는 결정)하고, 이후 재생구간에 속하는 비디오 및 오디오에 대해서는 DTS 및 PTS를 PCR로부터 일정 간격을 갖도록 조정(유지 또는 결정)하는 방식으로, 동영상의 초기 재생구간 및 이후 재생구간에 속하는 비디오 및 오디오의 DTS 및 PTS를 다르게 조정하고 있다.As described above, in the present invention, when encoding a moving picture, DTS and PTS are adjusted (changed or determined) close to PCR for video and audio belonging to the initial playback section of the moving picture, and DTS for video and audio belonging to a subsequent playback section and DTS and PTS of video and audio belonging to an initial playback section of a moving picture and a subsequent playback section are adjusted differently in a manner of adjusting (maintaining or determining) PTS to have a predetermined interval from PCR.

이처럼, 본 발명에서는, 동영상의 인코딩 시, 동영상의 초기 재생구간 및 이후 재생구간에 속하는 비디오 및 오디오의 DTS 및 PTS를 다르게 조정한 후 인코딩하는 방식을 통해, 인코딩된 동영상(파일) 자체를 초기 재생구간에서는 PCR 및 PTS 간 이격(간격)에 따른 재생 지연이 최소화되고 이후 재생구간에서는 재생 지연이 일정 수준(일정 간격) 이상 발생하여 버퍼링 역할로 활용 가능한 상태(형태, 구조)로 생성할 수 있다.As such, in the present invention, when encoding a moving picture, the encoded moving picture (file) itself is initially played through a method of encoding after adjusting DTS and PTS of video and audio belonging to the initial playback section and subsequent playback section of the moving picture differently. In the section, the playback delay due to the separation (interval) between PCR and PTS is minimized, and in the subsequent playback section, the playback delay occurs at a certain level (a certain interval) or more, so that it can be created in a state (shape, structure) that can be used as a buffering role.

이렇게 되면, 본 발명에 의해 인코딩된 동영상 파일을 재생하는 Player에서, 기존과 같은 방식으로 동영상 재생 시 영상(비디오/오디오)의 시간값(PCR, DTS, PTS)을 이용하여 디코딩 및 재생(화면 출력)하면, 초기 재생구간에서는 PCR 및 PTS 간 이격(간격)에 따른 재생 지연이 최소화되어 즉시 재생(화면 출력)하고 이후 재생구간에서는 재생 지연이 기존처럼 일정 수준(일정 간격) 이상 발생하여 버퍼링 역할로 활용할 수 있다.In this case, in the player that plays the video file encoded according to the present invention, decoding and playback (screen output) using the time values (PCR, DTS, PTS) of the video (video/audio) when playing the video in the same way as before ), the playback delay due to the separation (interval) between PCR and PTS is minimized in the initial playback section, and playback (screen output) is performed immediately. can be utilized

더 나아가, 시간값조정부(110)는, 특정 TS 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 근접하도록 조정하는 근접 정도를, 초기 재생구간에 속하는 가장 앞선 특정 TS 패킷에 대해 가장 근접하게 하고 마지막 특정 TS 패킷까지 순차적으로 멀게 하는 방식으로 변경할 수 있다.Furthermore, the time value adjustment unit 110 adjusts the decoding time value (DTS) and the playback time value (PTS) determined for each video and audio of a specific TS packet to be close to the time reference value (PCR). It can be changed in such a way that it is made closest to the earliest specific TS packet belonging to the initial playback section and sequentially farther from the last specific TS packet.

즉, 시간값조정부(110)는, 초기 재생구간에 속하는 가장 앞선 특정 TS 패킷에 대해 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 가장 근접하도록 조정(변경 또는 결정)하고, 그 다음 앞선 특정 TS 패킷에 대해 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 두번째로 근접하도록 조정(변경 또는 결정)하고, 그 다음 앞선 특정 TS 패킷에 대해 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 세번째로 근접하도록 조정(변경 또는 결정)는 방식으로, 초기 재생구간에 속하는 가장 앞선 특정 TS 패킷부터 마지막 특정 TS 패킷까지 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)가 근접하도록 조정하는 근접 정도를 순차적으로 멀어지게 변경할 수 있다.That is, the time value adjusting unit 110 adjusts (changes or determines) the decoding time value (DTS) and the reproduction time value (PTS) for the most advanced specific TS packet belonging to the initial reproduction section to be closest to the time reference value (PCR). ), and then adjusts (changes or determines) the decoding time value (DTS) and playback time value (PTS) for the preceding specific TS packet to be second to the time reference value (PCR), and then in the preceding specific TS packet In this way, the decoding time value (DTS) and the playback time value (PTS) are adjusted (changed or determined) to be thirdly close to the time reference value (PCR), from the earliest specific TS packet belonging to the initial playback section to the last specific TS packet The degree of proximity for adjusting the decoding time value (DTS) and the reproduction time value (PTS) to be close to the time reference value (PCR) may be sequentially changed away from each other.

이렇게 되면, 도 3에 도시된 바와 같이, 본 발명에 의해 인코딩된 동영상 파일을 재생하는 Player에서, 기존과 같은 방식으로 동영상 재생 시 영상(비디오/오디오)의 시간값(PCR, DTS, PTS)을 이용하여 디코딩 및 재생(화면 출력)하면, 초기 재생구간(영상1~영상N-1)에서는 PCR 및 PTS 간 이격(간격)에 따른 재생 지연이 최초에 최소화되어 즉시 재생(화면 출력)하며 점점 재생 지연이 길어지고 이후 재생구간에서는 재생 지연이 기존처럼 일정 수준(일정 간격) 이상 발생하며 버퍼링 역할로 활용할 수 있다.In this case, as shown in FIG. 3, in the player that plays the video file encoded by the present invention, the time values (PCR, DTS, PTS) of the video (video/audio) when playing the video in the same way as before If decoding and playback (screen output) is performed, the playback delay due to the interval (interval) between PCR and PTS is initially minimized in the initial playback section (video 1 to video N-1), and playback is performed immediately (screen output) and gradually played back As the delay becomes longer, in the subsequent playback section, the playback delay occurs over a certain level (a certain interval) as before, and can be used as a buffering role.

이상 설명한 바와 같이, 본 발명의 실시예들에 따르면, 동영상의 인코딩 시 초기 재생구간 및 이후 재생구간에서 비디오 및 오디오의 DTS 및 PTS를 다르게 조정하여 인코딩함으로써, 동영상의 초기 재생구간에서만 버퍼링 역할의 재생 지연을 최소화할 수 있는 기술, 즉 초기 재생 지연 최소화 인코딩 방안을 실현하고 있다.As described above, according to the embodiments of the present invention, when encoding a moving picture, the DTS and PTS of video and audio are differently adjusted and encoded in the initial playback section and the subsequent playback section, thereby playing the buffering role only in the initial playback section of the moving picture. A technology capable of minimizing the delay, that is, an encoding method for minimizing the initial playback delay, is being realized.

이로 인해, 본 발명에 따르면, 동영상 전송 기술인 Mpeg-TS에서 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여, 동영상 초기 재생의 지연은 최소화하면서 초기 재생구간 이후에는 버퍼링 역할도 유지할 수 있는 효과를 기대할 수 있다.For this reason, according to the present invention, by using three time values (PCR, DTS, PTS) of video and audio in Mpeg-TS, which is a moving picture transmission technology, the delay of the initial playback of the video is minimized and the buffering role is also performed after the initial playback section Sustainable effects can be expected.

이하에서는, 도 4를 참조하여, 본 발명의 일 실시예에 따른 동영상 인코딩방법을 설명하겠다. 설명의 편의 상, 도 2의 참조번호를 언급하여 설명하도록 한다.Hereinafter, a video encoding method according to an embodiment of the present invention will be described with reference to FIG. 4 . For convenience of description, reference numerals in FIG. 2 will be referred to.

본 발명의 일 실시예에 따른 동영상 인코딩방법에서 동영상 인코딩장치(100)는, 인코딩을 위한 동영상 파일의 패킷이 로드(Load)되면(S10), 동영상의 초기 재생구간의 특정 패킷(이하, 특정 TS 패킷)인지 확인한다(S20).In the video encoding method according to an embodiment of the present invention, the video encoding apparatus 100, when a packet of a video file for encoding is loaded (S10), a specific packet of the initial playback section of the video (hereinafter, a specific TS packet) is checked (S20).

본 발명의 일 실시예에 따른 동영상 인코딩방법에서 동영상 인코딩장치(100)는, 초기 재생구간의 특정 TS 패킷인 경우(S20 Yes), 특정 TS 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 특정 TS 패킷에 정해지는 시간기준값(PCR)에 근접하도록 조정하여, 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 해당 특정 TS 패킷의 재생 지연을 최소로 감소시킬 수 있다(S30).In the video encoding method according to an embodiment of the present invention, the video encoding apparatus 100 provides a decoding time value (DTS) determined for each video and audio of a specific TS packet when it is a specific TS packet in the initial playback section (S20 Yes). ) and the playback time value (PTS) are adjusted to be close to the time reference value (PCR) determined for the specific TS packet, and the playback delay of the specific TS packet according to the separation between the time reference value (PCR) and the playback time value (PTS) can be reduced to a minimum (S30).

Mpeg-TS(Transport Stream)로 이미 생성된 동영상 파일의 각 영상 단위 비디오/오디오에는, 시간기준값(PCR)이 정해지며, 시간기준값(PCR)을 기준으로 일정 간격을 갖는 디코딩시간값(DTS) 및 재생시간값(PTS)이 기 정해져 있을 것이다.A time reference value (PCR) is determined for each video unit video/audio of a moving picture file already created with Mpeg-TS (Transport Stream), and a decoding time value (DTS) having a predetermined interval based on the time reference value (PCR) and The playback time value (PTS) may be predetermined.

이에, 본 발명의 일 실시예에 따른 동영상 인코딩방법에서 동영상 인코딩장치(100)는, 특정 TS 패킷의 비디오 및 오디오 각각에 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 특정 TS 패킷에 정해지는 시간기준값(PCR)에 근접한 시간값으로 변경(기 설정 값에서 수정)하는 방식으로, 디코딩시간값(DTS) 및 재생시간값(PTS)을 조정할 수 있다(S30).Accordingly, in the video encoding method according to an embodiment of the present invention, the video encoding apparatus 100 sets the decoding time value (DTS) and the playback time value (PTS) predetermined for each video and audio of a specific TS packet to the corresponding specific value. The decoding time value (DTS) and the playback time value (PTS) can be adjusted by changing the time value close to the time reference value (PCR) determined in the TS packet (modified from the preset value) (S30).

더 나아가, 본 발명의 일 실시예에 따른 동영상 인코딩방법에서 동영상 인코딩장치(100)는, 특정 TS 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 근접하도록 조정하는 근접 정도를, 초기 재생구간에 속하는 가장 앞선 특정 TS 패킷에 대해 가장 근접하게 하고 마지막 특정 TS 패킷까지 순차적으로 멀게 하는 방식으로 변경할 수 있다.Furthermore, in the video encoding method according to an embodiment of the present invention, the video encoding apparatus 100 sets the decoding time value (DTS) and the playback time value (PTS) determined for each video and audio of a specific TS packet as a time reference value. The degree of proximity adjusted to approximate (PCR) may be changed in such a way that it is closest to the earliest specific TS packet belonging to the initial playback section and sequentially farther from the last specific TS packet.

즉, 동영상 인코딩장치(100)는, 초기 재생구간에 속하는 가장 앞선 특정 TS 패킷에 대해 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 가장 근접하도록 조정(변경 또는 결정)하고, 그 다음 앞선 특정 TS 패킷에 대해 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 두번째로 근접하도록 조정(변경 또는 결정)하고, 그 다음 앞선 특정 TS 패킷에 대해 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 세번째로 근접하도록 조정(변경 또는 결정)는 방식으로, 초기 재생구간에 속하는 가장 앞선 특정 TS 패킷부터 마지막 특정 TS 패킷까지 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)가 근접하도록 조정하는 근접 정도를 순차적으로 멀어지게 변경할 수 있다.That is, the video encoding apparatus 100 adjusts (changes or determines) the decoding time value (DTS) and the playback time value (PTS) for the most advanced specific TS packet belonging to the initial playback section to be closest to the time reference value (PCR). ), and then adjusts (changes or determines) the decoding time value (DTS) and playback time value (PTS) for the preceding specific TS packet to be second to the time reference value (PCR), and then in the preceding specific TS packet In this way, the decoding time value (DTS) and the playback time value (PTS) are adjusted (changed or determined) to be thirdly close to the time reference value (PCR), from the earliest specific TS packet belonging to the initial playback section to the last specific TS packet The degree of proximity for adjusting the decoding time value (DTS) and the reproduction time value (PTS) to be close to the time reference value (PCR) may be sequentially changed away from each other.

그리고, 본 발명의 일 실시예에 따른 동영상 인코딩방법에 따르면, S30단계에서 DTS 및 PTS가 조정(예: 수정)된 비디오 및 오디오는 먹싱된 후(특정 TS 패킷) 인코딩 처리되어, 동영상 파일로서 저장될 것이다(S40).And, according to the video encoding method according to an embodiment of the present invention, the video and audio of which DTS and PTS are adjusted (eg, corrected) in step S30 are muxed (specific TS packet) and then encoded and stored as a video file. will be (S40).

한편, 본 발명의 일 실시예에 따른 동영상 인코딩방법에서 동영상 인코딩장치(100)는, 초기 재생구간 이후 재생구간의 TS 패킷인 경우(S20 No), TS 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 TS 패킷에 정해지는 시간기준값(PCR)으로부터 일정 간격을 갖도록 (재) 조정하여, 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 해당 TS 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 한다(S50).On the other hand, in the video encoding method according to an embodiment of the present invention, the video encoding apparatus 100 provides a decoding time determined for each video and audio of the TS packet when it is a TS packet in the playback section after the initial playback section (S20 No). The value (DTS) and the playback time value (PTS) are (re)adjusted to have a certain interval from the time reference value (PCR) determined in the corresponding TS packet, so that the time reference value (PCR) and the playback time value (PTS) It enables the playback delay of the corresponding TS packet to be utilized as buffering (S50).

앞서 언급한 바와 같이, Mpeg-TS(Transport Stream)로 이미 생성된 동영상 파일의 각 영상 단위 비디오/오디오에는, 시간기준값(PCR)이 정해지며, 시간기준값(PCR)을 기준으로 일정 간격을 갖는 디코딩시간값(DTS) 및 재생시간값(PTS)이 기 정해져 있을 것이다.As mentioned above, a time reference value (PCR) is determined for each video unit video/audio of a moving picture file already created with Mpeg-TS (Transport Stream), and decoding having a predetermined interval based on the time reference value (PCR) The time value DTS and the playback time value PTS may be predetermined.

이에, 본 발명의 일 실시예에 따른 동영상 인코딩방법에서 동영상 인코딩장치(100)는, TS 패킷의 비디오 및 오디오 각각에 기 정해져 있는 디코딩시간값(DTS) 및 재생시간값(PTS)을 해당 TS 패킷에 정해지는 시간기준값(PCR)에 근접한 시간값으로 변경하지 않고 유지(기 설정 값 유지)하는 방식으로, 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)으로부터 일정 간격을 갖도록 (재) 조정할 수 있다.Accordingly, in the video encoding method according to an embodiment of the present invention, the video encoding apparatus 100 converts the decoding time value (DTS) and the playback time value (PTS) predetermined to each of the video and audio of the TS packet to the corresponding TS packet. The decoding time value (DTS) and the playback time value (PTS) are set at a certain interval from the time reference value (PCR) in a manner that maintains (maintains the preset value) without changing to a time value close to the time reference value (PCR) determined in It can be (re)adjusted to have

그리고, 본 발명의 일 실시예에 따른 동영상 인코딩방법에 따르면, S50단계에서 DTS 및 PTS가 조정(유지)된 비디오 및 오디오는 먹싱된 후(TS 패킷) 인코딩 처리되어, 동영상 파일로서 저장될 것이다(S40).And, according to the video encoding method according to an embodiment of the present invention, the video and audio of which DTS and PTS are adjusted (maintained) in step S50 are muxed (TS packet) and then encoded and stored as a video file ( S40).

이처럼, 본 발명의 일 실시예에 따른 동영상 인코딩방법에 따르면, 동영상의 인코딩 시, 동영상의 초기 재생구간 및 이후 재생구간에 속하는 비디오 및 오디오의 DTS 및 PTS를 다르게 조정한 후 인코딩하는 방식을 통해, 인코딩된 동영상(파일) 자체를 초기 재생구간에서는 PCR 및 PTS 간 이격(간격)에 따른 재생 지연이 최소화되고 이후 재생구간에서는 재생 지연이 일정 수준(일정 간격) 이상 발생하여 버퍼링 역할로 활용 가능한 상태(형태, 구조)로 생성할 수 있다.As such, according to the video encoding method according to an embodiment of the present invention, when encoding a video, the DTS and PTS of the video and audio belonging to the initial playback section and the subsequent playback section of the video are differently adjusted and then encoded. In the initial playback section of the encoded video (file) itself, the playback delay due to the separation (interval) between PCR and PTS is minimized, and in the subsequent playback section, the playback delay occurs at a certain level (a certain interval) or more, so it can be used as a buffering role ( form, structure).

이렇게 되면, 도 3에 도시된 바와 같이, 본 발명에 의해 인코딩된 동영상 파일을 재생하는 Player, 예를 들어 동영상 파일을 로드 및 재생하는 Player에서, 기존과 같은 방식으로 동영상 재생 시 영상(비디오/오디오)의 시간값(PCR, DTS, PTS)을 이용하여 디코딩 및 재생(화면 출력)하면, 초기 재생구간(영상1~영상N-1)에서는 PCR 및 PTS 간 이격(간격)에 따른 재생 지연이 최소화되어 즉시 재생(화면 출력)하고 이후 재생구간에서는 재생 지연이 기존처럼 일정 수준(일정 간격) 이상 발생하며 버퍼링 역할로 활용할 수 있다.In this case, as shown in FIG. 3 , in the player that plays the video file encoded by the present invention, for example, the player that loads and plays the video file, the video (video/audio) when playing the video in the same way as before ) using time values (PCR, DTS, PTS) to decode and reproduce (screen output), the playback delay due to the interval (interval) between PCR and PTS is minimized in the initial playback section (image 1 to image N-1). It plays immediately (screen output), and in the subsequent playback section, the playback delay occurs over a certain level (a certain interval) as before, and can be used as a buffering role.

이상 설명한 바와 같이, 본 발명의 실시예들에 따르면, 동영상의 인코딩 시 초기 재생구간 및 이후 재생구간에서 비디오 및 오디오의 DTS 및 PTS를 다르게 조정하여 인코딩함으로써, 동영상의 초기 재생구간에서만 버퍼링 역할의 재생 지연을 최소화할 수 있는 기술, 즉 초기 재생 지연 최소화 인코딩 방안을 실현하고 있다.As described above, according to the embodiments of the present invention, when encoding a moving picture, the DTS and PTS of video and audio are differently adjusted and encoded in the initial playback section and the subsequent playback section, thereby playing the buffering role only in the initial playback section of the moving picture. A technology capable of minimizing the delay, that is, an encoding method for minimizing the initial playback delay, is being realized.

이로 인해, 본 발명에 따르면, 동영상 전송 기술인 Mpeg-TS에서 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여, 동영상 초기 재생의 지연은 최소화하면서 초기 재생구간 이후에는 버퍼링 역할도 유지할 수 있는 효과를 기대할 수 있다.For this reason, according to the present invention, by using three time values (PCR, DTS, PTS) of video and audio in Mpeg-TS, which is a moving picture transmission technology, the delay of the initial playback of the video is minimized and the buffering role is also performed after the initial playback section Sustainable effects can be expected.

한편, 본 명세서에서 설명하는 기능적인 동작과 주제의 구현물들은 디지털 전자 회로로 구현되거나, 본 명세서에서 개시하는 구조 및 그 구조적인 등가물들을 포함하는 컴퓨터 소프트웨어, 펌웨어 혹은 하드웨어로 구현되거나, 이들 중 하나 이상의 결합으로 구현 가능하다.  본 명세서에서 설명하는 주제의 구현물들은 하나 이상의 컴퓨터 프로그램 제품, 다시 말해 제어 시스템의 동작을 제어하기 위하여 혹은 이것에 의한 실행을 위하여 유형의 프로그램 저장매체 상에 인코딩된 컴퓨터 프로그램 명령에 관한 하나 이상의 모듈로서 구현될 수 있다.On the other hand, the functional operations and implementations of the subject matter described in this specification are implemented as digital electronic circuits, computer software, firmware, or hardware including the structures disclosed in this specification and structural equivalents thereof, or at least one of these It can be implemented by combining. Implementations of the subject matter described herein are one or more computer program products, ie, one or more modules of computer program instructions encoded on a tangible program storage medium for controlling the operation of or for execution by a control system. can be implemented.

컴퓨터로 판독 가능한 매체는 기계로 판독 가능한 저장 장치, 기계로 판독 가능한 저장 기판, 메모리 장치, 기계로 판독 가능한 전파형 신호에 영향을 미치는 물질의 조성물 혹은 이들 중 하나 이상의 조합일 수 있다.The computer readable medium may be a machine readable storage device, a machine readable storage substrate, a memory device, a composition of matter that affects a machine readable radio wave signal, or a combination of one or more thereof.

본 명세서에서 "시스템"이나 "장치"라 함은 예컨대 프로그래머블 프로세서, 컴퓨터 혹은 다중 프로세서나 컴퓨터를 포함하여 데이터를 제어하기 위한 모든 기구, 장치 및 기계를 포괄한다. 제어 시스템은, 하드웨어에 부가하여, 예컨대 프로세서 펌웨어를 구성하는 코드, 프로토콜 스택, 데이터베이스 관리 시스템, 운영 체제 혹은 이들 중 하나 이상의 조합 등 요청 시 컴퓨터 프로그램에 대한 실행 환경을 형성하는 코드를 포함할 수 있다.As used herein, the term “system” or “device” encompasses all instruments, devices, and machines for controlling data, including, for example, a programmable processor, a computer, or multiple processors or computers. The control system may include, in addition to hardware, code forming an execution environment for a computer program upon request, such as, for example, code constituting processor firmware, a protocol stack, a database management system, an operating system, or a combination of one or more thereof. .

컴퓨터 프로그램(프로그램, 소프트웨어, 소프트웨어 어플리케이션, 스크립트 혹은 코드로도 알려져 있음)은 컴파일되거나 해석된 언어나 선험적 혹은 절차적 언어를 포함하는 프로그래밍 언어의 어떠한 형태로도 작성될 수 있으며, 독립형 프로그램이나 모듈, 컴포넌트, 서브루틴 혹은 컴퓨터 환경에서 사용하기에 적합한 다른 유닛을 포함하여 어떠한 형태로도 전개될 수 있다. 컴퓨터 프로그램은 파일 시스템의 파일에 반드시 대응하는 것은 아니다. 프로그램은 요청된 프로그램에 제공되는 단일 파일 내에, 혹은 다중의 상호 작용하는 파일(예컨대, 하나 이상의 모듈, 하위 프로그램 혹은 코드의 일부를 저장하는 파일) 내에, 혹은 다른 프로그램이나 데이터를 보유하는 파일의 일부(예컨대, 마크업 언어 문서 내에 저장되는 하나 이상의 스크립트) 내에 저장될 수 있다. 컴퓨터 프로그램은 하나의 사이트에 위치하거나 복수의 사이트에 걸쳐서 분산되어 통신 네트워크에 의해 상호 접속된 다중 컴퓨터나 하나의 컴퓨터 상에서 실행되도록 전개될 수 있다.A computer program (also known as a program, software, software application, script or code) may be written in any form of a programming language, including compiled or interpreted language or a priori or procedural language, and may be written as a stand-alone program or module; It can be deployed in any form, including components, subroutines, or other units suitable for use in a computer environment. A computer program does not necessarily correspond to a file in a file system. A program may be in a single file provided to the requested program, or in multiple interacting files (eg, files that store one or more modules, subprograms, or portions of code), or portions of files that hold other programs or data. (eg, one or more scripts stored within a markup language document). The computer program may be deployed to be executed on a single computer or multiple computers located at one site or distributed over a plurality of sites and interconnected by a communication network.

한편, 컴퓨터 프로그램 명령어와 데이터를 저장하기에 적합한 컴퓨터로 판독 가능한 매체는, 예컨대 EPROM, EEPROM 및 플래시메모리 장치와 같은 반도체 메모리 장치, 예컨대 내부 하드디스크나 외장형 디스크와 같은 자기 디스크, 자기광학 디스크 및 CD-ROM과 DVD-ROM 디스크를 포함하여 모든 형태의 비휘발성 메모리, 매체 및 메모리 장치를 포함할 수 있다. 프로세서와 메모리는 특수 목적의 논리 회로에 의해 보충되거나, 그것에 통합될 수 있다.On the other hand, computer-readable media suitable for storing computer program instructions and data include, for example, semiconductor memory devices such as EPROMs, EEPROMs and flash memory devices, such as magnetic disks such as internal hard disks or external disks, magneto-optical disks and CDs. -Can include all types of non-volatile memory, media and memory devices, including ROM and DVD-ROM disks. The processor and memory may be supplemented by, or incorporated into, special purpose logic circuitry.

본 명세서에서 설명한 주제의 구현물은 예컨대 데이터 서버와 같은 백엔드 컴포넌트를 포함하거나, 예컨대 어플리케이션 서버와 같은 미들웨어 컴포넌트를 포함하거나, 예컨대 사용자가 본 명세서에서 설명한 주제의 구현물과 상호 작용할 수 있는 웹 브라우저나 그래픽 유저 인터페이스를 갖는 클라이언트 컴퓨터와 같은 프론트엔드 컴포넌트 혹은 그러한 백엔드, 미들웨어 혹은 프론트엔드 컴포넌트의 하나 이상의 모든 조합을 포함하는 연산 시스템에서 구현될 수도 있다. 시스템의 컴포넌트는 예컨대 통신 네트워크와 같은 디지털 데이터 통신의 어떠한 형태나 매체에 의해서도 상호 접속 가능하다.An implementation of the subject matter described herein may include a backend component, such as a data server, or a middleware component, such as an application server, or a web browser or graphical user, such as a user capable of interacting with an implementation of the subject matter described herein. It may be implemented in a front-end component, such as a client computer having an interface, or in a computing system including any combination of one or more of such back-end, middleware, or front-end components. The components of the system may be interconnected by any form or medium of digital data communication, such as, for example, a communication network.

본 명세서는 다수의 특정한 구현물의 세부사항들을 포함하지만, 이들은 어떠한 발명이나 청구 가능한 것의 범위에 대해서도 제한적인 것으로서 이해되어서는 안되며, 오히려 특정한 발명의 특정한 실시형태에 특유할 수 있는 특징들에 대한 설명으로서 이해되어야 한다. 마찬가지로, 개별적인 실시형태의 문맥에서 본 명세서에 기술된 특정한 특징들은 단일 실시형태에서 조합하여 구현될 수도 있다. 반대로, 단일 실시형태의 문맥에서 기술한 다양한 특징들 역시 개별적으로 혹은 어떠한 적절한 하위 조합으로도 복수의 실시형태에서 구현 가능하다. 나아가, 특징들이 특정한 조합으로 동작하고 초기에 그와 같이 청구된 바와 같이 묘사될 수 있지만, 청구된 조합으로부터의 하나 이상의 특징들은 일부 경우에 그 조합으로부터 배제될 수 있으며, 그 청구된 조합은 하위 조합이나 하위 조합의 변형물로 변경될 수 있다.While this specification contains numerous specific implementation details, they should not be construed as limitations on the scope of any invention or claim, but rather as descriptions of features that may be specific to particular embodiments of particular inventions. should be understood Likewise, certain features that are described herein in the context of separate embodiments may be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment may also be implemented in multiple embodiments, either individually or in any suitable subcombination. Furthermore, although features operate in a particular combination and may be initially depicted as claimed as such, one or more features from a claimed combination may in some cases be excluded from the combination, the claimed combination being a sub-combination. or a variant of a sub-combination.

또한, 본 명세서에서는 특정한 순서로 도면에서 동작들을 묘사하고 있지만, 이는 바람직한 결과를 얻기 위하여 도시된 그 특정한 순서나 순차적인 순서대로 그러한 동작들을 수행하여야 한다거나 모든 도시된 동작들이 수행되어야 하는 것으로 이해되어서는 안 된다. 특정한 경우, 멀티태스킹과 병렬 프로세싱이 유리할 수 있다. 또한, 상술한 실시형태의 다양한 시스템 컴포넌트의 분리는 그러한 분리를 모든 실시형태에서 요구하는 것으로 이해되어서는 안되며, 설명한 프로그램 컴포넌트와 시스템들은 일반적으로 단일의 소프트웨어 제품으로 함께 통합되거나 다중 소프트웨어 제품에 패키징될 수 있다는 점을 이해하여야 한다Also, although operations are depicted in the drawings in a specific order herein, it is not to be understood that such operations must be performed in the specific order or sequential order shown or that all illustrated operations must be performed in order to achieve desirable results. Can not be done. In certain cases, multitasking and parallel processing may be advantageous. Further, the separation of the various system components of the above-described embodiments should not be construed as requiring such separation in all embodiments, and the program components and systems described may generally be integrated together into a single software product or packaged into multiple software products. It should be understood that

이와 같이, 본 명세서는 그 제시된 구체적인 용어에 본 발명을 제한하려는 의도가 아니다. 따라서, 상술한 예를 참조하여 본 발명을 상세하게 설명하였지만, 당업자라면 본 발명의 범위를 벗어나지 않으면서도 본 예들에 대한 개조, 변경 및 변형을 가할 수 있다. 본 발명의 범위는 상기 상세한 설명보다는 후술하는 특허청구범위에 의하여 나타내어지며, 특허청구범위의 의미 및 범위 그리고 그 등가개념으로부터 도출되는 모든 변경 또는 변형된 형태가 본 발명의 범위에 포함되는 것으로 해석되어야 한다.As such, this specification is not intended to limit the invention to the specific terminology presented. Accordingly, although the present invention has been described in detail with reference to the above-described examples, those skilled in the art can make modifications, changes, and modifications to the examples without departing from the scope of the present invention. The scope of the present invention is indicated by the following claims rather than the above detailed description, and all changes or modifications derived from the meaning and scope of the claims and their equivalent concepts should be interpreted as being included in the scope of the present invention. do.

본 발명의 동영상 인코딩장치 및 동영상 인코딩방법에 따르면, Mpeg-TS에서 비디오 및 오디오의 3가지 시간값(PCR, DTS, PTS)을 이용하여 동영상 초기 재생의 지연을 최소화하면서도 버퍼링 역할을 유지하는 기술을 실현하는 점에서, 기존 기술의 한계를 뛰어 넘음에 따라 관련 기술에 대한 이용만이 아닌 적용되는 장치의 시판 또는 영업의 가능성이 충분할 뿐만 아니라 현실적으로 명백하게 실시할 수 있는 정도이므로 산업상 이용가능성이 있는 발명이다.According to the video encoding apparatus and video encoding method of the present invention, a technology of maintaining a buffering role while minimizing the delay of the initial video playback by using three time values (PCR, DTS, PTS) of video and audio in Mpeg-TS In the sense of realization, as it goes beyond the limits of existing technologies, not only the use of the related technology, but also the possibility of marketing or business of the applied device is sufficient, and the invention has industrial applicability because it can be clearly implemented in reality. am.

100: 동영상 인코딩장치
110: 시간값조정부 120: 인코딩부
100: video encoding device
110: time value adjustment unit 120: encoding unit

Claims (11)

동영상의 재생 시 초기 재생구간에 속하는 특정 패킷에 대하여, 상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩 순서를 위한 시간값(DTS: Decoding Time Stamp) 및 재생 시각을 알려주는 시간값(PTS: Presentation Time Stamp)을 상기 특정 패킷에 정해지는 시간기준값(PCR: Program Clock Reference)에 근접하도록 조정하여, 상기 시간기준값(PCR) 및 재생시간값(PTS)의 이격을 감소시키는 시간값조정부; 및
상기 동영상의 각 패킷을 인코딩 처리하는 인코딩부를 포함하는 것을 특징으로 하는 동영상 인코딩장치.
With respect to a specific packet belonging to an initial playback section when a moving picture is reproduced, a time value (DTS: Decoding Time Stamp) for a decoding order determined for each video and audio of the specific packet and a time value (PTS: Presentation) indicating a playback time a time value adjusting unit for reducing the separation between the time reference value (PCR) and the playback time value (PTS) by adjusting the time stamp) to be close to a time reference value (PCR: Program Clock Reference) determined for the specific packet; and
and an encoding unit for encoding each packet of the moving picture.
제 1 항에 있어서,
상기 시간값조정부는,
상기 동영상의 초기 재생구간 이후 재생구간에 속하는 패킷에 대해서는, 상기 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS) 중 적어도 하나를 재 조정하여, 상기 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 상기 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 하는 것을 특징으로 하는 동영상 인코딩장치.
The method of claim 1,
The time value adjustment unit,
For a packet belonging to a playback section after the initial playback section of the moving picture, at least one of a decoding time value (DTS) and a playback time value (PTS) determined for each video and audio of the packet is readjusted, and the time reference value ( PCR) and a playback delay of the packet according to the separation of the playback time value (PTS) can be utilized as buffering.
삭제delete 제 2 항에 있어서,
상기 시간값조정부는,
상기 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 상기 패킷에 정해지는 시간기준값(PCR)으로부터 일정 간격을 갖도록 재 조정하여, 상기 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 상기 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 하는 것을 특징으로 하는 동영상 인코딩장치.
3. The method of claim 2,
The time value adjustment unit,
The time reference value (PCR) and A video encoding apparatus, characterized in that the playback delay of the packet according to the separation of the playback time value (PTS) can be utilized as buffering.
제 2 항에 있어서,
상기 시간값조정부는,
상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 근접하도록 조정하는 근접 정도를, 상기 초기 재생구간에 속하는 가장 앞선 특정 패킷에 대해 가장 근접하게 하고 마지막 특정 패킷까지 순차적으로 멀게 하는 것을 특징으로 하는 동영상 인코딩장치.
3. The method of claim 2,
The time value adjustment unit,
The degree of proximity for adjusting the decoding time value (DTS) and the playback time value (PTS), which are determined for the video and audio, respectively, of the specific packet to be close to the time reference value (PCR) is set to the earliest specific packet belonging to the initial playback section. Video encoding device, characterized in that the closest to each other and sequentially farther away from each other until the last specific packet.
제 1 항에 있어서,
상기 동영상은, Mpeg-TS(Transport Stream)로 생성된 파일을 포함하는 것을 특징으로 하는 동영상 인코딩장치.
The method of claim 1,
The video encoding apparatus, characterized in that it includes a file generated by Mpeg-TS (Transport Stream).
동영상의 재생 시 초기 재생구간에 속하는 특정 패킷에 대하여, 상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩 순서를 위한 시간값(DTS: Decoding Time Stamp) 및 재생 시각을 알려주는 시간값(PTS: Presentation Time Stamp)을 상기 특정 패킷에 정해지는 시간기준값(PCR: Program Clock Reference)에 근접하도록 조정하여, 상기 시간기준값(PCR) 및 재생시간값(PTS)의 이격을 감소시키는 시간값조정단계; 및
상기 동영상의 각 패킷을 인코딩 처리하는 인코딩단계를 포함하는 것을 특징으로 하는 동영상 인코딩방법.
With respect to a specific packet belonging to an initial playback section when a moving picture is reproduced, a time value (DTS: Decoding Time Stamp) for a decoding order determined for each video and audio of the specific packet and a time value (PTS: Presentation) indicating a playback time a time value adjustment step of reducing the separation between the time reference value (PCR) and the playback time value (PTS) by adjusting the time stamp) to be close to a time reference value (PCR: Program Clock Reference) determined for the specific packet; and
and an encoding step of encoding each packet of the video.
제 7 항에 있어서,
상기 시간값조정단계는,
상기 동영상의 초기 재생구간 이후 재생구간에 속하는 패킷에 대해서는, 상기 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS) 중 적어도 하나를 재 조정하여, 상기 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 하는 것을 특징으로 하는 동영상 인코딩방법.
8. The method of claim 7,
The time value adjustment step is,
For a packet belonging to a playback section after the initial playback section of the moving picture, at least one of a decoding time value (DTS) and a playback time value (PTS) determined for each video and audio of the packet is readjusted to reproduce the packet A video encoding method characterized in that the delay can be utilized as buffering.
삭제delete 제 8 항에 있어서,
상기 시간값조정단계는,
상기 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 상기 패킷에 정해지는 시간기준값(PCR)으로부터 일정 간격을 갖도록 재 조정하여, 상기 시간기준값(PCR) 및 재생시간값(PTS)의 이격에 따른 상기 패킷의 재생 지연이 버퍼링으로 활용될 수 있게 하는 것을 특징으로 하는 동영상 인코딩방법.
9. The method of claim 8,
The time value adjustment step is,
The time reference value (PCR) and A video encoding method, characterized in that the playback delay of the packet according to the separation of the playback time value (PTS) can be utilized as buffering.
제 8 항에 있어서,
상기 시간값조정단계는,
상기 특정 패킷의 비디오 및 오디오 각각에 정해지는 디코딩시간값(DTS) 및 재생시간값(PTS)을 시간기준값(PCR)에 근접하도록 조정하는 근접 정도를, 상기 초기 재생구간에 속하는 가장 앞선 특정 패킷에 대해 가장 근접하게 하고 마지막 특정 패킷까지 순차적으로 멀게 하는 것을 특징으로 하는 동영상 인코딩방법.
9. The method of claim 8,
The time value adjustment step is,
The degree of proximity for adjusting the decoding time value (DTS) and the playback time value (PTS), which are determined for the video and audio, respectively, of the specific packet to be close to the time reference value (PCR) is set to the earliest specific packet belonging to the initial playback section. Video encoding method, characterized in that the closest to each other and sequentially farther away from each other until the last specific packet.
KR1020200044241A 2020-04-10 2020-04-10 Video incoding device and video incoding method KR102313323B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020200044241A KR102313323B1 (en) 2020-04-10 2020-04-10 Video incoding device and video incoding method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020200044241A KR102313323B1 (en) 2020-04-10 2020-04-10 Video incoding device and video incoding method

Publications (1)

Publication Number Publication Date
KR102313323B1 true KR102313323B1 (en) 2021-10-14

Family

ID=78116184

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020200044241A KR102313323B1 (en) 2020-04-10 2020-04-10 Video incoding device and video incoding method

Country Status (1)

Country Link
KR (1) KR102313323B1 (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR19990047314A (en) * 1997-12-03 1999-07-05 이계철 Display Start Point (PTS) and Decode Start Point (DTS) Processing Circuits for Non / Audio Synchronization
JP2001309306A (en) * 2000-04-26 2001-11-02 Sony Corp Device and method for reproduction and recording medium
KR20040037147A (en) * 2001-09-29 2004-05-04 코닌클리케 필립스 일렉트로닉스 엔.브이. Robust method for recovering a program time base in MPEG-2 transport streams and achieving audio/video synchronization
JP2008187248A (en) * 2007-01-26 2008-08-14 Toshiba Corp Stream reproducing device
KR20140053777A (en) * 2012-10-22 2014-05-08 한국전자통신연구원 Method and apparatus for decoder buffering in hybrid coded video system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR19990047314A (en) * 1997-12-03 1999-07-05 이계철 Display Start Point (PTS) and Decode Start Point (DTS) Processing Circuits for Non / Audio Synchronization
JP2001309306A (en) * 2000-04-26 2001-11-02 Sony Corp Device and method for reproduction and recording medium
KR20040037147A (en) * 2001-09-29 2004-05-04 코닌클리케 필립스 일렉트로닉스 엔.브이. Robust method for recovering a program time base in MPEG-2 transport streams and achieving audio/video synchronization
JP2008187248A (en) * 2007-01-26 2008-08-14 Toshiba Corp Stream reproducing device
KR20140053777A (en) * 2012-10-22 2014-05-08 한국전자통신연구원 Method and apparatus for decoder buffering in hybrid coded video system

Similar Documents

Publication Publication Date Title
JP7036962B2 (en) Playback method and playback device
US7870281B2 (en) Content playback device, content playback method, computer-readable storage medium, and content playback system
US7630612B2 (en) Video stream adaptive frame rate scheme
TWI571115B (en) Techniques for synchronization of audio and video
US10129587B2 (en) Fast switching of synchronized media using time-stamp management
US8242942B2 (en) System and method to modify a metadata parameter
TWI788744B (en) Dynamic reduction in playout of replacement content to help align end of replacement content with end of replaced content
US20070058730A1 (en) Media stream error correction
US10638180B1 (en) Media timeline management
US9549027B2 (en) Network-synchronized media playback
US8244897B2 (en) Content reproduction apparatus, content reproduction method, and program
US10616652B2 (en) Playback method and electronic device using the same
JP4511952B2 (en) Media playback device
US20180359428A1 (en) Method and/or apparatus for frame accurate hot failover
KR102313323B1 (en) Video incoding device and video incoding method
US9473732B2 (en) Self correcting record pipeline
EP4040794A1 (en) Systems and methods for adaptive output
US9420278B2 (en) Audiovisual content generation method for multistage high-speed reproduction
US20190387271A1 (en) Image processing apparatus, image processing method, and program
JP2012222530A (en) Receiving device and method, and program
US10750233B2 (en) Recording apparatus, recording method, and program
US20240112703A1 (en) Seamless insertion of modified media content
US11303940B2 (en) Transmission apparatus, transmission method, and non-transitory computer-readable storage medium
JP5775006B2 (en) Information processing apparatus, information processing method, and semiconductor device
US20090110364A1 (en) Reproduction apparatus and reproduction method

Legal Events

Date Code Title Description
AMND Amendment
E601 Decision to refuse application
X091 Application refused [patent]
AMND Amendment
X701 Decision to grant (after re-examination)
GRNT Written decision to grant