Image data compression method and interface circuit

文档序号:1173037 发布日期:2020-09-18 浏览:20次 中文

阅读说明:本技术 一种图像数据的压缩方法以及接口电路 (Image data compression method and interface circuit ) 是由 李停 李林 张远 陈西昌 张正威 于 2020-06-12 设计创作,主要内容包括:本发明提供了一种图像数据的压缩方法以及接口电路,所述压缩方法包括:接收待压缩的图像数据,并利用一维小波变换法对待压缩的图像数据进行一维小波变换以得到变换后的数据;对所述变换后的数据进行量化处理以得到量化系数;对所述量化系数进行零游程编码以得到压缩后的图像数据。本发明所提供的压缩方法的延迟较低,输出频率较高,所需存储空间较小。同时,本发明提供的接口电路的结构较为简单,占用面积较小。(The invention provides a compression method of image data and an interface circuit, wherein the compression method comprises the following steps: receiving image data to be compressed, and performing one-dimensional wavelet transform on the image data to be compressed by using a one-dimensional wavelet transform method to obtain transformed data; performing quantization processing on the transformed data to obtain a quantization coefficient; and carrying out zero run coding on the quantized coefficient to obtain compressed image data. The compression method provided by the invention has the advantages of low delay, high output frequency and small required storage space. Meanwhile, the interface circuit provided by the invention has a simpler structure and a smaller occupied area.)

1. A method of compressing image data, the method comprising:

receiving image data to be compressed, and performing one-dimensional wavelet transform on the image data to be compressed by using a one-dimensional wavelet transform method to obtain transformed data;

performing quantization processing on the transformed data to obtain a quantization coefficient;

and carrying out zero run coding on the quantized coefficient to obtain compressed image data.

2. A method of compressing image data as claimed in claim 1, wherein said one-dimensional wavelet transform method comprises an 3/1 wavelet transform method.

3. The method of compressing image data according to claim 2, wherein the method of performing one-dimensional wavelet transform on the image data to be compressed using the one-dimensional wavelet transform method comprises:

providing a formula, and performing wavelet transformation on each pixel point of the image data to be compressed by using the formula to obtain the transformed data;

y(i)pixel=x(i)pixeli≤8

y(i)pixel=x(i)pixel-ceil((x(i-1)pixel+x(i+1)pixel)/2) i>8 and i is an odd number

y(i)pixel=x(i)pixel+ceil((y(i-4)pixel+y(i-5)pixel+y(i-6)pixel+y(i-7)pixel)/4) i>8 and i is an even number

Wherein, x (i)pixelData indicating a point corresponding to an ith pixel of image data to be compressed, y (i)pixelFor indicating pairs x (i)pixelAnd (4) carrying out wavelet transformation on the obtained data, wherein the ceil function is used for indicating an upward rounding function.

4. The method of compressing image data according to claim 1, wherein the method of receiving the image data to be compressed includes: and receiving the image data to be compressed in parallel.

5. The method of compressing image data according to claim 1, wherein the method of quantizing the transformed data includes: and quantizing the transformed data by adopting a uniform quantization method to obtain a uniform quantization coefficient.

6. The method of compressing image data according to claim 1, wherein after zero-run coding said quantized coefficients to obtain compressed image data, said method further comprises: and outputting the compressed image data in parallel.

7. An interface circuit, wherein the interface circuit is configured in a MIPI interface;

and the interface circuit comprises a compression circuit for performing the compression method according to any one of claims 1-6.

8. The interface circuit of claim 7, wherein the compression circuit comprises:

the wavelet transformation module is used for receiving image data to be compressed and carrying out one-dimensional wavelet transformation on the image data to be compressed by utilizing a one-dimensional wavelet transformation method to obtain transformed data;

the quantization module is used for performing quantization processing on the transformed data to obtain a quantization coefficient;

and the coding module is used for carrying out zero run coding on the quantized coefficient to obtain compressed image data.

9. An interface circuit as in claim 8, where said wavelet transform module comprises a phase filter consisting of a combination of a 3-tap low pass filter and a 1-tap high pass filter.

10. The interface circuit of claim 7, wherein the interface circuit further comprises a transmit module and a control interface;

the sending module is connected with the compression circuit and used for receiving compressed image data sent by the compression circuit in parallel and outputting the compressed image data in parallel;

the control interface is connected with the compression circuit and used for sending configuration information to the compression circuit, wherein the configuration information comprises the compression type of the image data to be compressed.

Technical Field

The present invention relates to the field of image data, and in particular, to a method for compressing image data and an interface circuit.

Background

In the field of image data, it is often necessary to compression encode the original image to eliminate redundancy. Specifically, an original image is received by using an MIPI interface, the original image is compressed and encoded by using a compression circuit in the MIPI interface, and then the compressed data is output through the MIPI interface for subsequent processing.

Disclosure of Invention

The invention aims to provide a compression method of image data and an interface circuit, which are used for solving the technical problems that a compression circuit in the related technology is complex, has high delay and cannot realize high-frequency output.

In a first aspect, to solve the above technical problem, the present invention provides a method for compressing image data, including: receiving image data to be compressed, and performing one-dimensional wavelet transform on the image data to be compressed by using a one-dimensional wavelet transform method to obtain transformed data;

performing quantization processing on the transformed data to obtain a quantization coefficient;

and carrying out zero run coding on the quantized coefficient to obtain compressed image data.

Optionally, the one-dimensional wavelet transform method includes 3/1 wavelet transform method.

Optionally, the method for performing one-dimensional wavelet transform on image data to be compressed by using a one-dimensional wavelet transform method includes:

providing a formula, and performing wavelet transformation on each pixel point of the image data to be compressed by using the formula to obtain the transformed data;

y(i)pixel=x(i)pixeli≤8

y(i)pixel=x(i)pixel-ceil((x(i-1)pixel+x(i+1)pixel)/2)i>8 and i is an odd number

y(i)pixel=x(i)pixel+ceil((y(i-4)pixel+y(i-5)pixel+y(i-6)pixel+y(i-7)pixel)/4)i>8 and i is an even number

Wherein, x (i)pixelData indicating a point corresponding to an ith pixel of image data to be compressed, y (i)pixelFor indicating pairs x (i)pixelAnd (4) carrying out wavelet transformation on the obtained data, wherein the ceil function is used for indicating an upward rounding function.

Optionally, the method for receiving image data to be compressed includes: and receiving the image data to be compressed in parallel.

Optionally, the method for performing quantization processing on the transformed data includes: and quantizing the transformed data by adopting a uniform quantization method to obtain a uniform quantization coefficient.

Optionally, after performing zero run length coding on the quantized coefficient to obtain compressed image data, the method further includes: and outputting the compressed image data in parallel.

In a second aspect, the present invention further provides an interface circuit, where the interface circuit is configured in the MIPI interface;

and the interface circuit comprises a compression circuit for performing the compression method as described in the first aspect above.

Optionally, the compression circuit includes:

the wavelet transformation module is used for receiving image data to be compressed and carrying out one-dimensional wavelet transformation on the image data to be compressed by utilizing a one-dimensional wavelet transformation method to obtain transformed data;

the quantization module is used for performing quantization processing on the transformed data to obtain a quantization coefficient;

and the coding module is used for carrying out zero run coding on the quantized coefficient to obtain compressed image data.

Optionally, the wavelet transform module includes a phase filter composed of a combination of a 3-tap low-pass filter and a 1-tap high-pass filter.

Optionally, the interface circuit further includes a sending module and a control interface;

the sending module is connected with the compression circuit and used for receiving compressed image data sent by the compression circuit in parallel and outputting the compressed image data in parallel;

the control interface is connected with the compression circuit and used for sending configuration information to the compression circuit, wherein the configuration information comprises the compression type of the image data to be compressed.

In summary, in the compression method and the interface circuit for image data provided by the present invention, when the compression method is used to compress image data, one-dimensional wavelet transform is performed on each pixel point of the image data to be compressed to obtain transformed data, then quantization processing is performed on the transformed data to obtain a quantization coefficient, and finally zero-run coding is performed on the quantization coefficient to obtain the compressed image data. Therefore, when the data is compressed, each pixel point is compressed and coded in a clock pipeline-based mode, the requirement on the correlation among the pixel points is low, namely, when each pixel point is coded, coding is not needed based on the coding results of other pixel points, and the phenomenon that when a certain pixel point is coded, the coding result of the previous pixel point needs to be decoded first to obtain a decoding value and then the coding is carried out can not occur. Therefore, when a plurality of pixel points are input by adopting multiple channels, the plurality of pixel points can be coded simultaneously, and the coding results of the pixel points can be simultaneously obtained and then simultaneously output, so that the delay is reduced, the coding efficiency and the output frequency are improved, and high-frequency output can be realized.

In addition, in this embodiment, when each pixel is encoded, since the encoding result of other pixels does not need to be applied, the encoding results of other pixels do not need to be stored. Compared with the coding result of the previous pixel point of the current pixel point and the decoding value corresponding to the coding result which need to be stored in the related technology, the compression method of the invention can also reduce the storage space.

In addition, the one-dimensional wavelet transform method adopted in the invention has a simple realization mode of performing wavelet transform on image data to be compressed, and can reduce the calculation amount without applying a multiplier.

Drawings

Fig. 1 is a schematic diagram of a compression circuit of image data provided in the related art;

fig. 2 is a flowchart of a method for compressing image data according to an embodiment of the present invention;

FIG. 3 is a diagram illustrating an image data compression circuit according to an embodiment of the present invention;

fig. 4 is an interface circuit according to an embodiment of the present invention.

Detailed Description

The following describes the compression method, compression circuit, and interface circuit of the image data according to the present invention in further detail with reference to the accompanying drawings and specific embodiments. The advantages and features of the present invention will become more apparent from the following description. It is to be noted that the drawings are in a very simplified form and are not to precise scale, which is merely for the purpose of facilitating and distinctly claiming the embodiments of the present invention.

Fig. 2 is a flowchart of a method for compressing image data according to an embodiment of the present invention, and as shown in fig. 2, the method may include:

step 100, receiving image data to be compressed, and performing one-dimensional wavelet transform on the image data to be compressed by using a one-dimensional wavelet transform method to obtain transformed data.

The image data to be compressed may be original image data sent by an external camera, or may be test image data sent by an internal test module. Specifically, before the compression circuit is used to compress and encode the original image data sent by the external camera, the compression circuit may send the test image data to the compression circuit first, so that the compression circuit compresses and encodes the test image data to obtain an encoding result, and determines whether the compression circuit successfully compresses the test image data based on the encoding result, so as to further determine whether the compression circuit normally operates, thereby ensuring that the original image data sent by the external camera can be subsequently compressed successfully and accurately.

In this embodiment, the image data to be compressed is received in parallel through multiple channels, and after the wavelet transform is performed to obtain transformed data, the transformed data corresponding to each pixel point is also sent out in parallel through multiple channels.

Further, in the present embodiment, the one-dimensional wavelet transform method mainly includes 3/1 wavelet transform method, and the 3/1 wavelet transform method adopted in the present embodiment is not the conventional 3/1 wavelet transform method, but is modified 3/1 wavelet transform method to be suitable for the interactive manner of simultaneous reception and simultaneous transmission by multiple channels in the present embodiment. Specifically, in this embodiment, an interactive mode that employs four channels to simultaneously receive and simultaneously transmit is taken as an example for explanation, and a calculation formula of the improved 3/1 wavelet transform method employed in this embodiment is as follows:

y(i)pixel=x(i)pixeli≤8 ①

y(i)pixel=x(i)pixel-ceil((x(i-1)pixel+x(i+1)pixel)/2)i>8 and i is odd ②

y(i)pixel=x(i)pixel+ceil((y(i-4)pixel+y(i-5)pixel+y(i-6)pixel+y(i-7)pixel)/4)i>8 and i is even ③

Wherein, x (i)pixelData indicating a point corresponding to an ith pixel of image data to be compressed, y (i)pixelFor indicating pairs x (i)pixelData obtained after wavelet transformation, ceil (z) function being used to refer toIndicating an upward rounding function, wherein the upward rounding function is: when z is a decimal, 1 is added to the integer ceil (z) z, for example, when z is 1.1, ceil (z) 1+ 1-2.

And, in this embodiment, the above formula (c) corresponds to an image prediction operation, and the above formula (c) corresponds to an image update operation.

Based on this, in this embodiment, the method for performing one-dimensional wavelet transform on the image data to be compressed by using the one-dimensional wavelet transform method to obtain the transformed data may specifically include: and calculating each pixel point of the image data to be compressed based on the formula (I) to the formula (III) to obtain transformed data. Specifically, the first 8 pixels of the image data to be compressed may be calculated based on a formula, and subsequent pixels may be processed separately in odd and even manner, wherein an odd pixel after the first 8 pixels may be calculated based on a pixel immediately before and a pixel immediately after the odd pixel, and an even pixel after the first 8 pixels may be calculated based on data after wavelet transformation of a fourth pixel before, a fifth pixel before, a sixth pixel before, and a seventh pixel before. In this way, the data of each pixel point of the image data to be compressed can be calculated to obtain the transformed data.

And, it should be noted that, for the interactive mode of parallel receiving and parallel sending data of four channels, the method of performing wavelet transform by using the above formula has low delay and can ensure high frequency output. Specifically, every four pixel points in the image data to be compressed are divided into one group according to the sequence, and each group of pixel points are respectively input into the compression circuit along four channels in parallel to perform wavelet transformation. As can be seen from formula (i), the data after wavelet transform corresponding to the first 8 pixel points should be the data corresponding to each pixel point, and then it can be determined that: when the wavelet transformation is carried out on the first 8 pixel points, the data after the wavelet transformation of a certain pixel point is not required to be applied, so that the phenomenon that when the wavelet transformation is carried out on the current pixel point, the wavelet transformation is carried out on the current pixel point only after the wavelet transformation is carried out on the certain pixel point is waited for firstly can be avoided.

And a formula II shows that when wavelet transformation is performed on the odd pixel point after the 8 th pixel point, the wavelet transformation is mainly performed on the basis of the data of the pixel point immediately before and the data of the pixel point immediately after the current odd pixel point, so that the calculation is not required to be performed on the data of the pixel point before or after the wavelet transformation of the current odd pixel point, and the phenomenon that when the wavelet transformation is performed on the current odd pixel point, the wavelet transformation is performed on the current odd pixel point only after the wavelet transformation is performed on a certain pixel point is avoided.

Meanwhile, based on the formula III, when wavelet transformation is performed on the even-numbered pixel points after the 8 th pixel point, the wavelet transformation is mainly performed on the wavelet-transformed data of the fourth pixel point before the current even-numbered pixel point, the fifth pixel point before the current even-numbered pixel point, the sixth pixel point before the current even-numbered pixel point and the seventh pixel point before the current even-numbered pixel point. In this embodiment, since four channels are mainly input simultaneously, that is, four pixels are input at a time, the fourth pixel before the current even pixel, the fifth pixel before, the sixth pixel before, and the seventh pixel before are certainly not input to the compression circuit simultaneously with the current even pixel, and should be input to the four pixels in the compression circuit in parallel at the previous time of the current even pixel. Correspondingly, the wavelet transformation of the fourth pixel point before the current even pixel point, the fifth pixel point before the current even pixel point, the sixth pixel point before the current even pixel point and the seventh pixel point before the current even pixel point is also executed in the previous time when the current even pixel point is input into the compression circuit, at this time, the data after the wavelet transformation of the fourth pixel point before the current even pixel point, the fifth pixel point before the current even pixel point, the sixth pixel point before the current even pixel point and the seventh pixel point before the current even pixel point can be directly obtained when the wavelet transformation is carried out on the current even pixel point, and the phenomenon that the wavelet transformation is carried out after the wavelet transformation is carried out on the current even pixel point is waited for the pixel point input at the same time first can.

It can be known from the above content that the 3/1 wavelet transform method adopted in this embodiment does not need to apply data after wavelet transform of other pixel points input at the same time when performing wavelet transform on each pixel point input in parallel at the same time, so that the correlation of the operation of wavelet transform between each pixel point input at the same time is small, and then the wavelet transform can be performed on each pixel point input at the same time, thereby reducing the delay of performing wavelet transform between each pixel point input at the same time, and ensuring that high-frequency output can be realized.

In the present embodiment, the 3/1 wavelet transform method executed based on the formulas (i) to (iii) mainly performs integer transform on each pixel point, so that the calculation amount can be reduced, wherein compared with the conventional 3/1 wavelet transform method, the 3/1 wavelet transform method in the present embodiment can reduce half of the calculation amount. Moreover, after the 3/1 wavelet transform method provided by the embodiment is adopted, accurate reconstruction can be realized during subsequent decoding, and data is ensured not to be distorted.

In addition, in this embodiment, as can be seen from the above formula (i) to formula (iii), when the image data to be compressed is transformed by the one-dimensional wavelet transform method, there is no multiplication operation, and it is not necessary to apply the multiplication operation to the multiplier, so that the operation difficulty and the operation amount can be greatly reduced.

And, after wavelet transformation is performed on image data to be compressed, redundancy among image pixels can be reduced.

And 200, performing quantization processing on the transformed data to obtain a quantization coefficient.

The quantization processing may specifically be uniform quantization processing, where the uniform quantization processing specifically refers to dividing the transformed data into at least one quantization interval at equal intervals, then performing quantization processing on the data in each quantization interval to obtain a quantization result corresponding to each quantization interval, where the quantization result may be, for example, an average value of the data in each quantization interval, and finally, combining the quantization results corresponding to each quantization interval to obtain a uniform quantization coefficient.

And, in the present embodiment, visual redundancy of image data can be eliminated by quantization processing.

And step 300, performing zero run length coding on the quantized coefficient to obtain compressed image data.

Wherein, the zero run coding specifically comprises: and recording the code value and the number of continuous repetitions of the code aiming at the repeated code so as to realize data compression. For example, if the quantized coefficient obtained in step 300 is 1111100000011111100000, which includes four consecutive repeats of data, "11111" in the first consecutive repeat, and the length of the consecutive repeats is 5, the zero-run code corresponding to the first consecutive repeat of data should be (1, 5); the second segment of continuously repeated data is "000000", and the length of the continuous repetition is 6, then the zero run length code corresponding to the second segment of continuously repeated data should be (0, 6); and calculating the zero run length code corresponding to each continuously repeated data segment by analogy, and combining each continuously repeated data segment to obtain the final zero run length code, namely: (1, 5) (0, 6) (1, 6) (0, 5) to implement zero run coding of quantized coefficients.

Wherein redundancy can be probabilistically eliminated by performing zero-run coding. And the zero run length coding is mainly a statistical coding, which is lossless coding, so that the compression loss ratio can be ensured to a great extent when coding is carried out by using a zero run length coding mode, and the data distortion after coding is prevented.

In addition, in the embodiment, the data after the wavelet transform is quantized and then encoded, so that the number of samples can be reduced to a great extent, and the compression ratio of the image can be improved.

As can be seen from the above, the compression method of image data provided in this embodiment mainly encodes the image data to be compressed by performing steps 100 to 300. It should be noted that the compression method provided in this embodiment should be suitable for compressing image data of various types and sizes, for example, in this embodiment, the data type of the image data to be compressed may be one of RAW8, RAW10, and RAW12, and the data size of the image data to be compressed may be equal to or less than 4M.

In addition, in this embodiment, the compression type of the compression method may be set in advance. The compression type mainly limits the bit width of the pixel points before compression, the bit width of the pixel points after compression and the bit width of the pixel points after decompression. For example, the compression type may be indicated as X-Y-Z, where X represents a pixel bit width before compression, Y represents a pixel bit width after compression, and Z represents a pixel bit width after decompression. Then, in this embodiment, the compression type may be, for example: 12-8-12, 12-7-12, 12-6-12, 10-8-10, 10-7-10, 10-6-10, 8-6-8, 8-7-8.

It should be noted that, in this embodiment, the wavelet transform operation, the uniform quantization process, and the zero run length coding may be performed within one clock beat, where a compression period of each clock beat may be specifically calculated by using sequential logic. Therefore, when the compression method of the present invention is used to perform compression encoding on 1080P frames of image data to be compressed, 1920 × 1080 clock beats are required to complete the compression encoding. Based on this, the present embodiment can estimate the clock frequency of encoding the image data to be compressed by the number of clock beats.

In summary, in the method for compressing image data provided by the present invention, when compressing image data, one-dimensional wavelet transform is performed on each pixel point of the image data to be compressed to obtain transformed data, then quantization processing is performed on the transformed data to obtain a quantization coefficient, and finally zero-run coding is performed on the quantization coefficient to obtain the compressed image data. Therefore, when the data is compressed, each pixel point is compressed and coded in a clock pipeline-based mode, the requirement on the correlation among the pixel points is low, namely, when each pixel point is coded, coding is not needed based on the coding results of other pixel points, and the phenomenon that when a certain pixel point is coded, the coding result of the previous pixel point needs to be decoded first to obtain a decoding value and then the coding is carried out can not occur. Therefore, when a plurality of pixel points are input by adopting multiple channels, the plurality of pixel points can be coded simultaneously, and the coding results of the pixel points can be simultaneously obtained and then simultaneously output, so that the delay is reduced, the coding efficiency and the output frequency are improved, and the high-frequency output is realized. When an interactive mode of simultaneous input and simultaneous output of four channels is adopted, the output frequency of the compression method provided by the embodiment of the invention can be up to 6 Gbit/s.

In addition, in this embodiment, when each pixel is encoded, since the encoding result of other pixels does not need to be applied, the encoding results of other pixels do not need to be stored. Compared with the coding result of the previous pixel point of the current pixel point and the decoding value corresponding to the coding result which need to be stored in the related technology, the compression method of the invention can also reduce the storage space.

In addition, the one-dimensional wavelet transform method adopted in the invention has a simple realization mode of performing wavelet transform on image data to be compressed, and can reduce the calculation amount without applying a multiplier.

Further, fig. 3 is a schematic diagram of a compression circuit for image data according to an embodiment of the present invention, and as shown in fig. 3, the compression circuit may include:

the wavelet transformation module is used for receiving the image data to be compressed and carrying out one-dimensional wavelet transformation on the image data to be compressed by utilizing a one-dimensional wavelet transformation method to obtain transformed data.

And the quantization module is used for performing quantization processing on the transformed data to obtain a quantization coefficient.

And the coding module is used for carrying out zero run coding on the quantized coefficient to obtain compressed image data.

Alternatively, the wavelet transform module may be a phase filter composed of a combination of a 3-tap low-pass filter and a 1-tap high-pass filter. The wavelet transform module may specifically receive the image data to be compressed in parallel to perform one-dimensional wavelet transform on the image data to obtain transformed data, and then may output the transformed data to the quantization module in parallel. And, in this embodiment, the wavelet transform module may perform one-dimensional wavelet transform on the received image data to be compressed based on the formula (i) -c in step 100.

Optionally, the quantization module is configured to perform quantization processing on the transformed data by using a uniform quantization method to obtain a uniform quantization coefficient, and output the uniform quantization coefficient to the encoding module in parallel.

Optionally, the encoding module is further configured to output the compressed image data in parallel.

In addition, fig. 4 is an interface circuit according to an embodiment of the present invention, and as shown in fig. 4, the interface circuit includes the compression circuit shown in fig. 3.

Optionally, the interface circuit further includes a sending module connected to the compression circuit, and configured to receive compressed image data sent by the compression circuit in parallel, and output the compressed image data in parallel and at high frequency through a physical interface.

Optionally, the interface circuit further includes a control interface connected to the compression circuit and the sending module, where the control interface is configured to send configuration information to the compression circuit, where the configuration information includes a compression type of a compression method. The control interface can control the compression type of the image data to be compressed, and the compression type mainly limits the bit width of the pixel points before compression, the bit width of the pixel points after compression and the bit width of the pixel points after decompression. Specifically, the compression type may be indicated as X-Y-Z, where X represents a pixel bit width before compression, Y represents a pixel bit width after compression, and Z represents a pixel bit width after decompression. And in this embodiment, the compression type may be, for example: 12-8-12, 12-7-12, 12-6-12, 10-8-10, 10-7-10, 10-6-10, 8-6-8, 8-7-8

Optionally, the control interface may include an I2C interface.

Optionally, the interface circuit may further include an internal test module connected to the compression circuit, and configured to send test image data to a wavelet transform module in the compression circuit, so that the compression circuit performs compression coding on the test image data to test whether the compression circuit of the image data operates normally. The method for testing whether the compression circuit normally works according to the test image data may specifically refer to the description in step 100, which is not described herein again in this embodiment.

Optionally, in this embodiment, the control interface is further configured to be connected to the internal test module, so as to configure a data type and a data size of the test image data, where the data type of the test image data may be one of RAW8, RAW10, and RAW12, and the data size of the test image data may be less than or equal to 4M.

Optionally, the interface circuit may be specifically configured in the MIPI interface. The MIPI can support four-channel parallel input and four-channel parallel output at most, the clock frequency of the four-channel parallel input can reach 187.5Mhz at most, the bit rate of each channel output can reach 1.5Gbit/s, and the bit rate of the four-channel parallel output can reach 6Gbit/s at most.

Optionally, the compression circuit is further configured to receive original image data sent by an external camera, so as to compress the original image data.

In summary, in the method for compressing image data and the interface circuit provided by the present invention, when compressing image data, one-dimensional wavelet transform is performed on each pixel point of the image data to be compressed to obtain transformed data, then quantization processing is performed on the transformed data to obtain a quantization coefficient, and finally zero run coding is performed on the quantization coefficient to obtain the compressed image data. Therefore, when the data is compressed, each pixel point is compressed and coded in a clock pipeline-based mode, the requirement on the correlation among the pixel points is low, namely, when each pixel point is coded, coding is not needed based on the coding results of other pixel points, and the phenomenon that when a certain pixel point is coded, the coding result of the previous pixel point needs to be decoded first to obtain a decoding value and then the coding is carried out can not occur. Therefore, when a plurality of pixel points are input by adopting multiple channels, the plurality of pixel points can be coded simultaneously, and the coding results of the pixel points can be simultaneously obtained and then simultaneously output, so that the delay is reduced, the coding efficiency and the output frequency are improved, and high-frequency output can be realized.

In addition, in this embodiment, when each pixel is encoded, since the encoding result of other pixels does not need to be applied, the encoding results of other pixels do not need to be stored. Compared with the coding result of the previous pixel point of the current pixel point and the decoding value corresponding to the coding result which need to be stored in the related technology, the compression method of the invention can also reduce the storage space.

In addition, the one-dimensional wavelet transform method adopted in the invention has a simple realization mode of performing wavelet transform on image data to be compressed, and can reduce the calculation amount without applying a multiplier.

The compression circuit and the interface circuit provided by the invention are simple and occupy small area, and meanwhile, the interface circuit can compatibly receive various data types through an external configurable register, so that various types of data can be compressed and coded.

The embodiments in the present description are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. For the system disclosed by the embodiment, the description is relatively simple because the system corresponds to the method disclosed by the embodiment, and the relevant points can be referred to the method part for description.

The above description is only for the purpose of describing the preferred embodiments of the present invention, and is not intended to limit the scope of the present invention, and any variations and modifications made by those skilled in the art based on the above disclosure are within the scope of the appended claims.

12页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:视频弹幕的显示控制方法、装置、存储介质和电子设备

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!

技术分类