JP2007189587A - Stream conversion device, information recorder and stream converting method - Google Patents

Stream conversion device, information recorder and stream converting method Download PDF

Info

Publication number
JP2007189587A
JP2007189587A JP2006007219A JP2006007219A JP2007189587A JP 2007189587 A JP2007189587 A JP 2007189587A JP 2006007219 A JP2006007219 A JP 2006007219A JP 2006007219 A JP2006007219 A JP 2006007219A JP 2007189587 A JP2007189587 A JP 2007189587A
Authority
JP
Japan
Prior art keywords
stream
pes
header
packet
conversion
Prior art date
Legal status (The legal status 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 status listed.)
Granted
Application number
JP2006007219A
Other languages
Japanese (ja)
Other versions
JP4675784B2 (en
JP2007189587A5 (en
Inventor
Daiki Matsuura
大樹 松浦
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Mitsubishi Electric Corp
Original Assignee
Mitsubishi Electric Corp
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 Mitsubishi Electric Corp filed Critical Mitsubishi Electric Corp
Priority to JP2006007219A priority Critical patent/JP4675784B2/en
Publication of JP2007189587A publication Critical patent/JP2007189587A/en
Publication of JP2007189587A5 publication Critical patent/JP2007189587A5/ja
Application granted granted Critical
Publication of JP4675784B2 publication Critical patent/JP4675784B2/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Television Signal Processing For Recording (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide a stream conversion device and method capable of converting even a TS (transport stream) that is not a TS with an arranged data format into a PS (program stream) and simplifying a device configuration, and an information recorder. <P>SOLUTION: The stream conversion device has a detecting and dividing part (step S10 and S11) for analyzing a TS header included in an inputted TS and detecting and dividing a TS packet including video data and sound data from the inputted TS, a buffer, a PS converting part (step S13) for generating a PES (packetized elementary stream) packet of a TS from a TS payload of the TS packet divided by the detecting and dividing part to write the PES packet in the buffer, reading the PES payload included in the PES packet of the TS from the buffer when an amount of data stored in the buffer becomes a prescribed value or more, adding a header to the read PES payload to generate a PS pack, and an SCR (system clock reference) setting part (step S14) for rewriting the value of the header of the PS. <P>COPYRIGHT: (C)2007,JPO&INPIT

Description

本発明は、デジタル映像音声情報であるトランスポートストリーム(TS)をデジタル映像音声情報であるプログラムストリーム(PS)に変換するストリーム変換装置、このストリーム変換装置を含む情報記録装置、及びストリーム変換方法に関するものである。   The present invention relates to a stream conversion device that converts a transport stream (TS) that is digital video / audio information into a program stream (PS) that is digital video / audio information, an information recording device including the stream conversion device, and a stream conversion method. Is.

近年、多くの国でデジタル放送が開始され、デジタル放送の番組がTSで伝送されている。このことに伴い、デジタル放送の番組をTSのまま記録及び再生できる機器が開発されている。一方、現在のDVD論理規格(DVD−Video規格、DVD−Audio規格、DVD Video Recording規格、DVD Stream Recording規格)においては、PSで番組を保存することが規定されている。よって、デジタル放送の番組をDVD論理規格に則った形式でDVDに保存するためには、TSをPSに変換する必要がある。   In recent years, digital broadcasting has started in many countries, and digital broadcasting programs are transmitted by TS. Along with this, devices that can record and play back digital broadcast programs as they are TS are being developed. On the other hand, in the current DVD logic standard (DVD-Video standard, DVD-Audio standard, DVD Video Recording standard, DVD Stream Recording standard), it is defined that a program is stored in PS. Therefore, in order to save a digital broadcast program on a DVD in a format conforming to the DVD logical standard, it is necessary to convert TS to PS.

また、TSは伝送誤りが発生する環境下における使用を想定して規格化されたものであり、蓄積向けに規格化されたPSと比較して、冗長度が高い。そのため、デジタル放送の番組をTS形式のまま記録すると、多くの記録領域を使ってしまうという問題が発生する。以上のことから、TSをPSに変換して記録する情報記録装置が必要となる(例えば、特許文献1及び2参照)。   Also, TS is standardized assuming use in an environment where transmission errors occur, and has a higher degree of redundancy than PS standardized for storage. For this reason, when a digital broadcast program is recorded in the TS format, there is a problem that a large number of recording areas are used. From the above, an information recording apparatus that converts TS into PS and records it is necessary (see, for example, Patent Documents 1 and 2).

特表2005−513936号公報(要約)JP 2005-513936 A (summary) 特開2004−312441号公報(段落0039−0048、図1、図2)Japanese Patent Laying-Open No. 2004-312441 (paragraphs 0039-0048, FIGS. 1 and 2)

しかしながら、特許文献1に記載された情報記録装置は、TSからPSへの変換が容易になるように形式が整えられたTSを生成し記録する。そして、TSからPSへの変換については、この情報記録装置で生成されたTSのみを対象としている。そのため、この情報記録装置では、TSのデータ形式を整えるという処理を経た後でなければTSからPSへの変換を行なうことができない。   However, the information recording apparatus described in Patent Document 1 generates and records a TS that has a format that facilitates conversion from TS to PS. The conversion from TS to PS is intended only for the TS generated by this information recording apparatus. For this reason, in this information recording apparatus, conversion from TS to PS can be performed only after a process of adjusting the data format of TS.

また、特許文献2に記載された情報記録装置は、PSのシステムクロックリファレンス(System Clock Reference:SCR)と呼ばれるパラメータを設定するために、27MHzのクロック発生装置を使用している。そのため、この情報記録装置は、クロック発生装置なしでは、TSからPSへの変換を行なうことができない。   The information recording apparatus described in Patent Document 2 uses a 27 MHz clock generator to set a parameter called a PS system clock reference (SCR). Therefore, this information recording apparatus cannot perform conversion from TS to PS without a clock generator.

そこで、本発明は、上記従来技術の課題を解決するためになされたものであり、その目的は、TSからPSへの変換をデータ形式を整えるという処理を経ることなく行うことができ、しかも装置の構成を簡素化することができるストリーム変換装置、このストリーム変換装置を搭載した情報記録装置、及びストリーム変換方法を提供することにある。   Accordingly, the present invention has been made to solve the above-described problems of the prior art, and the object of the present invention is to perform the conversion from TS to PS without processing the data format, and the apparatus. Is to provide a stream conversion apparatus, an information recording apparatus equipped with the stream conversion apparatus, and a stream conversion method.

本発明のストリーム変換装置は、映像音声のデジタルデータストリームであるTSを映像音声のデジタルデータストリームであるPSに変換するストリーム変換装置であって、入力されたTSに含まれるTSヘッダを解析し、前記入力されたTSから映像データ及び音声データを含むTSパケットを検出して分離する検出分離部と、バッファ手段と、前記検出分離部で分離されたTSパケットのTSペイロードからTSのPESパケットを生成して前記バッファ手段に書き込み、前記バッファ手段に格納されたデータ量が所定値以上になったときに、前記TSのPESパケットに含まれるPESペイロードを前記バッファ手段から読み出し、この読み出された前記PESペイロードにヘッダを付加してPSパックを生成するPS変換部とを有することを特徴としている。   The stream converter of the present invention is a stream converter that converts a TS that is a video / audio digital data stream into a PS that is a video / audio digital data stream, and analyzes a TS header included in the input TS, Detection and separation unit for detecting and separating TS packets including video data and audio data from the input TS, buffer means, and generating TS PES packet from TS payload of TS packets separated by the detection and separation unit When the amount of data stored in the buffer means becomes equal to or greater than a predetermined value, the PES payload contained in the PES packet of the TS is read from the buffer means, and the read PS conversion unit that generates a PS pack by adding a header to the PES payload It is characterized in Rukoto.

本発明の情報記録装置は、前記ストリーム変換装置と、前記ストリーム変換装置から出力されるPSファイルを格納する記録部と、前記ストリーム変換装置から出力されるPSファイルを前記記録部に格納する動作を制御する制御部とを有することを特徴としている。   The information recording apparatus of the present invention includes the stream converter, a recording unit that stores a PS file output from the stream converter, and an operation for storing the PS file output from the stream converter in the recording unit. And a control unit for controlling.

本発明のストリーム変換装置、情報記録装置、及びストリーム変換方法よれば、TSからPSへの変換をデータ形式を整えるという処理を経ていないデータに対して行うことができ、しかも装置の構成を簡素化することができるという効果を得ることができる。   According to the stream conversion device, the information recording device, and the stream conversion method of the present invention, conversion from TS to PS can be performed on data that has not undergone the process of adjusting the data format, and the configuration of the device is simplified. The effect that it can be done can be obtained.

以下に、本発明の実施の形態に係るストリーム変換装置及びこのストリーム変換装置を搭載した情報記録装置、及びストリーム変換方法を、図面を参照しながら説明する。   Hereinafter, a stream conversion apparatus, an information recording apparatus equipped with the stream conversion apparatus, and a stream conversion method according to an embodiment of the present invention will be described with reference to the drawings.

先ず、MPEG2仕様(ITU−T勧告H.222.0|ISO/IEC13818−1)で規格化されたデジタル映像音声情報であるMPEGトランスポートストリーム(Transport Stream:TS)からMPEG2仕様で規格化されたデジタル映像音声情報であるMPEGプログラムストリーム(Program Stream:PS)への変換処理を説明する。   First, it was standardized by MPEG2 specification from MPEG transport stream (Transport Stream: TS) which is digital video / audio information standardized by MPEG2 specification (ITU-T recommendation H.222.0 | ISO / IEC13818-1). A conversion process to an MPEG program stream (Program Stream: PS) which is digital video / audio information will be described.

図1は、TSのデータ構造を示す図である。図1に示されるように、TSは、188バイト(byte)固定長のTSパケット(TS packet)により構成される。各TSパケットは、TSヘッダ(TS header)とTSペイロード(TS payload)とから構成される。映像データ及び音声データは、TSペイロードの中に含まれる。   FIG. 1 is a diagram illustrating a data structure of a TS. As shown in FIG. 1, a TS is composed of a TS packet (TS packet) having a fixed length of 188 bytes. Each TS packet is composed of a TS header (TS header) and a TS payload (TS payload). Video data and audio data are included in the TS payload.

図2は、PSのデータ構造を示す図である。図2に示されるように、PSは、PSパック(PS pack)により構成される。PSパックは、可変長であるが、DVD(デジタル多用途ディスク)などにおいてはセクタ長に合わせるために、通常、2048byteである。各PSパックは、パックヘッダ(pack header)と、システムヘッダ(system header)と、PESパケット(Packetized Elementary Stream packet)とから構成される。システムヘッダは、PSの最初のPSパックにおいては、必須であるが、最初のPSパック以降のPSパックにおいては、有っても無くてもよい。映像データ及び音声データは、PESパケットの中に含まれる。   FIG. 2 is a diagram illustrating a data structure of the PS. As shown in FIG. 2, the PS is configured by a PS pack (PS pack). The PS pack has a variable length, but is usually 2048 bytes in order to match the sector length in a DVD (digital versatile disc) or the like. Each PS pack is composed of a pack header, a system header, and a PES packet (Packetized Elementary Stream packet). The system header is essential in the first PS pack of the PS, but may or may not be present in PS packs after the first PS pack. Video data and audio data are included in the PES packet.

なお、TS及びPSのデータ構造の詳細は、ITU−T勧告H.222.0|ISO/IEC13818−1に記述されている。   Details of the data structure of TS and PS are described in ITU-T Recommendation H.264. 222.0 | ISO / IEC13818-1.

TSには、1番組以上の映像データ及び音声データの他、複数の番組を分離するための情報などが含まれている。一方、PSには、1番組分のみの映像データ及び音声データを含めることができる。よって、TSからPSへの変換においては、1つのTSから1つ以上のPSが生成されることとなる。   The TS includes video data and audio data for one program or more, and information for separating a plurality of programs. On the other hand, video data and audio data for only one program can be included in the PS. Therefore, in the conversion from TS to PS, one or more PSs are generated from one TS.

図3は、TSからPSへの変換における、データ処理の流れを示す図である。図3に示されるように、TSからPSへの変換処理においては、まず、TSを構成するTSパケットを、映像又は音声又はそれ以外の種類別に分類する。図3には、番組1の映像のTSパケット、番組1の音声のTSパケット、番組N(Nは2以上の整数)の映像のTSパケット、番組Nの音声のTSパケット、及び映像・音声以外のTSパケットが示されている。次に、映像のTSパケット及び音声のTSパケットからTSヘッダ情報などを取り除き、映像のデータ及び音声のデータを取り出す。図3には、番組1の映像のデータ、番組1の音声のデータ、番組Nの映像のデータ、及び番組Nの音声のデータが取り出され、映像のTSパケット及び音声のTSパケット以外のTSパケットが破棄されたことが示されている。次に、取り出された映像のデータ及び音声のデータを元にしてPSを生成する。図3には、番組1のPS、及び番組NのPSが生成されることが示されている。   FIG. 3 is a diagram showing the flow of data processing in the conversion from TS to PS. As shown in FIG. 3, in the conversion process from TS to PS, first, TS packets constituting the TS are classified according to video, audio, or other types. In FIG. 3, the TS packet of the video of the program 1, the TS packet of the audio of the program 1, the TS packet of the video of the program N (N is an integer of 2 or more), the TS packet of the audio of the program N, and other than video / audio TS packets are shown. Next, TS header information and the like are removed from the video TS packet and audio TS packet, and video data and audio data are extracted. In FIG. 3, video data of program 1, audio data of program 1, video data of program N, and audio data of program N are extracted, and TS packets other than video TS packets and audio TS packets are extracted. Is shown to have been destroyed. Next, a PS is generated based on the extracted video data and audio data. FIG. 3 shows that a PS for program 1 and a PS for program N are generated.

図4は、本発明の実施の形態に係る情報記録装置の構成を概略的に示すブロック図である。図4に示されるように、実施の形態に係る情報記録装置は、TSからPSへの変換処理を行うストリーム変換装置1と、情報を記録する記録部2と、情報記録装置全体の動作を制御する制御部3とを有している。記録部2は、磁気ディスクに対する情報の書き込み及び読み取りを行うハードディスクドライブ、DVDなどの光ディスクに対する情報の書き込み及び読み取りを行う光ディスク装置、又は半導体メモリに対する情報の書き込み及び読み取りを行う半導体記憶装置などから構成される。   FIG. 4 is a block diagram schematically showing the configuration of the information recording apparatus according to the embodiment of the present invention. As shown in FIG. 4, the information recording apparatus according to the embodiment controls the operation of the stream conversion apparatus 1 that performs conversion processing from TS to PS, the recording unit 2 that records information, and the entire information recording apparatus. And a control unit 3 for performing the above. The recording unit 2 includes a hard disk drive for writing and reading information on a magnetic disk, an optical disk device for writing and reading information on an optical disk such as a DVD, or a semiconductor memory device for writing and reading information on a semiconductor memory. Is done.

図5は、図4に示されるストリーム変換装置1の構成を概略的に示すブロック図である。図5に示されるように、本発明の実施の形態に係るストリーム変換装置1は、TSから各種情報を検出して分離する検出分離部11と、TSをPSに変換する処理を行うPS変換部12と、PSのシステムクロックリファレンス(SCR)を設定するSCR設定部13と、ストリーム変換装置全体の動作を制御する変換制御部14とを有している。検出分離部11は、バッファ11aを有し、主に、後述する図6に示されるステップS10〜S12の処理を行う。PS変換部12は、バッファ12aを有し、主に、後述する図6に示されるステップS13の処理を行う。SCR設定部13は、後述する図6に示されるステップS14の処理を行う。なお、バッファ11a、12aのそれぞれは、複数の記憶領域に分割されていてもよく、また、複数の異なるバッファメモリを含んでいてもよい。   FIG. 5 is a block diagram schematically showing the configuration of the stream conversion apparatus 1 shown in FIG. As shown in FIG. 5, the stream conversion apparatus 1 according to the embodiment of the present invention includes a detection / separation unit 11 that detects and separates various types of information from a TS, and a PS conversion unit that performs a process of converting a TS into a PS. 12, an SCR setting unit 13 for setting a PS system clock reference (SCR), and a conversion control unit 14 for controlling the operation of the entire stream conversion apparatus. The detection / separation unit 11 includes a buffer 11a, and mainly performs processing of steps S10 to S12 shown in FIG. The PS conversion unit 12 includes a buffer 12a, and mainly performs the process of step S13 shown in FIG. The SCR setting unit 13 performs a process of step S14 shown in FIG. Each of the buffers 11a and 12a may be divided into a plurality of storage areas, and may include a plurality of different buffer memories.

図6は、ストリーム変換装置1において実行されるTSからPSへの変換処理の全体の流れを示すフローチャートである。図6に示されるように、TSからPSへの変換処理においては、まず、TSからプログラムアソシエーションテーブル(Program Association Table:PAT)の取得(ステップS10)、及びプログラムマップテーブル(Program Map Table:PMT)の取得(ステップS11)を行なう。PAT及びPMTの情報は、後に、TSから映像のパケット及び音声のパケットを分離する際に必要となる。PAT及びPMTの取得後、一旦TS読取のファイルポインタを先頭に戻す(ステップS12)。そして、TSから映像のデータ及び音声のデータを抽出し、PSを生成する処理(ステップS13)に入る。ただし、この時点においては、PSのSCRには正しい値が設定されない。上記図3のデータ処理は、図6のステップS13の処理に相当する。最後に、PSのSCRを正しい値に書き換える(ステップS14)。SCRの書き換え方法としては、SCR設定部13内のバッファ上でPSのSCRの書き換え行ってから記録部2にPSを記録する方法と、SCR設定部13が記録部2に記録されたPSのSCRを書き換える方法とがある。   FIG. 6 is a flowchart showing an overall flow of TS-to-PS conversion processing executed in the stream conversion apparatus 1. As shown in FIG. 6, in the conversion process from TS to PS, first, acquisition of a program association table (Program Association Table: PAT) from TS (Step S10), and program map table (Program Map Table: PMT) Is acquired (step S11). The PAT and PMT information will be required later when separating video packets and audio packets from the TS. After obtaining the PAT and PMT, the TS read file pointer is once returned to the head (step S12). Then, video data and audio data are extracted from the TS, and the process of generating a PS (step S13) is entered. However, at this time, a correct value is not set in the SCR of the PS. The data processing in FIG. 3 corresponds to the processing in step S13 in FIG. Finally, the SCR of PS is rewritten to a correct value (step S14). As a SCR rewriting method, a PS SCR is rewritten on the buffer in the SCR setting unit 13 and then the PS is recorded in the recording unit 2, and a PS SCR recorded in the recording unit 2 by the SCR setting unit 13 There is a method to rewrite.

次に、図6のステップS10に示されるPAT取得処理を説明する。図7は、TSパケットとPATの関係を示す図である。図7に示されるように、PATは、パケット識別子(Packet Identifier:PID)が0であるTSパケットのTSペイロードに含まれている。PATは、TSパケットより大きいことがあり、この場合、複数のTSパケットに分離されて含まれている。PATの先頭を含むTSパケットにおいては、TSヘッダ内のペイロードユニット開始インジケータ(payload_unit_start_indicator)は1であり、TSペイロードの1byte目はポインタフィールド(pointer field)であり、TSペイロードの2byte目からPATのデータが始まる。PATの先頭を含まないTSパケットにおいては、TSヘッダ内のpayload_unit_start_indicatorは0であり、TSペイロードの先頭(1byte目)からPATのデータが始まる。PAT取得の際は、PIDが0であり、かつ、TSヘッダ内のpayload_unit_start_indicatorが1であるパケットを最初に取得する。その後は、PIDが0であるパケットを取得していくことにより、PAT全体を取得することができる。PAT全体の長さは、PATのセクション長(section_length)に3byteを加えた値、すなわち、(section_length+3)byteである。なお、section_lengthは、PATのデータ構造を示す後述の図10に示されている。   Next, the PAT acquisition process shown in step S10 of FIG. 6 will be described. FIG. 7 is a diagram illustrating a relationship between a TS packet and a PAT. As shown in FIG. 7, the PAT is included in the TS payload of a TS packet whose packet identifier (PID) is 0. The PAT may be larger than the TS packet. In this case, the PAT is separated into a plurality of TS packets. In the TS packet including the head of the PAT, the payload unit start indicator (payload_unit_start_indicator) in the TS header is 1, the 1st byte of the TS payload is a pointer field (pointer field), and the PAT data from the 2nd byte of the TS payload. Begins. In a TS packet that does not include the beginning of the PAT, payload_unit_start_indicator in the TS header is 0, and PAT data starts from the beginning (1st byte) of the TS payload. When acquiring the PAT, a packet having a PID of 0 and a payload_unit_start_indicator of 1 in the TS header is first acquired. Thereafter, the entire PAT can be acquired by acquiring packets whose PID is 0. The total length of the PAT is a value obtained by adding 3 bytes to the section length (section_length) of the PAT, that is, (section_length + 3) bytes. Note that section_length is shown in FIG. 10, which will be described later, showing the data structure of PAT.

図8は、図6のステップS10に示されるPAT取得処理を示すフローチャートである。また、図9は、図7に示されるTSヘッダ内のデータ構造を示す図であり、図10は、図7に示されるPATのデータ構造を示す図である。   FIG. 8 is a flowchart showing the PAT acquisition process shown in step S10 of FIG. 9 is a diagram showing a data structure in the TS header shown in FIG. 7, and FIG. 10 is a diagram showing a data structure of the PAT shown in FIG.

図8に示されるように、PAT取得処理においては、まず、TSからTSヘッダの読み取りを行ない(ステップS100)、読み取られたTSヘッダからpayload_unit_start_indicator及びPIDを取得する。読み取り後、TS読み取りのファイルポインタをTSペイロードの先頭に移動する。なお、TSヘッダの長さは、図9に示されるTSヘッダ内のアダプテーションフィールドコントロール(adaptation_field_control)及びアダプテーションフィールド長(adaptation_field_length)から判断することができる。adaptation_field_controlが1である場合、アダプテーションフィールド(adaptation_field)は存在せず、TSヘッダは4byteとなる。adaptation_field_controlが2である場合、TSペイロードは存在せず、TSヘッダは188byteとなる。adaptation_field_controlが3である場合、TSヘッダの長さは(4+adaptation_field_length)byteとなる。   As shown in FIG. 8, in the PAT acquisition process, first, the TS header is read from the TS (step S100), and payload_unit_start_indicator and PID are acquired from the read TS header. After reading, the TS reading file pointer is moved to the head of the TS payload. The length of the TS header can be determined from the adaptation field control (adaptation_field_control) and the adaptation field length (adaptation_field_length) in the TS header shown in FIG. When adaptation_field_control is 1, there is no adaptation field (adaptation_field), and the TS header is 4 bytes. When adaptation_field_control is 2, there is no TS payload and the TS header is 188 bytes. When adaptation_field_control is 3, the length of the TS header is (4 + adaptation_field_length) bytes.

図8に示されるように、TSヘッダ読込後、PIDが0であるTSパケットからPATを取得する(ステップS101)。TSヘッダ内のpayload_unit_start_indicatorが1である場合(ステップS102)、PAT内のsection_lengthを取得してから(ステップS103)、TSペイロード内のPATのデータをバッファに読み出す(ステップS105)。TSヘッダ内のpayload_unit_start_indicatorが0である場合(ステップS102)、PATの先頭を既に取得しているときのみ(ステップS104)、バッファへの読み出し(ステップS105)を行なう。バッファのデータ量が(section_length+3)byteになったときに読み出しを終了する(ステップS106)。なお、ここで用いられるバッファは、図5のブロック図に示されるバッファ11aに含まれる。   As shown in FIG. 8, after reading the TS header, the PAT is acquired from the TS packet whose PID is 0 (step S101). When the payload_unit_start_indicator in the TS header is 1 (step S102), the section_length in the PAT is acquired (step S103), and the PAT data in the TS payload is read into the buffer (step S105). When payload_unit_start_indicator in the TS header is 0 (step S102), reading into the buffer (step S105) is performed only when the head of the PAT has already been acquired (step S104). When the data amount in the buffer reaches (section_length + 3) bytes, the reading is terminated (step S106). The buffer used here is included in the buffer 11a shown in the block diagram of FIG.

PAT全体をバッファに読み出した後に、PATからPMTのPIDを取得する(ステップS107)。PMTのPIDは、図10に示されるPATのデータ構造の中の繰り返しの部分に存在する。ただし、PAT内のプログラム番号(program_number)が0である組のPMTのPIDは無視する。なお、PMTのPIDは、複数存在することがある。PAT取得後、PMT取得処理に入る。   After reading the entire PAT into the buffer, the PMT PID is obtained from the PAT (step S107). The PID of the PMT exists in a repetitive portion in the data structure of the PAT shown in FIG. However, the PID of a set of PMTs whose program number (program_number) in the PAT is 0 is ignored. There may be a plurality of PMT PIDs. After PAT acquisition, the PMT acquisition process is entered.

次に、図6のステップS11に示されるPMT取得処理を説明する。図11は、図6のステップS11に示されるPAT取得処理を詳細に示すフローチャートである。また、図12は、PMTのデータ構造を示す図である。   Next, the PMT acquisition process shown in step S11 of FIG. 6 will be described. FIG. 11 is a flowchart showing in detail the PAT acquisition process shown in step S11 of FIG. FIG. 12 shows the data structure of the PMT.

PMTは、PATと同様に、複数のTSパケットに分割されてTSパケットに含まれていることがある。図11のフローチャートは説明をわかりやすくするために、PMTのPIDが1つである場合の処理を示している。PMTのPIDが複数存在する場合は、同様の処理が並行して行なわれる。   Like the PAT, the PMT may be divided into a plurality of TS packets and included in the TS packet. The flowchart of FIG. 11 shows the process when the PMT has one PID for easy understanding. When there are a plurality of PMT PIDs, the same processing is performed in parallel.

図11に示されるように、PMT取得処理においては、まず、TSからTSヘッダを読み取る(ステップS110)。TSヘッダを読み取る処理は、図8のステップS100に示されるPAT取得の場合における処理と同様である。TSヘッダ読込後、PIDの値からPMTのパケットを識別する。TSヘッダ内のpayload_unit_start_indicatorが1である場合、PMTからsection_lengthを取得してから(ステップS112、S113)、TSペイロードのPMTのデータをバッファに読み出す(ステップS114、S115)。TSヘッダ内のpayload_unit_start_indicatorが0である場合、PMTの先頭を既に取得しているときのみ、バッファへの読み出し(ステップS112、S114、S115)を行なう。バッファのデータ量が(section_length+3)byteになったときに、読み出しを終了する(ステップS116)。図12に示されるように、PMT全体の長さは、セクション長(section_length)に3byteを加えた値、すなわち、(section_length+3)byteである。なお、ここで用いられるバッファは、図5のブロック図に示されるバッファ11aに含まれる。   As shown in FIG. 11, in the PMT acquisition process, first, the TS header is read from the TS (step S110). The process of reading the TS header is the same as the process in the case of PAT acquisition shown in step S100 of FIG. After reading the TS header, the PMT packet is identified from the PID value. When payload_unit_start_indicator in the TS header is 1, after obtaining section_length from the PMT (steps S112 and S113), the PMT data of the TS payload is read out to the buffer (steps S114 and S115). When payload_unit_start_indicator in the TS header is 0, reading to the buffer is performed only when the head of the PMT has already been acquired (steps S112, S114, and S115). When the data amount in the buffer reaches (section_length + 3) bytes, the reading is terminated (step S116). As shown in FIG. 12, the total length of the PMT is a value obtained by adding 3 bytes to the section length (section_length), that is, (section_length + 3) bytes. The buffer used here is included in the buffer 11a shown in the block diagram of FIG.

PMT全体をバッファに読み出した後に、PMTから映像のPID及び音声のPIDを取得する(ステップS117)。図12に示されるPMTのデータ構造の中の繰り返し部分のストリーム識別子(stream_id)が‘0x2’であるときのエレメンタリーPID(elementary_PID)が映像のPIDであり、stream_idが‘0x3’又は‘0xf’であるときのelementary_PIDが音声のPIDである。なお、‘0x’は16進数表記を意味し、‘0x・’は「・」が16進数であることを意味する。   After reading the entire PMT into the buffer, the video PID and audio PID are acquired from the PMT (step S117). The elementary PID (elementary_PID) when the stream identifier (stream_id) of the repeated portion in the data structure of the PMT shown in FIG. 12 is “0x2” is the video PID, and the stream_id is “0x3” or “0xf”. The elementary_PID is the voice PID. Note that '0x' means hexadecimal notation, and '0x ·' means that '·' is a hexadecimal number.

次に、図6のステップS13に示されるTSからPSへの変換処理を説明する。図13は、図6のステップS13における映像及び音声のTSパケットを抽出してPSを生成する処理を示すフローチャートである。図13は説明をわかりやすくするために番組が1つである場合(すなわち、映像及び音声のそれぞれが1つずつである場合)を示している。なお、番組が複数存在する場合は同様の処理を並行して行なう。また、図14は、PSのパックヘッダのデータ構造を示す図であり、図15は、PSのシステムヘッダのデータ構造を示す図であり、図16は、PESパケット(パディングストリーム:padding stream)のデータ構造を示す図である。   Next, the conversion process from TS to PS shown in step S13 of FIG. 6 will be described. FIG. 13 is a flowchart showing the process of generating the PS by extracting the video and audio TS packets in step S13 of FIG. FIG. 13 shows a case where there is one program (that is, a case where there is one each of video and audio) in order to make the explanation easy to understand. If there are a plurality of programs, the same processing is performed in parallel. FIG. 14 is a diagram illustrating the data structure of the PS pack header, FIG. 15 is a diagram illustrating the data structure of the PS system header, and FIG. 16 is a diagram of the PES packet (padding stream: padding stream). It is a figure which shows a data structure.

図13に示されるように、図6のステップS13の処理においては、まず、PSの最初のPSパックを生成する(ステップS120)。ここでは、PSパックの全長は2048byteとする。PSパックは、図14に示されるデータ構造を持つパックヘッダ、図15に示されるデータ構造を持つシステムヘッダ、及び図16に示されるデータ構造を持つPESパケット(padding_stream)より構成される。   As shown in FIG. 13, in the process of step S13 of FIG. 6, first, the first PS pack of PS is generated (step S120). Here, the total length of the PS pack is 2048 bytes. The PS pack is composed of a pack header having the data structure shown in FIG. 14, a system header having the data structure shown in FIG. 15, and a PES packet (padding_stream) having the data structure shown in FIG.

図14に示されるように、PSのパックヘッダは、パックスタッフィングバイト(pack_stuffing_byte)を0byteとすることによって、その全長を14byteとする。図15に示されるように、PSのシステムヘッダは、繰り返し部分を2回とすることによって、その全長を18byteとする。図16に示されるように、PSのPESパケット(padding stream)は、PESペイロードの部分を2010byteの‘0xFF’で埋めることによって、その全長を2016byteとする。また、図14に示されるパックヘッダのパラメータは、図17に示す値に設定し、図15に示されるシステムヘッダのパラメータは、図18に示す値に設定し、図16に示されるPESヘッダ(padding stream)のパラメータは、図19に示す値に設定する。   As shown in FIG. 14, the PS pack header has a total length of 14 bytes by setting the pack stuffing byte (pack_stuffing_byte) to 0 bytes. As shown in FIG. 15, the PS system header has a total length of 18 bytes by setting the repeated portion twice. As shown in FIG. 16, the PES packet (padding stream) of PS is set to 2016 bytes by filling the PES payload part with “0xFF” of 2010 bytes. Further, the pack header parameter shown in FIG. 14 is set to the value shown in FIG. 17, the system header parameter shown in FIG. 15 is set to the value shown in FIG. 18, and the PES header ( The parameter of (padding stream) is set to the value shown in FIG.

図13に示されるように、最初のPSパック生成後、映像のパケットでかつフレームの先頭を含むパケットを探す(ステップS122)。検索された映像のパケットでかつフレームの先頭を含むパケット以前のパケットは、破棄する。フレームの先頭を含むか否かの判断は、TSヘッダ内のpayload_unit_start_indicatorが1であるか否かを調べることにより行なう。   As shown in FIG. 13, after the first PS pack is generated, a packet that is a video packet and includes the head of the frame is searched (step S122). The retrieved video packet and the packet before the packet including the head of the frame are discarded. Whether or not the head of the frame is included is determined by checking whether or not payload_unit_start_indicator is 1 in the TS header.

図13に示されるように、映像のフレームでかつフレームの先頭を含むパケットを見つけた後、TSパケットの種類を分類する。映像のパケットが来た場合は映像のパケットの処理に移行し(ステップS125)、音声のパケットが来た場合は音声のパケットの処理に移行し(ステップS126)、それ以外のパケットが来た場合はそのパケットを破棄する。   As shown in FIG. 13, after finding a packet that is a video frame and includes the head of the frame, the type of TS packet is classified. When a video packet has arrived, the process proceeds to video packet processing (step S125). When an audio packet has arrived, the process proceeds to audio packet processing (step S126), and any other packet has arrived. Discards the packet.

次に、映像のTSパケット又は音声のTSパケットが来た場合の処理(ステップS125、S126)の詳細について説明する。映像データ及び音声データはPESパケットの形式で保存されている。図20は、PESパケットのデータ構造を示す図である。映像のデータ及び音声のデータは、PESパケット内のPESペイロードに含まれている。また、図21は、TSを構成するTSパケットと、TSから生成されたPESパケットとの関係を示す図であり、図22は、TSから生成されたPESパケットと、PSとの関係を示す図である。   Next, details of processing (steps S125 and S126) when a video TS packet or an audio TS packet comes will be described. Video data and audio data are stored in a PES packet format. FIG. 20 is a diagram illustrating a data structure of a PES packet. Video data and audio data are included in the PES payload in the PES packet. FIG. 21 is a diagram showing the relationship between TS packets constituting the TS and the PES packet generated from the TS, and FIG. 22 is a diagram showing the relationship between the PES packet generated from the TS and the PS. It is.

図21に示されるように、一般に、PESパケットはTSパケットよりも大きいため、PESパケットのデータは、複数のTSパケットに分割されて含まれている。また、TSにおいて映像のPESパケットには、1フレーム分のデータが含まれている。一方、図22に示されるように、PSには、1つのPSパックに1つのPESパケットが含まれている。そのため、TSからPSへの変換の際は、図22に示されるように、TSのPESパケットのPESペイロードをPSのPSパックの大きさに合わせて分割する必要がある。   As shown in FIG. 21, since the PES packet is generally larger than the TS packet, the data of the PES packet is divided into a plurality of TS packets and included. In addition, the video PES packet in the TS includes data for one frame. On the other hand, as shown in FIG. 22, one PS pack contains one PES packet in one PS pack. Therefore, at the time of conversion from TS to PS, as shown in FIG. 22, it is necessary to divide the PES payload of the TS PES packet according to the size of the PS PS pack.

図23は、図13のステップS125に示される映像のTSパケットの処理を詳細に示すフローチャートである。図23に示されるように、図13における映像パケットの処理においては、まず、TSヘッダ内のpayload_unit_start_indicatorが1であるか否かで調べることで、TSパケットにPESヘッダが含まれているか否かを判定する(ステップS1000)。図23及び図21に示されるように、TSヘッダ内のpayload_unit_start_indicatorが1である場合、PESヘッダの読み取り(ステップS1001)、フレーム数のカウンタの増分(ステップS1002)を行ってから、PESペイロードのデータを映像用のバッファに読み出す(ステップS1003)。なお、フレーム数カウンタは、後にSCRを正しい値に設定する際に用いる。図23及び図21に示されるように、TSヘッダ内のpayload_unit_start_indicatorが0である場合、PESペイロードの読み取り(ステップS1003)のみを行なう。   FIG. 23 is a flowchart showing in detail the processing of the video TS packet shown in step S125 of FIG. As shown in FIG. 23, in the processing of the video packet in FIG. 13, first, it is checked whether or not the payload_unit_start_indicator is 1 in the TS header to determine whether or not the TS packet includes the PES header. Determination is made (step S1000). As shown in FIG. 23 and FIG. 21, when payload_unit_start_indicator is 1 in the TS header, the PES header data is read after reading the PES header (step S1001) and incrementing the frame number counter (step S1002). Are read out to the video buffer (step S1003). The frame number counter is used when the SCR is set to a correct value later. As shown in FIGS. 23 and 21, when the payload_unit_start_indicator in the TS header is 0, only the PES payload is read (step S1003).

図23及び図22に示されるように、PESペイロード読取(ステップS1003)の後、バッファのデータ量が2048byteを超えている場合に、PSのPSパックをPSのファイルへ出力する(ステップS1005)。出力するPSパックは、パックヘッダとPESパケットより構成し(又は、パックヘッダとシステムヘッダとPESパケットより構成し)、pack長が2048byteになるように、PESペイロードの長さを調整する。   As shown in FIGS. 23 and 22, after the PES payload reading (step S1003), if the buffer data amount exceeds 2048 bytes, the PS PS pack is output to the PS file (step S1005). The PS pack to be output is composed of a pack header and a PES packet (or composed of a pack header, a system header and a PES packet), and the length of the PES payload is adjusted so that the pack length is 2048 bytes.

図23に示されるように、PSパック出力後、PESヘッダのデータから、プレゼンテーションタイムスタンプ(Presentation Time Stamp:PTS)及びデコードタイムスタンプ(Decode Time Stamp:DTS)のデータを除去する(ステップS1006)。   As shown in FIG. 23, after the PS pack is output, the presentation time stamp (PTS) data and the decoding time stamp (DTS) data are removed from the data of the PES header (step S1006).

図24は、図13のステップS126に示される音声のTSパケットの処理を詳細に示すフローチャートである。図24に示されるように、図13に示される音声パケットの処理が、映像パケットの処理(図23)と異なる点は、フレーム数カウンタの処理(図23のステップS1003)がないことである。この点を除き、図24に示される処理は、図23に示される処理と同じである。   FIG. 24 is a flowchart showing in detail the processing of the audio TS packet shown in step S126 of FIG. As shown in FIG. 24, the audio packet processing shown in FIG. 13 is different from the video packet processing (FIG. 23) in that there is no frame number counter processing (step S1003 in FIG. 23). Except for this point, the process shown in FIG. 24 is the same as the process shown in FIG.

図25は、図6のステップS14に示されるPSのSCRを書き換える処理を詳細に示すフローチャートである。図25に示されるように、SCRの書換(ステップS132)においては、SCRの値SCRは、SCRベース(SCR_base)の最後のbyteの到着予定時間を表す。SCR_baseは、PSのパックヘッダのデータ構造に関する図14に示されている。PSファイルの再生時間をTとし、PSファイルのbyte数をLとし、Rをある正の整数としたときに、ストリームのRbyte目のデータの到着予定時間tは次式により求めることができる。

Figure 2007189587
FIG. 25 is a flowchart showing in detail the process of rewriting the SCR of the PS shown in step S14 of FIG. As shown in FIG. 25, in the SCR rewriting (step S132), the SCR value SCR p represents the estimated arrival time of the last byte of the SCR base (SCR_base). SCR_base is shown in FIG. 14 regarding the data structure of the PS pack header. When the PS file playback time is T, the number of PS file bytes is L, and R is a positive integer, the estimated arrival time t of the R-byte data of the stream can be obtained by the following equation.
Figure 2007189587

PSファイルの再生時間Tは、PSファイルのフレーム数Fから求めることができる。NTSC方式の映像のフレームレートは、30000/1001(≒29.97)Hzであるので、ストリームの再生時間Tはフレーム数Fを用いて次式により表すことができる。

Figure 2007189587
The reproduction time T of the PS file can be obtained from the number of frames F of the PS file. Since the frame rate of NTSC video is 30000/1001 (≈29.97) Hz, the playback time T of the stream can be expressed by the following equation using the number of frames F.
Figure 2007189587

MPEG2のpackの総数Pの中のp番目のパックヘッダのSCR_baseの最終バイトは、(2048×p+9)byte目となる。よって、p番目のパックヘッダのSCR_baseの到達予定時間tは次式により求めることができる。

Figure 2007189587
The last byte of the SCR_base of the p-th pack header in the total number P of MPEG2 packs is the (2048 × p + 9) byte. Thus, estimated arrival time t p of SCR_base the p-th pack header can be obtained by the following equation.
Figure 2007189587

SCRの値27000000は1秒に相当するので、p番目のパックヘッダのSCRの値SCRは次式により求めることができる。

Figure 2007189587
Since the SCR value 27000000 corresponds to 1 second, the SCR value SCR p of the p-th pack header can be obtained by the following equation.
Figure 2007189587

本実施の形態においては、SCRの値SCRの書換は上記の式により行なう。 In the present embodiment, the SCR value SCR p is rewritten by the above equation.

以上に説明したように、本実施の形態によれば、PSへの変換が容易になるように形式が整えられたTSでなくても、PSへ変換することができる。また、クロック発生装置なしであっても、SCRの値を適切に設定できる。   As described above, according to the present embodiment, even if it is not a TS whose format is arranged so that conversion to PS is easy, it can be converted into PS. Even without a clock generator, the SCR value can be set appropriately.

TSのデータ構造を示す図である。It is a figure which shows the data structure of TS. PSのデータ構造を示す図である。It is a figure which shows the data structure of PS. TSからPSへの変換におけるデータ処理の流れを示す図である。It is a figure which shows the flow of the data processing in conversion from TS to PS. 本発明の実施の形態に係る情報記録装置の構成を概略的に示すブロック図である。1 is a block diagram schematically showing a configuration of an information recording apparatus according to an embodiment of the present invention. 図4に示されるストリーム変換装置の構成を概略的に示すブロック図である。FIG. 5 is a block diagram schematically showing the configuration of the stream conversion apparatus shown in FIG. 4. 本発明の実施の形態に係るストリーム変換装置において実行されるTSからPSへの変換処理の全体の流れを示すフローチャートである。It is a flowchart which shows the whole flow of the conversion process from TS to PS performed in the stream converter which concerns on embodiment of this invention. TSパケットとPATの関係を示す図である。It is a figure which shows the relationship between TS packet and PAT. 図6のステップS10に示されるPAT取得処理を詳細に示すフローチャートである。It is a flowchart which shows the PAT acquisition process shown by step S10 of FIG. 6 in detail. TSヘッダのデータ構造を示す図である。It is a figure which shows the data structure of TS header. PATのデータ構造を示す図である。It is a figure which shows the data structure of PAT. 図6のステップS11に示されるPMT取得処理を詳細に示すフローチャートである。It is a flowchart which shows in detail the PMT acquisition process shown by step S11 of FIG. PMTのデータ構造を示す図である。It is a figure which shows the data structure of PMT. 図6のステップS13に示されるTSパケットを抽出してPSを生成する処理を詳細に示すフローチャートである。It is a flowchart which shows in detail the process which extracts TS packet shown by step S13 of FIG. 6, and produces | generates PS. PSのパックヘッダのデータ構造を示す図である。It is a figure which shows the data structure of the pack header of PS. PSのシステムヘッダのデータ構造を示す図である。It is a figure which shows the data structure of the system header of PS. PESパケットのデータ構造を示す図である。It is a figure which shows the data structure of a PES packet. PSの最初のPSパックにおける、パックヘッダのパラメータの値を示す図である。It is a figure which shows the value of the parameter of a pack header in the first PS pack of PS. PSの最初のPSパックにおける、システムヘッダのパラメータの値を示す図である。It is a figure which shows the value of the parameter of a system header in the first PS pack of PS. PSの最初のPSパックにおける、PESヘッダ(padding stream)のパラメータの値を示す図である。It is a figure which shows the value of the parameter of the PES header (padding stream) in the first PS pack of PS. PESパケットのデータ構造を示す図である。It is a figure which shows the data structure of a PES packet. TSパケットとPESパケットとの関係を示す図である。It is a figure which shows the relationship between a TS packet and a PES packet. TSから生成されたPESパケットとPSとの関係を示す図である。It is a figure which shows the relationship between the PES packet produced | generated from TS and PS. 図13のステップS125に示される映像のTSパケットの処理を詳細に示すフローチャートである。14 is a flowchart showing in detail processing of a video TS packet shown in step S125 of FIG. 図13のステップS126に示される音声のTSパケットの処理を詳細に示すフローチャートである。14 is a flowchart showing in detail the processing of the audio TS packet shown in step S126 of FIG. 図6のステップS14に示されるPSのSCRを書き換える処理を詳細に示すフローチャートである。It is a flowchart which shows in detail the process which rewrites SCR of PS shown by FIG.6 S14.

符号の説明Explanation of symbols

1 ストリーム変換装置、 2 記録部、 3 制御部、 11 検出分離部、 11a バッファ、 12 PS変換部、 12a バッファ、 13 SCR設定部。
DESCRIPTION OF SYMBOLS 1 Stream converter, 2 Recording part, 3 Control part, 11 Detection separation part, 11a buffer, 12 PS conversion part, 12a buffer, 13 SCR setting part

Claims (12)

映像音声のデジタルデータストリームであるTSを映像音声のデジタルデータストリームであるPSに変換するストリーム変換装置であって、
入力されたTSに含まれるTSヘッダを解析し、前記入力されたTSから映像データ及び音声データを含むTSパケットを検出して分離する検出分離部と、
バッファ手段と、
前記検出分離部で分離されたTSパケットのTSペイロードからTSのPESパケットを生成して前記バッファ手段に書き込み、前記バッファ手段に格納されたデータ量が所定値以上になったときに、前記TSのPESパケットに含まれるPESペイロードを前記バッファ手段から読み出し、この読み出された前記PESペイロードにヘッダを付加してPSパックを生成するPS変換部と
を有することを特徴とするストリーム変換装置。
A stream converter for converting a TS which is a video / audio digital data stream into a PS which is a video / audio digital data stream,
A detection separation unit that analyzes a TS header included in the input TS and detects and separates TS packets including video data and audio data from the input TS; and
Buffer means;
A TS PES packet is generated from the TS payload of the TS packet separated by the detection separation unit, written to the buffer means, and when the amount of data stored in the buffer means exceeds a predetermined value, A stream conversion apparatus comprising: a PS conversion unit that reads a PES payload included in a PES packet from the buffer unit and adds a header to the read PES payload to generate a PS pack.
前記PS変換部で生成されるPSパックから構成されるPSファイルのサイズと前記PSファイルに含まれる映像データのフレーム数とに基づいてシステムクロックリファレンスの値を計算し、前記PSファイルのシステムクロックリファレンスを、前記計算によって取得された前記値に設定するSCR設定部を有することを特徴とする請求項1に記載のストリーム変換装置。   A system clock reference value is calculated based on the size of a PS file composed of PS packs generated by the PS conversion unit and the number of frames of video data included in the PS file, and the system clock reference of the PS file is calculated. The stream conversion apparatus according to claim 1, further comprising: an SCR setting unit that sets the value to the value acquired by the calculation. 前記SCR設定部は、p番目(pは正の整数)のPSファイルのパックヘッダのシステムクロックリファレンスの値をSCRとし、PSファイルのフレーム数をFとし、PSファイルのバイト数をLとしたとき、下記の式
SCR={900900F×(2048×p+9)}/L
に基づいて前記システムクロックリファレンスを計算することを特徴とする請求項2に記載のストリーム変換装置。
The SCR setting unit sets the system clock reference value of the pack header of the p-th PS file (p is a positive integer) as SCR p , F as the number of frames in the PS file, and L as the number of bytes in the PS file. Then, the following formula SCR P = {900900F × (2048 × p + 9)} / L
The stream conversion apparatus according to claim 2, wherein the system clock reference is calculated based on the stream conversion time.
前記バッファ手段は、前記PS変換部の一部であることを特徴とする請求項1乃至3のいずれかに記載のストリーム変換装置。   4. The stream conversion apparatus according to claim 1, wherein the buffer means is a part of the PS conversion unit. 前記バッファ手段は、複数の記憶領域を有し、
前記PS変換部による前記バッファ手段への書き込みは、前記TSのTSペイロードに含まれるPESヘッダとPESペイロードを、前記バッファ手段の異なる前記記憶領域のそれぞれに書き込む処理であることを特徴とする請求項1乃至4のいずれかに記載のストリーム変換装置。
The buffer means has a plurality of storage areas,
The writing to the buffer unit by the PS conversion unit is a process of writing a PES header and a PES payload included in a TS payload of the TS to each of the different storage areas of the buffer unit. The stream converter according to any one of 1 to 4.
前記PS変換部は、前記TSパケット内にPESヘッダが無い場合に、プレゼンテーションタイムスタンプ及びデコードタイムスタンプを含まないPESヘッダを生成することを特徴とする請求項1乃至5のいずれかに記載のストリーム変換装置。   The stream according to any one of claims 1 to 5, wherein the PS conversion unit generates a PES header that does not include a presentation time stamp and a decoding time stamp when there is no PES header in the TS packet. Conversion device. 前記PS変換部は、PESヘッダを含むTSパケットのPESヘッダをコピーし、このコピーされたPESヘッダからプレゼンテーションタイムスタンプ及びデコードタイムスタンプを取り除くことにより、プレゼンテーションタイムスタンプ及びデコードタイムスタンプを含まないPESヘッダを生成することを特徴とする請求項1乃至6のいずれかに記載のストリーム変換装置。   The PS conversion unit copies the PES header of the TS packet including the PES header, and removes the presentation time stamp and the decoding time stamp from the copied PES header, thereby not including the presentation time stamp and the decoding time stamp. The stream conversion apparatus according to claim 1, wherein the stream conversion apparatus generates a stream. 前記PS変換部は、前記PESペイロードに付加される前記ヘッダと前記PESペイロードとのデータ量の合計が一定量となるようにすることを特徴とする請求項1乃至7のいずれかに記載のストリーム変換装置。   The stream according to any one of claims 1 to 7, wherein the PS conversion unit makes a total amount of data of the header and the PES payload added to the PES payload be a constant amount. Conversion device. 前記PS変換部が生成するPSパックは、映像のPSのPSパックと音声のPSのPSパックを同一のPSファイルに出力することを特徴とする請求項1乃至8のいずれかに記載のストリーム変換装置。   9. The stream conversion according to claim 1, wherein the PS pack generated by the PS conversion unit outputs the PS pack of video PS and the PS pack of audio PS to the same PS file. apparatus. 前記バッファ手段は、複数の記憶領域を有し、
前記PS変換部は、TSに含まれる番組の数に応じた数の前記記憶領域を用いる
ことを特徴とする請求項1乃至9のいずれかに記載のストリーム変換装置。
The buffer means has a plurality of storage areas,
The stream conversion apparatus according to claim 1, wherein the PS conversion unit uses a number of the storage areas corresponding to the number of programs included in the TS.
請求項1乃至10のいずれかに記載のストリーム変換装置と、
前記ストリーム変換装置から出力されるPSファイルを格納する記録部と、
前記ストリーム変換装置から出力されるPSファイルを前記記録部に格納する動作を制御する制御部と
を有することを特徴とする情報記録装置。
A stream converter according to any one of claims 1 to 10,
A recording unit for storing a PS file output from the stream converter;
An information recording apparatus comprising: a control unit that controls an operation of storing the PS file output from the stream conversion apparatus in the recording unit.
映像音声のデジタルデータストリームであるTSを映像音声のデジタルデータストリームであるPSに変換するストリーム変換方法であって、
入力されたTSに含まれるTSヘッダを解析し、前記入力されたTSから映像データ及び音声データを含むTSパケットを検出して分離し、
前記分離されたTSパケットのTSペイロードからTSのPESパケットを生成してバッファ手段に書き込み、
前記バッファ手段に格納されたデータ量が所定値以上になったときに、前記TSのPESパケットに含まれるPESペイロードを前記バッファ手段から読み出し、
この読み出された前記PESペイロードにヘッダを付加してPSパックを生成する
ことを特徴とするストリーム変換方法。
A stream conversion method for converting a TS which is a video / audio digital data stream into a PS which is a video / audio digital data stream,
Analyzing the TS header included in the input TS, detecting and separating TS packets including video data and audio data from the input TS,
A TS PES packet is generated from the TS payload of the separated TS packet and written to the buffer means,
When the amount of data stored in the buffer means exceeds a predetermined value, the PES payload included in the PES packet of the TS is read from the buffer means,
A stream conversion method, wherein a PS pack is generated by adding a header to the read PES payload.
JP2006007219A 2006-01-16 2006-01-16 Stream conversion apparatus, information recording apparatus, and stream conversion method Expired - Fee Related JP4675784B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2006007219A JP4675784B2 (en) 2006-01-16 2006-01-16 Stream conversion apparatus, information recording apparatus, and stream conversion method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2006007219A JP4675784B2 (en) 2006-01-16 2006-01-16 Stream conversion apparatus, information recording apparatus, and stream conversion method

Publications (3)

Publication Number Publication Date
JP2007189587A true JP2007189587A (en) 2007-07-26
JP2007189587A5 JP2007189587A5 (en) 2008-06-19
JP4675784B2 JP4675784B2 (en) 2011-04-27

Family

ID=38344440

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2006007219A Expired - Fee Related JP4675784B2 (en) 2006-01-16 2006-01-16 Stream conversion apparatus, information recording apparatus, and stream conversion method

Country Status (1)

Country Link
JP (1) JP4675784B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103596043A (en) * 2013-11-14 2014-02-19 上海电力学院 Method for converting TS into PS in digital television

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000092448A (en) * 1998-09-16 2000-03-31 Pioneer Electronic Corp Device and method for recording information
JP2004222307A (en) * 2004-02-06 2004-08-05 Matsushita Electric Ind Co Ltd Digital signal receiving apparatus, digital signal processing apparatus and program recording medium
JP2005512386A (en) * 2001-11-29 2005-04-28 トムソン ライセンシング ソシエテ アノニム Transport stream for program stream conversion

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2000092448A (en) * 1998-09-16 2000-03-31 Pioneer Electronic Corp Device and method for recording information
JP2005512386A (en) * 2001-11-29 2005-04-28 トムソン ライセンシング ソシエテ アノニム Transport stream for program stream conversion
JP2004222307A (en) * 2004-02-06 2004-08-05 Matsushita Electric Ind Co Ltd Digital signal receiving apparatus, digital signal processing apparatus and program recording medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103596043A (en) * 2013-11-14 2014-02-19 上海电力学院 Method for converting TS into PS in digital television
CN103596043B (en) * 2013-11-14 2017-05-10 上海电力学院 Method for converting TS into PS in digital television

Also Published As

Publication number Publication date
JP4675784B2 (en) 2011-04-27

Similar Documents

Publication Publication Date Title
EP1780713B1 (en) Information recording medium, data sorting device, and data reproduction device
EP1780711B1 (en) Information recording medium, data sorting device, and data reproducing device
JP3887006B2 (en) Additional information generation method for ensuring continuous reproduction between data strings, recording medium and recording, editing and / or reproducing apparatus for storing this information
JP3900050B2 (en) Data processing apparatus, video camera, and data processing method
EP1797563B1 (en) Information storage medium, ts packet judgment apparatus, and data reproduction apparatus
JPWO2006033279A1 (en) Data processing device
US8824864B2 (en) Data processor
US11238897B2 (en) Method of playing system stream files with different recording formats
JPWO2004084553A1 (en) Data processing device
CN111276170B (en) Decoding system and decoding method
EP3208803B1 (en) Reproduction method and reproduction device
JP4675784B2 (en) Stream conversion apparatus, information recording apparatus, and stream conversion method
US20050117888A1 (en) Video and audio reproduction apparatus
JP4464101B2 (en) Transport stream editing method and apparatus
JP4566745B2 (en) Data processing device
JP4616144B2 (en) Data processing device
US20080124051A1 (en) Method and system for fast format transformation
WO2006101053A1 (en) Recording device, reproducing device, recording medium, recording method, and lsi
JPWO2006075457A1 (en) Recording device
KR100376578B1 (en) Method for recoding digital data stream and providing presentation control information therefor
JP4823911B2 (en) Multiplexing device, information recording medium, decoding device, multiplexing method, decoding method, and program
JP3892759B2 (en) Recording / reproducing apparatus, recording apparatus, reproducing apparatus, and recording / reproducing method
JP2007066511A (en) Recording and reproducing apparatus, recording apparatus, reproducing apparatus, and recording and reproducing method
JP3889338B2 (en) DATA RECORDING METHOD, DATA RECORDING DEVICE, DATA CONVERSION METHOD, DATA CONVERSION DEVICE, DATA RECORDING MEDIUM, DATA RECORDING PROGRAM, AND RECORDING MEDIUM CONTAINING THE PROGRAM
JP5762100B2 (en) Digital stream signal transfer apparatus, digital stream signal reception apparatus, digital stream signal transfer method, and digital stream signal reception method

Legal Events

Date Code Title Description
A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080430

A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20080430

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20110120

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20110125

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20110126

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20140204

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

LAPS Cancellation because of no payment of annual fees