JP4190384B2 - Video camera - Google Patents
Video camera Download PDFInfo
- Publication number
- JP4190384B2 JP4190384B2 JP2003349524A JP2003349524A JP4190384B2 JP 4190384 B2 JP4190384 B2 JP 4190384B2 JP 2003349524 A JP2003349524 A JP 2003349524A JP 2003349524 A JP2003349524 A JP 2003349524A JP 4190384 B2 JP4190384 B2 JP 4190384B2
- Authority
- JP
- Japan
- Prior art keywords
- image
- audio
- image signal
- video camera
- frame
- 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.)
- Expired - Fee Related
Links
- 238000000034 method Methods 0.000 claims description 27
- 230000005236 sound signal Effects 0.000 claims description 25
- 238000001514 detection method Methods 0.000 claims description 19
- 230000004044 response Effects 0.000 claims description 6
- 230000000295 complement effect Effects 0.000 claims description 3
- 230000003247 decreasing effect Effects 0.000 claims description 3
- 238000007906 compression Methods 0.000 description 34
- 230000006835 compression Effects 0.000 description 34
- 238000012545 processing Methods 0.000 description 22
- 230000006837 decompression Effects 0.000 description 19
- 230000001360 synchronised effect Effects 0.000 description 18
- 239000002131 composite material Substances 0.000 description 3
- 238000006243 chemical reaction Methods 0.000 description 2
- 238000013144 data compression Methods 0.000 description 2
- 230000003287 optical effect Effects 0.000 description 2
- 230000000750 progressive effect Effects 0.000 description 2
- 238000005070 sampling Methods 0.000 description 2
- 238000004364 calculation method Methods 0.000 description 1
- 238000012790 confirmation Methods 0.000 description 1
- 238000007796 conventional method Methods 0.000 description 1
- 238000012937 correction Methods 0.000 description 1
- 230000037433 frameshift Effects 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 239000000203 mixture Substances 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
- 230000008929 regeneration Effects 0.000 description 1
- 238000011069 regeneration method Methods 0.000 description 1
- 238000000926 separation method Methods 0.000 description 1
Images
Landscapes
- Television Signal Processing For Recording (AREA)
- Studio Devices (AREA)
Description
この発明は、ビデオカメラに関し、特にたとえば、画像データおよび音声データを記録再生する、ビデオカメラに関する。 The present invention relates to a video camera, and more particularly to a video camera that records and reproduces image data and audio data, for example.
従来のこの種の信号処理装置の一例が、特許文献1および2に開示されている。特許文献1で開示された従来技術(1)は、ビデオ信号に付加されたタイムスタンプとオーディオ信号に付加されたタイムスタンプとの差分を求め、ディスプレイに送出する垂直帰線消去信号期間をこの差分に応じて変更し、これによってビデオ信号およびオーディオ信号の滑らかな同期再生を実現しようとするものである。
An example of a conventional signal processing apparatus of this type is disclosed in
また、特許文献2で開示された従来技術(2)は、音声データの再生量を監視して求められた再生時刻と画像データに割り当てられたタイムスタンプとに基づいて、音声および画像の間で同期を確保しようとするものである。
しかし、従来技術(1)では、記録時にビデオ信号およびオーディオ信号の両方にタイムスタンプを付加するため、タイムスタンプの生成に時計回路が必要となる。従来技術(2)でも、記録時に画像データにタイムスタンプを付加するため、タイムスタンプを生成するための時計回路を準備する必要がある。つまり、従来技術(1)および(2)のいずれにおいても、回路構成が複雑になるという問題がある。 However, in the prior art (1), since a time stamp is added to both the video signal and the audio signal at the time of recording, a clock circuit is required to generate the time stamp. Even in the prior art (2), it is necessary to prepare a clock circuit for generating a time stamp in order to add a time stamp to image data at the time of recording. That is, both the conventional techniques (1) and (2) have a problem that the circuit configuration is complicated.
それゆえに、この発明の主たる目的は、簡単な回路構成で再生画像と再生音声との同期を確保することができる、ビデオカメラを提供することである。 SUMMARY OF THE INVENTION Therefore, a main object of the present invention is to provide a video camera that can ensure synchronization between a reproduced image and reproduced sound with a simple circuit configuration.
請求項1の発明は、イメージセンサによって撮影された被写体の動画像信号とマイクロフォンによって取り込まれた音声信号とを記録媒体に記録するビデオカメラにおいて、動画像信号を形成する各画面の静止画像信号をラスタ走査態様でモニタに向けて出力する第1画像出力手段、第1画像出力手段によって走査されている画素位置を間欠的に検出する第1検出手段、および第1検出手段によって検出された画素位置を第1検出手段による検出時点でマイクロフォンによって取り込まれた音声信号に割り当てる割り当て手段を備えることを特徴とする、ビデオカメラである。 According to a first aspect of the present invention, there is provided a video camera for recording a moving image signal of a subject photographed by an image sensor and an audio signal captured by a microphone on a recording medium. First image output means for output to the monitor in a raster scanning manner, first detection means for intermittently detecting pixel positions scanned by the first image output means, and pixel positions detected by the first detection means A video camera comprising: assigning means for assigning to the audio signal captured by the microphone at the time of detection by the first detecting means.
請求項1の発明では、第1画面出力手段が動画像信号を形成する各画面の静止画像信号をラスタ走査態様でモニタに向けて出力し、第1検出手段が第1画像出力手段によって走査されている画素位置を間欠的に検出する。そして、割り当て手段が第1検出手段によって検出された画素位置を第1検出手段による検出時点でマイクロフォンによって取り込まれた音声信号に割り当てる。したがって、再生時に、音声信号に割り当てられた画素位置と現在再生(走査)されている静止画像信号の画素位置とを比較することによって再生画像と再生音声との同期を確保することができる。 In the first aspect of the invention, the first screen output means outputs the still image signal of each screen forming the moving image signal to the monitor in a raster scanning manner, and the first detection means is scanned by the first image output means. The detected pixel position is detected intermittently. Then, the assigning means assigns the pixel position detected by the first detecting means to the audio signal captured by the microphone at the time of detection by the first detecting means. Therefore, at the time of reproduction, synchronization between the reproduced image and the reproduced audio can be ensured by comparing the pixel position assigned to the audio signal with the pixel position of the still image signal currently reproduced (scanned).
請求項2の発明は、マイクロフォンによって取り込まれた音声信号の記録に先立って所定量毎の符号化処理を施す符号化手段をさらに備え、第1検出手段は所定量の音声信号が取り込まれる毎に画素位置を検出する、請求項1記載のビデオカメラである。
The invention of
請求項2の発明では、符号化手段がマイクロフォンによって取り込まれた音声信号の記録に先立って所定量毎の音声信号に対して符号化処理を施し、第1検出手段は所定量の音声信号が取り込まれる毎に走査されている画素位置を検出する。したがって、音声信号が取り込まれた時点での画素位置が音声信号に割り当てられる。 According to the second aspect of the present invention, the encoding means performs an encoding process on the audio signal for each predetermined amount prior to recording of the audio signal captured by the microphone, and the first detecting means captures the predetermined amount of the audio signal. Each time a pixel is scanned, the position of the scanned pixel is detected. Therefore, the pixel position at the time when the audio signal is captured is assigned to the audio signal.
請求項3の発明は、記録媒体から読み出された動画像信号を形成する各画像の静止画像信号をラスタ走査態様でモニタに向けて出力する第2画像出力手段、記録媒体から読み出された音声信号をスピーカに向けて出力する音声出力手段、音声出力手段によって出力される音声信号に割り当てられた画素位置を検出する第2検出手段、第2検出手段の検出時点で第2画像出力手段によって走査されている画素位置と第2検出手段によって検出された画素位置とのずれを判別する判別手段、および第2画像出力手段によって出力される静止画像信号の画面数を判別手段の判別結果に応じて調整する調整手段をさらに備える、請求項1または2記載のビデオカメラである。
According to a third aspect of the present invention, the second image output means for outputting the still image signal of each image forming the moving image signal read from the recording medium toward the monitor in a raster scanning manner, read from the recording medium Audio output means for outputting an audio signal to a speaker, second detection means for detecting a pixel position assigned to the audio signal output by the audio output means, and second image output means at the time of detection by the second detection means A discriminating unit that discriminates a deviation between the pixel position being scanned and the pixel position detected by the second detecting unit, and the number of still image signals output by the second image output unit according to the discrimination result The video camera according to
請求項3の発明では、第2画像出力手段が記録媒体から読み出された動画像信号を形成する各画像の静止画像信号をラスタ走査態様でモニタに向けて出力し、音声出力手段が記録媒体から読み出された音声信号をスピーカに向けて出力する。第2検出手段が音声出力手段によって出力される音声信号に割り当てられた画素位置を検出する。判別手段が第2検出手段の検出時点で第2画像出力手段によって走査されている画素位置と第2検出手段によって検出された画素位置とのずれを判別する。そして、調整手段は第2画像出力手段によって出力される静止画像信号の画面数を判別手段の判別結果に応じて調整する。したがって、音声と画像との同期のずれを画素位置レベルで検出し、ずれに応じて画像の枚数を調整することによって音声と画像との同期を確保することができる。
In the invention of
請求項4の発明は、動画像信号は1画面ずつ符号化された状態で記録媒体に記録され、第2画像出力手段は各画面の符号化静止画像信号を復号命令に応答して復号する復号手段を含み、調整手段は復号命令の発生タイミングを制御する、請求項3記載のビデオカメラである。 According to a fourth aspect of the present invention, a moving image signal is recorded on a recording medium in a state of being encoded for each screen, and the second image output means decodes the encoded still image signal of each screen in response to a decoding command. It includes means, adjusting means for controlling the generation timing of the decoding instructions, a video camera according to claim 3 Symbol placement.
請求項4の発明では、動画像信号は1画面ずつ符号化された状態で記録媒体に記録され、復号手段が各画面の符号化静止画像信号を復号命令に応じて復号する。そして、調整手段が復号手段に与える復号命令の発生タイミングを制御する。したがって、符号化静止画像信号の復号のタイミングを制御することによって、音声と画像との同期のずれを調整し、同期を確保することができる。 According to the fourth aspect of the present invention, the moving image signal is recorded on the recording medium in a state of being encoded one screen at a time, and the decoding means decodes the encoded still image signal of each screen in accordance with the decoding command. Then, the generation timing of the decoding instruction given to the decoding unit by the adjusting unit is controlled. Therefore, by controlling the decoding timing of the encoded still image signal, it is possible to adjust the synchronization deviation between the sound and the image and ensure the synchronization.
請求項5の発明は、復号手段は、復号命令に応答して復号された静止画像信号を第1メモリに書き込み、かつ第1メモリに格納された静止画像信号を所定周期で第1メモリから読み出す、請求項4記載のビデオカメラである。
The decoding means writes the still image signal decoded in response to the decoding command to the first memory, and reads the still image signal stored in the first memory from the first memory at a predetermined cycle. 5. A video camera according to
請求項5の発明では、復号手段は、復号命令に応答して復号した静止画像信号をバッファである第1メモリに書き込み、第1メモリに書き込まれた静止画像信号を一定の周期で第1メモリから読み出す。第1メモリに書き込まれた静止画像信号が再生されるので、復号手段に与える復号命令の周期を第1メモリに書き込まれた静止画像信号を読み出す周期よりも短くしたり長くしたりすることによって、再生される動画像を見かけ上スキップしたり停止したりして音声との同期を調整することができる。
In the invention of
請求項6の発明は、調整手段は、画面数を増大させるとき復号命令の発生周期を延長し、画面数を減少させるとき復号命令の発生周期を短縮する、請求項4または5記載のビデオカメラである。
6. The video camera according to
請求項6の発明では、調整手段は、画像数を増大させるとき画像の復号命令の発生周期を延長し、画面数を減少させるとき復号命令の発生周期を短縮する。つまり、復号命令の発生周期を第1メモリからの静止画像信号の読み出し周期よりも長くすると、第1メモリに記録されている静止画像信号が更新されないうちに第1メモリから静止画像信号が読み出されるので同一画像が再生されて画面数が増大する。これによって画像の表示が一時停止されて音声が画像に追いつくことができる。逆に、復号命令の発生周期を第1メモリからの静止画像信号の読み出し周期よりも短くすると、第1メモリから静止画像信号が読み出される前に第1メモリの内容が上書きされるので、第1メモリから読み出される静止画像信号は1画面分スキップされる。したがって、再生される画面数が減少する。これによって、音声に対する画像の遅れを取り戻すことができる。 According to the sixth aspect of the present invention, the adjusting means extends the generation cycle of the image decoding command when increasing the number of images, and shortens the generation cycle of the decoding command when decreasing the number of screens. That is, if the generation cycle of the decoding command is longer than the read cycle of the still image signal from the first memory, the still image signal is read from the first memory before the still image signal recorded in the first memory is updated. Therefore, the same image is reproduced and the number of screens increases. As a result, the display of the image is paused and the sound can catch up with the image. On the contrary, if the generation cycle of the decoding instruction is made shorter than the reading cycle of the still image signal from the first memory, the contents of the first memory are overwritten before the still image signal is read from the first memory. The still image signal read from the memory is skipped for one screen. Therefore, the number of screens to be played is reduced. Thereby, the delay of the image with respect to the sound can be recovered.
請求項7の発明は、第2画像出力手段は、復号手段から出力された静止画像信号を第2メモリに書き込む書き込み手段、および第2メモリに格納された静止画像信号を読み出す読み出し手段をさらに含む、請求項4ないし6に記載のビデオカメラである。
The second image output means further includes a writing means for writing the still image signal output from the decoding means to the second memory, and a reading means for reading the still image signal stored in the second memory. A video camera according to any one of
請求項7の発明では、書き込み手段が復号手段から出力された静止画像信号をSDRAMなどの第2メモリに書き込み、読み出し手段が第2メモリに書き込まれた静止画像信号を読み出す。こうして第2メモリに書き込まれた静止画像信号が読み出されて再生される。 According to another aspect of the invention, the writing means writes the still image signal output from the decoding means to a second memory such as an SDRAM, and the reading means reads the still image signal written to the second memory. In this way, the still image signal written in the second memory is read and reproduced.
請求項8の発明は、第2メモリは第1エリアおよび第2エリアを含み、書き込み手段は復号手段から出力された静止画像信号を第1エリアおよび第2エリアに交互に書き込み、読み出し手段は静止画像信号を第1エリアおよび第2エリアから交互に読み出す、請求項7記載のビデオカメラである。
According to an eighth aspect of the present invention, the second memory includes a first area and a second area, the writing means alternately writes still image signals output from the decoding means to the first area and the second area, and the reading means is stationary. The video camera according to
請求項8の発明では、第2メモリは第1エリアおよび第2エリアを含んでいる。そして、書き込み手段は復号手段のバッファ(第1メモリ)から出力された静止画像信号を第1エリアおよび第2エリアに交互に書き込み、読み出し手段は静止画像信号を第1エリアおよび第2エリアから交互に読み出す。 According to an eighth aspect of the present invention, the second memory includes a first area and a second area. The writing means alternately writes the still image signal output from the buffer (first memory) of the decoding means to the first area and the second area, and the reading means alternately writes the still image signal from the first area and the second area. Read to.
請求項9の発明は、書き込み手段による書き込みと読み出し手段による読み出しとは相補的に行われる、請求項8記載のビデオカメラである。
The invention of claim 9 is the video camera according to
請求項9の発明では、書き込み手段による第2メモリへの書き込みと読み出し手段による第2メモリからの読み出しとは相補的に行われる。したがって、第2メモリにおける書き込みアドレスに対する読み出しアドレスの追い越しが発生しないので再生画面にフレームのずれが出現することがない。 In the invention of claim 9, the writing to the second memory by the writing means and the reading from the second memory by the reading means are performed in a complementary manner. Accordingly, since the overtaking of the read address with respect to the write address in the second memory does not occur, no frame shift appears on the playback screen.
請求項10の発明は、動画像信号はMPEG4方式に従って符号化される、請求項4ないし9のいずれかに記載のビデオカメラである。 A tenth aspect of the present invention is the video camera according to any one of the fourth to ninth aspects, wherein the moving image signal is encoded according to the MPEG4 system.
請求項10の発明では、動画像信号はMPEG4方式に従って符号化される。 In the invention of claim 10, the moving image signal is encoded according to the MPEG4 system.
この発明によれば、動画像データの画素位置に基づいて動画像データの再生タイミングを制御するので、時計回路を必要としないのでより簡単な回路構成によって動画像データと音声データとの同期を実現することができる。 According to the present invention, since the reproduction timing of the moving image data is controlled based on the pixel position of the moving image data, a clock circuit is not required, and synchronization of the moving image data and the audio data is realized with a simpler circuit configuration. can do.
この発明の上述の目的,その他の目的,特徴および利点は、図面を参照して行う以下の実施例の詳細な説明から一層明らかとなろう。 The above object, other objects, features and advantages of the present invention will become more apparent from the following detailed description of embodiments with reference to the drawings.
図1に示すこの発明の一実施例であるビデオカメラ10は、タイムスタンプを用いることなく画像(動画)データおよび音声データの同期を確保しようとするものである。再生時に画像と音声との同期を取るために、記録時に音声データにこの音声データの入力タイミングにおいて表示されているスルー画像データのフィールド番号情報,垂直ライン位置情報および水平画素位置情報(これらを“同期サンプル情報”と呼ぶ)を付加する。そして、再生時には、音声フレームから同期サンプル情報を取り出し、取り出された同期サンプル情報と、現在再生されている画像のフィールド番号,垂直ライン位置および水平画素位置とから音声と画像との同期のずれを算出する。このずれが許容範囲を超えるときには、画像を一時停止するかもしくは画像をスキップすることによって画面数を調整してずれを修正する。 A video camera 10 according to an embodiment of the present invention shown in FIG. 1 is intended to ensure synchronization of image (moving image) data and audio data without using a time stamp. In order to synchronize the image and sound during playback, the field number information, the vertical line position information, and the horizontal pixel position information of the through-image data displayed at the time of input of the sound data are added to the sound data at the time of recording. "Synchronized sample information"). At the time of reproduction, the synchronization sample information is extracted from the audio frame, and the synchronization deviation between the audio and the image is detected from the extracted synchronization sample information and the field number, vertical line position, and horizontal pixel position of the currently reproduced image. calculate. When this deviation exceeds the allowable range, the number of screens is adjusted by temporarily stopping the image or skipping the image to correct the deviation.
この実施例のビデオカメラ10では、上述の構成によって画像と音声との同期をとるので、従来とは違って時計回路が必要でなく、簡単な回路構成で画像と音声との同期を実現できる。 In the video camera 10 of this embodiment, since the image and the sound are synchronized with the above-described configuration, a clock circuit is not required unlike the conventional one, and the synchronization between the image and the sound can be realized with a simple circuit configuration.
図1を参照して、ビデオカメラ10は、イメージセンサ12を含む。被写界の光学像は、図示しない光学レンズを介してこのイメージセンサ12の受光面に照射される。
With reference to FIG. 1, a video camera 10 includes an
オペレータが操作パネル42に設けられたモード切換スイッチ42mdによってカメラモードを選択すると、CPU40によってスルー画像処理が実行される。イメージセンサ12は被写界の生画像信号を1/30秒ごとに出力し、CDS/AGC/AD回路14は出力された生画像信号にノイズ除去,レベル調整およびA/D変換の一連の処理を実行する。CDS/AGC/AD回路14からはディジタル信号である生画像データが出力される。信号処理回路16は、出力された生画像データに白バランス調整,色分離,YUV変換などの信号処理を施し、これによってYUV形式の画像データが生成される。生成された画像データは、メモリ制御回路32によってSDRAM30の伸長画像記録領域に書き込まれる。伸長画像記録領域は、AおよびBの2つのバンクに区切られており、画像データの第1フレームは、まず、バンクAに書き込まれる。1/30秒ごとにバンクが切り換えられ、第2フレームはバンクBに書き込まれ、第3フレームは再びバンクAに書き込まれる。
When the operator selects the camera mode with the mode switch 42md provided on the
ビデオエンコーダ22は、SDRAM30のバンクに書き込まれた画像データを1/60秒ごとにメモリ制御回路32を通してプログレッシブ方式で読み出す。まずバンクAから画像データを読み出し、次にバンクBから画像データを読み出す。SDRAM30のバンクAもしくはバンクBから読み出された画像データはビデオエンコーダ22によってコンポジットビデオ信号に変換されて640画素×240ラインのサイズに縮小される。この縮小されたコンポジットビデオ信号が疑似インタレーススキャン方式でLCD24に与えられる。これによって、1/60秒(16.6ミリ秒)に1フィールドの割合で画像がLCD24に表示される。
The
また、ビデオエンコーダ22では、現フィールドの何ライン目までの描画が終了したかをVカウンタ22vを用いてカウントし、現ラインの何画素目までを描画し終えたかをHカウンタ22hを用いてカウントしている。Vカウンタ22vの最高値は240であり、Hカウンタ22hの最高値は640である。
The
操作パネル42に設けられたシャッタボタン42stがオペレータによって操作されると、CPU40は、信号処理回路20を能動化するとともに、画像圧縮(符号化)命令および音声圧縮(符号化)命令の各々を周期的にMPEG−4コーデック34に与える。
When the shutter button 42st provided on the
能動化された信号処理回路20は、マイクロフォン18から入力される音声信号を48kHzの周期でサンプリングしてディジタル信号である音声データに変換し、この音声データをメモリ制御回路32を通してSDRAM30に書き込む。48kHzのサンプリング処理では、1024サンプルによって約21ミリ秒分の音声データが生成される。詳しくは後述するが、音声データは1024サンプル単位で音声フレームというデータに加工される。CPU40は、SDRAM30への音声データの書き込み量を監視しており、1024サンプル分の音声データの書き込みが開始されるごとに、書き込み開始のタイミングでビデオエンコーダ22からVカウンタ22vのカウント値(垂直ライン位置情報)およびHカウンタ22hのカウント値(水平画素位置情報)を取得する。
The activated
また、CPU40はLCD24に表示されるスルー画像の画像フィールド番号を画像の表示開始時からフィールドカウンタ40fによってカウントしている。このフィールドカウンタ40fのカウント値(フィールド番号情報)は、ビデオエンコーダ22から取得された垂直ライン位置情報および水平画素位置情報とともに、1024サンプルごとの音声データに対応付けられてRAM46上のテーブル46tに記録される。
The
画像フィールドは1/60秒(16.6ミリ秒)ごとに生成され、音声フレームは21ミリ秒ごとに生成されるため、画像フィールドと音声フレームとの発生タイミングは図2に示すようになる。図2からわかるように、音声フレーム番号と音声フレームに同期サンプル情報として付加されるフィールド番号(情報)とは1対1の対応関係にはない。図2の例では、フィールド番号“4”が添付される音声フレームは存在しない。 Since the image field is generated every 1/60 seconds (16.6 milliseconds) and the audio frame is generated every 21 milliseconds, the generation timing of the image field and the audio frame is as shown in FIG. As can be seen from FIG. 2, there is no one-to-one correspondence between the audio frame number and the field number (information) added as synchronization sample information to the audio frame. In the example of FIG. 2, there is no audio frame to which the field number “4” is attached.
MPEG−4コーデック34は、画像圧縮命令が与えられると、メモリ制御回路32を通してSDRAM30から音声データを随時読み出し、読み出した画像データにMPEG−4圧縮を施す。1回の画像圧縮命令によって1フレームの画像データが圧縮される。MPEG−4圧縮によって再生された圧縮画像データはメモリ制御回路32を通して再びSDRAM30に書き込まれる。
When an image compression command is given, the MPEG-4
また、MPEG−4コーデック34は、音声圧縮命令が与えられると、メモリ制御回路32を通してSDRAM30から音声データを随時読み出す。そして、読み出した音声データにMPEG−4圧縮を施す。1回の音声圧縮命令によって1024サンプルの音声データが圧縮される。MPEG−4圧縮によって生成された圧縮音声データはメモリ制御回路32を通して再びSDRAM30に書き込まれる。
The MPEG-4
シャッタボタン42stが再度押されない限り、CPU40は、MPEG−4コーデック34に画像圧縮命令および音声圧縮命令を繰り返し与え、信号処理回路20を能動化し続ける。これによって、圧縮画像データおよび圧縮音声データがSDRAM30に蓄積されてゆく。
Unless the shutter button 42st is pressed again, the
メモリカード38には、最初のシャッタボタン42stの操作に応答してMPEGファイルが新規に作成される。CPU40は、上述の圧縮処理の出力と並行して、SDRAM30に蓄積された圧縮画像データおよび圧縮音声データをメモリ制御回路32を通して読み出す。読み出された圧縮画像データおよび圧縮音声データは、I/F36を通してメモリカード38に与えられて記録される。
In the
圧縮音声データは、SDRAM30から読み出されてメモリカード38に記録されるときに、図3に示すように、1024サンプルごとに音声データヘッダを有する音声フレームという単位にまとめられる。1024サンプルの音声データが音声フレームにまとめられると、RAM46に形成されたテーブル46tを参照して当該1024サンプルの音声データに対応する同期サンプル情報が特定され、特定された同期サンプル情報が音声フレームに付加される。図3には音声フレームが連続した状態で示されているが、メモリカード38に形成されるMPEGファイルには、圧縮画像データと圧縮音声データとが混在した状態で記録される。
When the compressed audio data is read from the
圧縮画像データおよび圧縮音声データの記録が終了すると、総ファイルサイズ,総フレーム数,総音声サイズ,フレームレートなどの情報がMPEGファイルのファイルヘッダに書き込まれる。また、ファイルヘッダには第何画像フレームの画像データおよび第何音声フレームの音声データがどのアドレスに記録されているかとう情報を保持したテーブルが含まれている。このテーブルを参照することによって所望のフレームの画像データおよび音声データを読み出すことができる。 When the recording of the compressed image data and the compressed audio data is completed, information such as the total file size, the total number of frames, the total audio size, and the frame rate is written in the file header of the MPEG file. In addition, the file header includes a table holding information such as which address the image data of which image frame and the audio data of which audio frame are recorded at. By referring to this table, image data and audio data of a desired frame can be read out.
シャッタボタン42stがオペレータによって操作されると、CPU40は、信号処理回路20を不能化し、MPEG−4コーデック34への圧縮命令の出力を停止する。これによって、圧縮画像データおよび圧縮音声データの生成が終了し、その後、メモリカード38への圧縮画像データおよび圧縮音声データの書き込みが終了する。
When the shutter button 42st is operated by the operator, the
このように、MPEGファイルに記録された音声データは1024サンプルごとに音声フレームという単位にまとめられ、各音声フレームには1024サンプルの音声データがSDRAM30に記録され始めたタイミングの画像データのフィールド番号,垂直ライン位置および水平画素位置を示す情報(同期サンプル情報)が付加されている。
As described above, the audio data recorded in the MPEG file is grouped into units called audio frames every 1024 samples, and in each audio frame, the field number of the image data at the timing when the audio data of 1024 samples starts to be recorded in the
オペレータがモード切換スイッチ42mdによって再生モードを選択し、かつ、ファイル選択キー42fsによって所望のMPEGファイルを選択すると、CPU40は、ファイルヘッダに含まれる上述のテーブルを参照して、第1フレームである圧縮画像データおよび第1音声フレームである圧縮音声データをメモリカード38から読み出す。読み出された圧縮画像データおよび圧縮音声データはメモリ制御回路32を通してSDRAM30に書き込まれる。
When the operator selects the playback mode with the mode switch 42md and selects the desired MPEG file with the file selection key 42fs, the
CPU40はまた、MPEG−4コーデック34に画像伸長(復号)命令および音声伸長(復号)命令を繰り返し与える。画像伸長命令は1/30秒(33ミリ秒)ごとに発行され、音声伸長命令は21ミリ秒ごとに発行される。
The
CPU40から音声伸長命令が与えられると、MPEG−4コーデック34は、メモリ制御回路32を通して圧縮音声データをSDRAM30から読み出し、読み出した圧縮音声データにMPEG−4伸長を施す。1回の音声伸長命令によって1フレームの圧縮音声データが伸長される。伸長された音声データは、メモリ制御回路32を通して再びSDRAM30に書き込まれる。信号処理回路26は、伸長音声データをメモリ制御回路32を通して読み出し、読み出した伸長音声データをアナログ信号に変換し、そして、変換した音声データをスピーカ28に与える。これによって、再生音声がスピーカ28から出力される。圧縮音声データは、順次メモリカード38から読み出され、MPEG−4コーデック34によって伸長されて、スピーカ28から出力される。これによって、途切れることなく音声がスピーカ28から出力される。
When an audio decompression command is given from the
また、MPEG−4コーデック34は、CPU40から画像伸長命令が与えられると、メモリ制御回路32を通して圧縮画像データをSDRAM30から読み出す。読み出した圧縮画像データはMPEG−4伸長が施される。1回の画像伸長命令によって1フレームの圧縮画像データが伸長される。伸長された画像データはMPEG−4コーデック34が備えるバッファ34a(第1メモリ)に蓄積される。 バッファ34aに蓄積された1フレームの画像データは、1/30秒(33ミリ秒)ごとに読み出され、メモリ制御回路32を通してSDRAM30の伸長画像記録領域(第2メモリ)に記録される。伸長画像記録領域は、上述したように、AおよびBの2つのバンクに区切られており、伸長された画像データは、まず、バンクA(第1エリア)に記録される。1/30秒ごとにバンクが切り換えられ、次に伸長された第2画像フレームはバンクB(第2エリア)に記録され、第3画像フレームは再びバンクAに記録される。
The MPEG-4
ビデオエンコーダ22は、1/60秒ごとにメモリ制御回路32を通してSDRAM30のバンクから伸長された画像データをプログレッシブスキャン方式によって読み出す。まず、バンクAに記録されている画像データを読み出し、次にバンクを切り換えてバンクBに記録されている画像データを読み出す。ビデオエンコーダ22は、SDRAM30から読み出した画像データをコンポジットビデオ信号に変換して640画素×240ラインのサイズに縮小し、縮小した画像データを疑似インタレーススキャン方式でLCD24に与える。この疑似インタレーススキャン方式によって、LCD24には1/60秒に1フィールドの割合で画像が表示される。
The
また、ビデオエンコーダ22は、記録時と同様に再生時においても、Vカウンタ22vおよびHカウンタ22hを用いて、現フィールドの何ライン目までの描画が終了したか、および現ラインの何画素目までを描画し終えたかをそれぞれカウントしている。さらに、第何番目の画像フィールドが描画されているかがCPU40のフィールドカウンタ40fによってカウントされている。
Further, the
図2に示したように、音声フレームと画像フィールドとは1対1の対応関係にないので、音声フレームと画像フィールドとの同期を確保する仕組みが必要になる。音声は1音声フレームずつ順番に逐次の再生を行い、途中でスキップされたり停止されたりすることはない。一方、画像は、現在再生されている画像データの描画位置(フィールドカウンタ40fの値,Vカウンタ22vの値およびHカウンタ22hの値)と音声フレームに付加されている同期サンプル情報(画像フィールド番号情報,垂直ライン位置情報および水平画素位置情報)とから音声フレームと画像フィールドとのずれが算出され、ずれが許容範囲外であるときには、ずれを修正するためにスキップされたり停止されたりする。
As shown in FIG. 2, since there is no one-to-one correspondence between audio frames and image fields, a mechanism for ensuring synchronization between the audio frames and the image fields is required. The audio is sequentially reproduced one by one in an audio frame, and is not skipped or stopped midway. On the other hand, for the image, the drawing position of the currently reproduced image data (the value of the
図4を用いてより具体的に説明する。メモリカード38から音声フレームが読み出されると、読み出された音声フレームから同期サンプル情報(画像フィールド番号情報,垂直ライン位置情報および水平画素位置情報)が抽出される。この同期サンプル情報が示す画面上の位置をA点とする。このA点は、この音声フレームがサンプリングされたときに再生されていた画像の画素の位置を示している。つまり、この音声フレームがサンプリングされていたときには、第Xフィールドの第(Xa+1)ラインの第Ya画素が描画されたところであったことを示している。
This will be described more specifically with reference to FIG. When an audio frame is read from the
また、音声フレームから同期サンプル情報が抽出されるタイミングで、CPU40は、ビデオエンコーダ22からVカウンタ22vおよびHカウンタ22hのカウント値を取得する。取得したカウント値とフィールドカウンタ40fのカウント値とが示す位置をB点とする。つまり、音声フレームから同期サンプル情報が抽出された時点では、第Xフィールドの第(Xb+1)ラインの第Yb画素が描画されていたことになる。
Further, the
A点とB点とが一致する場合に音声と画像とが記録時と同じタイミングで再生されていることになる。したがって、A点とB点との位置の差が音声と画像との同期のずれとなる。図4の例の場合、画像の再生が音声の再生に比べて、(Xb−Xa)ラインと(Yb−Ya)画素分だけ進んでいることになる。なお、図4の例ではA点とB点とは同一の画像フィールド上に存在するが、A点とB点とが異なる画像フィールド上に存在する場合もある。 When the A point and the B point coincide with each other, the sound and the image are reproduced at the same timing as when recording. Therefore, the difference in position between the point A and the point B is a synchronization shift between the sound and the image. In the case of the example in FIG. 4, the image reproduction is advanced by (Xb−Xa) line and (Yb−Ya) pixels compared to the audio reproduction. In the example of FIG. 4, the point A and the point B exist on the same image field, but the point A and the point B may exist on different image fields.
音声と画像との同期のずれが許容範囲を超える場合はずれの修正を行う。つまり、画像が音声よりも進んでいる場合には画像を1フレーム時間分(1/30秒)だけ停止させ、画像が音声よりも遅れている場合には画像を1フレーム分だけスキップさせる。 If the synchronization deviation between the sound and the image exceeds the allowable range, the deviation is corrected. That is, when the image is ahead of the sound, the image is stopped for one frame time (1/30 second), and when the image is behind the sound, the image is skipped by one frame.
画像を停止させる場合には、CPU40は、1/30秒おきに発生させるMPEG−4コーデック34への画像伸長命令を1回中止する。MPEG−4コーデック34によって伸長された画像データはバッファ34aに格納され、バッファ34aに格納された画像データは1/30秒おきにメモリ制御回路32を通してSDRAM30のバンクAもしくはバンクBに書き込まれる。CPU40が画像伸長命令の発生を1回中止すると、バッファ34aに蓄積されている伸長された画像データは更新されない。したがって、SDRAM30のバンクAもしくはバンクBには前回と同じ画像データが書き込まれる。つまり、バンクAとバンクBには同じ画像データが書き込まれた状態となる。
When stopping the image, the
このため、ビデオエンコーダ22は、バンクは異なるものの2回続けて同じ画像データを読み出して再生することになる。したがって、LCD24には前回と同じ画像が表示され、見かけ上画像が1フレーム時間分停止されることになる。
For this reason, the
一方、画像をスキップさせる場合には、CPU40は、通常1/30秒に1回発生させるMPEG−4コーデック34への画像伸長命令を1/30秒の間に2回発生させる。すると、1/30秒に1回読み出されてSDRAM30のバンクに書き込まれるバッファ34aの内容が、読み出される前に次の伸長画像データによって上書きされる。このためSDRAM30のバンクAもしくはバンクBにはバッファ34aに上書きされた画像データが書き込まれる。そして、この上書きされた画像データがビデオエンコーダ22によって読み出されて再生される。したがって、連続した画像フレームがMPEG−4コーデック34によって伸長されるが、LCD24には1フレーム分スキップされて画像が表示される。このようにして音声と画像とのずれが修正され、同期が保たれる。
On the other hand, when skipping an image, the
以下に、図5から図10に示すフロー図を用いて、画像圧縮タスク,音声取込タスク,音声圧縮タスク,音声再生タスクおよび画像再生タスクにおけるCPU40の動作について説明する。なお、画像圧縮タスク,音声取込タスクおよび音声圧縮タスクは同時に平行して実行され、音声再生タスクおよび画像再生タスクは同時に平行して実行される。また、CPU40はフラッシュメモリ44に格納されているプログラムにしたがって動作する。
Hereinafter, the operations of the
画像圧縮タスクにおけるCPU40の動作は図5のフロー図に示される。まず、CPU40は、ステップS1において、オペレータによって記録開始操作が行われたかどうかを判断する。ステップS1においてYESと判断すると、次にステップS3において、記録開始操作から1/30秒が経過するまで待機する。この1/30秒の待機は、1フレーム分の画像データが信号処理回路16を経てメモリ制御回路32によってSDRAM30に書き込まれるのを待つためのものである。
The operation of the
ステップS3においてYESと判断すると、ステップS5では、MPEG−4コーデック34に対して画像圧縮命令を与える。すると、MPEG−4コーデック34はメモリ制御回路32を通してSDRAM30から1フレーム分の画像データを読み出してMPEG−4圧縮を施す。そして、圧縮画像データは再びメモリ制御回路32を通してSDRAM30に書き込まれる。SDRAM30に書き込まれた圧縮画像データは別のタスクによって順次メモリカード38に書き込まれる。
If YES is determined in the step S3, an image compression command is given to the MPEG-4
ステップS5において画像の圧縮命令をMPEG−4コーデック34に対して与えると、ステップS7では、圧縮命令の発生から1/30秒が経過したかどうかを判断する。ステップS7においてYESと判断すると、ステップS5に戻って再びMPEG−4コーデック34に対して画像の圧縮命令を与える。
When an image compression command is given to the MPEG-4
ステップS7においてNOと判断すると、ステップS9においてオペレータによって記録停止の操作が行われたかどうかを判断する。ステップS7においてNOと判断するとステップS7に戻り、YESと判断すると画像圧縮タスクを終了する。 If NO is determined in step S7, it is determined in step S9 whether or not a recording stop operation has been performed by the operator. If NO is determined in step S7, the process returns to step S7, and if YES is determined, the image compression task is ended.
音声取込タスクにおけるCPU40の動作は図6のフロー図に示される。まず、CPU40は、ステップS11において、オペレータによって記録開始操作が行われたかどうかを判断する。記録開始操作が行われると、マイクロフォン18から入力された音声が信号処理回路20によって音声データに変換され、この音声データがメモリ制御回路32を通してSDRAM30に書き込まれる。ステップS13では、SDRAM30における音声データの書き込み開始位置(アドレス)を取得してレジスタW1に格納する。なお、レジスタW1に格納されている値を“W1”で表現する。
The operation of the
ステップS15では、第1同期サンプル処理を行う。第1同期サンプル処理では、1番目の1024サンプル(第1フレーム)に対応する同期サンプル情報を取得し、取得した同期サンプル情報を当該1024サンプルの音声データに対応させてRAM46のテーブル46tに記録する。つまり、音声データのSDRAM30への書き込みが開始された時点で、ビデオエンコーダ22からVカウンタ22vおよびHカウンタ22hの値を取得し、CPU40がカウントしている画像フィールド番号の値をフィールドカウンタ40fから取得する。
In step S15, a first synchronous sample process is performed. In the first synchronization sample processing, synchronization sample information corresponding to the first 1024 samples (first frame) is acquired, and the acquired synchronization sample information is recorded in the table 46t of the
ステップS17では、SDRAM30における音声データの現状での書き込み終了位置(アドレス)を取得してレジスタW2に格納する。なお、レジスタW2に格納されている値を“W2”で表現する。
In step S17, the current write end position (address) of the audio data in the
ステップS19では、レジスタW1に格納されている値とレジスタW2に格納されている値とから、SDRAM30に書き込まれた音声データのデータ量を算出する。そして、ステップS21では、SDRAM30に書き込まれた音声データの量が1024サンプル分となったかどうかを判断する。
In step S19, the data amount of the audio data written in the
ステップS21においてNOと判断すると、ステップS17に戻って再び書き込み終了位置を取得する。一方、ステップS21においてYESと判断すると、ステップS23において第1同期サンプル処理を行う。この第1同期サンプル処理では、上述したように、次にSDRAM30に書き込まれる1024サンプル分の音声データに対応する同期サンプル情報を取得して、RAM46に形成されたテーブル46tに記録する。
If NO is determined in step S21, the process returns to step S17 to acquire the write end position again. On the other hand, if YES is determined in the step S21, the first synchronous sample process is performed in a step S23. In the first synchronous sample processing, as described above, synchronous sample information corresponding to 1024 samples of audio data written to the
ステップS25では、次の1024サンプル分の音声データを算出するために、書き込み開始位置(W1)を現状における書き込み終了アドレスの次のアドレス(W2+1)で更新する。そして、ステップS27では、オペレータがシャッタボタン42stを操作して記録終了操作を行ったかどうかを判断する。ステップS27においてNOと判断するとステップS17に戻る。ステップS27でYESと判断すると音声取込タスクを終了する。 In step S25, in order to calculate audio data for the next 1024 samples, the write start position (W1) is updated with the address (W2 + 1) next to the current write end address. In step S27, it is determined whether or not the operator has performed the recording end operation by operating the shutter button 42st. If NO is determined in step S27, the process returns to step S17. If YES is determined in the step S27, the voice capturing task is ended.
音声圧縮タスクにおけるCPU40の動作は図7のフロー図に示される。まず、CPU40は、オペレータが記録開始の操作を行うと、その旨がステップS31において判断される。ステップS33では、記録開始の操作から1024サンプル期間(21ミリ秒)が経過するまで待機する。この待機は、マイクロフォン18から入力された1024サンプル分の音声が信号処理回路20およびメモリ制御回路32を通してSDRAM30に書き込まれるのを待つために行われる。
The operation of the
ステップS33においてYESと判断すると、CPU40は、ステップS35において音声データの圧縮命令をMPEG−4コーデック34に対して与える。これによって、1フレーム、つまり、1024サンプル分の音声データがMPEG−4コーデック34に取り込まれMPEG−4圧縮が施される。圧縮された音声データはメモリ制御回路32を通して再びSDRAM30に書き込まれる。
If YES is determined in the step S33, the
音声データの圧縮命令の発行を行うと、ステップS37において、RAM46に形成されたテーブル46tを参照して当該1024サンプルの音声データに対応する同期サンプル情報を取得する。そして、ステップS39において、取得した同期サンプル情報を音声データに付加する。これによって1音声フレームがSDRAM30上に形成される。こうして形成された音声フレームは、別のタスクによって適宜SDRAM30から読み出されてI/F36を通してメモリカード38に書き込まれる。
When the audio data compression command is issued, in step S37, the synchronization sample information corresponding to the 1024 samples of audio data is acquired with reference to the table 46t formed in the
ステップS41では、ステップS35における音声の圧縮命令の発生から1024サンプル期間(21ミリ秒)が経過したかどうかを判断する。ステップS41においてYESと判断すると、ステップS35に戻って再びMPEG−4コーデック34に音声の圧縮命令を与える。ステップS41においてNOと判断すると、ステップS43において、オペレータがシャッタボタン42stを操作して記録終了操作を行ったかどうかを判断する。ステップS43においてNOと判断するとステップS41に戻る。ステップS43でYESと判断すると音声圧縮タスクを終了する。
In step S41, it is determined whether or not 1024 sample periods (21 milliseconds) have elapsed since the generation of the voice compression command in step S35. If YES is determined in the step S41, the process returns to the step S35 to again give an audio compression command to the MPEG-4
以上に説明した画像圧縮タスク,音声取込タスクおよび音声圧縮タスクによって、メモリカード38に音声データと画像データとを含むMPEGファイルが形成される。次に、音声再生タスクおよび画像再生タスクについて説明する。
The MPEG file including the audio data and the image data is formed on the
音声再生タスクにおけるCPU40の動作は図9のフロー図に示される。まず、ステップS51において音声停止フラグがオン状態であるかどうかを判断し、オン状態である場合には音声停止フラグがオフ状態になるまで待機する。音声停止フラグがオフ状態になると、ステップS53において位置特定フラグがオン状態であるかどうかを判断する。
The operation of the
音声停止フラグおよび位置特定フラグは、後述する画像再生タスクにおいてオン状態に設定される。画像再生タスクにおいて、画像のコマ送り再生やスキップ再生を行っているときには、音声の再生は行わない。そこで、コマ送り再生やスキップ再生を行っている間は、音声停止フラグをオン状態にして音声の再生を停止する。また、画像を第1フレームから再生するときには音声も第1音声フレームから再生すればよいが、画像のコマ送り再生やスキップ再生を行った後に、途中の画像から再生する場合には、再生される画像フレームに対応した音声フレームを特定し、特定された音声フレームから再生しなければならない。そのため、画像のコマ送り再生やスキップ再生を行ったときに位置特定フラグをオン状態に設定して再生する音声フレームの特定が必要なことを画像再生タスクに知らせる。 The audio stop flag and the position specifying flag are set to an on state in an image reproduction task described later. In the image reproduction task, audio is not reproduced when frame-by-frame reproduction or skip reproduction is performed. Therefore, during frame-by-frame playback or skip playback, the audio stop flag is turned on to stop audio playback. In addition, when the image is reproduced from the first frame, the sound may be reproduced from the first audio frame. However, when the image is reproduced from the middle image after frame-by-frame reproduction or skip reproduction, the image is reproduced. An audio frame corresponding to the image frame must be identified and reproduced from the identified audio frame. Therefore, when performing frame-by-frame playback or skip playback, the position specifying flag is set to the on state to notify the image playback task that it is necessary to specify the audio frame to be played back.
ステップS53でYESと判断すると、ステップS55で、画像再生タスクにおいてCPU40がレジスタFpを用いてカウントしている再生画像フレームの番号Fpを参照して第Fp番目の画像フレームに対応する音声フレームを特定する。なお、レジスタFpに格納されている値を“Fp”で表す。音声フレームは、画像フレームの番号ではなく、画像フィールドの番号を保持しているので、(Fp×2−1)番のフィールド番号を保持している音声フレームを第Fp画像フレームに対応する音声フレームとして特定する。そして、ステップS57では、音声フレームの特定を終えたので位置特定フラグをオフ状態に設定する。
If YES is determined in the step S53, an audio frame corresponding to the Fp-th image frame is specified with reference to the reproduction image frame number Fp counted by the
ステップS59では、ステップS55において特定された音声フレームの伸長命令をMPEG−4コーデック34に与える。ステップS53でNOと判断された場合には、第1音声フレームから伸長される。
In step S59, the MPEG-4
ステップS61では、伸長命令の対象となった音声フレームから、同期サンプル情報(画像フィールド番号情報,垂直ライン位置情報および水平画素位置情報)を取得して、RAM46に記録する。そして、ステップS63では、同期サンプリング情報の取得を画像再生タスクに知らせるために同期サンプル情報取得フラグをオン状態に設定する。
In step S 61, synchronization sample information (image field number information, vertical line position information, and horizontal pixel position information) is acquired from the audio frame that is the target of the decompression command and recorded in the
ステップS65では、ステップS59で音声フレームの伸長命令を発してから1音声フレームの再生にかかる時間である21ミリ秒が経過したかどうかを判断する。ステップS65においてYESと判断するとステップS51に戻る。一方、ステップS65においてNOと判断するとステップS67に進む。 In step S65, it is determined whether 21 milliseconds, which is the time taken to reproduce one audio frame, has elapsed since the audio frame decompression command was issued in step S59. If YES is determined in the step S65, the process returns to the step S51. On the other hand, if NO is determined in step S65, the process proceeds to step S67.
ステップS67では、オペレータによって再生終了操作が行われるか、もしくは、すべてのデータ(音声フレームおよび画像フレーム)の再生が終了したかどうかを判断する。ステップS67でNOと判断したときにはステップS65に戻り、YESと判断したときには音声再生タスクを終了する。 In step S67, it is determined whether or not a reproduction end operation has been performed by the operator, or whether or not the reproduction of all data (audio frames and image frames) has been completed. When NO is determined in the step S67, the process returns to the step S65, and when YES is determined, the sound reproduction task is ended.
画像再生タスクにおけるCPU40の動作は図9および図10のフロー図に示される。まず、図9のステップS71では、再生される画像フレームをカウントするためにレジスタFpに1を格納して初期化する。ステップS73では、オペレータによってコマ送り再生もしくはスキップ再生の操作が行われたかどうかを判断する。ステップS73においてYESと判断すると、ステップS87においてコマ送り再生もしくはスキップ再生が行われている旨を音声再生タスクに知らせるために音声停止フラグをオン状態に設定する。また、ステップS89では、コマ送り再生もしくはスキップ再生によって画像が途中から再生されるので再生を開始する音声フレームを特定する必要がある旨を音声再生タスクに知らせるために位置特定フラグをオン状態に設定する。
The operation of the
ステップS91ではコマ送り再生もしくはスキップ再生の処理を行う。コマ送り再生およびスキップ再生の処理の詳細な説明は省略する。コマ送り再生およびスキップ再生の処理では、コマ送り再生もしくはスキップ再生に応じた画像フレームの伸長命令を発行するとともに、画像フレームカウンタFpの更新が行われる。 In step S91, frame advance playback or skip playback processing is performed. A detailed description of the frame advance playback and skip playback processing will be omitted. In the frame advance playback and skip playback processing, an image frame expansion command corresponding to frame advance playback or skip playback is issued, and the image frame counter Fp is updated.
ステップS73においてNOと判断すると、ステップS75において音声停止フラグをオフ状態に設定する。これによって、音声再生タスクにおいて、音声フレームの再生が開始される。 If NO is determined in step S73, the voice stop flag is set to an off state in step S75. Thereby, the playback of the audio frame is started in the audio playback task.
次に、ステップS77では同期サンプル情報取得フラグがオン状態であるかどうか、つまり、音声再生タスクにおいて音声フレームから同期サンプル情報が取得され、画像と音声とのずれを確認するタイミングが到来したかどうかを判断する。 Next, in step S77, whether or not the synchronization sample information acquisition flag is in an on state, that is, whether or not the timing for confirming the difference between the image and the audio has been acquired from the audio frame in the audio reproduction task. Judging.
ステップS77においてNOと判断すると、ステップS93において前回画像フレームの伸長命令が発生されてから1/30秒が経過したかどうかを判断する。画像フレームは1/30秒ごとに再生されるため、1/30秒が経過していなければステップS73に戻る。 If NO is determined in step S77, it is determined in step S93 whether 1/30 second has elapsed since the previous image frame decompression command was generated. Since the image frame is reproduced every 1/30 seconds, if 1/30 seconds have not elapsed, the process returns to step S73.
ステップS93においてYESと判断すると、ステップS95において、第Fp画像フレームの伸長命令をMPEG−4エンコーダ34に対して発生する。これによって、第Fp画像フレームが伸長されて再生される。そして、ステップS97において、カウンタFpに格納されている値を1だけインクリメントする。
If YES is determined in the step S93, a decompression command for the Fp image frame is generated to the MPEG-4
一方、ステップS77においてYESと判断すると、画像と音声とのずれの確認および修正を行う。まず、ステップS79では、同期サンプル情報取得フラグをオフ状態に設定する。 On the other hand, if “YES” is determined in the step S77, confirmation and correction of the deviation between the image and the sound are performed. First, in step S79, the synchronization sample information acquisition flag is set to an off state.
ステップS81では、第2同期サンプル処理を行う。この第2同期サンプル処理では、ビデオエンコーダ22からVカウンタ22vおよびHカウンタ22hの値を取得してRAM46に記録するとともに、CPU40がカウントしている画像フィールド番号の値をフィールドカウンタ40fから取得してRAM46に記録する。
In step S81, a second synchronous sample process is performed. In this second synchronous sample processing, the values of the
そして、ステップS83では、先の音声再生タスクのステップS61(図8)において音声フレームから取り出されてRAM46に記録された、フィールド番号情報が示す値,垂直ライン位置情報が示す値および水平画素位置情報が示す値と、この画像再生タスクのステップS81における第2同期サンプル処理において取得されてRAM46に記録された、フィールドカウンタ40fの値,Vカウンタ22vの値およびHカウンタ22hの値とから、音声と画像との再生タイミングが何フィールド,何ラインそして何画素分ずれているかを計算する。
In step S83, the value indicated by the field number information, the value indicated by the vertical line position information, and the horizontal pixel position information extracted from the audio frame and recorded in the
ステップS85では、音声と画像とタイミングのずれが許容範囲内であるかどうかを判断する。ステップS85でYESと判断すると前述のステップS93に進んで前回の画像フレームの伸長から1/30秒が経過したかどうかを判断し、判断結果がYESであればステップS95においてMPEG−4コーデック34に対する画像フレームの伸長命令を発生する。
In step S85, it is determined whether or not the timing difference between the sound and the image is within an allowable range. If YES is determined in the step S85, the process proceeds to the above-described step S93 to determine whether or not 1/30 second has elapsed from the previous image frame expansion. If the determination result is YES, the MPEG-4
一方、ステップS85においてNOと判断すると、図10のステップS101において、音声と画像とのずれは画像の遅れによるものであるかどうかを判断する。ステップS101においてYESと判断すると、画像の遅れを取り戻すために画像のスキップ処理を行う。つまり、ステップS103において、前回の画像フレームの伸長命令の発生から1/30秒の経過を待たずに第Fp画像フレームの伸長命令をMPEG−4コーデック34に対して発生する。そして、ステップS105では、レジスタFpに格納されている値を1だけインクリメントして図9のステップS73に戻る。
On the other hand, if NO is determined in step S85, it is determined in step S101 in FIG. 10 whether or not the difference between the sound and the image is due to the delay of the image. If YES is determined in the step S101, an image skip process is performed in order to recover the image delay. That is, in step S103, the Fp image frame decompression command is issued to the MPEG-4
MPEG−4コーデック34によって伸長されてバッファ34aに蓄積された伸長画像データは、1/30秒ごとに読み出されてメモリ制御回路32を通してSDRAM30のバンク(バンクAもしくはバンクB)に書き込まれる。そして、バンクに書き込まれた伸長画像データがビデオエンコーダ22によって読み出されて再生される。
The decompressed image data decompressed by the MPEG-4
しかし、ステップS103では、1/30秒を待たずに画像の伸長命令がMPEG−4コーデック34に与えられるので、バッファ34aの内容は1/30秒の間に2回更新される。そのため、SDRAM30のバンクには1フレーム分とんで伸長画像データが書き込まれる。そして、ビデオエンコーダ22はそのまま伸長画像データを読み出すので、LCD24に表示される画像は1フレーム分スキップされる。このようにして、画像を音声に追いつかせる。
However, in step S103, since the image decompression command is given to the MPEG-4
一方、ステップS101においてNOと判断すると、画像の先行を修正するために画像の表示を1フレーム分停止させる。つまり、ステップS107において、1/15秒(1/30秒の2回分)待機し、ステップS103に進む。 On the other hand, if NO is determined in step S101, the display of the image is stopped for one frame in order to correct the preceding of the image. That is, in step S107, it waits for 1/15 seconds (twice 1/30 seconds), and proceeds to step S103.
MPEG−4エンコーダ34のバッファ34aの内容は1/30秒ごとに読み出されてSDRAM30のバンクに書き込まれる。しかし、MPEG−4エンコーダ34に画像の伸長命令が与えられないまま1/30秒が経過するので、1/30秒経ってもバッファ34aの内容は更新されない。そのため、SDRAM30のバンクには前回と同じ伸長画像データがバッファ34aから読み出されて書き込まれ、バンクAとバンクBとの内容が同じになる。したがって、ビデオエンコーダ22は、バンクは異なるが前回と同じ伸長画像データをSDRAM30から読み出して再生するので、LCD24に表示される画像は見かけ上停止することになる。画像が停止している間にも音声は再生されるので、音声が画像に追いつく。
The contents of the
以上に説明したように、この実施例のビデオカメラ10においては、画像と音声とを記録するときに音声フレームに対応する画像のフィールド番号,垂直ライン位置および水平画素位置の各情報を音声フレームに付加する。そして、再生するときには、再生される音声フレームから取り出した画像フィールド番号情報,垂直ライン位置情報および水平画素位置情報と、現在再生されている画像のフィールド番号,垂直ライン位置および水平画素位置とから音声と画像との同期のずれを算出する。そして、このずれが許容範囲を超えるときには、画像を一時停止するかもしくは画像をスキップすることによってずれを修正する。したがって、従来とは異なりタイムスタンプ用の時計回路を必要とせず、簡単な回路構成によって音声と画像との同期を実現することができる。 As described above, in the video camera 10 of this embodiment, when recording an image and sound, information on the image field number, vertical line position, and horizontal pixel position corresponding to the sound frame is stored in the sound frame. Append. Then, when reproducing, the audio is obtained from the image field number information, vertical line position information and horizontal pixel position information extracted from the reproduced audio frame, and the field number, vertical line position and horizontal pixel position of the currently reproduced image. And the synchronization deviation of the image is calculated. When the deviation exceeds the allowable range, the deviation is corrected by temporarily stopping the image or skipping the image. Therefore, unlike the prior art, a clock circuit for time stamp is not required, and synchronization between sound and image can be realized with a simple circuit configuration.
10 …ビデオカメラ
16,20,26 …信号処理回路
22 …ビデオエンコーダ
30 …SDRAM
32 …メモリ制御回路
34 …MPEG−4コーデック
38 …メモリカード
40 …CPU
44 …フラッシュメモリ
46 …RAM
DESCRIPTION OF SYMBOLS 10 ...
32 ...
44 ...
Claims (10)
前記動画像信号を形成する各画面の静止画像信号をラスタ走査態様でモニタに向けて出力する第1画像出力手段、
前記第1画像出力手段によって走査されている画素位置を間欠的に検出する第1検出手段、および
前記第1検出手段によって検出された画素位置を前記第1検出手段による検出時点で前記マイクロフォンによって取り込まれた音声信号に割り当てる割り当て手段を備えることを特徴とする、ビデオカメラ。 In a video camera for recording a moving image signal of a subject photographed by an image sensor and an audio signal captured by a microphone on a recording medium,
First image output means for outputting a still image signal of each screen forming the moving image signal to a monitor in a raster scanning manner;
First detection means for intermittently detecting a pixel position scanned by the first image output means; and a pixel position detected by the first detection means is captured by the microphone at the time of detection by the first detection means. A video camera comprising assigning means for assigning to a recorded audio signal.
前記第1検出手段は前記所定量の音声信号が取り込まれる毎に前記画素位置を検出する、請求項1記載のビデオカメラ。 Encoding means for performing an encoding process for each predetermined amount prior to recording of the audio signal captured by the microphone;
2. The video camera according to claim 1, wherein the first detection unit detects the pixel position each time the predetermined amount of the audio signal is captured.
前記記録媒体から読み出された音声信号をスピーカに向けて出力する音声出力手段、
前記音声出力手段によって出力される音声信号に割り当てられた画素位置を検出する第2検出手段、
前記第2検出手段の検出時点で前記第2画像出力手段によって走査されている画素位置と前記第2検出手段によって検出された画素位置とのずれを判別する判別手段、および
前記第2画像出力手段によって出力される静止画像信号の画面数を前記判別手段の判別結果に応じて調整する調整手段をさらに備える、請求項1または2記載のビデオカメラ。 Second image output means for outputting a still image signal of each image forming a moving image signal read from the recording medium toward the monitor in the raster scanning mode;
Audio output means for outputting an audio signal read from the recording medium toward a speaker;
Second detection means for detecting a pixel position assigned to the audio signal output by the audio output means;
A discriminating unit for discriminating a deviation between a pixel position scanned by the second image output unit at the time of detection by the second detection unit and a pixel position detected by the second detection unit; and the second image output unit The video camera according to claim 1, further comprising an adjusting unit that adjusts the number of screens of the still image signal output by the unit according to a determination result of the determining unit.
前記第2画像出力手段は各画面の符号化静止画像信号を復号命令に応答して復号する復号手段を含み、
前記調整手段は前記復号命令の発生タイミングを制御する、請求項3記載のビデオカメラ。 The moving image signal is recorded on the recording medium in a state of being encoded screen by screen,
The second image output means includes decoding means for decoding the encoded still image signal of each screen in response to a decoding command;
It said adjusting means controls the generation timing of the decoded instruction, claim 3 Symbol placement of the video camera.
前記書き込み手段は前記復号手段から出力された静止画像信号を前記第1エリアおよび前記第2エリアに交互に書き込み、
前記読み出し手段は前記静止画像信号を前記第1エリアおよび前記第2エリアから交互に読み出す、請求項7記載のビデオカメラ。 The second memory includes a first area and a second area;
The writing means alternately writes the still image signal output from the decoding means to the first area and the second area,
The video camera according to claim 7, wherein the reading unit reads the still image signal alternately from the first area and the second area.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2003349524A JP4190384B2 (en) | 2003-10-08 | 2003-10-08 | Video camera |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2003349524A JP4190384B2 (en) | 2003-10-08 | 2003-10-08 | Video camera |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2005117400A JP2005117400A (en) | 2005-04-28 |
| JP4190384B2 true JP4190384B2 (en) | 2008-12-03 |
Family
ID=34541367
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2003349524A Expired - Fee Related JP4190384B2 (en) | 2003-10-08 | 2003-10-08 | Video camera |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP4190384B2 (en) |
Families Citing this family (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP4560788B2 (en) * | 2005-05-26 | 2010-10-13 | カシオ計算機株式会社 | Camera device, recording device, and program |
| CN1758772B (en) * | 2005-11-04 | 2010-05-05 | 无敌科技(西安)有限公司 | Method for synchronous playing video and audio of medium document and its system |
| JP2011199477A (en) * | 2010-03-18 | 2011-10-06 | Hitachi Kokusai Electric Inc | Video signal capturing device |
-
2003
- 2003-10-08 JP JP2003349524A patent/JP4190384B2/en not_active Expired - Fee Related
Also Published As
| Publication number | Publication date |
|---|---|
| JP2005117400A (en) | 2005-04-28 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US7705904B2 (en) | Moving-image recording device for recording moving image | |
| JP4724577B2 (en) | Imaging apparatus and control method thereof | |
| US8743227B2 (en) | Imaging apparatus and control method for reducing a load of writing image data on a recording medium | |
| JP4525561B2 (en) | Imaging apparatus, image processing method, and program | |
| JP2007318725A (en) | Camera, photographing control method of camera, program, and recording medium | |
| JP4958758B2 (en) | Recording apparatus, reproducing apparatus, recording method, reproducing method, and program | |
| CN102164242A (en) | Image capturing apparatus and image capturing control method | |
| JP2010074323A (en) | Recording apparatus and method, and recording and playback apparatus and method | |
| JP5164610B2 (en) | Imaging apparatus and control method thereof | |
| US8538247B2 (en) | Image processing apparatus and image processing method | |
| JP4252015B2 (en) | Image capturing apparatus, image reproducing apparatus, and image capturing / reproducing system | |
| JP4190384B2 (en) | Video camera | |
| JP2009272921A (en) | Moving image recording apparatus, moving image reproducing apparatus, moving image recording method, moving image reproducing method, and semiconductor integrated circuit | |
| JP2007266659A (en) | Imaging reproducing apparatus | |
| US20110043654A1 (en) | Image processing apparatus | |
| JP2005318180A (en) | Hard disk recorder and video recording apparatus | |
| JP2007043417A (en) | Image recording apparatus and method | |
| JP7374698B2 (en) | Imaging device, control method and program | |
| JP2742111B2 (en) | Video camera | |
| JP2020188415A (en) | Imaging device and its control method and program | |
| JP2015029211A (en) | Imaging device | |
| JP2005229553A (en) | Image processing apparatus | |
| JP2007228119A (en) | Imaging apparatus, image processing method, and program | |
| JP5084586B2 (en) | Image recording / reproducing apparatus and image reproducing apparatus | |
| JP2008160564A (en) | Camera device and chapter data generation method in camera device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20060831 |
|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20080527 |
|
| A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20080722 |
|
| 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: 20080819 |
|
| 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: 20080916 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20110926 Year of fee payment: 3 |
|
| LAPS | Cancellation because of no payment of annual fees |