Summary of the invention
One embodiment of the invention provides a kind of method for compressing image, and step includes: to divide generator by a segment to receive
One input image;By segment divide generator judge input image whether correspond to a local updating region and with a present frame
A segment or multiple segments combination be overlapped, and generate a judging result;And generator is divided according to sentencing by segment
Disconnected result decides whether to repartition segment and a part of present frame is re-compressed and encoded.
Another embodiment of the present invention also provides a kind of image processing system, including a segment divide generator, an encoder,
One frame buffer and a decoder.Segment divides generator to receive an input image, judges whether input image corresponds to
In a local updating region and the above-mentioned input image in the case where above-mentioned input image corresponds to above-mentioned local updating region
Whether it is overlapped with the combination of a segment of a present frame or multiple segments, and generates a judging result, and is tied according to judgement
Fruit decides whether to repartition segment.
An embodiment according to the present invention corresponds to a local updating region and local updating region in response to input image
When being overlapped with the combination of the segment of present frame or multiple segments, encoder is also to the input image for corresponding to local updating region
It is compressed and is encoded, to generate the image data for corresponding to local updating region, and local updating region will be corresponded to
Image data store into frame buffer.
Another embodiment according to the present invention, segment divide generator also according to the location information for corresponding to local updating region
The location information for corresponding to a non-update area is obtained, to export a local updating signal to decoder, decoder is also according to upper
It states local updating signal and corresponds to the image information of non-update area from one frame buffer access, and non-update area will be corresponded to
Image information store into frame buffer and decoder is also according to corresponding to the image data in local updating region and right
The image information of Ying Yuwei update area exports a next frame.
Another embodiment according to the present invention corresponds to local updating region, but local updating region in response to input image
When not being overlapped with the combination of the segment of present frame or multiple segments, segment divides generator also according to the ruler in local updating region
It is very little to repartition segment, so that segment and local updating area coincidence, take according to the location information for corresponding to local updating region
The location information corresponding to a non-update area is obtained, to export a local updating signal to decoder, decoder is also according to part
More new signal accesses the image information for corresponding to non-update area and encoder from frame buffer also to corresponding to local updating
The input image in region and image information corresponding to non-update area are compressed and are encoded, and are corresponded to generating
The image data of one frame, and the image data for corresponding to next frame is stored to frame buffer.
Another embodiment according to the present invention, when corresponding to a complete image in response to input image, segment divides generator
Also by the dimensional configurations of segment be it is identical as the size of complete image, encoder also compresses complete image and is encoded,
To obtain the image data for corresponding to a next frame, and the image data for corresponding to next frame is stored into one frame buffer.
The gate circuit quantity that hardware module development according to the present invention is simple, uses is few and low in energy consumption, is suitable for
Various types of panel driving chip.
Specific embodiment
Explanation is completes the relatively good implementation invented below, its object is to describe essence spirit of the invention, but simultaneously
Not to limit the present invention.Actual summary of the invention must refer to the scope of the claims.
It will be appreciated that using words such as "comprising", " comprising " in this manual, to indicate that there are specific skills
Art feature, numerical value, method and step, operation processing, element and/or component, but be not precluded can plus more technical characteristics,
Numerical value, method and step, operation processing, element, component or above any combination.
Fig. 2 is the block diagram for showing image processing system described in an embodiment according to the present invention.As shown in Fig. 2, image
Processing system 100 includes at least a segment and divides generator 110, an encoder 120, one frame buffer 130 and a decoder
140.Segment divides generator 110 to receive an input image from operating system (OS), and is sentenced according to the type of input image
It is disconnected whether to need to access the partial image information (such as pixel value etc.) for corresponding to current image from frame buffer 130, to produce
The raw image information for corresponding to next frame.Wherein, the image modality that operating system is exported is complete comprising one corresponding to entire frame
Whole image or the image for corresponding only to a local updating region.And in response to input image for corresponding to local updating area
When the image in domain, operating system also exports the location information corresponding to local updating region.Encoder 120 is to divide segment
110 image output information of generator are compressed and are encoded, and are stored into frame buffer 130.Decoder 140 is used
To correspond to the image data of next frame from the access of frame buffer 130, and it is decoded, in a display (not shown)
Upper display corresponds to the image of next frame.In addition, when being the image corresponding to local updating region in response to input image, decoding
Device 140 also divides the reception of generator 110 from segment and corresponds to the location information in local updating region, and is obtained according to location information
Corresponding to the location information of non-update area, to decode the image information for corresponding to non-update area, and image information is transmitted
It returns block and divides generator 110.It is worth noting that, image processing system 100 also may include other components, and the configuration of component
May with not homologous ray and it is different, and can be presented by various different modes, without being limited with the example of Fig. 2.In addition, segment is drawn
Mitogenetic grow up to be a useful person 110 can be realized by logic circuit.
An embodiment according to the present invention, dividing input image received by generator 110 in response to segment is complete shadow
When picture, it is identical as the size of complete image that segment, which divides generator 110 for the dimensional configurations of segment, and input image is exported
Into encoder 120.Then, encoder 120 is compressed and is encoded to input image, corresponds to input image to generate
Image data, and stored into frame buffer 130.Finally, decoder 140 in display correspond to next frame image when,
The image data being stored in frame buffer 130 can be decoded, to obtain the image information for corresponding to next frame.
Another embodiment according to the present invention divides input image received by generator 110 in response to segment and corresponds to
When the combination of segment or multiple segments that local updating region and local updating region have been divided with present frame is overlapped, segment
It divides generator 110 and location information corresponding to local updating region is sent to decoder 140, so that decoder 140 can root
According to location information corresponding to the non-update area of positional information calculation corresponding to local updating region, with from frame buffer 130
Middle access corresponds to the image data of non-update area, and is decoded to it.Then, decoder 140 is by decoded correspondence
Segment is back in the image information of non-update area and divides generator 110, so that segment divides generator 110 and will can not update
Image information corresponding to region and the image information of input image are combined into the image information corresponding to next frame, and by its
Storage is into frame buffer 130.Wherein, the image information as corresponding to local updating region and the image information of former frame be not
Together, therefore encoder 120 will be re-compressed and be encoded to input image.Further, since corresponding to non-update area
Image information is identical as the image information of former frame, that is, correlation when encoding between pel simultaneously has not been changed, therefore encoder 120 is simultaneously
It does not need again to encode non-update area, to increase the efficiency of image compression.
Another embodiment according to the present invention corresponds to local updating region and local updating region in response to input image
When the combination of the segment or multiple segments that have divided with present frame is not overlapped, segment divides generator 110 will be according to part more
Segment is repartitioned in the size of new region and position.For example, as shown in Figure 3A, in the image corresponding to present frame,
Segment divides generator 110 and whole image 300 is divided into the identical multiple band 310a~310n of height (such as Fig. 3 A institute
Show), and each band is compressed and encoded.However, the height due to new local updating region is less than band 310a
The height of~310n, therefore segment divides generator 110 and will further divide to the band where local update area,
And the band where local update area is re-compressed and encoded.
For example, be located in band 310a in response to local updating region, and its height be less than band 310a when, segment
It divides generator 110 and band 310a is divided further into the identical multiple sub- band 320a~320n of height (such as Fig. 3 B institute
Show, be that band 310a is divided into 3 sub- band 320a~320c in this example), and judge divided sub- band 320a
Whether the height of~320c is identical as the height in local updating region and is overlapped.In this embodiment, it is assumed that local updating area
The height in domain is just identical as the height of each of sub- band 320a~320c, and when being just overlapped with sub- band 320b, figure
Block divides generator 110 also judges whether the width in local updating region is of same size with sub- band 320b.For example, such as
Shown in Fig. 3 C, local updating region is located at the position of 330b, but its width is still less than the width of sub- band 320b, therefore segment is drawn
Sub- band 320b is divided into 3 segment 330a~330c by mitogenetic 110 positions based on local updating region of growing up to be a useful person.Finally, in
After segment divides the division that generator 110 completes segment, according to image information corresponding to non-update area and input image
The image information in corresponding local updating region is compressed and is recompiled via encoder 120, and will be after coding
Image data is stored in frame buffer 130.Wherein, the image information corresponding to non-update area passes through decoder in advance
140 read the image information of corresponding position in present frame from frame buffer 130.
It is worth noting that, when segment divides width of the generator 110 based on local updating region to band or sub- band
When carrying out segment division, segment size corresponding to local updating region may be different from the size of other segments.In other words, when
When segment division generator 110 carries out longitudinally divided, do not need for the size of segment to be divided into identical.In addition to this, work as figure
After block divides the division that generator 110 completes segment, also by cached location information corresponding to each segment in a pattern information
In record sheet, judge whether to need to segment again based on the position of next input image so that segment divides generator 110
It divides.
Fig. 4 A, 4B are the flow charts for showing the method for compressing image in another embodiment according to the present invention.In step S401,
Segment divides generator 110 and receives location information corresponding to input image and input image.In step S402, segment is divided
Generator 110 judges whether input image is a complete image.In response to input image be complete image when, enter step
S403, segment divide generator 110 segment is sized to it is identical as the size of complete image, and pass through encoder 120
Segment is compressed and is encoded to obtain the image data (step S404) for corresponding to next frame, and image data is stored up
It deposits into frame buffer 130 (step S405).
When corresponding to a local updating region conversely, in response to input image, S406 is entered step, segment divides generator
110 judge office corresponding to input picture according further to segment size and position recorded in pattern information record sheet
Portion's update area whether with segment at least one or a combination thereof be overlapped.Wherein, in response to local updating region and segment
When at least one or a combination thereof is overlapped, S407 is entered step, segment divides generator 110 will be corresponding to local updating region
Position is sent in decoder 140, so that the position according to corresponding to local updating region of decoder 140 calculates non-update area
Position, with from frame buffer 130 access correspond to non-update area image data.In step S408, encoder 120 is right
Image information corresponding to input image is compressed and is encoded to obtain the image data for corresponding to local updating region.In
Step S409, encoder 120 will correspond to the image data in local updating region and corresponding to the image numbers of non-update area
According to being stored in frame buffer 130.
However, in response to local updating region and segment at least one or a combination thereof be not overlapped when, enter step
S410, segment divides generator 110 and repartitions segment based on the size in local updating region, so that segment and local updating area
Domain is overlapped.In step S411, for non-update area, segment divides generator 110 and counts also according to the position in local updating region
The position of non-update area is calculated, to access the image number corresponding to non-update area from frame buffer 130 by decoder 140
According to.In step S412, encoder 120 again to image information corresponding to input image and non-update area compressed with
And coding corresponds to the image data in local updating region and corresponding to the image data of non-update area to obtain.Finally,
In step S413, encoder 120 will correspond to the image data in local updating region and corresponding to the image of non-update area
Data storage is in frame buffer 130, so that decoder 140 is decoded to export to display.
Fig. 5 is the block diagram for showing another image processing system as described in the examples according to the present invention.As shown in figure 5,
Image processing system 500 includes at least an encoder 510, one frame buffer 520 and a decoder 530.Encoder 510 is at least
Including a multiple selector 511 and a coding core 512.Multiple selector 511 corresponds to local updating region to receive
Image information and location information corresponding to local updating region, and it is according to the position in local updating region that image information is defeated
Out to coding core 512 to be compressed and be decoded to image information.Frame buffer 520 corresponds to the shadow of a frame to access
As data.Decoder 530 includes at least a main decoding core 531 and a collaboration decoding core 532.Main decoding core 531 to
The image data for corresponding to next frame from the access of frame buffer 520, to be decoded to image data and by decoded image
Information is exported to a display (not shown).Collaboration decodes core 532 to decode segment involved in local updating region, and will
Decoded image information is back to multiple selector 511.Wherein, it may also include a buffer in multiple selector 511, to
It is temporary to decode the received image information of core 532 from collaboration.
It is (wherein defeated from operating system to receive input image in response to multiple selector 511 for an embodiment according to the present invention
It is corresponding to a local updating region to enter image) after, collaboration decoding core 532 is according to the location information of input image (by operating system
Exported) image data of segment corresponding to local updating region is accessed and decoded from frame buffer 520, and will be decoded
Image information be back in multiple selector 511.Then, coding the position according to corresponding to local updating region of core 512 with
And returned by collaboration decoding core 532 and the segment is compressed and encoded again corresponding to the image information of the segment, with
Refresh the image data being originally stored in frame buffer 520.For example, as shown in fig. 6, region 622 is local updating area
Domain, region 621 is non-update area and region 620 is segment corresponding to local updating region.Side according to the present invention
Method, after receiving image information and location information corresponding to region 622 in response to multiple selector 511, collaboration decoding core
The 532 i.e. location information according to received by from operating system corresponds to the image number of segment 620 from the access of frame buffer 520
According to, and it is decoded, will be decoded after image information (the i.e. picture included in segment 620 corresponding to segment 620
Element) it is back to multiple selector 511.Multiple selector 511 is after receiving the image information corresponding to segment 620, according to office
The position of portion's update area sequentially by image corresponding to image information corresponding to segment 621 and local updating region believe
Coding core 512 is given in breath output, so that the pixel in coding verification segment is sequentially compressed and encoded again, to generate correspondence
In the image data of next frame.
It is worth noting that, although the size in local updating region is less than the size of segment, being compiled in this embodiment
Code device 510 can't change the size of segment, and by re-starting coding to segment corresponding to local update area.
Fig. 7 is the flow chart for showing another method for compressing image as described in the examples according to the present invention.In step S701,
Multiple selector 511 receives the input image for corresponding to local updating region from operating system.In step S702, multiple selector
511 judge segment corresponding to input image, and the enable collaboration decoding segment according to corresponding to input image of core 532 is slow from frame
It rushes device 520 and accesses image data corresponding to segment, and image data is decoded to be back to (the step of multiple selector 511
Rapid S703).In step S704, the location information according to corresponding to local updating region of multiple selector 511 sequentially output pixel
To coding core 512, again to the image for corresponding to non-update area in image information corresponding to input image and segment
Information is compressed and is encoded.Finally, in step S705, coding core 512 is by image data corresponding to segment and other
Image data corresponding to non-update area is stored in frame buffer 520, for mainly decoding core 531 before showing next frame
It is accessed and is decoded.
It is worth noting that, although the above method is retouched on the basis of using the flow chart of series of steps or box
State, but the present invention is not limited to the sequence of these steps, and some steps may differ from remaining step sequence execute or its
Remaining step can carry out simultaneously.In addition, those skilled in the art will be appreciated that step shown in flow charts is not unique,
It may include that other steps of flow chart or one or more steps can be deleted without will affect the scope of the present invention.
In conclusion image processing system according to the present invention and method for compressing image, the present invention can flexible twelve Earthly Branches
The local updating region of various sizes is held, while retaining the correlation between pel value to greatest extent, is reaching 1/2 or even 1/
Guarantee that subjective vision is substantially lossless in the case where 3 compression ratio.Meanwhile when local update area is not overlapped with existing segment
When, segment can be repartitioned, adaptively to reach optimal compression coding picture quality.In addition, according to the present invention hard
The gate circuit quantity that part module design is simple, uses is few and low in energy consumption, suitable for various types of panel driving chip.
The foregoing is merely present pre-ferred embodiments, the range that however, it is not to limit the invention is any to be familiar with sheet
The personnel of item technology can do further improvements and changes without departing from the spirit and scope of the present invention on this basis,
Therefore protection scope of the present invention should be subject to the range that following claims are defined.