Coding apparatus, decoding apparatus, coding method, decoding method, computer readable medium and computer data signal

Information

  • Patent Application
  • 20070188356
  • Publication Number
    20070188356
  • Date Filed
    September 13, 2006
    18 years ago
  • Date Published
    August 16, 2007
    17 years ago
Abstract
A coding apparatus includes a predicting unit, an intermediate-code generating unit, a first coding unit and a second coding unit. The predicting unit generates a piece of prediction data based on each piece of pixel data constituting a color image. The intermediate-code generating unit compares each piece of prediction data with the corresponding piece of pixel data, to generate an intermediate code in accordance with whether or not a difference between each piece of prediction data and the corresponding piece of pixel data is in a predetermined range. The first coding unit performs entropy coding on the generated intermediate code. The second coding unit performs entropy coding on the generated intermediate code. The intermediate-code generating unit assigns each generated intermediate code to either of the first and second coding units according to whether or not the difference is in the predetermined range.
Description

BRIEF DESCRIPTION OF THE DRAWINGS

Exemplary embodiments of the invention will be described in detail based on the following figures, wherein:



FIG. 1 is a view showing the hardware configuration of an image processing apparatus 2 which has a control device 21 as a chief topic and to which a coding method and a decoding method according to an exemplary embodiment of the invention are applied;



FIG. 2 a block diagram showing the functional configuration of a first coding program 5 executed by the control device 21 (FIG. 1) to achieve the coding method according to the exemplary embodiment of the invention;



FIG. 3 is a flow chart of a coding process (S10) to be performed by a coding program 5 (FIG. 2);



FIGS. 4A to 4C are views showing data generated in the coding process (S10);



FIG. 5A is a view for explaining code data 900 generated by the coding process (S10), and FIG. 5B is a view for explaining code data obtained by coding respective color components simply by a run-length coding system;



FIG. 6 is a block diagram showing the functional configuration of a first decoding program 6 executed by the control device 21 (FIG. 1) to achieve of the decoding method according to the exemplary embodiment of the invention;



FIG. 7 is a flow chart of a decoding process (S20) to be performed by the decoding program 6 (FIG. 6);



FIGS. 8A to 8C are views for explaining a predictive coding system used in a second exemplary embodiment;



FIGS. 9A to 9C are views for explaining code data generated by the predictive coding system described in FIGS. 8A to 8C;



FIG. 10 is a block diagram showing the functional configuration of a second coding program 7 executed by the control device 21 (FIG. 1) to achieve a coding method according to the exemplary embodiment of the invention;



FIG. 11 is a flow chart of a coding process (S30) to be performed by the coding program 7 (FIG. 10);



FIG. 12 is a block diagram showing the functional configuration of a second decoding program 8 executed by the control device 21 (FIG. 1) to achieve a decoding method according to the exemplary embodiment of the invention;



FIG. 13 is a flow chart of a decoding process (S40) to be performed by the decoding program 8 (FIG. 12); and



FIG. 14 is a modification of the coding program in the first exemplary embodiment.


Claims
  • 1. A coding apparatus comprising: a predicting unit that generates a piece of prediction data based on each piece of pixel data constituting a color image;an intermediate-code generating unit that compares each piece of prediction data with the corresponding piece of pixel data, to generate an intermediate code in accordance with whether or not a difference between each piece of prediction data and the corresponding piece of pixel data is in a range;a first coding unit that performs entropy coding on the intermediate code generated by the intermediate-code generating unit; anda second coding unit that performs entropy coding on the intermediate code generated by the intermediate-code generating unit, wherein:the intermediate-code generating unit assigns each generated intermediate code to either of the first and second coding units in accordance with whether or not the difference between the corresponding piece of prediction data and the corresponding piece of pixel data is in the range.
  • 2. The apparatus according to claim 1, wherein: when the difference between each piece of prediction data and the corresponding piece of pixel data is in the range, the intermediate-code generating unit assigns to the first coding unit coincidence information indicating that prediction of the corresponding piece of pixel data is true,when the difference between each piece of prediction data and the corresponding piece of pixel data is out of the range, the intermediate-code generating unit assigns to the second coding unit a plurality of color-component values included in the corresponding piece of pixel data,the first coding unit performs the entropy coding on a first intermediate code, which relates to a plurality of color components, andthe second coding unit performs the entropy coding on second intermediate codes, which relate to the plurality of color components, respectively.
  • 3. The apparatus according to claim 2, wherein: the second coding unit comprises a plurality of entropy coders each for performing the entropy coding,when the difference between each piece of prediction data and the corresponding piece of pixel data is out of the range, the intermediate-code generating unit assigns to the plurality of entropy coders of the second coding unit the plurality of color-component values included in the corresponding piece of pixel data, respectively, andthe plurality of entropy coders perform the entropy coding on the assigned color-component values concurrently.
  • 4. The apparatus according to claim 1, wherein: when the difference between each piece of prediction data and the corresponding piece of pixel data is in the range, the intermediate-code generating unit assigns to the first coding unit coincidence information indicating that prediction of the corresponding piece of pixel data is true, andwhen the difference between each piece of prediction data and the corresponding piece of pixel data is out of the range, the intermediate-code generating unit assigns to the first coding unit literal information indicating that the prediction of the corresponding piece of pixel data is false and assigns to the second coding unit a plurality of color-component values included in the corresponding piece of pixel data,the first coding unit performs the entropy coding on the coincidence information and the literal information assigned by the intermediate-code generating unit, andthe second coding unit performs the entropy coding on the plurality of color components values assigned by the intermediate-code generating unit.
  • 5. The apparatus according to claim 1, wherein: when the difference between each piece of prediction data and the corresponding piece of pixel data is in the range, the intermediate-code generating unit assigns to the first coding unit coincidence information indicating that prediction of the corresponding piece of pixel data is true,when the difference between each piece of prediction data and the corresponding piece of pixel data is out of the range, the intermediate-code generating unit assigns to the second coding unit prediction error values for the plurality of color components,the first coding unit performs the entropy coding on a first intermediate code, which relates to a plurality of color components, andthe second coding unit performs the entropy coding on second intermediate codes, which relate to the plurality of color components, respectively.
  • 6. The apparatus according to claim 5, wherein: the second coding unit comprises a plurality of entropy coders each for performing the entropy coding,when the difference between each piece of prediction data and the corresponding piece of pixel data is out of the range, the intermediate-code generating unit assigns to the entropy coders of the second coding unit the prediction error values for the plurality of color components, respectively, andthe plurality of entropy coders perform the entropy coding on the assigned prediction error values concurrently.
  • 7. The apparatus according to claim 1, wherein: when the difference between each piece of prediction data and the corresponding piece of pixel data is in the range, the intermediate-code generating unit assigns to the first coding unit coincidence information indicating that prediction of the corresponding piece of pixel data is true,when the difference between each piece of prediction data and the corresponding piece of pixel data is out of the range, the intermediate-code generating unit assigns to the first coding unit literal information indicating that the prediction of the corresponding piece of pixel data is false and assigns to the second coding unit prediction error values for the plurality of color components,the first coding unit performs the entropy coding on the coincidence information and the literal information assigned by the intermediate-code generating unit, andthe second coding unit performs the entropy coding on the prediction error values assigned by the intermediate-code generating unit.
  • 8. A coding apparatus comprising: an intermediate-code generating unit that generates intermediate codes as entropy-coding-process targets from an input color image;a first coding unit that performs entropy coding on a first intermediate code, which is common to a plurality of color components of one and the same pixel, among the intermediate codes generated by the intermediate-code generating unit, to generate a single code corresponding to the first intermediate code for the plurality of color components of the pixel; anda second coding unit that performs the entropy coding on second intermediate codes unique to the color components, among the intermediate codes generated by the intermediate-code generating unit.
  • 9. The apparatus according to claim 8, wherein: the intermediate-code generating unit predicts pixel values of the respective color components to generate coincidence information indicating whether or not prediction is true and the pixel values of the respective color components as the intermediate codes,the first coding unit performs the entropy coding on the coincidence information generated by the intermediate-code generating unit, andthe second coding unit performs the entropy coding on the pixel values of the respective color components generated by the intermediate-code generating unit.
  • 10. The apparatus according to claim 8, wherein: the intermediate-code generating unit predicts pixel values of the respective color components to generate coincidence information indicating whether or not prediction is true and prediction error values of the respective color components as the intermediate codes,the first coding unit codes the coincidence information generated by the intermediate-code generating unit, andthe second coding unit codes the prediction error values of the respective color components generated by the intermediate-code generating unit.
  • 11. A decoding apparatus for decoding code data of a color image generated by a predictive coding process, the decoding apparatus comprising: a first decoding unit that decodes a code common to a plurality of color components among input code data, to generate an intermediate code common to the plurality of color components;a second decoding unit that decodes a unique code unique to a given color component among the input code data, to generate an intermediate code unique to the color component; andan image generating unit that generates image data of the given color component from the intermediate code decoded by the first decoding unit and the intermediate code decoded by the second decoding unit.
  • 12. A coding method using a plurality of entropy coders, the coding method comprising: generating a piece of prediction data based on each piece of pixel data constituting a color image;comparing each piece of prediction data with the corresponding piece of pixel data, to generate an intermediate code in accordance with whether or not a difference between each piece of prediction data and the corresponding piece of pixel data is in a predetermined range; andassigning each generated intermediate code to any of the plurality of entropy coders in accordance with whether or not the difference between the corresponding piece of prediction data and the corresponding piece of pixel data is in the predetermined range.
  • 13. A decoding method comprising: among input code data, assigning a code common to a plurality of color components to a first entropy decoder, to generate an intermediate code common to the plurality of color components;among the input code data, assigning a unique code unique to a given color component to a second entropy decoder, to generate an intermediate code unique to the color component; andgenerating image data of the given color component using the intermediate codes decoded by the first entropy decoder and the second entropy decoder.
  • 14. A computer readable medium storing a program causing a computer to execute a process for encoding a color image, the process comprising: generating a piece of prediction data based on each piece of pixel data constituting the color image;comparing each piece of prediction data with the corresponding piece of pixel data, to generating an intermediate code in accordance with whether or not a difference between each piece of prediction data and the corresponding piece of pixel data is in a predetermined range; andassigning each generated intermediate code to any of the plurality of entropy coders in accordance with whether or not the difference between the corresponding piece of prediction data and the corresponding piece of pixel data is in the predetermined range.
  • 15. A computer data signal embodied in a carrier wave for enabling a computer to perform a process for encoding a color image, the process comprising: generating a piece of prediction data based on each piece of pixel data constituting the color image;comparing each piece of prediction data with the corresponding piece of pixel data, to generate an intermediate code in accordance with whether or not a difference between each piece of prediction data and the corresponding piece of pixel data is in a predetermined range; andassigning each generated intermediate code to any of the plurality of entropy coders in accordance with whether or not the difference between the corresponding piece of prediction data and the corresponding piece of pixel data is in the predetermined range.
Priority Claims (1)
Number Date Country Kind
2006-033938 Feb 2006 JP national