JP2009130563A - Unit, method, and program for processing data, imaging apparatus, and method and program for controlling the same - Google Patents

Unit, method, and program for processing data, imaging apparatus, and method and program for controlling the same Download PDF

Info

Publication number
JP2009130563A
JP2009130563A JP2007302552A JP2007302552A JP2009130563A JP 2009130563 A JP2009130563 A JP 2009130563A JP 2007302552 A JP2007302552 A JP 2007302552A JP 2007302552 A JP2007302552 A JP 2007302552A JP 2009130563 A JP2009130563 A JP 2009130563A
Authority
JP
Japan
Prior art keywords
data
unit
processing
image data
output
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.)
Pending
Application number
JP2007302552A
Other languages
Japanese (ja)
Inventor
Yuji Kawamura
裕二 川村
Takeshi Yoshida
剛 吉田
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.)
Sony Corp
Original Assignee
Sony 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 Sony Corp filed Critical Sony Corp
Priority to JP2007302552A priority Critical patent/JP2009130563A/en
Publication of JP2009130563A publication Critical patent/JP2009130563A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression Of Band Width Or Redundancy In Fax (AREA)
  • Communication Control (AREA)
  • Storing Facsimile Image Data (AREA)
  • Studio Devices (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To stably transfer data compressed and coded using a variable-length code or a fixed-length code. <P>SOLUTION: An RAW compression section 54 outputs compression RAW data at a prescribed interval T<SB>int</SB>for each data unit with data length that is equal to or shorter than the burst length of an SDRAM to which the compression RAW data are written as a data unit. The compression RAW data output in the data unit from the RAW compression section 54 in this manner are supplied to a bus I/F55. When data having the burst length of the SDRAM are stored in a buffer of the bus I/F55, the data for the burst length are read from the buffer and are transferred to the SDRAM via a bus 21. The amount of transfer data transferred from the bus I/F55 to the bus 21 is smoothed, and there is no sudden occurrence of large-capacity data transfer to the bus 21 from the bus I/F55, thus relieving congestion in the bus 21. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

この発明は、動画像と静止画像とを記録可能なデータ処理装置、データ処理方法およびデータ処理プログラム、ならびに、撮像装置、撮像装置の制御方法および撮像装置の制御プログラムに関し、特に、動画像を記録しながら静止画像を記録する際に、データの転送量を分散させるようにした構成に関する。   The present invention relates to a data processing device, a data processing method and a data processing program capable of recording a moving image and a still image, and an imaging device, a control method for the imaging device, and a control program for the imaging device. The present invention relates to a configuration in which the amount of data transfer is dispersed when a still image is recorded.

一般に、静止画像の撮影を主とするディジタルスチルカメラや、動画像の撮影を主とするディジタルビデオカメラの撮像素子の走査方法は、静止画撮影と動画撮影で各々適したものが主となり、その走査方法がシステム全体に大きく関与している。近年のディジタルスチルカメラは、数100万以上の画素数を持つ撮像素子を使用しており、より高解像度な静止画像を記録するために、撮像素子からの出力として、1/30秒若しくはそれ以上の時間をかけた順次走査を行った画像信号が採用されている。また、近年では、撮像素子から出力される撮像信号をそのまま用いたRAWデータをそのまま用いることで、より高解像度の静止画像出力を実現する例も多くなっている。一方、ディジタルビデオカメラは、被写体の動解像度を上げるため、1/60秒毎の飛越走査による画像信号が採用されることが多い。   In general, the scanning method of the image sensor of digital still cameras that mainly shoot still images and digital video cameras that mainly shoot moving images is mainly suitable for still image shooting and movie shooting. The scanning method is greatly involved in the entire system. Recent digital still cameras use an image sensor having a number of pixels of several million or more. In order to record a still image with higher resolution, the output from the image sensor is 1/30 second or more. An image signal that has been sequentially scanned over a period of time is used. Further, in recent years, there are many examples in which higher-resolution still image output is realized by using RAW data using an image pickup signal output from an image pickup device as it is. On the other hand, digital video cameras often employ image signals based on interlaced scanning every 1/60 seconds in order to increase the dynamic resolution of a subject.

このように、用途に応じて撮像素子の走査方法を適宜選択する場合において、1台の撮像装置において動画像と静止画像とを並列的に記録することを考える。   As described above, in the case where the scanning method of the image sensor is appropriately selected according to the use, it is considered that a moving image and a still image are recorded in parallel in one image capturing apparatus.

例えば静止画像記録の品位を優先したシステムの場合、1/30秒毎若しくはそれ以上の順次走査による画像を用いて動画像を記録することになるため、動解像度が不足することになる。逆に、動画像記録の品位を優先したシステムの場合、静止画像を、静止画記録指示が行われた瞬間(例えばシャッタボタンを押した時点)の1枚の動画像から取得する方法が考えられる。この場合には、色差補正やガンマ補正など基本的な画質処理が動画主体となり、必ずしも静止画に適した処理が行われないおそれがある。   For example, in the case of a system that prioritizes the quality of still image recording, a moving image is recorded using an image obtained by sequential scanning every 1/30 seconds or more, so that the dynamic resolution is insufficient. Conversely, in the case of a system that prioritizes the quality of moving image recording, a method of acquiring a still image from a single moving image at the moment when a still image recording instruction is issued (for example, when the shutter button is pressed) can be considered. . In this case, basic image quality processing such as color difference correction and gamma correction is mainly for moving images, and there is a possibility that processing suitable for still images is not necessarily performed.

さらに、動画像記録と静止画像記録の両機能を、撮像素子と処理手段とを共通に用いて互いに高品位な画像取得を目的として実現しようとした場合、走査方法など撮像素子全体の動作切換が必要となってくる。その結果、例えば動画像記録の最中に、高解像度な静止画像記録の指示が行われた場合、撮像素子の制御の切り換えと撮像信号処理の動作切換とが必要となり、静止画像取得期間中は、撮像素子から出力される動画像に適した撮像信号が途切れてしまうため、動画像記録が時間的に不連続となるおそれがある。   Furthermore, when both the moving image recording function and the still image recording function are to be realized for the purpose of mutually obtaining high quality images by using the image sensor and the processing means in common, the operation of the entire image sensor such as the scanning method can be switched. It becomes necessary. As a result, for example, when a high-resolution still image recording instruction is given during moving image recording, it is necessary to switch the control of the image sensor and switch the operation of the imaging signal processing, and during the still image acquisition period Since the image pickup signal suitable for the moving image output from the image sensor is interrupted, the moving image recording may be temporally discontinuous.

この静止画記録に伴う動画像記録の不連続性を回避するための技術が、特許文献1に記載されている。この特許文献1の記載によれば、動画周期のN(N≧2)倍毎に動画像よりも高い解像度を有する撮像信号を出力することで、動画像の解像度や画質を落とすことなく高解像度な静止画を得ることを可能としている。一方、この特許文献1に記載の方法によれば、動画周期のN倍毎に静止画用の高解像度信号を出力することは、換言すれば、残りの(N−1)フレーム期間に出力される撮像信号は、動画用の解像度となってしまうことになる。
特開2002−44531号公報
A technique for avoiding the discontinuity of the moving image recording accompanying the still image recording is described in Patent Document 1. According to the description in Patent Document 1, an image pickup signal having a resolution higher than that of a moving image is output every N (N ≧ 2) times of a moving image cycle, so that high resolution can be achieved without degrading the resolution and image quality of the moving image. It is possible to obtain a still image. On the other hand, according to the method described in Patent Document 1, outputting a high-resolution signal for a still image every N times the moving image period is, in other words, output in the remaining (N−1) frame periods. Therefore, the image pickup signal has a resolution for moving images.
JP 2002-44531 A

上述の問題を回避するために、静止画記録に用いるRAWデータをメモリに一時的に保存し、動画処理後にRAWデータに対する処理(現像処理など)を行う方法が提案されている。この場合、RAWデータの保存に用いるメモリの記憶容量により記録可能な静止画像の枚数が制限されてしまうことになる。この制限を回避するために、このRAWデータをメモリに一時的に保存する場合に、動画像の記録中、例えば水平ブランキング期間や垂直ブランキング期間にメモリからRAWデータを読み出し、このRAWデータに対して現像処理など所定の処理を施す方法も提案されている。   In order to avoid the above-described problem, a method has been proposed in which RAW data used for still image recording is temporarily stored in a memory, and processing (development processing, etc.) is performed on the RAW data after moving image processing. In this case, the number of still images that can be recorded is limited by the storage capacity of the memory used for storing the RAW data. In order to avoid this limitation, when the RAW data is temporarily stored in the memory, the RAW data is read from the memory during recording of the moving image, for example, during the horizontal blanking period or the vertical blanking period, and the RAW data is stored in the RAW data. On the other hand, a method of performing a predetermined process such as a development process has also been proposed.

ここで、RAWデータに対して画質の劣化を抑えた圧縮符号化処理を施してメモリに転送し保存することで、システム全体としてメモリ帯域の増加を抑制することができる。これにより、動画記録動作中の静止画記録を、より確実に行うことが可能となる。   Here, by performing compression encoding processing with reduced image quality degradation on the RAW data and transferring and storing it in the memory, it is possible to suppress an increase in the memory bandwidth of the entire system. As a result, still image recording during the moving image recording operation can be performed more reliably.

RAWデータに施す圧縮符号化方式としては、一定量のRAWデータに対して固定長の符号を出力する方式と、可変長の符号を出力する方式とが考えられる。可変長符号を用いる方式は、固定長符号を用いる方式に比べ圧縮効率が高く、より好ましい。   As a compression encoding method applied to RAW data, a method of outputting a fixed-length code for a certain amount of RAW data and a method of outputting a variable-length code can be considered. A method using a variable length code is more preferable because it has higher compression efficiency than a method using a fixed length code.

ところが、可変長符号を用いてRAWデータの圧縮符号化を行った場合、画像の絵柄や量子化を行う際の量子化スケールなどにより圧縮率に大きな変動が発生し、単位時間当たりの符号量の分布が変動することになる。これにより、システム全体のバス帯域の総和量が保証し難くなるという問題点があった。すなわち、動画記録動作中に静止画記録を行うような場合、RAWデータの圧縮率の変動に応じてメモリ帯域の確保が困難になり、処理が破綻する可能性があるという問題点があった。   However, when RAW data is compressed and encoded using variable-length codes, the compression rate varies greatly depending on the picture pattern, quantization scale when quantizing, and the like. The distribution will fluctuate. As a result, there is a problem that it is difficult to guarantee the total amount of the bus bandwidth of the entire system. That is, when still image recording is performed during a moving image recording operation, there is a problem in that it becomes difficult to secure a memory band according to a change in the compression rate of RAW data, and processing may fail.

また、RAWデータの圧縮符号化を固定長符号を用いて行った場合であっても、動画記録動作中に静止画記録を行うような場合に圧縮RAWデータのメモリへの転送処理などを安定的に行うためには、より広いメモリ帯域、バス帯域を必要とし、装置コストが嵩んでしまうという問題点があった。   In addition, even when RAW data is compressed and encoded using a fixed-length code, the process of transferring compressed RAW data to a memory is stable when still image recording is performed during a moving image recording operation. Therefore, there is a problem that a wider memory bandwidth and bus bandwidth are required to increase the device cost.

したがって、この発明の目的は、可変長符号または固定長符号を用いて圧縮符号化されたデータを安定的に転送可能なデータ処理装置、データ処理方法およびデータ処理プログラム、ならびに、撮像装置、撮像装置の制御方法および撮像装置の制御プログラムを提供することにある。   Therefore, an object of the present invention is to provide a data processing device, a data processing method and a data processing program capable of stably transferring data compressed and encoded using a variable length code or a fixed length code, and an imaging device and an imaging device And a control program for an imaging apparatus.

上述した課題を解決するために、第1の発明は、データを第1のデータ単位でバス上に転送するデータ転送部と、データに対して所定のデータ処理を施して、第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するデータ処理部とを有し、データ処理部から出力されたデータをデータ転送部からバス上に転送することを特徴とするデータ処理装置である。   In order to solve the above-described problem, the first invention is a data transfer unit that transfers data on a bus in units of a first data, and performs predetermined data processing on the data, and the first data unit And a data processing unit that outputs data at a predetermined interval for each second data unit having a data size that is equal to or equal to the data size obtained by dividing the first data unit by an integer, and is output from the data processing unit. The data processing apparatus is characterized in that the transferred data is transferred from the data transfer unit onto the bus.

また、第2の発明は、データを第1のデータ単位でバス上に転送するデータ転送のステップと、データに対して所定のデータ処理を施して、第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するデータ処理のステップとを有し、データ処理のステップにより出力されたデータをデータ転送のステップによりバス上に転送することを特徴とするデータ処理方法である。   The second aspect of the invention is a data transfer step for transferring data on the bus in units of the first data, and whether the data size is equal to the first data unit by performing predetermined data processing on the data. Or a data processing step of outputting a predetermined interval for each second data unit having a data size obtained by dividing the first data unit by an integer, and the data output by the data processing step is A data processing method is characterized in that the data is transferred onto a bus in a data transfer step.

また、第3の発明は、データを第1のデータ単位でバス上に転送するデータ転送のステップと、データに対して所定のデータ処理を施して、第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するデータ処理のステップとを有し、データ処理のステップにより出力されたデータをデータ転送のステップによりバス上に転送するようにしたデータ処理方法をコンピュータに実行させることを特徴とするデータ処理プログラムである。   According to a third aspect of the present invention, there is provided a data transfer step of transferring data on the bus in a first data unit, and a predetermined data processing is performed on the data so that the data size is equal to the first data unit. Or a data processing step of outputting a predetermined interval for each second data unit having a data size obtained by dividing the first data unit by an integer, and the data output by the data processing step is A data processing program that causes a computer to execute a data processing method that transfers data onto a bus in a data transfer step.

また、第4の発明は、撮像素子から出力された撮像信号に基づく動画データに対する処理を行うと共に、撮像信号に基づく静止画データに対する処理を動画データの処理と並列的に行えるようにした撮像装置において、光を光電変換で電気信号に変換し撮像信号として出力する撮像部と、撮像部から出力された撮像信号に対して所定の信号処理を施し画像データとして出力する撮像信号処理部と、第1の転送要求を出力し、第1の転送要求に応じて撮像信号処理部から出力された画像データに対してフレームタイミング毎の処理を行い動画データを出力する動画データ処理部と、第2の転送要求を出力し、第2の転送要求に応じて撮像信号処理部から出力された画像データに対して所定のタイミングで処理を行い静止画データを出力する静止画データ処理部とを有し、静止画データ処理部は、撮像信号処理部から出力された画像データを圧縮符号化する圧縮符号化部と、圧縮符号化部から出力された圧縮画像データを第1のデータ単位でバス上に転送するデータ転送部とを備え、圧縮符号化部は、圧縮画像データを第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するようにしたことを特徴とする撮像装置である。   According to a fourth aspect of the present invention, there is provided an imaging apparatus that performs processing on moving image data based on an imaging signal output from an image sensor and performs processing on still image data based on the imaging signal in parallel with processing of moving image data. An imaging unit that converts light into an electrical signal by photoelectric conversion and outputs it as an imaging signal, an imaging signal processing unit that performs predetermined signal processing on the imaging signal output from the imaging unit and outputs the signal as image data; A moving image data processing unit that outputs one moving request, performs processing at each frame timing on the image data output from the imaging signal processing unit in response to the first transferring request, and outputs moving image data; A still image that outputs a transfer request, processes the image data output from the imaging signal processing unit in response to the second transfer request at a predetermined timing, and outputs still image data A still image data processing unit that compresses and encodes the image data output from the imaging signal processing unit, and the compressed image data output from the compression encoding unit is a first A data transfer unit that transfers the data on the bus in units of data, and the compression encoding unit has the same data size as the first data unit or data obtained by dividing the first data unit into integers. The image pickup apparatus is characterized in that a predetermined interval is output for each second data unit of size.

また、第5の発明は、撮像素子から出力された撮像信号に基づく動画データに対する処理を行うと共に、撮像信号に基づく静止画データに対する処理を動画データの処理と並列的に行えるようにした撮像装置の制御方法において、光を光電変換で電気信号に変換して撮像部から出力された撮像信号に対して所定の信号処理を施し画像データとして出力する撮像信号処理のステップと、第1の転送要求を出力し、第1の転送要求に応じて撮像信号処理のステップにより出力された画像データに対してフレームタイミング毎の処理を行い動画データを出力する動画データ処理のステップと、第2の転送要求を出力し、第2の転送要求に応じて撮像信号処理のステップにより出力された画像データに対して所定のタイミングで処理を行い静止画データを出力する静止画データ処理のステップとを有し、静止画データ処理のステップは、撮像信号処理のステップにより出力された画像データを圧縮符号化する圧縮符号化のステップと、圧縮符号化のステップにより出力された圧縮画像データを第1のデータ単位でバス上に転送するデータ転送のステップとを備え、圧縮符号化のステップは、圧縮画像データを第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するようにしたことを特徴とする撮像装置の制御方法である。   According to a fifth aspect of the present invention, there is provided an imaging apparatus that performs processing on moving image data based on an imaging signal output from an image sensor and performs processing on still image data based on the imaging signal in parallel with processing of moving image data. In the control method, the imaging signal processing step for converting the light into an electrical signal by photoelectric conversion and performing predetermined signal processing on the imaging signal output from the imaging unit and outputting it as image data, and a first transfer request A video data processing step for outputting video data by performing processing at each frame timing on the image data output in the imaging signal processing step in response to the first transfer request, and a second transfer request In response to the second transfer request, the image data output in the imaging signal processing step is processed at a predetermined timing, and still image data is processed. A still image data processing step, the still image data processing step comprising: a compression encoding step for compressing and encoding the image data output by the imaging signal processing step; and a compression encoding step. A data transfer step of transferring the compressed image data output by the first data unit onto the bus, wherein the compression encoding step is performed to determine whether the compressed image data has the same data size as the first data unit, or Alternatively, the control method of the imaging apparatus is characterized in that the first data unit is output with a predetermined interval for each second data unit having a data size obtained by dividing the first data unit by an integer.

また、第6の発明は、撮像素子から出力された撮像信号に基づく動画データに対する処理を行うと共に、撮像信号に基づく静止画データに対する処理を動画データの処理と並列的に行えるようにした撮像装置の制御方法をコンピュータに実行させる制御プログラムにおいて、光を光電変換で電気信号に変換して撮像部から出力された撮像信号に対して所定の信号処理を施し画像データとして出力する撮像信号処理のステップと、第1の転送要求を出力し、第1の転送要求に応じて撮像信号処理のステップにより出力された画像データに対してフレームタイミング毎の処理を行い動画データを出力する動画データ処理のステップと、第2の転送要求を出力し、第2の転送要求に応じて撮像信号処理のステップにより出力された画像データに対して所定のタイミングで処理を行い静止画データを出力する静止画データ処理のステップとを有し、静止画データ処理のステップは、撮像信号処理のステップにより出力された画像データを圧縮符号化する圧縮符号化のステップと、圧縮符号化のステップにより出力された圧縮画像データを第1のデータ単位でバス上に転送するデータ転送のステップとを備え、圧縮符号化のステップは、圧縮画像データを第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するようにした撮像装置の制御方法をコンピュータに実行させることを特徴とする撮像装置の制御プログラムである。   According to a sixth aspect of the present invention, there is provided an imaging apparatus that performs processing on moving image data based on an imaging signal output from an image sensor and performs processing on still image data based on the imaging signal in parallel with processing of moving image data. In a control program for causing a computer to execute the control method, imaging signal processing is a step of performing predetermined signal processing on the imaging signal output from the imaging unit by converting light into an electrical signal by photoelectric conversion and outputting the image data as image data And a step of moving image data processing for outputting the moving image data by outputting the first transfer request, performing the processing for each frame timing on the image data output by the imaging signal processing step in response to the first transfer request And a second transfer request, and output the image data output by the imaging signal processing step in response to the second transfer request. A still image data processing step that performs processing at a predetermined timing and outputs still image data. The still image data processing step includes a compression code that compresses and encodes the image data output in the imaging signal processing step. And a data transfer step of transferring the compressed image data output by the compression encoding step onto the bus in a first data unit. The compression encoding step includes the first step of compressing the compressed image data. A method of controlling an image pickup apparatus that outputs a predetermined interval for each second data unit having a data size equal to or equal to the data size of the first data unit or a data size obtained by dividing the first data unit by an integer 6 is a program for controlling an imaging apparatus.

上述したように、第1、第2および第3の発明は、データに対して所定のデータ処理を施して、第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力し、第1のデータ単位でバス上に転送するようにしているため、バス上に転送されるデータが分散化される。   As described above, the first, second, and third inventions perform predetermined data processing on data, and the data size is equal to the first data unit, or the first data unit is an integer. For each second data unit of the divided data size, the data is output with a predetermined interval and transferred on the bus in the first data unit, so that the data transferred on the bus is distributed. The

また、第4、第5および第6の発明は、撮像素子から出力された撮像信号に基づく動画データに対する処理を行うと共に、撮像信号に基づく静止画データに対する処理を動画データの処理と並列的に行えるようにするに当たり、光を光電変換で電気信号に変換して撮像部から出力された撮像信号に対して所定の信号処理を施し画像データとして出力し、第1の転送要求に応じて出力された画像データに対してフレームタイミング毎の処理を行い動画データを出力し、第2の転送要求に応じて出力された画像データに対して所定のタイミングで処理を行い静止画データを出力するようにされ、静止画データ処理は、画像データを圧縮符号化し、圧縮画像データを第1のデータ単位でバス上に転送し、圧縮符号化処理は、圧縮画像データを第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するようにしているため、バス上に転送される圧縮画像データが分散化され、動画データと圧縮画像データとでバスを共有する場合でも、バス上で瞬間的なアクセスの混雑が発生することが抑制される。   The fourth, fifth, and sixth inventions perform processing on moving image data based on the imaging signal output from the imaging element, and perform processing on the still image data based on the imaging signal in parallel with the processing of the moving image data. In order to be able to do this, light is converted into an electrical signal by photoelectric conversion, and a predetermined signal processing is performed on the image pickup signal output from the image pickup unit and output as image data, which is output in response to the first transfer request. The image data is processed at each frame timing to output moving image data, and the image data output in response to the second transfer request is processed at a predetermined timing to output still image data. The still image data processing compresses and encodes the image data, and transfers the compressed image data to the bus in the first data unit. The compression encoding processing converts the compressed image data to the first data The data size is equal to the data unit, or the data is output at a predetermined interval for each second data unit of the data size obtained by dividing the first data unit by an integer. Even when the compressed image data is distributed and the moving image data and the compressed image data share the bus, the occurrence of instantaneous access congestion on the bus is suppressed.

第1、第2および第3の発明は、上述したように、データに対して所定のデータ処理を施して、第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力し、第1のデータ単位でバス上に転送するようにしているため、バス上に転送されるデータが分散化される効果がある。   In the first, second and third inventions, as described above, predetermined data processing is performed on the data, and the first data unit is equal in data size, or the first data unit is an integer. For each second data unit of the divided data size, the data is output with a predetermined interval and transferred on the bus in the first data unit, so that the data transferred on the bus is distributed. There is an effect.

また、第4、第5および第6の発明は、撮像素子から出力された撮像信号に基づく動画データに対する処理を行うと共に、撮像信号に基づく静止画データに対する処理を動画データの処理と並列的に行えるようにするに当たり、光を光電変換で電気信号に変換して撮像部から出力された撮像信号に対して所定の信号処理を施し画像データとして出力し、第1の転送要求に応じて出力された画像データに対してフレームタイミング毎の処理を行い動画データを出力し、第2の転送要求に応じて出力された画像データに対して所定のタイミングで処理を行い静止画データを出力するようにされ、静止画データ処理は、画像データを圧縮符号化し、圧縮画像データを第1のデータ単位でバス上に転送し、圧縮符号化処理は、圧縮画像データを第1のデータ単位とデータサイズが等しいか、または、第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するようにしているため、バス上に転送される圧縮画像データが分散化され、動画データと圧縮画像データとでバスを共有する場合でも、バス上で瞬間的なアクセスの混雑が発生することが抑制される効果がある。   The fourth, fifth, and sixth inventions perform processing on moving image data based on the imaging signal output from the imaging element, and perform processing on the still image data based on the imaging signal in parallel with the processing of the moving image data. In order to be able to do this, light is converted into an electrical signal by photoelectric conversion, and a predetermined signal processing is performed on the image pickup signal output from the image pickup unit and output as image data, which is output in response to the first transfer request. The image data is processed at each frame timing to output moving image data, and the image data output in response to the second transfer request is processed at a predetermined timing to output still image data. The still image data processing compresses and encodes the image data, and transfers the compressed image data to the bus in the first data unit. The compression encoding processing converts the compressed image data to the first data The data size is equal to the data unit, or the data is output at a predetermined interval for each second data unit of the data size obtained by dividing the first data unit by an integer. Even when the compressed image data to be distributed is distributed and the bus is shared between the moving image data and the compressed image data, there is an effect of suppressing occurrence of instantaneous access congestion on the bus.

以下、この発明の実施の形態について説明する。先ず、理解を容易とするために、この発明に適用可能なシステムについて説明する。図1は、この発明の実施の一形態に適用可能な撮像装置1の一例の構成を示す。この撮像装置1は、光学系10を介して入射された光を撮像素子11で受光して電気信号に変換して撮像信号とし、この撮像信号を信号処理部20で、信号処理部20に接続される外部メモリであるRAM35を用いて所定に処理して記録媒体37に記録する。撮像装置1は、撮像信号を、動画データとして記録媒体37に記録すると共に、撮影指示に応じたタイミングで取り込まれた静止画データとしても、記録媒体37に記録することができるようにされている。   Embodiments of the present invention will be described below. First, for easy understanding, a system applicable to the present invention will be described. FIG. 1 shows a configuration of an example of an imaging apparatus 1 applicable to an embodiment of the present invention. In this imaging device 1, light incident through the optical system 10 is received by the imaging element 11 and converted into an electrical signal to be an imaging signal, and this imaging signal is connected to the signal processing unit 20 by the signal processing unit 20. The data is recorded on the recording medium 37 by performing predetermined processing using the RAM 35 which is an external memory. The imaging device 1 is configured to record the imaging signal as moving image data on the recording medium 37 and also to the recording medium 37 as still image data captured at a timing according to the imaging instruction. .

なお、以下では、簡単のために、撮像素子11の有効画素数を水平2560画素、垂直1920画素とする。動画は、水平および垂直方向をそれぞれ1/4に縮小した水平640画素、垂直480画素を画枠とし、静止画は、撮像素子11の有効画素をそのまま用いて、画枠を水平2560画素、垂直1920画素とする。   In the following, for the sake of simplicity, the effective pixel count of the image sensor 11 is assumed to be 2560 horizontal pixels and 1920 vertical pixels. The moving image has horizontal 640 pixels and vertical 480 pixels reduced to ¼ in the horizontal and vertical directions, respectively, and the still image uses the effective pixels of the image sensor 11 as they are, and the image frame is horizontal 2560 pixels and vertical. It is assumed that there are 1920 pixels.

光学系10は、レンズ系、絞り機構、フォーカス機構ズーム機構などを有し、後述するCPU(Central Processing Unit)30の命令に基づく駆動部13の制御やマニュアル操作などにより、絞りやフォーカス、ズームなどが制御されるようになっている。被写体からの光が光学系10を介して撮像素子11に入射される。撮像素子11は、例えばCCD(Charge Coupled Device)からなり、入射された光を光電変換により電気信号に変換し、撮像信号としてライン順次で出力する。なお、撮像素子11は、CCDに限らず、例えばCMOS(Complementary Metal-Oxide Semiconductor)イメージャを用いてもよい。   The optical system 10 includes a lens system, a diaphragm mechanism, a focus mechanism zoom mechanism, and the like, and controls a drive unit 13 based on a command of a CPU (Central Processing Unit) 30 to be described later, a manual operation, and the like to perform diaphragm, focus, zoom, and the like. Is to be controlled. Light from the subject enters the image sensor 11 through the optical system 10. The image pickup device 11 is composed of, for example, a CCD (Charge Coupled Device), converts incident light into an electric signal by photoelectric conversion, and outputs the signal as an image pickup signal in line order. The image sensor 11 is not limited to a CCD, and for example, a CMOS (Complementary Metal-Oxide Semiconductor) imager may be used.

フロントエンド(F/E)部12は、例えばノイズ抑圧部、自動利得制御部およびA/D変換部を有し、撮像素子11からアナログ信号として出力された撮像信号に対し、ノイズ抑圧部で例えば相関二重サンプリング処理を施してノイズを抑圧し、自動利得制御部でゲインを制御する。そして、A/D変換部でディジタル撮像信号に変換して出力する。このディジタル撮像信号は、撮像素子11の各画素それぞれに直接的に対応するデータからなるRAWデータである。   The front end (F / E) unit 12 includes, for example, a noise suppression unit, an automatic gain control unit, and an A / D conversion unit, and is a noise suppression unit for an imaging signal output as an analog signal from the imaging device 11. A correlated double sampling process is performed to suppress noise, and the automatic gain control unit controls the gain. Then, it is converted into a digital imaging signal by an A / D conversion unit and output. This digital image signal is RAW data composed of data directly corresponding to each pixel of the image sensor 11.

なお、後述するタイミングジェネレータ14により出力されるタイミング信号(クロックパルス)に基づき、撮像素子11が、例えばフレームタイミング毎に光電変換が行われ撮像信号が出力されるように制御されると共に、フロントエンド部12が、フレームタイミングに同期して処理が行われるように制御される。   Note that, based on a timing signal (clock pulse) output from a timing generator 14 (to be described later), the image pickup device 11 is controlled so that, for example, photoelectric conversion is performed at each frame timing and an image pickup signal is output, and the front end. The unit 12 is controlled to perform processing in synchronization with the frame timing.

信号処理部20は、カメラ信号処理部22、拡張画像処理部23、解像度変換部24、静止画コーデック(CODEC)部25、動画コーデック部26、表示制御部27、CPU30、外部インターフェイス(I/F)部33、メモリコントローラ34および記録再生制御部36の各処理ブロックを含み、これら各処理ブロックがそれぞれバス21を介して接続される。   The signal processing unit 20 includes a camera signal processing unit 22, an extended image processing unit 23, a resolution conversion unit 24, a still image codec (CODEC) unit 25, a moving image codec unit 26, a display control unit 27, a CPU 30, an external interface (I / F). ) Unit 33, memory controller 34, and recording / playback control unit 36, and these processing blocks are connected via the bus 21.

カメラ信号処理部22は、フロントエンド部12から出力されたRAWデータが入力される。カメラ信号処理部22は、入力されたRAWデータを所定に補正し、バッファメモリを利用して、クロックをセンサ駆動系のクロックから信号処理部20の内部クロックに乗せ換える。クロックが乗せ換えられたRAWデータは、後段の動画処理に適した形式のデータに変換される。   The camera signal processing unit 22 receives RAW data output from the front end unit 12. The camera signal processing unit 22 corrects the input RAW data to a predetermined value, and transfers the clock from the sensor driving system clock to the internal clock of the signal processing unit 20 using the buffer memory. The RAW data with the clock changed is converted into data in a format suitable for the subsequent moving image processing.

また、RAWデータは、静止画の記録を行う場合には、所定に圧縮符号化されバス21にも送り出される。カメラ信号処理部22は、バス21を介して供給される圧縮符号化されたRAWデータの圧縮符号を復号して伸長し、さらに後段の静止画処理に適した形式のデータに変換する。   The RAW data is compressed and encoded in a predetermined manner and sent to the bus 21 when recording a still image. The camera signal processing unit 22 decodes and decompresses the compression code of the compression-coded RAW data supplied via the bus 21, and further converts the data into a format suitable for still image processing in the subsequent stage.

カメラ信号処理部22は、さらに、ベースバンドの動画データや静止画データを拡大および/または縮小し、動画データの記録や出力画像データとして必要な解像度(サイズ)に変換する。この例では、動画データの記録のためには、撮像素子11の有効画素に従い解像度が2560画素×1920画素のデータを、解像度が640画素×480画素のデータに縮小する。静止画記録については、この例では、この段階での解像度の変換は行わない。このように解像度変換がなされたベースバンドの動画データや静止画データがカメラ信号処理部22から出力される。   The camera signal processing unit 22 further enlarges and / or reduces the baseband moving image data and still image data, and converts them into a resolution (size) necessary for recording moving image data and output image data. In this example, for recording moving image data, data with a resolution of 2560 pixels × 1920 pixels is reduced to data with a resolution of 640 pixels × 480 pixels in accordance with the effective pixels of the image sensor 11. For still image recording, in this example, resolution conversion is not performed at this stage. The baseband moving image data and still image data subjected to resolution conversion in this way are output from the camera signal processing unit 22.

ここで、ベースバンドのデータとは、例えばアナログ信号がディジタル信号に変換されたデータであり、圧縮符号化や変調などの各種処理が施されていない状態のデータを指す。この例では、撮像素子11から出力されたアナログ信号がフロントエンド部12によってディジタル信号に変換されたディジタル撮像信号のことをベースバンドのデータと適宜称する。   Here, the baseband data is, for example, data obtained by converting an analog signal into a digital signal, and indicates data that has not been subjected to various types of processing such as compression coding and modulation. In this example, a digital image pickup signal obtained by converting an analog signal output from the image pickup element 11 into a digital signal by the front end unit 12 is appropriately referred to as baseband data.

拡張画像処理部23は、例えば被写体認識処理や超高速連写など、拡張的な画像処理を行う。被写体認識処理は、例えば予め学習されたパターン辞書などを用いて、画像から顔らしき部分を抽出する。超高速連写は、通常の動画データのフレームレートの60fps(frame per second)に対し、例えば240fpsといった非常に高いフレームレートで撮像素子11における電荷読み出しおよび撮像信号の出力を行うものである。超高速連写機能では、通常の動画データに比べて高速のデータ転送能力が要求されるため、処理部を別途、設けることが好ましい。   The extended image processing unit 23 performs extended image processing such as subject recognition processing and ultra-high speed continuous shooting. In the subject recognition process, for example, a part that looks like a face is extracted from an image using a previously learned pattern dictionary or the like. The ultra high-speed continuous shooting is to read out charges from the image sensor 11 and output an image pickup signal at a very high frame rate, for example, 240 fps with respect to the frame rate of 60 fps (frame per second) of normal moving image data. Since the ultra-high speed continuous shooting function requires a higher data transfer capability than normal moving image data, it is preferable to provide a separate processing unit.

解像度変換部24は、ベースバンドの動画データや静止画データの解像度を、後述する表示装置28に表示するのに適した解像度に変換したり、記録モードに応じた解像度に変換する処理を行う。   The resolution conversion unit 24 performs processing for converting the resolution of baseband moving image data or still image data to a resolution suitable for display on the display device 28 described later, or converting the resolution to a resolution corresponding to a recording mode.

静止画コーデック部25は、ベースバンドの静止画データに対する圧縮符号化処理と、圧縮符号化された静止画データに対する復号処理とを行う。圧縮符号化方式の種類は、特に問わないが、例えばJPEG(Joint Photographic Experts Group)方式が適用される。すなわち、静止画コーデック部25は、供給された静止画データのフレームを例えば8×8画素といった所定サイズの符号化ブロックに分割し、この符号化ブロック毎にDCTを行う。そして、DCTにより得られたDCT係数を所定の量子化スケールで量子化する。量子化されたデータは、ハフマン符号化などの可変長符号化によりさらに圧縮されて出力される。静止画コーデック部25による圧縮静止画データの復号処理は、圧縮符号化処理の逆の処理を以て行われる。   The still image codec unit 25 performs compression encoding processing on baseband still image data and decoding processing on compression-encoded still image data. The type of compression encoding method is not particularly limited, but for example, a JPEG (Joint Photographic Experts Group) method is applied. That is, the still image codec unit 25 divides the supplied still image data frame into encoded blocks of a predetermined size such as 8 × 8 pixels, and performs DCT for each encoded block. Then, the DCT coefficient obtained by DCT is quantized with a predetermined quantization scale. The quantized data is further compressed and output by variable length coding such as Huffman coding. The decoding process of the compressed still image data by the still image codec unit 25 is performed by the reverse process of the compression encoding process.

動画コーデック部26は、ベースバンドの動画データに対する圧縮符号化処理と、圧縮符号化された動画データに対する復号処理とを行う。圧縮符号化方式の種類は特に問わないが、例えばMPEG2(Moving Pictures Experts Group 2)方式や、ITU−T(International Telecommunication Union-Telecommunication Standarization Sector)勧告H.264あるいはISO(International Organization for Standarization)/IEC(International Electrotechnical Commission)国際標準14496−10(MPEG−4パート10)Advanced Video Coding(以下、H.264|AVCと略称する)方式などを適用することができる。以下では、動画コーデック部26は、圧縮符号化方式としてMPEG2方式を適用するものとする。   The moving image codec unit 26 performs compression encoding processing on baseband moving image data and decoding processing on compression encoded moving image data. The type of compression coding system is not particularly limited. For example, MPEG2 (Moving Pictures Experts Group 2) system or ITU-T (International Telecommunication Union-Telecommunication Standardization Sector) recommendation H.264 or ISO (International Organization for Standarization) / IEC (International Electrotechnical Commission) International Standard 14496-10 (MPEG-4 Part 10) Advanced Video Coding (hereinafter abbreviated as H.264 | AVC) or the like can be applied. it can. In the following, it is assumed that the moving picture codec unit 26 applies the MPEG2 system as a compression encoding system.

動画コーデック部26は、例えば、供給された動画データのフレームを例えば8×8画素といった所定サイズの符号化ブロックに分割し、この符号化ブロック毎にDCTを行う。そして、DCTにより得られたDCT係数を所定の量子化スケールで量子化する。また、動画コーデック部26は、供給された動画データについて、動き補償を用いた予測符号化によるフレーム間符号化も行う。フレーム内符号化およびフレーム間符号化を施されたデータは、ハフマン符号化などの可変長符号化によりさらに圧縮されて出力される。動画コーデック部26による圧縮動画データの復号処理は、圧縮符号化処理の逆の処理を以て行われる。   For example, the moving image codec unit 26 divides a frame of the supplied moving image data into encoded blocks of a predetermined size such as 8 × 8 pixels, and performs DCT for each encoded block. Then, the DCT coefficient obtained by DCT is quantized with a predetermined quantization scale. In addition, the moving image codec unit 26 also performs interframe coding on the supplied moving image data by predictive coding using motion compensation. Data subjected to intraframe coding and interframe coding is further compressed and output by variable length coding such as Huffman coding. The decoding process of the compressed moving image data by the moving image codec unit 26 is performed by the reverse process of the compression encoding process.

表示制御部27は、供給された画像データを表示装置28に表示可能な形式の信号に変換する。表示装置28は、例えばLCD(Liquid Crystal Display)からなり、撮像装置1におけるビューファインダとして用いられると共に、記録媒体37から再生された画像のモニタとして用いられる。また、表示制御部27は、後述するCPU30から供給される命令に基づき、表示装置28に文字や図形を表示させるための表示信号を生成する。表示信号に応じた表示も、表示装置28に表示される。例えば、撮像装置1に対する各種設定を行うための設定画面や、撮像装置1の各種状態を示す表示、カーソル表示などが表示装置28に所定に表示される。   The display control unit 27 converts the supplied image data into a signal in a format that can be displayed on the display device 28. The display device 28 includes, for example, an LCD (Liquid Crystal Display), is used as a viewfinder in the imaging device 1 and is used as a monitor for an image reproduced from the recording medium 37. In addition, the display control unit 27 generates a display signal for causing the display device 28 to display characters and graphics based on a command supplied from a CPU 30 described later. A display corresponding to the display signal is also displayed on the display device 28. For example, a setting screen for performing various settings for the imaging device 1, a display indicating various states of the imaging device 1, a cursor display, and the like are displayed on the display device 28 in a predetermined manner.

CPU30に、ROM(Read Only Memory)31と入力デバイス32とが接続される。CPU30は、図示されないRAM(Random Access Memory)をワークメモリとして用い、ROM(Read Only Memory)31に予め記憶されたプログラムに従いこの撮像装置1の全体の動作を制御する。   A ROM (Read Only Memory) 31 and an input device 32 are connected to the CPU 30. The CPU 30 uses a RAM (Random Access Memory) (not shown) as a work memory, and controls the overall operation of the imaging apparatus 1 according to a program stored in advance in a ROM (Read Only Memory) 31.

例えば、CPU30は、バス21を介して信号処理部20の各部とコマンドやデータのやりとりを行い、信号処理部20の各部を制御する。また、CPU30は、上述した入力デバイス32に対する操作に応じた制御信号や撮像信号などに基づき、光学系10のフォーカス、絞り、ズームなどを制御するための制御信号を生成し、駆動部13に供給する。駆動部13は、供給された制御信号に応じて光学系10の各部の制御を行う。また、CPU30は、タイミングジェネレータ14に対して、所定のクロックパルスを出力するようにコマンドを出す。   For example, the CPU 30 exchanges commands and data with each unit of the signal processing unit 20 via the bus 21 and controls each unit of the signal processing unit 20. Further, the CPU 30 generates a control signal for controlling the focus, aperture, zoom, and the like of the optical system 10 based on a control signal or an imaging signal according to the operation on the input device 32 described above, and supplies the control signal to the drive unit 13. To do. The drive unit 13 controls each unit of the optical system 10 according to the supplied control signal. Further, the CPU 30 issues a command to the timing generator 14 so as to output a predetermined clock pulse.

タイミングジェネレータ14は、CPU30から供給されたこのコマンドに応じて、例えばフレーム同期信号や水平同期信号、垂直同期信号をといった、撮像素子11から出力された撮像信号に対する処理に必要なタイミング信号を生成する。   In response to this command supplied from the CPU 30, the timing generator 14 generates a timing signal necessary for processing the image signal output from the image sensor 11, such as a frame synchronization signal, a horizontal synchronization signal, and a vertical synchronization signal. .

入力デバイス32は、この撮像装置1を操作するために用いられる各種の操作子が設けられ、各操作子に対する操作に応じた制御信号を出力する。例えば、電源部39による電源供給のON/OFFを切り替える電源キー、撮影モードや記録モードといった撮像装置1における動作モードを切り換えるモード切り換えキー、カーソル移動のためのキーなどが設けられる。さらに、入力デバイス32には、この撮像装置1で静止画を撮影する際に用いられるシャッタボタンや、動画や静止画を撮影する際に光学系10のフォーカス、絞り、ズームなどを操作するための操作子なども設けられる。   The input device 32 is provided with various operators that are used to operate the imaging apparatus 1 and outputs a control signal corresponding to an operation on each operator. For example, a power key for switching ON / OFF of power supply by the power supply unit 39, a mode switching key for switching an operation mode in the imaging apparatus 1 such as a shooting mode and a recording mode, a key for moving a cursor, and the like are provided. Further, the input device 32 is used for operating a shutter button used when taking a still image with the imaging apparatus 1 and operating the focus, aperture, zoom, and the like of the optical system 10 when shooting a moving image or a still image. An operator or the like is also provided.

外部I/F33は、この撮像装置1と外部の機器との間でのデータのやりとりを制御する。   The external I / F 33 controls data exchange between the imaging apparatus 1 and an external device.

メモリコントローラ34に対して、RAM35が接続される。RAM35は、例えばメモリバスクロックに同期して動作するSDRAM(Synchronous Dynamic Random-Access Memory)であって、データの入出力を所定のデータ長(バースト長)単位でバースト転送により行うことができる。RAM35は、バス21に接続される各部と共用して用いられる。メモリコントローラ34は、このRAM35に対するアクセス制御を行う。バス21に接続される各処理ブロックにおいて、RAM35に対する転送要求が発生した場合には、バス21からメモリコントローラ34に対して転送要求が渡され、メモリコントローラ34は、この転送要求に従いRAM35へのアクセスを発生させる。   A RAM 35 is connected to the memory controller 34. The RAM 35 is, for example, an SDRAM (Synchronous Dynamic Random Access Memory) that operates in synchronization with a memory bus clock, and can input and output data by burst transfer in units of a predetermined data length (burst length). The RAM 35 is used in common with each unit connected to the bus 21. The memory controller 34 controls access to the RAM 35. In each processing block connected to the bus 21, when a transfer request to the RAM 35 occurs, the transfer request is passed from the bus 21 to the memory controller 34, and the memory controller 34 accesses the RAM 35 according to this transfer request. Is generated.

記録再生制御部36は、記録媒体37に対するデータの記録制御や、記録媒体37に記録されたデータの再生制御を行う。記録媒体37としては、例えば着脱可能な不揮発性メモリを用いることができる。また、記録媒体37として記録可能なタイプの光ディスクを用いることもできる。さらに、着脱可能または撮像装置1に内蔵されるハードディスクを記録媒体37として用いることもできる。勿論、記録媒体37は、従来から動画データの記録に用いられる磁気テープを適用することも可能である。   The recording / reproducing control unit 36 performs recording control of data on the recording medium 37 and reproduction control of data recorded on the recording medium 37. As the recording medium 37, for example, a removable nonvolatile memory can be used. Also, a recordable optical disc can be used as the recording medium 37. Furthermore, a removable hard disk or a built-in hard disk in the imaging apparatus 1 can be used as the recording medium 37. Of course, as the recording medium 37, a magnetic tape conventionally used for recording moving image data can be applied.

図2は、カメラ信号処理部22の一例の構成を示す。カメラ信号処理部22は、RAW補正部50、スイッチ部51、信号処理部52および解像度変換部53を有すると共に、RAW圧縮部54およびRAW伸長部56、ならびに、バスI/F55、57および58を有する。   FIG. 2 shows an example of the configuration of the camera signal processing unit 22. The camera signal processing unit 22 includes a RAW correction unit 50, a switch unit 51, a signal processing unit 52, and a resolution conversion unit 53, and includes a RAW compression unit 54 and a RAW expansion unit 56, and bus I / Fs 55, 57, and 58. Have.

バスI/F55、57および58は、RAM35のデータを一時的に溜め込むことができるバッファメモリを有する。バスI/F55、57および58は、このバッファメモリに溜め込まれたデータを読み出し、バス21に送り出すことができる。また、バスI/F55、57および58は、RAM35からバースト長単位で読み出されたデータを一時的にバッファに溜め込み、所定のタイミングで出力することができるようにされている。   The bus I / Fs 55, 57, and 58 have buffer memories that can temporarily store data in the RAM 35. The bus I / Fs 55, 57 and 58 can read out the data stored in the buffer memory and send it to the bus 21. The bus I / Fs 55, 57, and 58 are configured such that data read from the RAM 35 in units of burst lengths can be temporarily stored in a buffer and output at a predetermined timing.

RAW補正部50は、補正処理部50Aおよび同期乗り換え部50Bを有する。補正処理部50Aは、供給されたRAWデータに対して欠陥補正やレンズ補正などの各種補正処理を施すと共に、RAWデータの配列に対してデモザイク処理を施し、後段での補正処理や色変換処理に適したデータ配列に並び替える。   The RAW correction unit 50 includes a correction processing unit 50A and a synchronous transfer unit 50B. The correction processing unit 50A performs various correction processes such as defect correction and lens correction on the supplied RAW data, and also performs demosaic processing on the array of RAW data, and performs correction processing and color conversion processing at a later stage. Rearrange to a suitable data array.

同期乗り換え部50Bは、センサ駆動系のクロックをシステム系のクロックへの乗り換え処理を行う。すなわち、カメラ信号処理部22に供給されるデータは、撮像素子11の出力であって、撮像素子11から電荷を読み出す際の駆動クロックに同期している。一方、カメラ信号処理部22から出力されるデータは、信号処理部20内部のクロックに同期している必要がある。同期乗り換え部50Bは、バッファメモリを有し、センサ駆動系のクロックに従いバッファメモリに入力データを書き込んでいき、システム系のクロックに従いバッファメモリからデータを読み出す。バッファメモリからのデータ読み出しは、同期乗り換え部50Bに供給される転送要求に応じて行われる。   The synchronous transfer unit 50B performs a process of changing the sensor drive system clock to the system clock. That is, the data supplied to the camera signal processing unit 22 is an output of the image sensor 11 and is synchronized with a drive clock when reading out charges from the image sensor 11. On the other hand, the data output from the camera signal processing unit 22 needs to be synchronized with the clock inside the signal processing unit 20. The synchronous transfer section 50B has a buffer memory, writes input data to the buffer memory in accordance with the sensor drive system clock, and reads data from the buffer memory in accordance with the system clock. Data reading from the buffer memory is performed in response to a transfer request supplied to the synchronous transfer unit 50B.

信号処理部52からの転送要求Aに応じて、同期乗り換え部50BのバッファメモリからRAWデータが読み出され、スイッチ部51の一方の端子51Aを介して信号処理部52に供給される。信号処理部52は、RAWデータを後段の処理に適した形式の画像信号に変換する。例えば、信号処理部52は、RAWデータを輝度信号Yと色差信号Cb/CrとからなるY/C信号に変換する。   In response to the transfer request A from the signal processing unit 52, RAW data is read from the buffer memory of the synchronous transfer unit 50B and supplied to the signal processing unit 52 via one terminal 51A of the switch unit 51. The signal processing unit 52 converts the RAW data into an image signal in a format suitable for subsequent processing. For example, the signal processing unit 52 converts the RAW data into a Y / C signal composed of a luminance signal Y and a color difference signal Cb / Cr.

信号処理部52は、さらに、RAWデータが変換された画像信号に対してホワイトバランス処理、ガンマ補正処理、エッジ強調処理など所定の画質補正処理を施す。なお、一般的に、動画像と静止画像とでは、求められる画質が異なると考えられている。そこで、信号処理部52は、例えばCPU30の制御により、動画データに対する処理を行う場合と、静止画データに対する処理を行う場合とで、これらの画質補正処理を行う際のパラメータを切り替えることができるようにされている。   The signal processing unit 52 further performs predetermined image quality correction processing such as white balance processing, gamma correction processing, and edge enhancement processing on the image signal obtained by converting the RAW data. In general, it is considered that the required image quality differs between a moving image and a still image. Therefore, for example, the signal processing unit 52 can switch parameters for performing the image quality correction processing depending on the control of the CPU 30 depending on whether the processing is performed on moving image data or the processing on still image data. Has been.

信号処理部52で信号処理された画像信号は、解像度変換部53で例えば動作モードに応じた解像度に解像度変換され、バスI/F58からの転送要求Cに応じて、バスI/F58を介してバス21に送り出される。   The image signal subjected to signal processing by the signal processing unit 52 is resolution-converted to a resolution corresponding to, for example, the operation mode by the resolution conversion unit 53, and is transmitted via the bus I / F 58 in response to a transfer request C from the bus I / F 58. It is sent to the bus 21.

信号処理部52からの転送要求Aは、バスI/F57にも供給される。バスI/F57は、この転送要求Aに応じて所定のタイミングで、例えばバス21を介してメモリコントローラ34に対してRAM35に格納される圧縮RAWデータの読み出しを要求し、この要求に応じてRAM35から読み出され転送された圧縮RAWデータを、RAW伸長部56に供給する。RAW伸長部56は、バスI/F57を介して供給されたこの圧縮RAWデータに対し、後述するRAW圧縮部54と逆の処理により復号処理を施し、伸長する。スイッチ部51で端子51Bが選択され、RAW伸長部56の出力は、スイッチ部51の端子51Bを介して信号処理部52に供給される。   The transfer request A from the signal processing unit 52 is also supplied to the bus I / F 57. The bus I / F 57 requests the memory controller 34 to read out the compressed RAW data stored in the RAM 35 via the bus 21 at a predetermined timing in response to the transfer request A, and the RAM 35 responds to this request. The compressed RAW data read from and transferred to the RAW decompression unit 56 is supplied. The RAW expansion unit 56 performs a decoding process on the compressed RAW data supplied via the bus I / F 57 by a process reverse to that of the RAW compression unit 54 described later, and expands the data. The switch 51 selects the terminal 51 </ b> B, and the output of the RAW decompression unit 56 is supplied to the signal processing unit 52 via the terminal 51 </ b> B of the switch unit 51.

なお、信号処理部52および解像度変換部53の処理は、バスI/F58から供給される転送要求Cと、信号処理部52が出力する転送要求Aに対する応答信号に基づき行われる。すなわち、信号処理部52および解像度変換部53では、出力相手側からのデータ転送要求と、入力相手側からのデータ出力応答とが共に有効となったときに、データの転送および信号処理が行われる。   The processing of the signal processing unit 52 and the resolution conversion unit 53 is performed based on a transfer request C supplied from the bus I / F 58 and a response signal to the transfer request A output from the signal processing unit 52. That is, in the signal processing unit 52 and the resolution conversion unit 53, data transfer and signal processing are performed when both the data transfer request from the output counterpart and the data output response from the input counterpart are valid. .

バスI/F55からの転送要求Bに応じて、同期乗り換え部50BのバッファメモリからRAWデータが読み出され、RAW圧縮部54に供給される。RAW圧縮部54は、供給されたRAWデータを圧縮符号化して出力する。RAW圧縮部54では、より画質劣化の少ない圧縮符号化方式を適用すると、好ましい。   In response to the transfer request B from the bus I / F 55, RAW data is read from the buffer memory of the synchronous transfer unit 50B and supplied to the RAW compression unit 54. The RAW compression unit 54 compresses and encodes the supplied RAW data and outputs it. In the RAW compression unit 54, it is preferable to apply a compression coding method with less image quality degradation.

例えば、特開2005−311743号公報に記載されるような、ガンマ曲線に似た変換カーブに基づき変換前データをよりビット長の短い変換後のデータに対応付ける変換テーブルを作成し、この変換テーブルを参照することでデータ長を短縮して圧縮符号化を行う方法を用いることができる。また、特開2006−352509号公報に記載されるような、ガンマ曲線に似た変換カーブに基づく変換テーブルを用いた圧縮符号化方式に対し、さらにDPCM(Defferential Pulse Code Modulation)方式による圧縮符号化方式を加えた方法を用いてもよい。   For example, a conversion table that associates pre-conversion data with post-conversion data having a shorter bit length based on a conversion curve similar to a gamma curve, as described in JP-A-2005-311743, It is possible to use a method of compressing and encoding by shortening the data length by referring. In addition to the compression coding method using a conversion table based on a conversion curve similar to a gamma curve as described in Japanese Patent Application Laid-Open No. 2006-352509, compression coding by a DPCM (Defective Pulse Code Modulation) method is further performed. You may use the method which added the system.

なお、RAW圧縮部54における圧縮符号化処理は、RAWデータの転送に対してリアルタイム性を重視してなされ、例えば、撮像素子11の読み出し特性に基づきライン順次で行われる。これに限らず、RAW圧縮部54に複数ラインを格納可能なラインメモリを設け、水平8画素×垂直8画素からなるブロック単位で、静止画データを水平方向に順次走査して行うようにもできる。   Note that the compression encoding process in the RAW compression unit 54 is performed with emphasis on real-time characteristics with respect to RAW data transfer, and is performed, for example, line-sequentially based on the readout characteristics of the image sensor 11. Not limited to this, a line memory capable of storing a plurality of lines is provided in the RAW compression unit 54, and still image data can be sequentially scanned in the horizontal direction in units of blocks of 8 horizontal pixels × 8 vertical pixels. .

RAW圧縮部54で圧縮符号化された圧縮RAWデータは、バスI/F55を介してバス21に送り出される。   The compressed RAW data compression-encoded by the RAW compression unit 54 is sent to the bus 21 via the bus I / F 55.

このような構成による撮像装置1における一例の動作について、概略的に説明する。動画データの記録を主に行う動画データ記録モード時には、被写体からの光が光学系10を介して撮像素子11に入射され、光電変換により電気信号に変換され撮像信号としてフレームタイミング毎に出力される。撮像信号は、フロントエンド部12によりノイズ抑圧処理やゲイン制御などの所定の処理を施され、さらにA/D変換されてRAWデータとしてフレームタイミング毎に出力される。フロントエンド部12から出力されたRAWデータは、信号処理部20に入力され、カメラ信号処理部22に供給される。   An example of the operation of the imaging apparatus 1 having such a configuration will be schematically described. In a moving image data recording mode in which moving image data is mainly recorded, light from a subject enters the image sensor 11 via the optical system 10, is converted into an electric signal by photoelectric conversion, and is output as an image signal at each frame timing. . The imaging signal is subjected to predetermined processing such as noise suppression processing and gain control by the front end unit 12, and is further A / D converted and output as RAW data at each frame timing. The RAW data output from the front end unit 12 is input to the signal processing unit 20 and supplied to the camera signal processing unit 22.

RAWデータは、カメラ信号処理部22において、補正処理部50Aで補正処理され、同期乗り換え部50Bでセンサ駆動系クロックでバッファメモリに書き込まれる。信号処理部52から出力された転送要求Aに応じて、バッファメモリからRAWデータが読み出される。このとき、バッファメモリからのデータの読み出しがシステム系クロックに従い行われ、クロックの乗せ換えが行われる。同期乗り換え部50Bから出力されたRAWデータは、スイッチ部51を介して信号処理部52に供給され、ベースバンドの動画データに変換され、解像度変換部53で所定に解像度変換される。転送要求Cに応じて解像度変換部53から動画データが出力され、バスI/F58によりバス21に転送され、RAM35に書き込まれる。   The RAW data is corrected in the camera signal processing unit 22 by the correction processing unit 50A, and is written in the buffer memory by the synchronous transfer unit 50B with the sensor drive system clock. In response to the transfer request A output from the signal processing unit 52, RAW data is read from the buffer memory. At this time, reading of data from the buffer memory is performed according to the system clock, and clock switching is performed. The RAW data output from the synchronous transfer unit 50B is supplied to the signal processing unit 52 via the switch unit 51, converted into baseband moving image data, and the resolution conversion unit 53 performs predetermined resolution conversion. In response to the transfer request C, the moving image data is output from the resolution conversion unit 53, transferred to the bus 21 via the bus I / F 58, and written to the RAM 35.

RAM35に書き込まれた動画データは、所定にRAM35から読み出されバス21を介して解像度変換部24および動画コーデック部26に供給される。解像度変換部24は、供給された動画データの解像度を例えば表示装置28に表示するのに適した解像度に変換する。解像度変換部24で解像度が変換された動画データは、バス21を介して表示制御部37に供給され、記録モニタ画像として表示装置28に表示される。   The moving image data written in the RAM 35 is read from the RAM 35 and supplied to the resolution conversion unit 24 and the moving image codec unit 26 via the bus 21. The resolution conversion unit 24 converts the resolution of the supplied moving image data into a resolution suitable for display on the display device 28, for example. The moving image data whose resolution is converted by the resolution conversion unit 24 is supplied to the display control unit 37 via the bus 21 and is displayed on the display device 28 as a recording monitor image.

RAM35に書き込まれた動画データは、バス21を介して動画コーデック部26にも供給される。動画コーデック部26は、例えばMPEG2方式により圧縮符号化を行う。圧縮動画データは、バス21を介してメモリコントローラ34に供給され、RAM35に格納される。る。解像度変換された動画データは、バス21を介してメモリコントローラ34に供給され、RAM35に格納される。   The moving image data written in the RAM 35 is also supplied to the moving image codec unit 26 via the bus 21. The moving image codec unit 26 performs compression encoding by, for example, the MPEG2 system. The compressed moving image data is supplied to the memory controller 34 via the bus 21 and stored in the RAM 35. The The resolution-converted moving image data is supplied to the memory controller 34 via the bus 21 and stored in the RAM 35.

なお、RAM35に書き込まれた動画データをバス21を介して拡張画像処理部23に供給して所定に画像処理を施し、その後、解像度変換部24に供給するようにしてもよい。これに限らず、解像度変換部24で解像度変換された動画データをバス21を介して拡張画像処理部23に供給し、画像処理を施すようにしてもよい。   Note that the moving image data written in the RAM 35 may be supplied to the extended image processing unit 23 via the bus 21 to perform predetermined image processing, and then supplied to the resolution conversion unit 24. However, the present invention is not limited to this, and the moving image data subjected to resolution conversion by the resolution conversion unit 24 may be supplied to the extended image processing unit 23 via the bus 21 to perform image processing.

記録再生制御部36は、RAM35に所定量以上の圧縮動画データが溜め込まれると、RAM35から、例えば記録媒体37の記録単位毎に圧縮動画データを読み出し、記録媒体37に記録する。   When a predetermined amount or more of the compressed moving image data is accumulated in the RAM 35, the recording / playback control unit 36 reads the compressed moving image data from the RAM 35 for each recording unit of the recording medium 37 and records it on the recording medium 37.

動画データの記録中に静止画記録を行う場合には、先ず、例えば動画の記録中に、静止画の記録を指示するために、入力デバイス32として設けられたシャッタボタンが押下される。シャッタボタンの押下に応じた制御信号が入力デバイス32からCPU30に供給される。CPU30は、この制御信号に基づき、撮像装置1の各部を、静止画記録を行うように制御する。   When recording a still image while recording moving image data, first, for example, during recording of a moving image, a shutter button provided as the input device 32 is pressed in order to instruct recording of a still image. A control signal corresponding to the pressing of the shutter button is supplied from the input device 32 to the CPU 30. Based on this control signal, the CPU 30 controls each unit of the imaging device 1 so as to perform still image recording.

例えば、シャッタボタンが押下された直後のフレームタイミングのRAWデータに基づく静止画データが取り込まれ記録される。すなわち、カメラ信号処理部22において、シャッタボタンが押下されタイミングに対応するRAWデータに対し、補正処理部50Aで所定に補正処理を施し同期乗り換え部50Bでセンサ駆動系クロックでバッファメモリに書き込まれる。バッファメモリに書き込まれたRAWデータは、転送要求Bに応じてシステム系クロックで読み出されてクロックが乗せ換えられ、RAW圧縮部54に供給される。RAW圧縮部54で圧縮符号化された圧縮RAWデータは、バスI/F55を介してバス21に送り出され、バス21およびメモリコントローラ34を介してRAM35に格納される。   For example, still image data based on RAW data at the frame timing immediately after the shutter button is pressed is captured and recorded. That is, in the camera signal processing unit 22, the RAW data corresponding to the timing when the shutter button is pressed is subjected to a predetermined correction process by the correction processing unit 50A, and written to the buffer memory by the synchronous transfer unit 50B with the sensor drive system clock. The RAW data written in the buffer memory is read by the system clock in response to the transfer request B, the clock is changed, and is supplied to the RAW compression unit 54. The compressed RAW data compression-encoded by the RAW compression unit 54 is sent to the bus 21 via the bus I / F 55 and stored in the RAM 35 via the bus 21 and the memory controller 34.

RAM35に格納された圧縮RAWデータは、所定のタイミングでRAM35から読み出され、カメラ信号処理部22に供給される。カメラ信号処理部22に供給された圧縮RAWデータは、転送要求Aに応じてバスI/F57を介してRAW伸長部56に供給され、圧縮符号を伸長される。伸長されたRAWデータは、信号処理部52でベースバンドの静止画データに変換され、解像度変換部53で解像度変換を施され、バスI/F58を介してバス21に転送され、メモリコントローラ34を介してRAM35に書き込まれる。   The compressed RAW data stored in the RAM 35 is read from the RAM 35 at a predetermined timing and supplied to the camera signal processing unit 22. The compressed RAW data supplied to the camera signal processing unit 22 is supplied to the RAW expansion unit 56 via the bus I / F 57 in response to the transfer request A, and the compression code is expanded. The expanded RAW data is converted into baseband still image data by the signal processing unit 52, resolution-converted by the resolution conversion unit 53, transferred to the bus 21 via the bus I / F 58, and sent to the memory controller 34. To the RAM 35.

RAM35に書き込まれたRAWデータは、所定に読み出されてバス21を介して静止画コーデック部25に供給され、例えばJPEG方式に従って圧縮符号化される。圧縮静止画データは、バス21を介して記録再生制御部36に供給され、動画データの記録が行われていないタイミングで記録媒体37に記録される。圧縮静止画データを一旦RAM35に格納し、記録媒体37に対して動画データの記録が行われていないタイミングでRAM35から圧縮静止画データを読み出して記録媒体37に記録するようにしてもよい。   The RAW data written in the RAM 35 is read out in a predetermined manner, supplied to the still image codec unit 25 via the bus 21, and is compressed and encoded in accordance with, for example, the JPEG method. The compressed still image data is supplied to the recording / playback control unit 36 via the bus 21 and is recorded on the recording medium 37 at a timing when the moving image data is not recorded. The compressed still image data may be temporarily stored in the RAM 35, and the compressed still image data may be read from the RAM 35 and recorded on the recording medium 37 at a timing when moving image data is not recorded on the recording medium 37.

なお、動画データの記録中に静止画データの記録を行う場合、動画データの記録を停止させないために、カメラ信号処理部22におけるRAWデータの圧縮符号化処理や、圧縮RAWデータのRAM35に対する書き込みは、撮像素子11の出力に同期してリアルタイムに行う必要がある。   Note that when still image data is recorded during recording of moving image data, the RAW data is compressed and encoded in the camera signal processing unit 22 and the compressed RAW data is written to the RAM 35 in order not to stop recording of the moving image data. It is necessary to perform in real time in synchronization with the output of the image sensor 11.

一方、RAM35に格納された圧縮RAWデータの読み出しや、読み出されたRAWデータのカメラ信号処理部22における伸長処理および信号処理、静止画コーデック部25における圧縮符号化処理、圧縮静止画データの記録再生制御部36への供給などは、例えば撮像素子11における駆動信号のブランキング期間といった、バス21が混雑していないタイミングで行う。なお、静止画データに対する信号処理は、リアルタイム性が要求されないため、CPU30におけるソフトウェア処理や、汎用DSP(Digital Signal Processor)を用いて低速で信号処理することが可能である。   On the other hand, reading of the compressed RAW data stored in the RAM 35, decompression processing and signal processing of the read RAW data in the camera signal processing unit 22, compression encoding processing in the still image codec unit 25, recording of compressed still image data The supply to the reproduction controller 36 is performed at a timing when the bus 21 is not congested, such as a drive signal blanking period in the image sensor 11. Since signal processing for still image data does not require real-time processing, it is possible to perform signal processing at low speed using software processing in the CPU 30 or a general-purpose DSP (Digital Signal Processor).

次に、カメラ信号処理部22における処理について説明する。図3は、カメラ信号処理部22の動作モード毎のデータパスの例を示す。なお、図3において、メモリコントローラ34は、省略されている。図3Aは、動画データ記録モード時の一例のデータパスを示す。動画データ記録モードでは、撮像素子11から出力されフロントエンド部12を介してカメラ信号処理部22に供給されたRAWデータに対する動画データとしての処理と、当該動画データを表示装置28に対して表示させるモニタリング処理とが行われる。動画データ記録モードでは、これらの処理がフレームタイミング毎の処理として行われる。   Next, processing in the camera signal processing unit 22 will be described. FIG. 3 shows an example of a data path for each operation mode of the camera signal processing unit 22. In FIG. 3, the memory controller 34 is omitted. FIG. 3A shows an example data path in the moving image data recording mode. In the moving image data recording mode, processing as moving image data for the RAW data output from the image sensor 11 and supplied to the camera signal processing unit 22 via the front end unit 12 and the moving image data are displayed on the display device 28. Monitoring process is performed. In the moving image data recording mode, these processes are performed as processes for each frame timing.

動画データ記録モードでは、スイッチ部51において端子51Aが選択され、図3Aに太線で例示されるように、RAW補正部50から例えばフレームタイミング毎に出力されるRAWデータは、信号処理部52からの転送要求Aに応じてスイッチ部51を介して信号処理部52および解像度変換部53に供給される。バスI/F58からの転送要求Cに応じて解像度変換部53からデータが出力され、このデータは、バスI/F58を介してバス21に転送され、RAM35に書き込まれる。RAM35に書き込まれたデータは、バス21を介して後段の動画コーデック部26や表示制御部27に供給される。   In the moving image data recording mode, the terminal 51A is selected in the switch unit 51, and the RAW data output from the RAW correction unit 50 at each frame timing, for example, is output from the signal processing unit 52 as illustrated by a thick line in FIG. In response to the transfer request A, the signal is supplied to the signal processing unit 52 and the resolution conversion unit 53 via the switch unit 51. Data is output from the resolution converter 53 in response to a transfer request C from the bus I / F 58, and this data is transferred to the bus 21 via the bus I / F 58 and written to the RAM 35. The data written in the RAM 35 is supplied to the moving image codec unit 26 and the display control unit 27 in the subsequent stage via the bus 21.

この、動画データ記録モードにおいては、RAW補正部50での処理から、RAM35に対するデータの書き込みまでを、リアルタイムに行う必要がある。なお、ここでいうリアルタイムは、データの時間的な連続性を損ねることなく処理が可能であることをいうものとする。より具体的には、動画データの場合、フレームの連続性が損なわれることなく、データ伝送および各部におけるデータ処理が行われる場合に、リアルタイム処理が成立する。   In this moving image data recording mode, it is necessary to perform the processing from the RAW correction unit 50 to the writing of data to the RAM 35 in real time. Note that the real time here means that processing is possible without impairing temporal continuity of data. More specifically, in the case of moving image data, real-time processing is established when data transmission and data processing in each unit are performed without loss of continuity of frames.

図3Bおよび図3Cは、静止画データ記録モード時の一例のデータパスを示す。静止画データ記録モードにおいては、撮像素子11からの撮像信号読み出しに伴うデータパスと、撮像信号が変換されたRAWデータに対する信号処理を行うデータパスとで異なる。   3B and 3C show an example data path in the still image data recording mode. In the still image data recording mode, the data path for reading the imaging signal from the imaging element 11 is different from the data path for performing signal processing on the RAW data obtained by converting the imaging signal.

図3Bは、撮像信号読み出しに伴う一例のデータパスを示す。この場合、図3Bに太線で例示されるように、バスI/F55からの転送要求Bに応じてRAW補正部50からRAWデータが出力され、このRAWデータがRAW圧縮部54で所定に圧縮符号化されてバスI/F55に供給される。この圧縮RAWデータは、バスI/F55からバス21に転送され、RAM35に書き込まれる。   FIG. 3B shows an example of a data path associated with image signal readout. In this case, as illustrated by a bold line in FIG. 3B, RAW data is output from the RAW correction unit 50 in response to the transfer request B from the bus I / F 55, and the RAW compression unit 54 compresses the RAW data to a predetermined compression code. And supplied to the bus I / F 55. The compressed RAW data is transferred from the bus I / F 55 to the bus 21 and written to the RAM 35.

図3Cは、このRAM35に書き込まれた圧縮RAWデータに対する信号処理を行う際の一例のデータパスを示す。RAM35に書き込まれた圧縮RAMデータが所定に読み出される。RAM35から読み出された圧縮RAWデータは、バス21およびバスI/F57を介してRAW伸長部56に供給され、端子51Bが選択されたスイッチ部51を介して信号処理部52に供給される。RAWデータは、信号処理部52および解像度変換部53で所定に信号処理され、バスI/F58からの転送要求Cに応じて解像度変換部53から出力され、バスI/F58およびバス21を介してRAM35に再び書き込まれる。RAM35に書き込まれたRAWデータは、バス21を介して後段の静止画コーデック部25などに供給される。   FIG. 3C shows an example data path when signal processing is performed on the compressed RAW data written in the RAM 35. The compressed RAM data written in the RAM 35 is read out in a predetermined manner. The compressed RAW data read from the RAM 35 is supplied to the RAW decompression unit 56 via the bus 21 and the bus I / F 57, and is supplied to the signal processing unit 52 via the switch unit 51 in which the terminal 51B is selected. The RAW data is subjected to predetermined signal processing by the signal processing unit 52 and the resolution conversion unit 53, output from the resolution conversion unit 53 in response to the transfer request C from the bus I / F 58, and via the bus I / F 58 and the bus 21. It is written again in the RAM 35. The RAW data written in the RAM 35 is supplied to the subsequent still image codec unit 25 and the like via the bus 21.

静止画像データに対する処理は、リアルタイム性が要求されないため、RAM35からの圧縮RAWデータの読み出しは、例えばバス21やRAM35のアクセス帯域に余裕があるタイミングで行うことができる。   Since processing for still image data does not require real-time processing, reading of compressed RAW data from the RAM 35 can be performed, for example, at a timing when there is a margin in the access bandwidth of the bus 21 or RAM 35.

次に、カメラ信号処理部22における処理について、より詳細に説明する。上述したように、同期乗り換え部50Bでは、センサ駆動系のクロックに同期して入力されたRAWデータをバッファメモリに一旦格納し、このバッファメモリからの読み出しをシステム系クロックに同期させて行うことで、クロックの乗せ替えを行っている。バッファメモリは、クロック乗せ換えと、バス21における瞬間的なアクセス遅延を吸収可能な容量を、少なくとも有しているものとする。バッファメモリからの読み出しが行われない状態で、バッファメモリに対する書き込みが発生すると、バッファメモリがオーバーフローを起こし、バッファ機能が破綻することになる。   Next, the processing in the camera signal processing unit 22 will be described in more detail. As described above, the synchronous transfer unit 50B temporarily stores the RAW data input in synchronization with the clock of the sensor drive system in the buffer memory, and performs reading from the buffer memory in synchronization with the system clock. , Changing clocks. It is assumed that the buffer memory has at least a capacity capable of absorbing clock transfer and instantaneous access delay in the bus 21. If writing to the buffer memory occurs without reading from the buffer memory, the buffer memory overflows, and the buffer function fails.

このように、バッファメモリに対するRAWデータの読み書きの速度差によりバッファ破綻が発生する例としては、RAW圧縮部54で圧縮符号化された圧縮RAWデータが送り出されるバス21において、データ転送量が増大してバス21が混雑している場合が考えられる。例えばバスI/F55は、バス21が圧縮RAWデータよりも優先度が高いデータの転送で混雑している場合、例えば当該データの転送が終了するまで圧縮RAWデータをバス21に送り出す処理を待機する。若しくは、RAW圧縮部54を制御してRAWデータの圧縮処理を停止し、当該データの転送が終了しバッファメモリが空になるのを待機する。   In this way, as an example of buffer failure due to the difference in the reading / writing speed of RAW data to / from the buffer memory, the data transfer amount increases on the bus 21 to which the compressed RAW data compressed and encoded by the RAW compression unit 54 is sent out. The bus 21 may be congested. For example, when the bus 21 is congested due to transfer of data having a higher priority than the compressed RAW data, the bus I / F 55 waits for processing for sending the compressed RAW data to the bus 21 until the transfer of the data is completed, for example. . Alternatively, the RAW compression unit 54 is controlled to stop the RAW data compression process, and wait for the transfer of the data to end and the buffer memory to become empty.

また、RAW圧縮部54がRAWデータの空間周波数成分に応じて圧縮率が変動する可変長符号化を用いてRAWデータの圧縮符号化を行う場合、圧縮符号化するRAWデータの高周波成分が多ければ、圧縮符号化後のデータ量が大きくなってしまう場合が有り得る。このような場合にも、バッファ破綻が発生する可能性がある。   In addition, when the RAW compression unit 54 performs compression encoding of RAW data using variable length encoding in which the compression rate varies according to the spatial frequency component of the RAW data, if there are many high-frequency components of the RAW data to be compression encoded, In some cases, the amount of data after compression encoding becomes large. Even in such a case, a buffer failure may occur.

バッファ破綻が発生した可能性がある場合、静止画データの記録を継続するためには、RAWデータの圧縮符号化処理およびその前段の処理を停止し、バッファメモリが空になるのを待つ必要がある。前段の処理は、例えば撮像素子11からの撮像信号の出力、フロントエンド部12からのRAWデータの出力、補正処理部50Aにおける補正処理が含まれる。しかしながら、動画データの記録中に静止画データの記録が行われる場合、動画データの記録を連続的に行う必要があるため、これら前段の処理を中止することができない。   If there is a possibility that a buffer failure has occurred, in order to continue recording of still image data, it is necessary to stop the RAW data compression encoding process and the preceding process and wait for the buffer memory to become empty. is there. The preceding process includes, for example, output of an imaging signal from the image sensor 11, output of RAW data from the front end unit 12, and correction processing in the correction processing unit 50A. However, when still image data is recorded during the recording of moving image data, it is necessary to continuously record moving image data, and therefore these preceding processes cannot be stopped.

そこで、同期乗り換え部50Bがバッファメモリの状態を監視し、バッファの破綻が検知されたら、破綻処理を行う。図4は、このような処理を行うようにされた同期乗り換え部50Bの一例の構成を示す。同期乗り換え部50Bは、バッファメモリ60と、読み出し制御部61とからなる。バッファメモリ60は、先入れ先出し(FIFO:First In, First Out)制御のメモリであって、前処理側から供給される書き込みイネーブル信号を受けて、データの書き込みを行う。読み出し制御部61は、上述した転送要求Aおよび転送要求Bと、バッファメモリ60の容量とに基づきバッファメモリ60に対してデータの読み出し要求を出す。バッファメモリ60の容量は、例えばバッファメモリが満杯(フル)状態および空(エンプティ)状態の何れかを示しているのみでもよい。   Therefore, the synchronous transfer unit 50B monitors the state of the buffer memory, and performs a failure process when a buffer failure is detected. FIG. 4 shows an example of the configuration of the synchronous transfer unit 50B configured to perform such processing. The synchronous transfer unit 50B includes a buffer memory 60 and a read control unit 61. The buffer memory 60 is a first-in first-out (FIFO) control memory, and writes data in response to a write enable signal supplied from the preprocessing side. The read control unit 61 issues a data read request to the buffer memory 60 based on the transfer request A and transfer request B described above and the capacity of the buffer memory 60. The capacity of the buffer memory 60 may only indicate, for example, whether the buffer memory is full (full) or empty (empty).

読み出し制御部61は、バッファメモリ60の容量が空ではなく、且つ、転送要求Aおよび転送要求Bの双方が成立する場合に、バッファメモリ60への読み出し要求をアクティブとしてバッファメモリ60からデータを読み出し、信号処理部52およびRAW圧縮部54に対して出力する。   When the capacity of the buffer memory 60 is not empty and both the transfer request A and the transfer request B are satisfied, the read control unit 61 reads the data from the buffer memory 60 by making the read request to the buffer memory 60 active. And output to the signal processing unit 52 and the RAW compression unit 54.

ここで、読み出し制御部61は、バッファメモリ60の容量と、転送要求Aおよび転送要求Bとに基づき、バッファが破綻した可能性の有無を判断する。すなわち、バッファメモリ60の容量がフル状態であって、少なくとも転送要求Aまたは転送要求Bの何れか一方が成立しない場合に、バッファが破綻した可能性があると判断する。なお、転送要求が成立するか否かは、例えばその転送要求により行われるべき処理のタイミングに当該転送要求が読み出し制御部61に到来しているか否かで判断することが考えられる。   Here, the read control unit 61 determines whether there is a possibility that the buffer has failed based on the capacity of the buffer memory 60 and the transfer request A and the transfer request B. That is, when the capacity of the buffer memory 60 is full and at least one of the transfer request A and the transfer request B is not established, it is determined that the buffer may have failed. Whether or not the transfer request is established can be determined by determining whether or not the transfer request has arrived at the read control unit 61 at the timing of processing to be performed according to the transfer request, for example.

図5は、バッファ破綻判定の一例の処理を示すフローチャートである。先ず、ステップS100でバッファメモリ60がフル状態であるか否かが判断される。フル状態ではないと判断されれば、処理はステップS101に移行され、例えば通常のデータ転送処理がなされる。   FIG. 5 is a flowchart illustrating an example of processing for determining a buffer failure. First, in step S100, it is determined whether or not the buffer memory 60 is full. If it is determined that the state is not full, the process proceeds to step S101, and, for example, a normal data transfer process is performed.

一方、ステップS100でバッファメモリ60がフル状態であると判断されたら、処理はステップS102に移行され、転送要求Aおよび転送要求Bについて、成立の可否が判定される。転送要求Aおよび転送要求Bが共に成立すると判断されれば、処理はステップS101に移行され、通常の転送処理が行われる。   On the other hand, if it is determined in step S100 that the buffer memory 60 is full, the process proceeds to step S102, and it is determined whether transfer request A and transfer request B are established. If it is determined that both transfer request A and transfer request B are established, the process proceeds to step S101, and normal transfer processing is performed.

ステップS102で、転送要求Aまたは転送要求Bが成立しないと判断された場合には、バッファが破綻した可能性があるとされる。このとき、転送要求Aまたは転送要求Bのうち何れか一方のみが成立しないと判断された場合を、部分破綻と呼び(ステップS103)、発生要因を例えば読み出し制御部61の内部レジスタに保持する(ステップS104)。また、転送要求Aと転送要求Bとが共に成立しないと判断された場合を、完全破綻と呼び(ステップS105)、発生要因を内部レジスタに保持する(ステップS106)。CPU30は、読み出し制御部61の内部レジスタを読み出すことで、フレーム処理の単位で、部分破綻または完全破綻の何れが発生したか否かを知ることができる。   If it is determined in step S102 that transfer request A or transfer request B is not established, the buffer may have failed. At this time, when it is determined that only one of the transfer request A and the transfer request B is not established, this is called partial failure (step S103), and the cause of occurrence is held in, for example, an internal register of the read control unit 61 ( Step S104). If it is determined that neither transfer request A nor transfer request B is established, it is called complete failure (step S105), and the cause is held in the internal register (step S106). The CPU 30 can know whether partial failure or complete failure has occurred in the unit of frame processing by reading the internal register of the read control unit 61.

なお、読み出し制御部61の内部レジスタに保持される発生要因は、例えば成立しないとされた転送要求の情報を用いることができる。一例として、転送要求Aが成立しないとされ、部分破綻した可能性があるとされた場合には、転送要求Aを示す情報を、読み出し制御部61の内部レジスタに保持することが考えられる。他の例として、転送要求Aおよび転送要求Bが共に成立しないとされ、完全破綻した可能性があるとされた場合には、転送要求Aおよび転送要求Bをそれぞれ示す情報を読み出し制御部61の内部レジスタに保持することが考えられる。   For example, information on a transfer request that is not established can be used as the generation factor held in the internal register of the read control unit 61. As an example, when it is determined that the transfer request A is not established and there is a possibility that the request has partially failed, it is possible to hold information indicating the transfer request A in an internal register of the read control unit 61. As another example, when it is determined that neither transfer request A nor transfer request B is established, and there is a possibility that the request has completely failed, information indicating transfer request A and transfer request B is read out from controller 61. It can be held in an internal register.

次に、この発明の実施の一形態について説明する。先ず、図6を用いて、RAWデータの圧縮符号化方式の種別による出力レートの違いについて説明する。なお、以下では、画像データ(RAWデータ)の圧縮符号化単位に対して、決められた長さの符号が割り当てられる場合を固定長符号化と呼び、圧縮符号化単位に対して割り当てられる符号長が決められていない場合を可変長符号化と呼ぶ。圧縮符号化単位は、例えば、単一画素、隣接する複数の画素(画素ブロックなど)、1または隣接する複数のラインを構成する画素である。   Next, an embodiment of the present invention will be described. First, the difference in output rate depending on the type of RAW data compression encoding method will be described with reference to FIG. Hereinafter, a case where a code having a predetermined length is assigned to a compression coding unit of image data (RAW data) is referred to as fixed-length coding, and a code length assigned to the compression coding unit. Is determined is called variable length coding. The compression coding unit is, for example, a single pixel, a plurality of adjacent pixels (such as a pixel block), or a pixel constituting one or a plurality of adjacent lines.

RAWデータの圧縮符号化を行わず、例えばRAWデータをRAW圧縮部54を通過させただけの場合(圧縮処理スルーと呼ぶ)には、出力レートは、撮像素子11からの読み出しレートと略等価となる。RAWデータの圧縮符号化を固定長符号化で行った場合には、RAWデータを通過させただけの場合に比べ、RAWデータの圧縮率分だけ、出力レートが低下する。一方、RAWデータの圧縮符号化を可変長符号化で行った場合には、例えば圧縮符号化単位毎の画像の絵柄により割り当てられる符号量が変動するため、出力レートも、この符号化の処理に応じて変動する。   When the RAW data is not compressed and encoded, for example, when the RAW data is simply passed through the RAW compression unit 54 (referred to as compression processing through), the output rate is substantially equivalent to the read rate from the image sensor 11. Become. When compression encoding of RAW data is performed with fixed-length encoding, the output rate is reduced by the amount of RAW data compression compared to the case of only passing RAW data. On the other hand, when compression encoding of RAW data is performed by variable-length encoding, for example, the amount of code allocated varies depending on the picture pattern for each compression encoding unit, so the output rate is also included in this encoding process. Fluctuate accordingly.

なお、上述の撮像装置1のように、圧縮RAWデータを格納するための外部メモリ(RAM35)としてSDRAMを用いている場合、固定長符号化では圧縮符号化単位の固定符号長がSDRAMのバースト長を超えていたり、可変長符号化処理では符号長の変動に伴い転送レートが局所的に粗密になることが起こり得る。このような場合、最大転送レートの予測が困難となり、システム全体としてのメモリ帯域の確保や、撮像素子11からの読み出しにおけるリアルタイム性の保証が難しくなる。   When the SDRAM is used as the external memory (RAM 35) for storing the compressed RAW data as in the above-described imaging apparatus 1, in the fixed length encoding, the fixed code length of the compression encoding unit is the burst length of the SDRAM. In the variable length encoding process, the transfer rate may locally become dense with a change in the code length. In such a case, it is difficult to predict the maximum transfer rate, and it becomes difficult to ensure the memory bandwidth of the entire system and to guarantee real-time performance in reading from the image sensor 11.

そこで、この発明の実施の一形態では、圧縮符号化処理の出力を、外部メモリとして用いるSDRAMのバースト長と同一か、当該バースト長よりも短いデータ長を単位として行うようにする。すなわち、RAW圧縮部54から出力される圧縮RAWデータが書き込まれるRAM35のバースト長と等しいか、または、当該バースト長より短いデータ長をデータ単位として、RAW圧縮部54から圧縮RAWデータを出力する。こうしてRAW圧縮部54から当該データ単位で出力された圧縮RAWデータは、バスI/F55に供給され、RAM35のバースト長を単位としてバス21に転送され、RAM35に書き込まれる。   Therefore, in the embodiment of the present invention, the output of the compression encoding process is performed in units of data length that is the same as or shorter than the burst length of the SDRAM used as the external memory. That is, the compressed RAW data is output from the RAW compression unit 54 with a data length equal to or shorter than the burst length of the RAM 35 to which the compressed RAW data output from the RAW compression unit 54 is written. The compressed RAW data output from the RAW compression unit 54 in this data unit is supplied to the bus I / F 55, transferred to the bus 21 in units of the burst length of the RAM 35, and written to the RAM 35.

このように、RAM35への書き込みのためにRAW圧縮部54からバスI/F55に圧縮RAWデータを出力する際に、当該圧縮RAWデータのデータ単位をRAM35のバースト長と等しいか、または、当該バースト長より短いデータ長とすることで、バスI/F55からバス21に転送される転送データ量が平滑化される。これにより、バスI/F55からバス21に対して、突発的に大容量のデータ転送が発生することがなくなり、バス21の混雑が緩和される。したがって、上述した完全破綻や部分破綻の発生を抑制することが可能となる。   Thus, when outputting the compressed RAW data from the RAW compression unit 54 to the bus I / F 55 for writing to the RAM 35, the data unit of the compressed RAW data is equal to the burst length of the RAM 35, or the burst By setting the data length shorter than the length, the transfer data amount transferred from the bus I / F 55 to the bus 21 is smoothed. As a result, suddenly large-capacity data transfer from the bus I / F 55 to the bus 21 does not occur, and the congestion of the bus 21 is alleviated. Therefore, it is possible to suppress the occurrence of the above-mentioned complete failure or partial failure.

図7は、この発明の実施の一形態によるRAW圧縮部54の一例の構成を概略的に示す。図7の例では、RAW圧縮部54は、量子化部70、符号化部71、バッファ制御部72および符号パッキングバッファ73を有する。量子化部70は、例えばRAW補正部50から出力されたRAWデータが供給される。量子化部70は、供給されたRAWデータを所定に量子化し、連続的な値からなるデータを離散的な値のデータに変換することで、データの圧縮を行う。上述の例では、例えばRAWデータをガンマ曲線に似た変換カーブに対応付ける処理が量子化部70で行われる。   FIG. 7 schematically shows a configuration of an example of the RAW compression unit 54 according to the embodiment of the present invention. In the example of FIG. 7, the RAW compression unit 54 includes a quantization unit 70, an encoding unit 71, a buffer control unit 72, and a code packing buffer 73. The quantization unit 70 is supplied with, for example, RAW data output from the RAW correction unit 50. The quantizing unit 70 compresses the data by quantizing the supplied RAW data to a predetermined value and converting data consisting of continuous values into data having discrete values. In the above example, for example, the quantization unit 70 performs processing for associating RAW data with a conversion curve similar to a gamma curve.

符号化部71は、量子化部70でRAWデータが量子化された量子化データを、所定の規則で符号化する。上述の例では、例えば量子化部70でRAWデータをガンマ曲線に似た変換カーブに対応付ける処理の結果に基づき変換テーブルが参照され、当該処理の結果に対応する符号が出力される。この変換テーブルを、一定量のRAWデータに対して固定長の符号を出力するように構成することで、固定長符号を用いたRAWデータの圧縮符号化を行うことができる。一方、この変換テーブルを、一定量のRAWデータに対して可変長の符号を出力するように構成することで、可変長符号を用いたRAWデータの圧縮符号化を行うことができる。この場合、例えば、上述の処理の結果の統計的な頻度に基づき決められた符号長からなる変換テーブルを用いることが考えられる。   The encoding unit 71 encodes the quantized data obtained by quantizing the RAW data by the quantizing unit 70 according to a predetermined rule. In the above-described example, for example, the conversion table is referred to based on the result of the process of associating the RAW data with the conversion curve similar to the gamma curve in the quantization unit 70, and the code corresponding to the result of the process is output. By configuring this conversion table so that a fixed-length code is output for a certain amount of RAW data, it is possible to perform compression encoding of the RAW data using a fixed-length code. On the other hand, this conversion table is configured to output a variable-length code for a certain amount of RAW data, so that the RAW data can be compressed and encoded using the variable-length code. In this case, for example, it is conceivable to use a conversion table having a code length determined based on the statistical frequency of the result of the above processing.

符号パッキングバッファ73は、符号化部71で固定長または可変長で符号化された符号を一時的に溜め込む。符号パッキングバッファ73は、例えば所定容量のメモリを2面(それぞれA面、B面と呼ぶ)有し、この2面のメモリを、符号化部71側からの書き込みと、出力側(バスI/F55側)からの読み出しとで排他処理させて実現させる。符号パッキングバッファ73の各面は、例えば、少なくとも、このRAW圧縮部54から出力された圧縮RAWデータが書き込まれるRAM35のバースト長の容量を有するものとする。この例では、符号パッキングバッファ73のA面およびB面の容量を、それぞれ64バイトとしている。   The code packing buffer 73 temporarily stores the codes encoded by the encoding unit 71 with a fixed length or a variable length. The code packing buffer 73 has, for example, two memories (referred to as A-plane and B-plane, respectively) having a predetermined capacity. The two memories are written from the encoding unit 71 side and output side (bus I / O). The exclusive processing is realized by reading from the F55 side). Each surface of the code packing buffer 73 has, for example, at least a burst length capacity of the RAM 35 into which the compressed RAW data output from the RAW compression unit 54 is written. In this example, the capacity of the A side and the B side of the code packing buffer 73 is 64 bytes.

なお、符号パッキングバッファ73は、2面構成に限らず、FIFO制御のメモリにより構成することも可能である。   Note that the code packing buffer 73 is not limited to a two-plane configuration, and may be configured by a FIFO-controlled memory.

バッファ制御部72は、符号パッキングバッファ73における書き込みおよび読み出しを制御する。例えば、バッファ制御部72は、符号パッキングバッファ73に書き込まれているデータ容量を取得し、この容量に基づき符号パッキングバッファ73におけるアクセス制御を行う。例えば、バッファ制御部72は、当該容量に基づきA面およびB面の切り換えと、A面および/またはB面に対するデータの書き込みおよび読み出しのタイミングなどの制御を行う。なお、バッファのA面とB面とを切り替える動作を、バッファ面フリップと呼ぶ。   The buffer control unit 72 controls writing and reading in the code packing buffer 73. For example, the buffer control unit 72 acquires the data capacity written in the code packing buffer 73 and performs access control in the code packing buffer 73 based on this capacity. For example, the buffer control unit 72 performs control such as switching between the A side and the B side and data writing and reading timings on the A side and / or the B side based on the capacity. In addition, the operation | movement which switches the A surface and B surface of a buffer is called buffer surface flip.

また、バッファ制御部72は、バスI/F55からの転送要求に基づき符号パッキングバッファ73からのデータの読み出しを行うと共に、符号パッキングバッファ73がデータの書き込みを可能な状態であると判断した場合には、転送要求Bを出力する。一例として、バス21が混雑しているなどの要因によりバスI/F55からバッファ制御部72に対して転送要求が出力されなければ、符号パッキングバッファ73からのデータの読み出しが行われず、このとき、符号パッキングバッファ73の容量がフル状態であれば、当該符号パッキングバッファ73に対する書き込みが行えないため、転送要求Bが出力されない。   The buffer control unit 72 reads data from the code packing buffer 73 based on a transfer request from the bus I / F 55 and determines that the code packing buffer 73 is in a state where data can be written. Outputs a transfer request B. As an example, if a transfer request is not output from the bus I / F 55 to the buffer control unit 72 due to a factor such as the bus 21 being congested, data reading from the code packing buffer 73 is not performed. If the capacity of the code packing buffer 73 is full, writing to the code packing buffer 73 cannot be performed, so that the transfer request B is not output.

次に、RAWデータの圧縮符号化を固定長符号化を用いて行った場合のデータ転送制御の例を、より具体的に説明する。なお、ここでは、1画素のデータ長を16ビットとし、外部メモリ(RAM35)のバースト長を32バイトとする。また、バスI/F55は、上述したように、RAM35のバースト長単位でデータを一時的に溜め込むことができるバッファメモリを有し、このバッファメモリから読み出したデータを、バス21に対して出力する。   Next, an example of data transfer control when compression encoding of RAW data is performed using fixed-length encoding will be described more specifically. Here, the data length of one pixel is 16 bits, and the burst length of the external memory (RAM 35) is 32 bytes. Further, as described above, the bus I / F 55 has a buffer memory that can temporarily store data in units of the burst length of the RAM 35, and outputs data read from the buffer memory to the bus 21. .

図8は、圧縮処理スルーの場合における、圧縮RAWデータ転送の一例のタイミングチャートを示す。図8Aは、RAW圧縮部54の一例の出力を示し、図8Bは、バスI/F55の一例の出力を示す。バスI/F55の出力がバス21を介してRAM35に転送される。圧縮処理スルーの場合、RAW圧縮部54は、1画素毎に入力されたRAWデータをそのまま出力させる(図8A)。出力されたデータは、バスI/F55に供給される。撮像素子11において画素データの間引き処理などを行っていなければ、出力データの転送レートは、撮像素子11の読み出しレートと等価となる。バスI/F55では、供給されたデータをバッファに溜め込みむ。バッファに溜め込まれたデータは、所定に読み出されてバス21に対して出力される(図8B)。1画素のデータ長が16ビットのこの例では、16画素を単位として、RAM35に対するバースト転送が行われることになる。   FIG. 8 shows a timing chart of an example of compressed RAW data transfer in the case of compression processing through. FIG. 8A shows an example of the output of the RAW compression unit 54, and FIG. 8B shows an example of the output of the bus I / F 55. The output of the bus I / F 55 is transferred to the RAM 35 via the bus 21. In the case of compression processing through, the RAW compression unit 54 outputs the RAW data input for each pixel as it is (FIG. 8A). The output data is supplied to the bus I / F 55. When the pixel data is not thinned out in the image sensor 11, the output data transfer rate is equivalent to the readout rate of the image sensor 11. In the bus I / F 55, the supplied data is stored in a buffer. The data stored in the buffer is read out in a predetermined manner and output to the bus 21 (FIG. 8B). In this example in which the data length of one pixel is 16 bits, burst transfer to the RAM 35 is performed in units of 16 pixels.

図9は、RAW圧縮部54において、従来の方法でデータ出力を行った場合の一例のタイミングチャートを示す。ここでは、説明を容易とするために、RAW圧縮部54では、圧縮符号化単位を64画素とし、圧縮率を1/2とする。したがって、圧縮符号化単位毎に64バイト(=16ビット×64画素×1/2)の圧縮RAWデータが出力されることになる。   FIG. 9 shows an example timing chart when the RAW compression unit 54 outputs data by a conventional method. Here, for ease of explanation, the RAW compression unit 54 sets the compression encoding unit to 64 pixels and the compression rate to 1/2. Therefore, 64 bytes (= 16 bits × 64 pixels × 1/2) of compressed RAW data is output for each compression encoding unit.

RAW圧縮部54では、圧縮符号化されたRAWデータをバッファに溜め込み、64バイトの圧縮RAWデータが溜め込まれると、書き込み面と読み出し面とを切り替え、バッファから圧縮RAWデータを読み出す。読み出された圧縮RAWデータは、バスI/F55に供給される(図9A)。バスI/F55は、32バイト分の圧縮RAWデータが供給される毎に出力を行うため、図9Bに例示されるように、32バイト単位のバースト転送が2回、連続されるような動作となる。   The RAW compression unit 54 stores the compression-encoded RAW data in the buffer. When the 64-byte compressed RAW data is stored, the RAW compression unit 54 switches between the writing surface and the reading surface and reads the compressed RAW data from the buffer. The read compressed RAW data is supplied to the bus I / F 55 (FIG. 9A). Since the bus I / F 55 outputs every time 32 bytes of compressed RAW data is supplied, as illustrated in FIG. 9B, the burst transfer in units of 32 bytes is continuously performed twice. Become.

この場合、例えば図8に示した圧縮スルーの場合に比べ、RAM35を共有する他の処理を待機させる時間が増大してしまうおそれがある。また、処理を待機させられる側において、処理がメモリ帯域を確保するためのバッファを設ける必要が生じる可能性があり、この場合、装置コストの増加を招いてしまうことになる。   In this case, for example, compared with the case of the compression through shown in FIG. In addition, on the side where processing is waited, it may be necessary to provide a buffer for ensuring the memory bandwidth for processing, and in this case, the cost of the apparatus is increased.

図10および図12は、この発明の実施の一形態によるデータ転送の例を示すタイミングチャートである。図10は、圧縮符号化処理により出力されるデータ単位を、外部メモリ(RAM35)として用いるSDRAMのバースト長と同一とした場合の例である。例えば、RAW圧縮部54において、バッファに溜め込まれた圧縮RAWデータを32バイト分、読み出して出力し、所定の間隔Tintが経過したら、バッファに溜め込まれた、圧縮符号化単位の残りの32バイト分の圧縮RAWデータを読み出して出力する(図10A)。 10 and 12 are timing charts showing examples of data transfer according to the embodiment of the present invention. FIG. 10 shows an example in which the data unit output by the compression encoding process is the same as the burst length of the SDRAM used as the external memory (RAM 35). For example, the RAW compression unit 54 reads and outputs 32 bytes of compressed RAW data stored in the buffer, and when the predetermined interval T int elapses, the remaining 32 bytes of the compression encoding unit stored in the buffer The compressed RAW data for the minute is read and output (FIG. 10A).

RAW圧縮部54からの出力を、このように、RAM35のバースト長に対応するデータ長を単位として、圧縮符号化単位毎に間隔Tintを空けて行うことで、バスI/F55によるバースト転送も、図10Bに例示されるように分散的に行われる。これにより、RAM35を共有する他の処理を待機させる時間を、図9に示す転送方法に比べて短縮させることが可能となる。 As described above, the output from the RAW compression unit 54 is performed with a data length corresponding to the burst length of the RAM 35 as a unit, with an interval T int for each compression encoding unit, so that burst transfer by the bus I / F 55 is also possible. , In a distributed manner as illustrated in FIG. 10B. As a result, the time for waiting for other processes sharing the RAM 35 can be shortened compared to the transfer method shown in FIG.

図11は、図10に示した、圧縮符号化処理により出力されるデータ単位を、外部メモリとして用いるSDRAMのバースト長と同一とした場合の、RAW圧縮部54における符号パッキングバッファ73の一例の読み出し制御を示すフローチャートである。なお、初期状態において、符号パッキングバッファ73は、A面が書き込み面、B面が読み出し面とされているものとする。また、上述したように、符号パッキングバッファ73において、A面およびB面は、それぞれ64バイトの容量を有し、外部メモリ(RAM35)のバースト長は、32バイトであるものとする。   11 shows an example of the code packing buffer 73 in the RAW compression unit 54 when the data unit output by the compression encoding process shown in FIG. 10 is the same as the burst length of the SDRAM used as the external memory. It is a flowchart which shows control. In the initial state, it is assumed that the code packing buffer 73 has the A surface as a writing surface and the B surface as a reading surface. Further, as described above, in the code packing buffer 73, the A side and the B side each have a capacity of 64 bytes, and the burst length of the external memory (RAM 35) is 32 bytes.

圧縮符号化処理が、例えば撮像素子11のフレーム同期信号をトリガとして開始される。圧縮符号化処理が開始されると、符号化部71から出力された圧縮RAWデータが符号パッキングバッファ73の書き込み面に書き込まれる。この符号パッキングバッファ73に対する書き込み制御については、後述する。ステップS10で、書き込み面に書き込まれたデータ容量が64バイトに達したか否かが判断され、64バイトに達したと判断されれば、処理はステップS11に移行される。ステップS11では、符号パッキングバッファ73のバッファ面がフリップされ、それまで書き込み面だった面が新たな読み出し面とされ、読み出し面だった面が新たな書き込み面とされる。なお、新たに書き込み面とされた面には、圧縮RAWデータの書き込みが、元の書き込み面に対する書き込みに引き継がれて行われる。   The compression encoding process is started using, for example, a frame synchronization signal of the image sensor 11 as a trigger. When the compression encoding process is started, the compressed RAW data output from the encoding unit 71 is written on the writing surface of the code packing buffer 73. Write control on the code packing buffer 73 will be described later. In step S10, it is determined whether or not the capacity of the data written on the writing surface has reached 64 bytes. If it is determined that the capacity has reached 64 bytes, the process proceeds to step S11. In step S11, the buffer surface of the code packing buffer 73 is flipped, and the surface that has been the writing surface so far becomes a new reading surface, and the surface that has been the reading surface becomes a new writing surface. It should be noted that the writing of the compressed RAW data is carried over to the original writing surface on the new writing surface.

次のステップS12では、読み出し面から、外部メモリのバースト長と同一の、32バイト分の圧縮RAWデータが読み出される。読み出された圧縮RAWデータは、RAW圧縮部54から出力されバスI/F55に供給される。ステップS13で、間隔Tintだけ処理が待たれ、間隔Tintが経過したら、ステップS14で、符号パッキングバッファ73の読み出し面から、上述のステップS12で32バイト分が読み出された残りの32バイト分のデータが読み出される。 In the next step S12, 32-byte compressed RAW data that is the same as the burst length of the external memory is read from the reading surface. The read compressed RAW data is output from the RAW compression unit 54 and supplied to the bus I / F 55. In step S13, awaited is processed by a distance T int, after a lapse of the interval T int, in step S14, the reading surface of the code packing buffer 73, the remaining 32 bytes of 32 bytes in step S12 described above is read Minutes of data are read out.

そして、処理はステップS10に戻され、符号パッキングバッファ73の書き込み面に64バイト分の圧縮RAWデータが書き込まれるのが待機される。   Then, the process is returned to step S10, and it is awaited that the compressed RAW data for 64 bytes is written on the writing surface of the code packing buffer 73.

なお、間隔Tintは、バス21に対するデータの転送が分散化されるような値を選ぶのが好ましい。例えば、RAW圧縮部54に圧縮符号化単位分の画素データが供給される期間より短く、且つ、32バイト毎の出力データが連続的に出力されないような値とする。RAM35に対するバースト転送の分散化を考慮した場合、例えば、RAW圧縮部54から圧縮符号化単位分のデータが出力される期間を等分するように、間隔Tintを設定することが考えられる。より具体的な例としては、撮像素子11からの、圧縮符号化単位の1/2である32画素分の読み出し周期に相当する時間を、RAW圧縮部54を駆動するクロック周波数に換算したクロック数を設定する。 Note that the interval T int is preferably selected so that data transfer to the bus 21 is distributed. For example, it is set to a value that is shorter than the period in which the pixel data for the compression encoding unit is supplied to the RAW compression unit 54 and that the output data for every 32 bytes is not continuously output. In consideration of dispersion of burst transfer to the RAM 35, for example, it is conceivable to set the interval T int so as to equally divide the period during which data for the compression encoding unit is output from the RAW compression unit 54. As a more specific example, the number of clocks obtained by converting the time corresponding to the readout cycle of 32 pixels, which is ½ of the compression encoding unit, from the image sensor 11 into the clock frequency for driving the RAW compression unit 54. Set.

図12は、圧縮符号化処理により出力されるデータ単位を、外部メモリ(RAM35)として用いるSDRAMのバースト長よりも短くした場合の例である。圧縮符号化処理により出力されるデータ単位は、例えば外部メモリのバースト長を整数分割したサイズとされる。この図12の例では、圧縮符号化単位である64画素分、64バイト(圧縮率が1/2の場合)の圧縮RAWデータを8分割し、8バイト毎に、間隔Tintに従いRAW圧縮部54から出力するようにしている(図12A)。間隔Tintは、この例では、撮像素子11からの、圧縮符号化単位の1/8である8画素分の読み出し周期に相当する時間に基づく。 FIG. 12 shows an example in which the data unit output by the compression encoding process is shorter than the burst length of the SDRAM used as the external memory (RAM 35). The data unit output by the compression encoding process is, for example, a size obtained by dividing the burst length of the external memory by an integer. In the example of FIG. 12, the compressed RAW data of 64 pixels (in the case of a compression ratio of 1/2) for 64 pixels, which is a compression encoding unit, is divided into 8 parts, and the RAW compression unit according to the interval T int every 8 bytes. 54 is output (FIG. 12A). In this example, the interval T int is based on a time corresponding to a readout cycle of 8 pixels, which is 1/8 of the compression encoding unit, from the image sensor 11.

バスI/F55は、4バイト毎にRAW圧縮部54から供給される圧縮RAWデータをバッファに溜め込み、RAM35のバースト長に対応する32バイト分の圧縮RAWデータがバッファに溜め込まれたら、バッファから圧縮RAWデータを読み出して、RAM35に対してバースト転送する(図12B)。   The bus I / F 55 stores the compressed RAW data supplied from the RAW compression unit 54 every 4 bytes in the buffer, and compresses the compressed RAW data for 32 bytes corresponding to the burst length of the RAM 35 from the buffer. RAW data is read out and burst transferred to the RAM 35 (FIG. 12B).

この場合、RAW圧縮部54からどのような単位でデータを出力するかは、バスI/F55との接続関係や、RAW圧縮部54の符号パッキングバッファ73をFIFO制御のメモリとして構成した場合のバッファ容量などに応じて、適当に設定することができる。   In this case, the unit of data output from the RAW compression unit 54 depends on the connection relationship with the bus I / F 55 and the buffer when the code packing buffer 73 of the RAW compression unit 54 is configured as a FIFO control memory. It can be set appropriately according to the capacity.

図13は、図12に示した、圧縮符号化処理により出力されるデータ単位を、外部メモリとして用いるSDRAMのバースト長よりも短くした場合の、RAW圧縮部54における符号パッキングバッファ73の一例の読み出し制御を示すフローチャートである。なお、初期状態において、符号パッキングバッファ73は、A面が書き込み面、B面が読み出し面とされているものとする。   13 shows an example of the code packing buffer 73 in the RAW compression unit 54 when the data unit output by the compression encoding process shown in FIG. 12 is made shorter than the burst length of the SDRAM used as the external memory. It is a flowchart which shows control. In the initial state, it is assumed that the code packing buffer 73 has the A surface as a writing surface and the B surface as a reading surface.

また、ここでは、符号パッキングバッファ73において、A面およびB面は、それぞれLバイトの容量を有するものとし、圧縮符号化処理により、Mバイト単位でデータが出力されるものとする。ここで、Lバイトは、少なくとも外部メモリのバースト長分の容量とされ、Mバイトは、当該バースト長と等しいか、当該バースト長を整数分割したサイズとする。したがって、RAW圧縮部54からバスI/F55に対して、L/M=N回、データ転送を行うことで、符号パッキングバッファ73の一方のバッファ面からの読み出しが完了されることになる。   Here, in the code packing buffer 73, the A and B surfaces each have a capacity of L bytes, and data is output in units of M bytes by compression encoding processing. Here, L bytes are at least the capacity of the burst length of the external memory, and M bytes are equal to the burst length or have a size obtained by dividing the burst length by an integer. Therefore, reading from one buffer surface of the code packing buffer 73 is completed by performing data transfer L / M = N times from the RAW compression unit 54 to the bus I / F 55.

フローチャートの開始に先立って、転送回数Ctが0とされる。圧縮符号化処理が開始されると、RAWデータが圧縮された圧縮RAWデータが符号パッキングバッファ73の書き込み面に書き込まれる。ステップS20で、書き込み面に書き込まれたデータ容量がLバイトに達したか否かが判断され、Lバイトに達したと判断されれば、処理はステップS21に移行され、バッファ面がフリップされ書き込み面と読み出し面とが切り替えられる。新たに書き込み面とされた面には、圧縮RAWデータの書き込みが行われる。 Prior to the start of the flowchart, the transfer count C t is set to zero. When the compression encoding process is started, the compressed RAW data obtained by compressing the RAW data is written to the writing surface of the code packing buffer 73. In step S20, it is determined whether or not the data capacity written on the writing surface has reached L bytes. If it is determined that the data has reached L bytes, the process proceeds to step S21, and the buffer surface is flipped and written. The surface and the readout surface are switched. The compressed RAW data is written on the newly written surface.

次のステップS22では、読み出し面からMバイト分の圧縮RAWデータが読み出される。読み出された圧縮RAWデータは、RAW圧縮部54から出力されバスI/F55に供給される。ステップS23で転送回数Ctが1だけインクリメントされ、ステップS24で、間隔Tintだけ処理が待たれる。次のステップS25で、転送回数CtがN回に達したか否かが判断される。達していないと判断されれば、処理はステップS22に戻され、次のMバイト分の転送が行われ、転送回数Ctがインクリメントされ(ステップS23)、間隔Tintで待ち処理がなされる(ステップS24)。 In the next step S22, M bytes of compressed RAW data are read from the reading surface. The read compressed RAW data is output from the RAW compression unit 54 and supplied to the bus I / F 55. In step S23, the transfer count Ct is incremented by 1, and in step S24, processing is waited for the interval Tint . In the next step S25, whether the number of transfers C t has reached N times or not. If it is determined that it has not reached, the process returns to step S22, the next M bytes are transferred, the transfer count Ct is incremented (step S23), and a wait process is performed at the interval T int ( Step S24).

一方、ステップS25で、転送回数CtがN回に達したと判断されれば、処理はステップS26に移行され、転送回数Ctが0とされる。そして、処理がステップS20に戻され、符号パッキングバッファ73の書き込み面にLバイト分の圧縮RAWデータが書き込まれるのが待機される。 On the other hand, in step S25, the number of transfers C t is when it is determined that reaches N times, the processing routine advances to step S26, the number of transfers Ct is zero. Then, the process returns to step S20 to wait for L bytes of compressed RAW data to be written on the writing surface of the code packing buffer 73.

この図13のフローチャートにおいて、Lバイトを64バイトとし、Mバイトを8バイトとすれば、図12のタイミングチャートの状態に一致することになる。また、Lバイトを64バイトとし、Mバイトを32バイトとすれば、上述した図10のタイミングチャートの状態と一致し、図11のフローチャートの処理と等価となる。このように、圧縮符号化処理により出力されるデータ単位を外部メモリのバースト長と同一とした場合の例は、当該データ単位を外部メモリのバースト長よりも短くした場合の例の特別な場合であるといえる。   In the flowchart of FIG. 13, if the L byte is 64 bytes and the M byte is 8 bytes, the state of the timing chart of FIG. If the L byte is 64 bytes and the M byte is 32 bytes, it matches the state of the timing chart of FIG. 10 described above, and is equivalent to the process of the flowchart of FIG. As described above, an example in which the data unit output by the compression encoding process is the same as the burst length of the external memory is a special case of an example in which the data unit is shorter than the burst length of the external memory. It can be said that there is.

図14は、符号パッキングバッファ73に対する一例の書き込み制御を示すフローチャートである。この図14に示す処理は、図10および図11を用いて説明した、圧縮符号化処理により出力されるデータ単位を、外部メモリとして用いるSDRAMのバースト長と同一とした場合と、図12および図13を用いて説明した、当該データ単位を、外部メモリのバースト長よりも短くした場合とに共通して適用可能なものである。   FIG. 14 is a flowchart showing an example of write control for the code packing buffer 73. The processing shown in FIG. 14 is the same as the case where the data unit output by the compression encoding processing described with reference to FIGS. 10 and 11 is the same as the burst length of the SDRAM used as the external memory. This is applicable in common with the case where the data unit described with reference to 13 is shorter than the burst length of the external memory.

なお、符号パッキングバッファ73は、初期状態においてA面が書き込み面、B面が読み出し面とされているものとする。また、上述したように、符号パッキングバッファ73において、A面およびB面は、それぞれ64バイトの容量を有し、外部メモリ(RAM35)のバースト長は、32バイトであるものとする。   In the initial state of the code packing buffer 73, it is assumed that the A surface is the writing surface and the B surface is the reading surface. Further, as described above, in the code packing buffer 73, the A side and the B side each have a capacity of 64 bytes, and the burst length of the external memory (RAM 35) is 32 bytes.

量子化部70および符号化部71で圧縮符号化処理が開始されると、ステップS30で、符号パッキングバッファ73から符号化部71に対してデータの要求がなされる。例えばRAW圧縮部54において、バッファ制御部72により符号化部71に対し、圧縮符号化された圧縮RAWデータを出力するように要求される。符号化部71から出力された圧縮RAWデータは、符号パッキングバッファ73の書き込み面に書き込まれる(ステップS31)。符号パッキングバッファ73の書き込み面に書き込まれたデータ容量が所定容量、例えばバッファ面の容量上限の64バイトに達したら(ステップS32)、処理はステップS33に移行される。   When the compression coding process is started in the quantization unit 70 and the coding unit 71, a data request is made from the code packing buffer 73 to the coding unit 71 in step S30. For example, in the RAW compression unit 54, the buffer control unit 72 requests the encoding unit 71 to output the compressed and encoded compressed RAW data. The compressed RAW data output from the encoding unit 71 is written on the writing surface of the code packing buffer 73 (step S31). When the data capacity written on the writing surface of the code packing buffer 73 reaches a predetermined capacity, for example, 64 bytes, the upper limit of the capacity of the buffer surface (step S32), the process proceeds to step S33.

ステップS33では、符号パッキングバッファ73の読み出し面からのデータ読み出しが完了しているか否かが判断される。すなわち、符号パッキングバッファ73は、既に書き込み面への書き込みが所定容量、例えば64バイトに達すると、後述するようにバッファ面がフリップされ、新たに書き込み面とされた面に対するデータの書き込みが行われると共に、新たに読み出し面とされた面からのデータの読み出しが行われるように制御される。   In step S33, it is determined whether data reading from the reading surface of the code packing buffer 73 has been completed. That is, in the code packing buffer 73, when the writing to the writing surface has already reached a predetermined capacity, for example, 64 bytes, the buffer surface is flipped as will be described later, and data is written to the newly written surface. At the same time, control is performed so that data is read out from the newly designated surface.

ステップS33で、符号パッキングバッファ73の読み出し面からの読み出しが完了していると判断されれば、処理はステップS34に移行し、バッファ面がフリップされ、処理がステップS30に戻される。   If it is determined in step S33 that reading from the reading surface of the code packing buffer 73 has been completed, the process proceeds to step S34, the buffer surface is flipped, and the process returns to step S30.

一方、ステップS33で、符号パッキングバッファ73の読み出し面からの読み出しが完了してないと判断されたら、処理はステップS35に移行され、破綻処理が行われる。すなわち、符号パッキングバッファ73において、読み出し面からの読み出しが完了していなければ、バッファ面のフリップを行うことができない。一方、符号パッキングバッファ73の書き込み面に対してバッファ容量の上限までデータの書き込みが行われていれば、バッファ面をフリップする必要がある。したがって、書き込み面に対してバッファ容量の上限までデータの書き込みが行われているのに関わらず、読み出し面からの読み出しが終了していない場合、バッファ機能が破綻することになる。   On the other hand, if it is determined in step S33 that reading from the reading surface of the code packing buffer 73 has not been completed, the process proceeds to step S35, and a failure process is performed. That is, in the code packing buffer 73, if the reading from the reading surface is not completed, the buffer surface cannot be flipped. On the other hand, if data is written up to the upper limit of the buffer capacity on the writing surface of the code packing buffer 73, it is necessary to flip the buffer surface. Therefore, the buffer function is broken if the reading from the reading surface is not completed regardless of the data being written to the upper limit of the buffer capacity on the writing surface.

ステップS35では、このように、バッファ機能が破綻した場合の救済処理を行う。より具体的には、バッファ機能が破綻している間、空圧縮処理を行うと共に、空圧縮処理を行った画素のRAWデータ上の座標が所定に保持される。例えば、少なくとも空圧縮処理が開始された座標と、終了された座標とがレジスタなどに保持される。また、RAW補正部50に対する転送要求Bを、強制的に発行しながら空圧縮処理を行う。これにより、破綻位置を正確に知ることができる。さらに、バッファ機能が破綻した旨を示すフラグ(破綻フラグと呼ぶ)をレジスタなどに所定に保持する。例えばCPU30によりこの破綻フラグを読み出すことで、適切な破綻救済処理を実行可能とするものである。   In step S35, relief processing is performed when the buffer function fails in this way. More specifically, while the buffer function is broken, the empty compression process is performed, and the coordinates on the RAW data of the pixels subjected to the empty compression process are held in a predetermined manner. For example, at least the coordinates at which the empty compression process is started and the coordinates at which the empty compression process is ended are held in a register or the like. In addition, an empty compression process is performed while forcibly issuing a transfer request B to the RAW correction unit 50. Thereby, it is possible to accurately know the failure position. Further, a flag indicating that the buffer function has failed (referred to as a failure flag) is held in a predetermined register or the like. For example, the CPU 30 can read out the failure flag to execute appropriate failure relief processing.

なお、空圧縮処理は、例えば、量子化部70および符号化部71において、圧縮符号化単位毎(この例では64画素)に圧縮符号化された圧縮RAWデータを、符号パッキングバッファ73に書き込まないようにする。   In the empty compression process, for example, the compressed RAW data compression-encoded for each compression encoding unit (64 pixels in this example) in the quantization unit 70 and the encoding unit 71 is not written in the code packing buffer 73. Like that.

一例として、量子化部70および符号化部71で実際に圧縮符号化処理を行い、その結果生成された圧縮RAWデータ例えば破棄し、符号化部71から出力しないことも考えられる。すなわち、空圧縮処理により、バッファ機能の破綻から回復するまで、RAW補正部50からRAWデータを出力させると共に、当該RAWデータに応じた書き込みを符号パッキングバッファ73に対して発生させないようになされる。   As an example, it is also conceivable that the quantization unit 70 and the encoding unit 71 actually perform compression encoding processing, discard the compressed RAW data generated as a result, for example, and not output from the encoding unit 71. That is, the RAW data is output from the RAW correction unit 50 and writing according to the RAW data is not generated in the code packing buffer 73 until recovery from the failure of the buffer function by the empty compression process.

これに限らず、空圧縮処理は、RAW圧縮部54において、供給されたRAWデータに対して何ら処理を行わないようにしてもよい。この場合、例えば当該RAWデータを破棄し、圧縮符号化を行った旨を示すステータスのみを所定に出力することが考えられる。   However, the RAW compression unit 54 may not perform any processing on the supplied RAW data. In this case, for example, it may be possible to discard the RAW data and output only a status indicating that compression encoding has been performed.

ステップS35で破綻処理が行われると、次のステップS36で符号パッキングバッファ73の読み出し面からの読み出しが完了したか否かが判断される。完了していないと判断されれば、処理はステップS35に戻される。一方、読み出しが完了したと判断されたら、処理はステップS37に移行され、符号パッキングバッファ73の書き込み面に対し、空圧縮処理が行われた画素に対応する位置に、当該位置で破綻処理が行われたことを示す破綻コードが挿入される。そして、処理がステップS30に戻される。   When the failure processing is performed in step S35, it is determined in the next step S36 whether or not reading from the reading surface of the code packing buffer 73 is completed. If it is determined that the process has not been completed, the process returns to step S35. On the other hand, if it is determined that the reading has been completed, the process proceeds to step S37, and the failure processing is performed at the position corresponding to the pixel on which the empty compression processing has been performed on the writing surface of the code packing buffer 73. A broken code indicating that it has been broken is inserted. Then, the process returns to step S30.

なお、1フレームの画像について、データの総転送量が符号パッキングバッファ73の各面の容量(この例では64バイト)の倍数ではない場合には、符号パッキングバッファ73への1フレームの画像の最終符号が書き込まれたことを検知し、所定に圧縮符号化動作を終了させる。すなわち、RAW圧縮部54は、1フレームの画像の最終のRAWデータが符号パッキングバッファ73に書き込まれたことを検知したら、符号パッキングバッファ73の読み出し面からのデータの読み出しが完了するのを待って、バッファ面のフリップを強制的に行い、新たな読み出し面からデータを全て読み出し、圧縮符号化動作を終了させるようにする。   If the total transfer amount of data for one frame image is not a multiple of the capacity of each side of the code packing buffer 73 (in this example, 64 bytes), the final image of one frame to the code packing buffer 73 will be described. It is detected that the code has been written, and the compression encoding operation is terminated in a predetermined manner. That is, when the RAW compression unit 54 detects that the final RAW data of one frame image has been written in the code packing buffer 73, it waits for the completion of reading of data from the reading surface of the code packing buffer 73. The buffer plane is forcibly flipped to read all the data from the new read plane and finish the compression encoding operation.

1フレームの画像の最終符号を検知する方法は、様々に考えられる。一例として、RAW圧縮部54がRAW補正部50から供給されるRAWデータの数を計測し、計測されたRAWデータの数に基づき1フレームの画像の最終符号を判断することができる。計測は、例えばフレームパルスを基準として行うことが考えられる。他の例として、RAW補正部50において1フレームの画像の最終のRAWデータを出力しRAW圧縮部54に供給する際に、当該RAWデータが1フレームの最終データである旨をRAW圧縮部54に通知するようにもできる。   There are various methods for detecting the final code of an image of one frame. As an example, the RAW compression unit 54 can measure the number of RAW data supplied from the RAW correction unit 50 and determine the final code of an image of one frame based on the measured number of RAW data. For example, the measurement may be performed using a frame pulse as a reference. As another example, when the RAW correction unit 50 outputs the final RAW data of an image of one frame and supplies it to the RAW compression unit 54, the RAW compression unit 54 indicates that the RAW data is the final data of one frame. It can also be notified.

上述のステップS33において、符号パッキングバッファ73に対する最初の書き込みの場合には、読み出し面に読み出すべきデータが未だ書き込まれていない状態となっている。したがって、この、最初の書き込み時にはステップS33での判断処理を省略して、ステップS32からステップS34に直接的に処理を移行させる。   In the above-described step S33, in the case of the first writing to the code packing buffer 73, the data to be read is not yet written on the reading surface. Therefore, at the time of the first writing, the determination process in step S33 is omitted, and the process is directly transferred from step S32 to step S34.

次に、この発明の実施の一形態の変形例について説明する。上述の実施の一形態では、RAW圧縮部54で、固定長符号を用いてRAWデータの圧縮符号化を行っていた。これに対し、この実施の一形態の変形例は、RAW圧縮部54で、可変長符号を用いてRAWデータの圧縮符号化を行う場合の例である。   Next, a modification of the embodiment of the present invention will be described. In the above-described embodiment, the RAW compression unit 54 performs compression encoding of RAW data using a fixed-length code. On the other hand, the modification of this embodiment is an example in which the RAW compression unit 54 performs compression encoding of RAW data using a variable length code.

図15は、RAW圧縮部54において可変長符号を用いて圧縮符号化を行い、従来の方法でデータ出力を行った場合の一例のタイミングチャートを示す。上述と同様に、RAW圧縮部54では、圧縮符号化単位を64画素とし、圧縮率を1/2とする。したがって、圧縮符号化単位毎に64バイト(=16ビット×64画素×1/2)の圧縮RAWデータが出力されることになる。   FIG. 15 is a timing chart showing an example of the case where the RAW compression unit 54 performs compression encoding using a variable length code and outputs data by a conventional method. Similarly to the above, the RAW compression unit 54 sets the compression encoding unit to 64 pixels and the compression rate to 1/2. Therefore, 64 bytes (= 16 bits × 64 pixels × 1/2) of compressed RAW data is output for each compression encoding unit.

図15Aは、可変長符号を用いて圧縮符号化を行った場合に、圧縮符号化単位(この例では64画素)で圧縮符号化された圧縮RAWデータが、データサイズおよび出力タイミングが変動されながら、RAW圧縮部54から出力される様子を示している。   FIG. 15A shows a case where compressed RAW data compressed and encoded in a compression encoding unit (64 pixels in this example) is subjected to compression encoding using a variable length code while the data size and output timing are changed. , The state output from the RAW compression unit 54 is shown.

バスI/F55は、32バイト分の圧縮RAWデータが供給される毎に出力を行うため、図15Bに一例が示されるように、32バイト単位のバースト転送が、供給される圧縮RAWデータのデータサイズに応じた回数だけ連続されるように行われる。図15Bの例では、30バイトの圧縮RAWデータに対して1回のバースト転送がなされ、40バイトの圧縮RAWデータに対して2回のバースト転送が連続的に行われる。また、120バイトの圧縮RAWデータに対して4回のバースト転送が連続的に行われ、130バイトの圧縮RAWデータに対して5回のバースト転送が連続的に行われる。   Since the bus I / F 55 outputs data every time 32 bytes of compressed RAW data is supplied, as shown in an example in FIG. It is performed so as to be continued a number of times according to the size. In the example of FIG. 15B, one burst transfer is performed for 30-byte compressed RAW data, and two burst transfers are continuously performed for 40-byte compressed RAW data. Further, four burst transfers are continuously performed on the 120-byte compressed RAW data, and five burst transfers are continuously performed on the 130-byte compressed RAW data.

このように、可変長符号を用いて圧縮符号化を行った場合には、絵柄などに応じて圧縮符号化単位で圧縮率が変動し、外部メモリへのデータの転送密度も変動する。圧縮率が悪くなると、外部メモリへのデータ転送によるアクセスが密となる期間と、疎となる期間との差が大きくなり、外部メモリのメモリ帯域を確保することが難しくなる。   As described above, when compression encoding is performed using a variable-length code, the compression rate varies in units of compression encoding according to the design and the like, and the transfer density of data to the external memory also varies. When the compression ratio is deteriorated, a difference between a period when access due to data transfer to the external memory is dense and a period when the access is sparse becomes large, and it becomes difficult to secure a memory bandwidth of the external memory.

図16および図17は、この発明の実施の一形態の変形例による、RAW圧縮部54におけるデータ出力の例を示すタイミングチャートである。図16は、図10を用いて説明したのと同様に、圧縮符号化により出力されるデータ単位を、外部メモリ(RAM35)として用いるSDRAMのバースト長と同一とした場合の例である。   16 and 17 are timing charts showing an example of data output in the RAW compression unit 54 according to a modification of the embodiment of the present invention. FIG. 16 shows an example in which the data unit output by compression encoding is the same as the burst length of the SDRAM used as the external memory (RAM 35), as described with reference to FIG.

RAW圧縮部54では、可変長符号を用いて圧縮符号化した圧縮RAWデータを、既に図14のフローチャートを用いて説明した処理に従い、64バイト毎に符号パッキングバッファ73のA面およびB面に書き込み、図11または図13のフローチャートを用いて説明した処理に従い、符号パッキングバッファ73のA面およびB面から、RAM35のバースト長に対応して32バイト毎に、間隔Tintに従い読み出す(図15A)。バスI/F55は、このRAW圧縮部54から32バイト毎に、間隔Tintを空けて供給される圧縮RAWデータを、バースト長である32バイト毎にRAM35にバースト転送する(図15B)。 In the RAW compression unit 54, the compressed RAW data compressed and encoded using the variable length code is written to the A and B surfaces of the code packing buffer 73 every 64 bytes in accordance with the process already described with reference to the flowchart of FIG. In accordance with the processing described with reference to the flowchart of FIG. 11 or FIG. 13, data is read from the A and B surfaces of the code packing buffer 73 every 32 bytes corresponding to the burst length of the RAM 35 according to the interval T int (FIG. 15A). . Bus I / F55 from the RAW compression unit 54 every 32 bytes, the compressed RAW data supplied at intervals T int, burst transfers to RAM35 every 32 bytes is a burst length (Figure 15B).

したがって、図15Bに例示されるように、RAM35へのデータ転送によるアクセスを、バースト長の単位で分散させることができる。またこのとき、間隔Tintにより、RAM35に対する最短のアクセス間隔を定義することができる。そのため、システム全体としてのメモリ帯域の保証が容易となる。またこれにより、メモリアクセスの集中を防止できるので、ピーク電流を抑制することも可能となる。 Therefore, as illustrated in FIG. 15B, access by data transfer to the RAM 35 can be distributed in units of burst length. At this time, the shortest access interval to the RAM 35 can be defined by the interval T int . Therefore, it becomes easy to guarantee the memory bandwidth of the entire system. This can also prevent concentration of memory access, so that peak current can be suppressed.

図17は、図12を用いて説明したのと同様に、圧縮符号化処理により出力されるデータ単位を、外部メモリ(RAM35)として用いるSDRAMのバースト長よりも短くした場合の例である。この図17の例では、図12と同様に、圧縮符号化単位である64画素分、64バイトの圧縮RAWデータを8分割し、8バイト毎に、間隔Tintに従いRAW圧縮部54から出力するようにしている。 FIG. 17 shows an example in which the data unit output by the compression encoding process is made shorter than the burst length of the SDRAM used as the external memory (RAM 35), as described with reference to FIG. In the example of FIG. 17, similarly to FIG. 12, 64 bytes of compressed RAW data for 64 pixels, which are compression coding units, are divided into 8 and output from the RAW compression unit 54 at intervals of 8 bytes according to the interval T int. I am doing so.

すなわちRAW圧縮部54では、可変長符号を用いて圧縮符号化した圧縮RAWデータを、既に図14のフローチャートを用いて説明した処理に従い、64バイト毎に符号パッキングバッファ73のA面およびB面に書き込み、図13のフローチャートを用いて説明した処理に従い、符号パッキングバッファ73のA面およびB面から、8バイト毎に、間隔Tintに従い読み出す(図17A)。バスI/F55は、このRAW圧縮部54から8バイト毎に、間隔Tintを空けて供給される圧縮RAWデータをバッファに溜め込み、RAM35のバースト長に対応する32バイト分の圧縮RAWデータがバッファに溜め込まれたら、バッファから圧縮RAWデータを読み出して、RAM35に対してバースト転送する(図17B)。 That is, in the RAW compression unit 54, the compressed RAW data compressed and encoded using the variable length code is applied to the A side and the B side of the code packing buffer 73 every 64 bytes according to the process already described with reference to the flowchart of FIG. In accordance with the processing described with reference to the flowchart of FIG. 13, the data is read from the A and B surfaces of the code packing buffer 73 every 8 bytes according to the interval T int (FIG. 17A). The bus I / F 55 stores compressed RAW data supplied from the RAW compression unit 54 with an interval T int every 8 bytes in a buffer, and 32 bytes of compressed RAW data corresponding to the burst length of the RAM 35 is buffered. Then, the compressed RAW data is read from the buffer and burst transferred to the RAM 35 (FIG. 17B).

この場合でも、図16を用いて説明した、圧縮符号化により出力されるデータ単位を外部メモリのバースト長と同一とした場合同様に、RAM35へのデータ転送によるアクセスを、バースト長の単位で分散させることができる。またこのとき、間隔Tintにより、RAM35に対する最短のアクセス間隔を定義することができる。そのため、システム全体としてのメモリ帯域の保証が容易となる。またこれにより、メモリアクセスの集中を防止できるので、ピーク電流を抑制することも可能となる。 Even in this case, as in the case where the data unit output by compression encoding described with reference to FIG. 16 is the same as the burst length of the external memory, the access by the data transfer to the RAM 35 is distributed in units of the burst length. Can be made. At this time, the shortest access interval to the RAM 35 can be defined by the interval T int . Therefore, it becomes easy to guarantee the memory bandwidth of the entire system. This can also prevent concentration of memory access, so that peak current can be suppressed.

発明の実施の一形態に適用可能な撮像装置の一例の構成を示すブロック図である。It is a block diagram which shows the structure of an example of the imaging device applicable to one Embodiment of invention. カメラ信号処理部の一例の構成を示すブロック図である。It is a block diagram which shows the structure of an example of a camera signal processing part. カメラ信号処理部の動作モード毎のデータパスの例を示す略線図である。It is a basic diagram which shows the example of the data path for every operation mode of a camera signal processing part. 同期乗り換え部の一例の構成を示すブロック図である。It is a block diagram which shows the structure of an example of a synchronous transfer part. バッファ破綻判定の一例の処理を示すフローチャートである。It is a flowchart which shows a process of an example of a buffer failure determination. RAWデータの圧縮符号化方式の種別による出力レートの違いについて説明するための略線図である。It is a basic diagram for demonstrating the difference in the output rate by the classification of the compression encoding system of RAW data. 発明の実施の一形態によるRAW圧縮部の一例の構成を概略的に示すブロック図である。It is a block diagram which shows roughly the structure of an example of the RAW compression part by one Embodiment of invention. 圧縮処理スルーの場合における、圧縮RAWデータ転送の一例のタイミングチャートである。6 is a timing chart of an example of compressed RAW data transfer in the case of compression processing through. RAW圧縮部において、従来の方法でデータ出力を行った場合の一例のタイミングチャートである。5 is a timing chart of an example when data is output by a conventional method in a RAW compression unit. 圧縮符号化処理により出力されるデータ単位を外部メモリのバースト長と同一とした場合における、圧縮RAWデータ転送の一例のタイミングチャートである。6 is a timing chart illustrating an example of compressed RAW data transfer when the data unit output by compression encoding processing is the same as the burst length of the external memory. 圧縮符号化処理により出力されるデータ単位を外部メモリのバースト長と同一とした場合の、符号パッキングバッファの一例の読み出し制御を示すフローチャートである。It is a flowchart which shows read-out control of an example of a code packing buffer when the data unit output by compression encoding processing is made the same as the burst length of the external memory. 圧縮符号化処理により出力されるデータ単位を外部メモリのバースト長よりも短くした場合における、圧縮RAWデータ転送の一例のタイミングチャートである。It is a timing chart of an example of compressed RAW data transfer when the data unit output by the compression encoding process is shorter than the burst length of the external memory. 圧縮符号化処理により出力されるデータ単位を外部メモリのバースト長よりも短くした場合の、符号パッキングバッファの一例の読み出し制御を示すフローチャートである。It is a flowchart which shows reading control of an example of a code packing buffer when the data unit output by compression encoding processing is made shorter than the burst length of an external memory. 符号パッキングバッファに対する一例の書き込み制御を示すフローチャートである。It is a flowchart which shows an example of write-in control with respect to a code packing buffer. 可変長符号を用いて圧縮符号化を行い、従来の方法でデータ出力を行った場合における、圧縮RAWデータ転送の一例のタイミングチャートである。It is a timing chart of an example of compressed RAW data transfer when compression encoding is performed using a variable-length code and data is output by a conventional method. 圧縮符号化により出力されるデータ単位を外部メモリのバースト長と同一とした場合における、圧縮RAWデータ転送の一例のタイミングチャートである。10 is a timing chart of an example of compressed RAW data transfer when the data unit output by compression encoding is the same as the burst length of the external memory. 圧縮符号化処理により出力されるデータ単位を外部メモリのバースト長よりも短くした場合における、圧縮RAWデータ転送の一例のタイミングチャートである。It is a timing chart of an example of compressed RAW data transfer when the data unit output by the compression encoding process is shorter than the burst length of the external memory.

符号の説明Explanation of symbols

1 撮像装置
11 撮像素子
21 バス
22 カメラ信号処理部
30 CPU
34 メモリコントローラ
35 RAM
50 RAW補正部
50A 補正処理部
50B 同期乗り換え部
54 RAW圧縮部
55,57,58 バスI/F
56 RAW伸長部
60 バッファメモリ
61 読み出し制御部
70 量子化部
71 符号化部
72 バッファ制御部
73 符号パッキングバッファ
DESCRIPTION OF SYMBOLS 1 Image pick-up device 11 Image pick-up element 21 Bus 22 Camera signal processing part 30 CPU
34 Memory controller 35 RAM
50 RAW Correction Unit 50A Correction Processing Unit 50B Synchronous Transfer Unit 54 RAW Compression Units 55, 57, 58 Bus I / F
56 RAW expansion unit 60 buffer memory 61 read control unit 70 quantization unit 71 encoding unit 72 buffer control unit 73 code packing buffer

Claims (26)

データを第1のデータ単位でバス上に転送するデータ転送部と、
データに対して所定のデータ処理を施して、上記第1のデータ単位とデータサイズが等しいか、または、上記第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するデータ処理部と
を有し、
上記データ処理部から出力されたデータを上記データ転送部から上記バス上に転送する
ことを特徴とするデータ処理装置。
A data transfer unit for transferring data on the bus in a first data unit;
Predetermined data processing is performed on the data, and the first data unit is equal in data size to the first data unit, or for each second data unit having a data size obtained by dividing the first data unit by an integer A data processing unit for outputting at intervals,
A data processing device for transferring data output from the data processing unit onto the bus from the data transfer unit.
請求項1に記載のデータ処理装置において、
上記バスに接続され、バースト長単位でのバースト転送が可能なメモリをさらに有し、
上記メモリに対して上記データ転送部により上記バスを介してデータを転送するようにされ、上記第1のデータ単位のデータサイズを上記バースト長と等しくした
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 1,
A memory connected to the bus and capable of burst transfer in units of burst length;
A data processing device, wherein data is transferred to the memory via the bus by the data transfer unit, and the data size of the first data unit is made equal to the burst length.
請求項1に記載のデータ処理装置において、
上記データ処理部でなされる上記データ処理は、圧縮符号化処理である
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 1,
The data processing apparatus, wherein the data processing performed by the data processing unit is compression encoding processing.
請求項1に記載のデータ処理装置において、
上記データ処理部は、固定長符号を用いて上記データ処理を行う
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 1,
The data processing device, wherein the data processing unit performs the data processing using a fixed-length code.
請求項1に記載のデータ処理装置において、
上記データ処理部は、可変長符号を用いて上記データ処理を行う
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 1,
The data processing device, wherein the data processing unit performs the data processing using a variable length code.
請求項1に記載のデータ処理装置において、
上記データ処理部は、
少なくとも上記第1のデータ単位分の容量を持ち、上記データ処理を行ったデータを一時的に溜め込むバッファを備え、
上記バッファに溜め込まれたデータを上記第1のデータ単位毎に読み出す
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 1,
The data processing unit
A buffer having at least a capacity corresponding to the first data unit and temporarily storing the data subjected to the data processing;
A data processing apparatus, wherein the data stored in the buffer is read for each of the first data units.
請求項6に記載のデータ処理装置において、
上記バッファに対するアクセス状態と、上記データ転送部からの転送要求とに基づき該バッファの機能が破綻したか否かを判断し、破綻したと判断された場合に所定の処理を行うようにした
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 6, wherein
Based on the access status to the buffer and the transfer request from the data transfer unit, it is determined whether or not the function of the buffer has failed, and when it is determined that the function has failed, predetermined processing is performed. Characteristic data processing device.
請求項7に記載のデータ処理装置において、
上記所定の処理は、上記データ処理を行ったデータを上記バッファに書き込まないようにした
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 7, wherein
The data processing apparatus according to claim 1, wherein the predetermined processing is such that the data subjected to the data processing is not written to the buffer.
請求項8に記載のデータ処理装置において、
上記データ処理部に対する上記データの供給は、転送要求に応じてなされ、
上記所定の処理は、さらに、上記転送要求を強制的に出力する
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 8, wherein
The data is supplied to the data processor in response to a transfer request.
The predetermined processing further includes forcibly outputting the transfer request.
請求項8に記載のデータ処理装置において、
上記所定の処理は、さらに、上記破綻が生じた位置を示す情報を保持する
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 8, wherein
The data processing apparatus, wherein the predetermined processing further holds information indicating a position where the failure has occurred.
請求項8に記載のデータ処理装置において、
上記所定の処理は、さらに、上記バッファから読み出される上記データの、上記破綻が生じた位置に対して、上記破綻が生じた旨を示す符号を挿入する
ことを特徴とするデータ処理装置。
The data processing apparatus according to claim 8, wherein
The data processing apparatus, wherein the predetermined processing further inserts a code indicating that the failure has occurred at a position where the failure has occurred in the data read from the buffer.
データを第1のデータ単位でバス上に転送するデータ転送のステップと、
データに対して所定のデータ処理を施して、上記第1のデータ単位とデータサイズが等しいか、または、上記第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するデータ処理のステップと
を有し、
上記データ処理のステップにより出力されたデータを上記データ転送のステップにより上記バス上に転送する
ことを特徴とするデータ処理方法。
A data transfer step of transferring data on the bus in first data units;
Predetermined data processing is performed on the data, and the first data unit is equal in data size to the first data unit, or for each second data unit having a data size obtained by dividing the first data unit by an integer. And a data processing step for outputting at intervals,
A data processing method, wherein the data output in the data processing step is transferred onto the bus in the data transfer step.
データを第1のデータ単位でバス上に転送するデータ転送のステップと、
データに対して所定のデータ処理を施して、上記第1のデータ単位とデータサイズが等しいか、または、上記第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するデータ処理のステップと
を有し、
上記データ処理のステップにより出力されたデータを上記データ転送のステップにより上記バス上に転送する
ようにしたデータ処理方法をコンピュータに実行させる
ことを特徴とするデータ処理プログラム。
A data transfer step of transferring data on the bus in first data units;
Predetermined data processing is performed on the data, and the first data unit is equal in data size to the first data unit, or for each second data unit having a data size obtained by dividing the first data unit by an integer. And a data processing step for outputting at intervals,
A data processing program for causing a computer to execute a data processing method for transferring data output in the data processing step onto the bus in the data transfer step.
撮像素子から出力された撮像信号に基づく動画データに対する処理を行うと共に、該撮像信号に基づく静止画データに対する処理を該動画データの処理と並列的に行えるようにした撮像装置において、
光を光電変換で電気信号に変換し撮像信号として出力する撮像部と、
上記撮像部から出力された上記撮像信号に対して所定の信号処理を施し画像データとして出力する撮像信号処理部と、
第1の転送要求を出力し、該第1の転送要求に応じて上記撮像信号処理部から出力された上記画像データに対してフレームタイミング毎の処理を行い動画データを出力する動画データ処理部と、
第2の転送要求を出力し、該第2の転送要求に応じて上記撮像信号処理部から出力された上記画像データに対して所定のタイミングで処理を行い静止画データを出力する静止画データ処理部と
を有し、
上記静止画データ処理部は、
上記撮像信号処理部から出力された上記画像データを圧縮符号化する圧縮符号化部と、
上記圧縮符号化部から出力された上記圧縮画像データを第1のデータ単位でバス上に転送するデータ転送部と
を備え、
上記圧縮符号化部は、上記圧縮画像データを上記第1のデータ単位とデータサイズが等しいか、または、上記第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するようにした
ことを特徴とする撮像装置。
In an imaging apparatus that performs processing on moving image data based on an imaging signal output from an imaging element, and that can perform processing on still image data based on the imaging signal in parallel with the processing of the moving image data.
An imaging unit that converts light into an electrical signal by photoelectric conversion and outputs it as an imaging signal;
An imaging signal processing unit that performs predetermined signal processing on the imaging signal output from the imaging unit and outputs the signal as image data;
A moving image data processing unit that outputs a first transfer request, performs processing for each frame timing on the image data output from the imaging signal processing unit in response to the first transfer request, and outputs moving image data; ,
Still image data processing for outputting a second transfer request, processing the image data output from the imaging signal processing unit in response to the second transfer request at a predetermined timing, and outputting still image data And
The still image data processing unit
A compression encoding unit that compresses and encodes the image data output from the imaging signal processing unit;
A data transfer unit that transfers the compressed image data output from the compression encoding unit onto the bus in a first data unit;
The compression encoding unit has a predetermined size for each second data unit having a data size equal to the first data unit or the data size obtained by dividing the first data unit by an integer. An imaging apparatus characterized in that output is performed at intervals.
請求項14に記載の撮像装置において、
上記バスに接続され、バースト長単位でのバースト転送が可能なメモリをさらに有し、
上記メモリに対して上記データ転送部により上記バスを介してデータを転送するようにされ、上記第1のデータ単位のデータサイズを上記バースト長と等しくした
ことを特徴とする撮像装置。
The imaging device according to claim 14, wherein
A memory connected to the bus and capable of burst transfer in units of burst length;
An image pickup apparatus, wherein data is transferred to the memory by the data transfer unit via the bus, and the data size of the first data unit is made equal to the burst length.
請求項14に記載の撮像装置において、
上記メモリおよび上記バスは、上記動画データおよび上記静止画データの転送処理で共有される
ことを特徴とする撮像装置。
The imaging device according to claim 14, wherein
The image pickup apparatus, wherein the memory and the bus are shared by transfer processing of the moving image data and the still image data.
請求項14に記載の撮像装置において、
上記圧縮符号化部は、固定長符号を用いて上記圧縮符号化処理を行う
ことを特徴とする撮像装置。
The imaging device according to claim 14, wherein
The imaging apparatus, wherein the compression encoding unit performs the compression encoding process using a fixed-length code.
請求項14に記載の撮像装置において、
上記圧縮符号化部は、可変長符号を用いて上記圧縮符号化処理を行う
ことを特徴とする撮像装置。
The imaging device according to claim 14, wherein
The image pickup apparatus, wherein the compression encoding unit performs the compression encoding process using a variable length code.
請求項14に記載の撮像装置において、
上記圧縮符号化部は、
少なくとも上記第1のデータ単位分の容量を持ち、上記圧縮符号化処理を行った圧縮画像データを一時的に溜め込むバッファを備え、
上記バッファに溜め込まれた上記圧縮画像データを上記第2のデータ単位毎に読み出す
ことを特徴とする撮像装置。
The imaging device according to claim 14, wherein
The compression encoding unit is
A buffer having at least a capacity for the first data unit and temporarily storing the compressed image data subjected to the compression encoding process;
An imaging apparatus, wherein the compressed image data stored in the buffer is read for each second data unit.
請求項19に記載の撮像装置において、
上記静止画データ処理部は、上記バッファに対するアクセス状態と、上記データ転送部からの転送要求とに基づき該バッファの機能が破綻したか否かを判断し、破綻したと判断された場合に所定の処理を行うようにした
ことを特徴とする撮像装置。
The imaging device according to claim 19,
The still image data processing unit determines whether or not the function of the buffer has failed based on an access state to the buffer and a transfer request from the data transfer unit. An imaging apparatus characterized by performing processing.
請求項20に記載の撮像装置において、
上記所定の処理は、上記圧縮符号化処理を行った圧縮画像データを上記バッファに書き込まないようにした
ことを特徴とする撮像装置。
The imaging device according to claim 20,
The imaging apparatus according to claim 1, wherein in the predetermined processing, the compressed image data subjected to the compression encoding processing is not written to the buffer.
請求項21に記載の撮像装置において、
上記圧縮符号化部に対する上記画像データの供給は、上記第2の転送要求に応じてなされ、
上記所定の処理は、さらに、上記第2の転送要求を強制的に出力する
ことを特徴とする撮像装置。
The imaging device according to claim 21, wherein
The supply of the image data to the compression encoding unit is made in response to the second transfer request,
The predetermined processing further forcibly outputs the second transfer request.
請求項21に記載の撮像装置において、
上記所定の処理は、さらに、上記破綻が生じた位置を示す情報を保持する
ことを特徴とする撮像装置。
The imaging device according to claim 21, wherein
The predetermined apparatus further holds information indicating a position where the failure has occurred.
請求項21に記載の撮像装置において、
上記所定の処理は、さらに、上記バッファから読み出される上記圧縮画像データの、上記破綻が生じた位置に対して、上記破綻が生じた旨を示す符号を挿入する
ことを特徴とする撮像装置。
The imaging device according to claim 21, wherein
The imaging apparatus, wherein the predetermined processing further inserts a code indicating that the failure has occurred at a position where the failure has occurred in the compressed image data read from the buffer.
撮像素子から出力された撮像信号に基づく動画データに対する処理を行うと共に、該撮像信号に基づく静止画データに対する処理を該動画データの処理と並列的に行えるようにした撮像装置の制御方法において、
光を光電変換で電気信号に変換して撮像部から出力された上記撮像信号に対して所定の信号処理を施し画像データとして出力する撮像信号処理のステップと、
第1の転送要求を出力し、該第1の転送要求に応じて上記撮像信号処理のステップにより出力された上記画像データに対してフレームタイミング毎の処理を行い動画データを出力する動画データ処理のステップと、
第2の転送要求を出力し、該第2の転送要求に応じて上記撮像信号処理のステップにより出力された上記画像データに対して所定のタイミングで処理を行い静止画データを出力する静止画データ処理のステップと
を有し、
上記静止画データ処理のステップは、
上記撮像信号処理のステップにより出力された上記画像データを圧縮符号化する圧縮符号化のステップと、
上記圧縮符号化のステップにより出力された上記圧縮画像データを第1のデータ単位でバス上に転送するデータ転送のステップと
を備え、
上記圧縮符号化のステップは、上記圧縮画像データを上記第1のデータ単位とデータサイズが等しいか、または、上記第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力するようにした
ことを特徴とする撮像装置の制御方法。
In a control method of an imaging apparatus that performs processing on moving image data based on an imaging signal output from an imaging element, and that can perform processing on still image data based on the imaging signal in parallel with the processing of the moving image data.
An imaging signal processing step of performing predetermined signal processing on the imaging signal output from the imaging unit by converting light into an electrical signal by photoelectric conversion and outputting as image data;
The first transfer request is output, and the image data output by the imaging signal processing step in response to the first transfer request is processed at each frame timing to output moving image data. Steps,
Still image data that outputs a second transfer request, processes the image data output in the imaging signal processing step in response to the second transfer request at a predetermined timing, and outputs still image data Processing steps,
The still image data processing steps are as follows:
A compression encoding step of compressing and encoding the image data output by the imaging signal processing step;
A data transfer step of transferring the compressed image data output in the compression encoding step on the bus in a first data unit;
The compression encoding step is performed for each second data unit having a data size equal to the first data unit or the data size obtained by dividing the first data unit by an integer. An image pickup apparatus control method characterized in that output is performed with an interval of.
撮像素子から出力された撮像信号に基づく動画データに対する処理を行うと共に、該撮像信号に基づく静止画データに対する処理を該動画データの処理と並列的に行えるようにした撮像装置の制御方法をコンピュータに実行させる制御プログラムにおいて、
光を光電変換で電気信号に変換して撮像部から出力された上記撮像信号に対して所定の信号処理を施し画像データとして出力する撮像信号処理のステップと、
第1の転送要求を出力し、該第1の転送要求に応じて上記撮像信号処理のステップにより出力された上記画像データに対してフレームタイミング毎の処理を行い動画データを出力する動画データ処理のステップと、
第2の転送要求を出力し、該第2の転送要求に応じて上記撮像信号処理のステップにより出力された上記画像データに対して所定のタイミングで処理を行い静止画データを出力する静止画データ処理のステップと
を有し、
上記静止画データ処理のステップは、
上記撮像信号処理のステップにより出力された上記画像データを圧縮符号化する圧縮符号化のステップと、
上記圧縮符号化のステップにより出力された上記圧縮画像データを第1のデータ単位でバス上に転送するデータ転送のステップと
を備え、
上記圧縮符号化のステップは、上記圧縮画像データを上記第1のデータ単位とデータサイズが等しいか、または、上記第1のデータ単位を整数分割したデータサイズの第2のデータ単位毎に、所定の間隔を空けて出力する
ようにした撮像装置の制御方法をコンピュータに実行させる
ことを特徴とする撮像装置の制御プログラム。
A method of controlling an imaging apparatus that performs processing on moving image data based on an imaging signal output from an image sensor and that can perform processing on still image data based on the imaging signal in parallel with the processing of the moving image data. In the control program to be executed,
An imaging signal processing step of performing predetermined signal processing on the imaging signal output from the imaging unit by converting light into an electrical signal by photoelectric conversion and outputting as image data;
The first transfer request is output, and the image data output by the imaging signal processing step in response to the first transfer request is processed at each frame timing to output moving image data. Steps,
Still image data that outputs a second transfer request, processes the image data output in the imaging signal processing step in response to the second transfer request at a predetermined timing, and outputs still image data Processing steps,
The still image data processing steps are as follows:
A compression encoding step of compressing and encoding the image data output by the imaging signal processing step;
A data transfer step of transferring the compressed image data output in the compression encoding step on the bus in a first data unit;
The compression encoding step is performed for each second data unit having a data size equal to the first data unit or the data size obtained by dividing the first data unit by an integer. An image pickup apparatus control program that causes a computer to execute a method for controlling an image pickup apparatus that outputs the image data at intervals.
JP2007302552A 2007-11-22 2007-11-22 Unit, method, and program for processing data, imaging apparatus, and method and program for controlling the same Pending JP2009130563A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007302552A JP2009130563A (en) 2007-11-22 2007-11-22 Unit, method, and program for processing data, imaging apparatus, and method and program for controlling the same

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007302552A JP2009130563A (en) 2007-11-22 2007-11-22 Unit, method, and program for processing data, imaging apparatus, and method and program for controlling the same

Publications (1)

Publication Number Publication Date
JP2009130563A true JP2009130563A (en) 2009-06-11

Family

ID=40821060

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007302552A Pending JP2009130563A (en) 2007-11-22 2007-11-22 Unit, method, and program for processing data, imaging apparatus, and method and program for controlling the same

Country Status (1)

Country Link
JP (1) JP2009130563A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013114647A (en) * 2011-12-01 2013-06-10 Exvision Inc Gesture input system
WO2014084072A1 (en) * 2012-11-29 2014-06-05 ソニー株式会社 Image sensor, method for transmitting data from same, information processing device, information processing method, electronic device, and program

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2013114647A (en) * 2011-12-01 2013-06-10 Exvision Inc Gesture input system
WO2014084072A1 (en) * 2012-11-29 2014-06-05 ソニー株式会社 Image sensor, method for transmitting data from same, information processing device, information processing method, electronic device, and program
CN104854854A (en) * 2012-11-29 2015-08-19 索尼公司 Image sensor, method for transmitting data from same, information processing device, information processing method, electronic device, and program
JPWO2014084072A1 (en) * 2012-11-29 2017-01-05 ソニーセミコンダクタソリューションズ株式会社 Image sensor and data transmission method thereof, information processing apparatus and information processing method, electronic device, and program
CN104854854B (en) * 2012-11-29 2019-04-05 索尼半导体解决方案公司 Imaging sensor and its data transmission method, information processing unit and method, electronic equipment and program
US10362220B2 (en) 2012-11-29 2019-07-23 Sony Semiconductor Solutions Corporation Conversation of pixel data into compression format of pixels

Similar Documents

Publication Publication Date Title
JP5056370B2 (en) IMAGING DEVICE, IMAGING DEVICE CONTROL METHOD, IMAGING DEVICE CONTROL PROGRAM, DATA PROCESSING DEVICE, DATA PROCESSING METHOD, AND DATA PROCESSING PROGRAM
US8743227B2 (en) Imaging apparatus and control method for reducing a load of writing image data on a recording medium
JP4508132B2 (en) Imaging device, imaging circuit, and imaging method
US7705895B2 (en) Image taking apparatus and image-taking method
JP2006352509A (en) Image data processor, image data processing method, and program
JP5141324B2 (en) Imaging apparatus, imaging apparatus control method, signal processing apparatus, and signal processing method
US10003767B2 (en) Image processing apparatus and image processing method
JP5496047B2 (en) Image reproduction method, image reproduction apparatus, image reproduction program, imaging system, and reproduction system
JP2000278589A (en) Image signal processing unit
JP2008113070A (en) Imaging device and imaging method
JP2012085001A5 (en)
US7440629B2 (en) Image encoding apparatus and image encoding method
US9179065B2 (en) Image processing apparatus, image processing method, and program product
US10360660B2 (en) Image processing apparatus and image processing method for handling raw images
KR20100061311A (en) Photographing apparatus and controlling method thereof
JP2009130563A (en) Unit, method, and program for processing data, imaging apparatus, and method and program for controlling the same
JP2008113112A (en) Imaging apparatus
JP4103276B2 (en) Image recording apparatus and method
JP2009130561A (en) Imaging apparatus, control method of imaging apparatus and control program of imaging apparatus
US8953055B2 (en) Image pickup apparatus
JP2010074597A (en) Image processing device, image processing method, program and imaging device
JP2009232004A (en) Signal processor and signal processing method, and imaging apparatus and control method of the imaging apparatus
JP2010147531A (en) Imaging apparatus and imaging method
JP2013219682A (en) Imaging device
JP2023008624A (en) Imaging apparatus and control method thereof and program