Image coding apparatus and image decoding apparatus

Abstract: An image coding apparatus which outputs a coded bit stream of moving pictures comprises: a plurality of frame memory groups (43, 44) for storing, individually for a plurality of objects which construct a screen, decoded images of the objects in the past; an image storage controller (35) for selecting, in response to a control signal, a frame memory from a predetermined one of said plurality of frame memory groups (43, 44) into which a decoded image is to be written; a motion compensation prediction unit (21) for selecting one of forward direction prediction, backward direction prediction, bidirection prediction and background prediction in individual objects using reference images read out from frame memories of said plurality of frame memory groups (43, 44) provided for the individual objects to perform motion compensating prediction; a subtractor (2) for calculating a difference between the predicted image and a current image to calculate a prediction error image; an adding unit (8) for adding the predicted image from the reference images and the prediction error image of the current image; and a variable length coding unit (17) for variable length coding information.

Description: BACKGROUND OF THE INVENTION Field of the Invention This invention relates to an image coding apparatus and an image decoding apparatus for use with a system which performs high efficiency coding or decoding of moving pictures to perform efficient transmission or storage of images, and more particularly to an image coding apparatus and an image decoding apparatus which can be applied to processing of, for example, a digital broadcasting system which is performed using a satellite or aground wave or cable communication network, a digital video disk, a mobile video phone, a PHS video phone or a data base for images. Description of the Prior Art As a representative one of conventional high efficiency coding systems, the MPEG2 is known which is an international standard system recommended by the ISO/IEC/JTC1/SC29/WG11. For example, "Image Information Engineering and Broadcasting Techniques", Journal of the Television Engineering Society of Japan, April, 1995 explains the MPEG as a theme of special editing. A coding system of the MPEG2 is disclosed in "3-2 Video Compression" of the same document, pp. 29-60. The coding system of the MPEG2 is described below. FIG. 18 is a block diagram showing a basic construction of an ordinary encoder of the MPEG2, and FIG. 19 is a block diagram showing a basic construction of an MPEG2 decoder. Referring to FIGS. 18 and 19, reference numeral 1 denotes a frame re-arranging unit, 2 a subtracting unit, reference characters 3a and 3b denote each an inter(interframe)/intra(intraframe) switching selector, reference numeral 4 denotes a converting unit, 5 a quantizing unit, 6 a reverse quantizing unit, 7 a reverse converting unit, 8 an adder, 9 a first frame memory, 10 a second frame memory, 11 a forward direction motion compensating unit, 12 a bidirection motion compensating unit, 13 a backward direction motion compensating unit, 15 a motion estimating unit, 16 a coding control unit, 17 a variable length coding unit, and 18 a buffer. Further, reference numeral 100 denotes input image data in the form of digital data, 101 re-arranged input image data, 102 a predictive error image, 103 an original input image or predictive error image, 104 a conversion coefficient, 105 a quantization coefficient, 106 a reverse quantized conversion coefficient, 107 reversed converted image data, 108 a locally decoded image, 109 a reference image from the first frame memory, 110 a reference image from the second frame memory, 111 a forward direction motion predicted image, 112 a bidirection motion predicted image, 113 a backward direction motion predicted image, 115 a determined predicted image, 117 a control signal to the selector, 118 a control signal to the converting unit 4, 119 an adaptive quantization value, 120 a variable length coder, 121 a bit stream, 123 a motion vector, 124 a reference image, and 125 an intra/inter switching signal. Operation of the conventional image encoder is described below with reference to FIG. 18. First, an input image signal 100 in the form of a digital signal is inputted to the frame re-arranging unit 1, by which picture frames to be coded are re-arranged. FIG. 20 illustrates such re-arrangement. Referring to FIG. 20, reference character I denotes an intra (intraframe) coded picture, P an interframe coded picture, and B a bidirectional predictive coded picture. It is to be noted that reference numerals 1 to 10 represent an order in time in which they are displayed. The first frame is first coded as an I picture, and then the fourth frame is coded as a P picture, whereupon the already coded I picture is used as a reference frame for prediction. Then, the second frame is coded as a B picture. Thereupon, the I picture of the first frame and the P picture of the fourth frame coded already are used as reference frames for the prediction. In FIG. 20 each arrow mark represents a direction in which prediction is performed. Thereafter, coding is performed in the construction of I, B, B, P, B, B, P, ... by similar processing. Accordingly, the action of the frame re-arranging unit 1 is to re-arrange the input image signal 100, in which the picture frames are arranged in order of time, so that they appear in order of coding in order to allow the processing described above. Subsequently, since predictive coding is not performed for the I picture mentioned above, when the re-arranged image 101 is inputted as it is to the selector 3a, from which it is transmitted as a selector output 103 to the converting unit 4. On the other hand, for predictive coding for the P picture or the B picture mentioned above, the re-arranged image 101 is subtracted from a predicted image 115 by the subtracting unit 2, and a predictive error image 102 is transmitted as the selector output 103 to the converting unit 4. Then, the selector output 103 is inputted to the converting unit 4, and a conversion coefficient 104 is outputted from the converting unit 4. The conversion coefficient 104 passes the quantizing unit 5, and a quantization coefficient 105 is obtained from the quantizing unit 5. The quantization coefficient 105 is coded into a variable length code by the variable length coding unit 17, and a variable length coded word 120 is outputted from the variable length coding unit 17. The quantization coefficient 105 is, on the other hand, inputted to the reverse quantizing unit 6, and a quantization coefficient 106 is outputted from the reverse quantizing unit 6. Further, the quantization coefficient 106 is reverse converted back to an image level by the reverse converting unit 7, and image data 107 is outputted from the reverse converting unit 7. The image data 107 is, where it is data of the I picture, added to a predicted image 116 selected by the adding unit 8, and a locally decoded image 108 is outputted from the adding unit 8. It is to be noted that the locally decoded image 108 is written as it is into the first frame memory 9 when it is an I picture, but, when it is a P picture, it is written into the second frame memory 10. On the other hand, when the locally decoded image 108 is a B picture, it is written into none of the first frame memory 9 and the second frame memory 10. Thereafter, when the locally decoded image 108 is a P picture, since only forward prediction is used to predict a P picture, a reference image 124 in the first frame memory 9 is read out, and motion prediction is performed for each macroblock (basic unit for processing of 16 pixels x 16 lines) by the motion estimating unit 15. The motion estimating unit 15 thus selects one of the macroblocks which has a value nearest to that of the current macroblock as a predicted image, and simultaneously outputs a motion vector 123 therefrom. The motion vector 123 is inputted to the motion compensating units 11, 12 and 13 surrounded by a dotted line in FIG. 18 and motion predictive pictures are outputted from the motion compensating units 11, 12 and 13. In this instance, the forward direction motion compensating unit 11 produces a forward direction motion predicted image 111 using a reference image 109 from the first frame memory 9 and outputs a thus determined predicted image 115. Further, as described hereinabove, the locally decoded images 108 of all macroblocks in a P picture are written into the second frame memory. However, even with the P picture mentioned above, when the macroblocks thereof are intraframe (intra) coded, the frame re-arranged image 101 is outputted directly as the selector output. Meanwhile, for a B picture, the procedure of coding processing is similar to that for a P picture described above, but different from the processing for a P picture, two reference frames are used for prediction. The motion estimating unit 15 performs forward direction prediction using the reference image 109 from the first frame memory 9, backward direction prediction using a reference image 110 from the second frame memory 10, and bidirection prediction using both of the reference images 109 and 110 to select one of the prediction modes with which a value nearest to that of the current macroblock is obtained, and outputs a motion vector 123 then. In accordance with the thus determined prediction mode, in the motion compensating unit, one of the motion compensating units 11, 12 and 13 which corresponds to the determined prediction mode produces and outputs a predicted picture. For example, when bidirection motion prediction is selected, the bidirection motion compensating unit 12 produces and outputs a predicted image 115 determined using a bidirection predicted image 112. After coding of the B pictures of the second and third frames shown in FIG. 20 is completed, image data written in the second frame memory is transferred to the first frame memory. Thereafter, the P picture of the seventh frame is coded, and a decoded picture is written into the second frame memory. Thereafter, B pictures (fifth and sixth frames) are coded by similar processing to that described above. When the macroblocks are intraframe (intra) coded, the image 101 after frame re-arrangement is directly outputted as the selector output similarly as in the case of a P picture. FIG. 19 is a block diagram of a conventional decoder. Referring to FIG. 19, reference character 22 denotes a variable length decoding unit, 107(a) an intra (intraframe) coded picture, and 107 (b) a prediction error picture. Subsequently, operation of the conventional decoder will be described. A bit stream 121 is stored for a certain period of time into the receiving buffer 18, and a variable length coded word 120 is variable length decoded by the variable length decoding unit 22 and outputted as a quantization coefficient 105. The processing procedure after this is quite similar to the local decoding processing of the encoder described hereinabove. When the macroblock is intra decoded, a reverse converted image 107 makes an image 107(a) without passing the adding unit 8, but when the macroblock is inter (interframe) decoded, the reverse converted image data 107 makes an image 107(b). The image 107(b) is added to a predicted image 115 by the adding unit 8, and a decoded image 108 is outputted from the adding unit 8. The decoded image 108 is processed by the displayed frame re-arranging unit 38 such that such decoded images are re-arranged so that they appear in order of time, and finally, an output image 137 is outputted the displayed frame re-arranging unit 38. The example of a conventional image coder and image decoder described above is a representative apparatus of a type which performs forward direction, bidirection and backward direction prediction coding in combination. In the example, for coding of a P picture, only forward direction prediction is performed using the first frame memory to perform predictive coding. On the other hand, for coding of a B picture, one of the modes of forward direction prediction, backward direction prediction and bidirection prediction with which a minimum predictive error is provided is selected using the first and second frame memories. Accordingly, as coding processing proceeds, decoded pictures written in the frame memories are erased. Consequently, for example, even if one of coded pictures processed in the past is similar to a picture of the currently coded frame, since the past decoded pictures have already been erased from the frame memories, the similar coded picture cannot be used for reference, resulting in a subject to be solved in that the efficiency in image processing is low as much. US-A-4,833,535 discloses an image transmission apparatus wherein an input image is divided into blocks, subjected to cosine transform and then converted into a signal of a spatial frequency region. After the cosine transform, the data is subjected to subtraction with respect to first to fourth types of data. Data of the same block of a previous frame is used as the first data to provide a first difference between frames. Data of different blocks in the same frame is used as the second data to provide a second difference within the same frame. The third data is background image data and the fourth data is specific data. The minimum one of the first to fourth difference data is selected, and is then quantized and transmitted. K. Asai, T. Fukuhara: "Core Experiments of Video coding with Block-Partitioning and Adaptive Selection of Two Frame Memories (STFM/LTFM)" MPEG 96/0654, ISO/IEC JTC1/SC29/WG11, January 1996, Munich, XP002060567, describes a core experiment which contains two major components: one is adaptive selection of two time-differential frame memories, and the other is block partitioning motion compensation. Main goal for the two components in improvement of motion prediction. Motion compensation using long term frame memory is expected to improve the prediction efficiency when there are some occlusion areas. In addition it also works as a temporal interpolation filter which reduces prediction noises. SUMMARY OF THE INVENTION It is an object of the present invention to provide, in order to solve the subject of the conventional image encoder and image decoder described above, an image coding apparatus and an image decoding apparatus wherein a decoded image obtained in the past can be utilized efficiently as a reference picture and the overall prediction efficiency is improved to achieve moving picture coding and decoding of a high efficiency. According to a first aspect of the present invention, there is provided an image decoding apparatus which outputs a coded bit stream of moving pictures, comprising a plurality of frame memory groups for storing, individually for a plurality of objects which construct a screen, decoded images of objects in the past, a subtractor for calculating a difference between a predicted image and a current image to calculate a prediction error image, an adding unit for adding the predicted image from reference images and the prediction error image of the current image, a variable length coding unit for variable length coding information, an image storage controller for selecting, in response to a control signal, a frame memory from a predetermined one of the plurality of frame memory groups into which a decoded image is to be written, and a motion compensation predicting unit for selecting one of forward direction prediction, backward direction prediction, bidirection prediction and background prediction in individual objects using reference images read out from frame memories of the plurality of frame memory groups provided for the individual objects to perform motion compensating prediction. According to a second aspect of the present invention, there is provided an image decoding apparatus which decodes a coded bit stream of moving pictures, comprising a plurality of frame memory groups for storing, individually for a plurality of objects which construct a screen, decoded images of the objects, a variable length decoding unit for variable length decoding the coded bit stream, an image storage controller for selecting, in response to a control signal, a frame memory from a predetermined one of the plurality of frame memory groups into which a decoded image is to be written, and a motion compensating unit for selecting one of forward direction prediction, backward direction prediction, bidirection prediction and background prediction in individual objects using reference images read out from frame memories of the plurality of frame memory groups to generate a motion compensated image. The image coding apparatus of the present invention may be constructed such that the re-writing of image contents of a region in which an object which is a subject of coding is included in the plurality of frame memory groups in which coded images of the object in the past are stored is performed after a certain interval of time or in response to a control signal from the outside. The image coding apparatus of the present invention may be constructed such that re-writing of image contents of a region in which an object which is a subject of decoding is included in the plurality of frame memory groups in which coded images of the object in the past are stored is performed after a certain interval of time or in response to a control signal from the outside. The image coding apparatus of the present invention may be constructed such that searching ranges for a motion vector from reference images from the plurality of frame memory groups for the individual objects are variable for the individual objects. The image coding apparatus of the present invention may be constructed such that it further comprises differential vector generation means for storing a motion vector in the past obtained by referring to images from the plurality of frame memory groups for the individual objects and calculating difference vectors separately for the individual objects, wherein the difference vectors are variable length coded. The image decoding apparatus of the present invention may be constructed such that it further comprises a motion vector adding unit for holding decoded motion vectors in the past obtained by referring to images in the plurality of frame memory groups for the individual objects for a certain period of time and adding the motion vectors decoded in the past to the decoded difference vectors to regenerate motion vectors for the individual objects. BRIEF DESCRIPTION OF THE DRAWINGS FIG. 1 is a block diagram of a coding apparatus for moving pictures according to an embodiment which is used for explaining the invention but not covered by the invention but not covered by the invention; FIG. 2 is a block diagram showing an internal construction of a motion estimating unit of the coding apparatus of the embodiment shown in FIG. 1; FIG. 3 is a block diagram showing an internal construction of a motion compensation predicting unit of the coding apparatus of the embodiment shown in FIG. 1; FIG. 4 is a block diagram showing another construction of the coding apparatus for moving pictures according to the embodiment shown in FIG. 1; FIGS. 5A to 5C are diagrammatic views illustrating an example of the relationship between patterns of pictures and prediction modes in the embodiment shown in FIG. 1; FIG. 6 is a block diagram of a decoding apparatus for moving pictures according to an embodiment which is used for explaining the invention but not covered by the invention; FIG. 7 is a block diagram of a motion compensating unit of the decoding apparatus of the embodiment shown in FIG. 6; FIG. 8 is a diagrammatic view illustrating the relationship between pictures and objects; FIG. 9 is a block diagram of a coding apparatus according to embodiments 1 and 6 of the present invention; FIG. 10 is a block diagram of a decoding apparatus according to an embodiment 2 of the present invention; FIG. 11 is a block diagram of a coding apparatus according to embodiments 3 and 6 of the present invention; FIG. 12 is a block diagram of a decoding apparatus according to an embodiment 4 of the present invention; FIG. 13 is a diagrammatic view illustrating re-writing of an image in an object region performed in a coding apparatus according to an embodiment 5 of the present invention; FIG. 14 is a diagrammatic view of a coding apparatus according to an embodiment 7 of the present invention; FIG. 15 is a diagrammatic view of a decoding apparatus according to an embodiment 8 of the present invention; FIG. 16 is a diagrammatic view of a coding apparatus according to an embodiment 9 of the present invention; FIG. 17 is a diagrammatic view of a decoding apparatus according to an embodiment 10 of the present invention; FIG. 18 is a block diagram of a conventional encoder; FIG. 19 is a block diagram of a conventional decoder; and FIG. 20 is a diagrammatic view showing an example of an array of pictures. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS FIG. 1 is a block diagram of a coding apparatus for moving pictures according to an embodiment not covered by the invention. Referring to FIG. 1, reference numeral 21 denotes a motion compensation predicting unit as motion compensation predicting means, 35 a frame memory selecting unit as background image storing control means, and 45 a multiplexing unit. Further, reference numeral 126 denotes a determined motion prediction mode, reference numerals 134 and 135 denote each a selected decoded image, and reference numeral 139 denotes a multiplexed bit stream. Since the other components are similar to those used in the description of the prior art shown in FIGS. 18 to 20, they are denoted by same reference numerals and repetitive description of them is omitted here. Subsequently, operation will be described. Basic coding operation is equivalent to motion compensating prediction + conversion coding described hereinabove in connection with the conventional example. Accordingly, only differences will be described here. A locally decoded image 108 is inputted to the frame memory selecting unit 35, by which it is selected into which one of the first frame memory 9 and the second frame memory 10 it is to be written. Meanwhile, the motion estimating unit 15 reads out reference images 109 and 110 from the frame memories 9 and 10 and outputs a determined motion prediction mode 126 and a motion vector 123 with which the prediction error of the locally decoded image 108 from the re-arranged input image data 101 is minimized. The motion compensation predicting unit 21 reads out the reference images 109 and 110 and outputs a motion predicted image 115 based on the determined motion prediction mode 126 and the motion vector 123. The bit stream 121 is multiplexed together with the prediction mode 126 by the multiplexing unit 45 and forwarded from the multiplexing unit 45. The foregoing is the basic operation of the image coding apparatus of the embodiment shown in FIG. 1. In the following, details of the individual units will be described. FIG. 2 shows an internal construction of the motion estimating unit 15. Referring to FIG. 2, reference numeral 27 denotes a forward direction predicted image generating unit, 28 a bidirection predicted image generating unit, 29 a backward direction predicted image generating unit, 30 a background predicted image generating unit, 31 a prediction mode determining unit, 127 a forward direction predicted image, 128 a bidirection predicted image, 129 a backward direction predicted image, and 130 a background predicted image. Subsequently, operation of the motion estimating unit 15 will be described. Each of the predicted image generating units 27, 28, 29 and 30 generates a predicted image in accordance with a predetermined prediction mode. For example, the forward direction predicted image generating unit 27 reads out reference images 109 from the first frame memory 9 and searches the reference images 109 for an image which has a value nearest to the value of the input image data 101. To this end, for example, a block matching method which is employed also in the conventional example described in connection with the prior art may be used as it is. In particular, matching is performed for all pixels in macroblocks described above, and an image wherein the sum total of error values exhibits a minimum value is searched for. As a result, the forward direction predicted image generating unit 27 outputs a forward direction predicted image 127. The backward direction predicted image generating unit 29 performs searching of reference images 110 from the second frame memory 10 and then performs block matching similarly. Then, the backward direction predicted image generating unit 29 outputs a backward direction predicted image 129. The bidirection predicted image generating unit 28 outputs a bidirection predicted image 128 using the two frame memories 9 and 10. The bidirection predicted image generating unit 28 generates a forward direction predicted image and a backward direction predicted image separately from each other, and generates a bidirection predicted image based on those images. For example, a technique wherein an average image of the forward direction predicted image and the backward direction predicted image is obtained and determined as a bidirection predicted image 128 may be used. Meanwhile, the background predicted image generating unit 30 reads out a reference image 110 from the second frame memory and outputs a background predicted image 130 by block matching. The prediction mode determining unit 31 inputs predicted images selected in the predicted images 127, 128, 129 and 130 and selects a prediction mode in which the difference (prediction error) from the input image 101 is minimized. In this instance, a prediction mode 126 and a motion vector 123 are outputted from the prediction mode determining unit 31. The prediction mode 126 may be determined such that, for example, it has a value 0 for the forward direction prediction mode, another value 1 for the backward direction prediction mode, a further value 2 for the bidirectional prediction mode, and a still further value 3 for the background prediction mode. It is to be noted that processing operation of the motion vector 123 generated by and outputted from the prediction mode determining unit 31 of FIG. 2 is such as follows. In particular, when searching of reference images is performed within a predetermined range and a predicted image which exhibits a minimum prediction error is obtained by each of the predicted image generating units, motion vectors 123(a), 123(b), 123(c) and 123(d) are outputted from the predicted image generating units 27 to 30 together with the predicted images, respectively. The outputs are all inputted to the prediction mode determining unit 31, by which one of the predicted images 127, 128, 129 and 130 which exhibits a minimum error from the current image 101 is selected. Thus, the motion vector (one of the motion vectors 123(a), 123(b), 123(c) and 123(d)) which provides the minimum value is finally outputted as a motion vector 123 from the prediction mode determining unit 31. FIG. 3 is a block diagram showing an internal construction of the motion compensation predicting unit 21. Referring to FIG. 3, reference numerals 24 and 26 denote each a selector (switch), and reference numeral 114 denotes a background predicted image. Subsequently, operation will be described. In the switch 24, two switches SW1 and SW2 are opened or closed in accordance with the determined motion prediction mode 126. For example, when the prediction mode 126 outputted from the prediction mode determining unit 31 indicates the bidirection prediction image mode, the switch SW1 of the selector 24 selects a node B and the switch SW2 selects another node C. On the other hand, when the background prediction mode is selected, the switch SW1 is OFF (provides no selection) and the switch SW2 selects a further node E. In the former case, the bidirection motion compensating unit 12 generates a bidirection predicted image 112 using a motion vector 123. Simultaneously, the output node from the bidirection motion compensating unit 12 is selected by the switch 26. Consequently, the bidirection predicted image 112 from the motion compensation predicting unit 21 is outputted as a determined predicted image 115. Further, while the embodiment described above is constructed such that it includes a motion estimating unit and a motion compensation predicting unit separately from each other and a prediction mode and a motion vector obtained by the motion estimating unit are sent to the motion compensation predicting unit so that a predicted image is generated by the motion compensation predicting unit, an equivalent function can be realized even by such a construction that the two units are replaced by a motion estimating/compensating unit 39 as seen in FIG. 4. By the way, in the embodiment described above, similarly as in the conventional example, coding is performed in units of a macroblock which is a processing unit for images. Meanwhile, in the processing of the MPEG2 of the conventional example described in connection with the prior art, three types of pictures including an I picture, a P picture and a B picture are involved, and a prediction mode is restricted by those pictures. In particular, in an I picture, all macroblocks are intra coded, and no prediction mode is involved. In a P picture, only forward direction prediction is involved, and in a B picture, three prediction modes of forward direction prediction, backward direction prediction and bidirection prediction are involved. In the meantime, according to the present invention, in addition to the pictures described above, two other picture types of a PG picture and a PBG picture, which will be hereinafter described, are involved. In a PG picture, two prediction modes including forward direction prediction and background prediction are involved, and in a PBG picture, four prediction modes of forward direction-prediction, backward direction prediction, bidirection prediction and background prediction are involved. FIGS. 5A, 5B and 5C show examples of patterns of coded pictures. For example, the pattern shown in FIG. 5A is similar to the conventional example, and similar means to that of the prior art may be applied. For the pattern shown in FIG. 5B, two prediction modes including background prediction from a background image (indicated at "BG" in FIG. 5B) written in the second frame memory 10 and forward direction prediction from an immediately preceding decoded picture are involved, and one of the two prediction modes which provides a smaller prediction error is selected. This operation is performed up to the sixth picture, and then beginning with the seventh picture, the picture structure changes to the structure of P, B, B, P, ... In this instance, up to the sixth picture, a background image is recorded in the second frame memory 10. Thereafter, however, the ninth picture is first forward direction predicted referring to the sixth picture. Then, similarly as in the conventional example, the seventh and eighth pictures are predicted referring to decoded pictures of the sixth picture and the ninth picture. In FIG. 5B, a dotted line extending from the second picture to the "BG" signifies that, for example, contents of the decoded image of the second picture are written as a background image into the second frame memory. As the writing timing, writing may be performed after each certain interval of time or in response to a control signal from the outside. However, the pattern described above is a mere example, and any other pattern may be available. FIG. 5C shows a pattern wherein the first picture is an I picture, and it can be seen that a coded picture of the I picture is written as a background image into the second frame memory. Then, the prediction modes of macroblocks of all pictures beginning with the third picture are selected either to background image prediction or to forward direction prediction. This is effective where the background image is stationary, and is very effective with a scene wherein some person speaks in front of the background image since a phenomenon called occlusion wherein the background image comes into and out of sight by a movement of the person occurs. Further, when the background image is a still picture and is known in advance, the background image may be written into the second frame in advance before coding processing is started. It is to be noted that the pattern of coded pictures may take any pattern other than those shown in FIGS. 5A, 5B and 5C. Subsequently, operation of the frame memory selecting unit 35 shown in FIG. 1 will be described. In the frame memory selecting unit 35, it is determined into which one of the first frame memory 9 and the second frame memory 10 the locally decoded image 108 is to be written. As the determination method, a technique may be employed wherein, for example, a control signal from the frame re-arranging unit 1 is received by the frame memory selecting unit 35 and switching between the first frame memory 9 and the second frame memory 10 is performed in accordance with the received control signal by the frame memory selecting unit 35. In this instance, since the types of a currently coded picture and another picture to be coded subsequently are known, for example, a decoded image is written into the first frame memory 9 till the "BG" and indicated in FIG. 5B unless a signal from the outside is received, and since the picture structure thereafter changes to the structure of P, B, B, P, ..., the frame memory for a subject of writing should be selected adaptively as in the conventional example. Further, as seen in FIG. 5B, as writing of a background image from a decoded picture at a certain position into the second frame memory 10, for example, when a scene change is detected, the decoded image may be written after a predetermined interval of time since then. For the detection method for a scene change, a technique conventionally used may be used. For example, a method wherein, if the number of those of macroblocks in one frame with which the prediction error is higher than a threshold value is larger than a certain value, this is regarded as a scene change. It is a matter of course that various other techniques than that described just above are available. Further, while, in the image coding apparatus of the present embodiment, the first and second frame memories are. provided as storage means to realize a construction for switching of motion compensation prediction, for implementation of the hardware, a plurality of frame memories can be provided at a time by cutting a memory having a storage capacity for the plurality of frame memories based on internal addresses. As described above, with the image coding apparatus of the present embodiment, since a background image is stored and motion compensating prediction is performed using background prediction based on the background image, coding can be performed while keeping a high prediction efficiency without being influenced by a coding sequence. It is to be noted that, while storage control of a background image into the frame memories is described in the foregoing description, it is a matter of course that the background image here signifies an image which is stored continuously and does not signify contents themselves of an image. In particular, since images which are successively updated like a conventional picture array include some image which is effective for later prediction, this image is continuously stored independently of storage by the updating procedure, and here, this image is referred to as background image. FIG. 6 is a block diagram of a decoding apparatus for moving pictures according to an embodiment not covered by the invention. Referring to FIG. 6, reference numeral 23 denotes a motion compensating unit, and 46 a demultiplexing unit. The other components than those are similar to those employed in the embodiment shown in FIGS. 1 to 5, and accordingly, repetitive description of them is omitted here. Operation will be described subsequently. The decoding apparatus of FIG. 6 corresponds to the coding apparatus described in connection with FIG. 1, and a basic processing procedure for decoding thereof is similar to that of the decoding apparatus described in the conventional example described in the prior art. Thus, description will be given here principally of differences between them. A locally decoded image 108 is inputted to the frame memory selecting unit 35. The frame memory selecting unit 35 receives the locally decoded image 108, selects a frame memory of a subject of writing, and transfers a selected decoded image 134 or 135 to the first frame memory 9 and the second frame memory 10. Then, the decoded image is written into the first frame memory 9 or the second frame memory 10. Meanwhile, the motion compensating unit 23 reads out reference images 109 and 110 from the two frame memories and generates a predicted image 115 in accordance with a predetermined motion prediction mode 126 in a similar procedure to that in local decoding of the coding apparatus. FIG. 7 is a block diagram showing an internal construction of the motion compensating unit 23. Referring to FIG. 7, reference numeral 32 denotes a switch. Subsequently, operation will be described. One of the predicted image generating units 27 to 30 which corresponds to a selected prediction mode 126 reads out reference images 109 or 110 to generate a predicted image. Further, the switch 32 is switched in response to the selected prediction mode so that a finally determined predicted image 115 is outputted. Embodiment 1 While, in the coding apparatus of FIG. 1, an entire screen in a picture is used as a subject of coding, the image coding apparatus of the present embodiment 1 is constructed such that the picture type for coding is variable in units of one of a plurality of subject images (objects) which construct the screen. Referring to FIG. 8, for example, if a screen is composed of an object 1 (fish), an object 2 (water: background picture) and an object 3 (ball) and boundaries among them are known, then those objects can be coded using different techniques from one another. In the image coding apparatus of the present embodiment 1, such coding techniques are realized by using different picture types from one another. For example, since the object 1 exhibits a comparatively large amount of motion, the construction of picture types of FIG. 5A is used for the object 1 taking it into consideration that bidirection prediction is higher in prediction efficiency than background prediction. On the other hand, since the object 2 is an image which exhibits little motion, it is effective to use background prediction for it. Accordingly, the construction of FIG. 5C should be used. However, if such a variation that a scene changes rapidly occurs with a certain midst picture, then the construction which includes B pictures beginning with the midst picture as seen in FIG. 5B should be employed. FIG. 9 is a block diagram showing a concrete example of the image coding apparatus provided by the present embodiment 1. Referring to FIG. 9, reference numeral 42 denotes an object distinguishing unit, 43 a first frame memory group, 44 a second frame memory group, and 138 an object identification signal. Operation will be described subsequently. An input image 100 includes identification signals applied to individual objects in advance, and the identification signals are identified by the object distinguishing unit 42. The number of each of the thus identified objects is outputted as an object identification signal 138 from the object distinguishing unit 42. The motion estimating unit 15 selects, from among the first frame memory group 43 and the second frame memory group 44, a frame memory which corresponds to the object of the subject of coding in accordance with the object identification signal 138, reads out a reference image from the selected frame memory and performs motion prediction. Meanwhile, the motion compensation predicting unit 21 selects a frame memory corresponding to a predetermined object in accordance with a motion prediction mode 126 determined by the motion estimating unit 15 and generates a predicted image 115. On the other hand, the frame memory selecting unit 35 writes a decoded image 108 into one of the frame memories of a predetermined one of the frame memory groups which corresponds to a predetermined object in accordance with the object identification signal 138. Further, the object identification signal 138 is multiplexed together with other coding information by the multiplexing unit 45 and sent out as a multiplexed bit stream 139 to an external apparatus (not shown). While, in the image coding apparatus of the present embodiment 1, the first and second memory groups are provided to realize the construction for switching of motion compensating prediction, for implementation of the hardware, a plurality of frame memories can be provided at a time by cutting a memory having a storage capacity for the plurality of frame memories based on internal addresses. As described above, with the image coding apparatus of the present embodiment 1, since a prediction structure which conforms with motion of an object can be taken, the overall prediction efficiency is improved. Embodiment 2 A block diagram of an image decoding apparatus which corresponds to the image coding apparatus of the embodiment 1 shown in FIG. 9 is shown in FIG. 10. Referring to FIG. 10, reference numeral 46 denotes a demultiplexing unit. The other components are similar to those of the image decoding apparatus of, for example, the embodiment shown in FIG. 6, and accordingly, repetitive description of them is omitted here. Operation will be described subsequently. In response to an object identification signal 138 demultiplexed by the demultiplexing unit 46, the motion compensating unit 23 reads out a reference image from one of frame memories of a predetermined frame memory group which corresponds to a predetermined object, and performs motion compensation corresponding to a prediction mode to generate a predicted image 115. In the meantime, the frame memory selecting unit 35 writes a decoded image 108 into one of the frame memories of a predetermined frame memory group which correspond s to a predetermined object in accordance with the object identification signal 138. The other processing is similar to that of the image decoding apparatus of the embodiment shown in FIG. 6, and accordingly, repetitive description of it is omitted here. Embodiment 3 FIG. 11 is a block diagram of an image coding apparatus which includes a further frame memory group in addition to the construction of the embodiment 1 described hereinabove with reference to FIG. 9 such that it may include totaling three frame memory groups. Referring to FIG. 11, reference numeral 49 denotes a third frame memory group. The other components are similar to those of the image coding apparatus of the embodiment 1 shown in FIG. 9, and accordingly, repetitive description of them is omitted here. Subsequently, operation will be described. An input image 100 includes identification signals applied to individual objects in advance, and the identification signals are identified by the object distinguishing unit 42. The number of each of the thus identified objects is outputted as an object identification signal 138 from the object distinguishing unit 42. The motion estimating unit 15 selects, from among the first frame memory group 43, the second frame memory group 44 and the third frame memory group 49, a frame memory which corresponds to the object of the subject of coding in accordance with the object identification signal 138, reads out a reference image from the selected frame memory and performs motion prediction. Meanwhile, the motion compensation predicting unit 21 selects a frame memory corresponding to a predetermined object in accordance with a motion prediction mode 126 determined by the motion estimating unit 15 and generates a predicted image 115. On the other hand, the frame memory selecting unit 35 writes a decoded image 108 into one of the frame memories of a predetermined one of the frame memory groups which corresponds to a predetermined object in accordance with the object identification signal 138. Further, the object identification signal 138 is multiplexed together with other coding information by the multiplexing unit 45 and sent out as a multiplexed bit stream 139. While, in the image coding apparatus of the present embodiment 3, the first, second and third memory groups are provided to realize the construction for switching of motion compensating prediction, for implementation of the hardware, a plurality of frame memories can be provided at a time by cutting a memory having a storage capacity for the plurality of frame memories based on internal addresses. Embodiment 4 A block diagram of an image decoding apparatus corresponding to the image coding apparatus of the embodiment 3 shown in FIG. 11 is shown in FIG. 12. Referring to FIG. 12, reference numeral 49 denotes a third frame memory group. The other components are similar to those of the image decoding apparatus of, for example, the embodiment 2 shown in FIG. 10, and accordingly, repetitive description of them is omitted here. Operation will be described subsequently. In response to an object identification signal 138 demultiplexed by the demultiplexing unit 46, the motion compensating unit 23 reads out a reference image from one of frame memories of a predetermined frame memory group which corresponds to a predetermined object, and performs motion compensation corresponding to a prediction mode to generate a predicted image 115. In the meantime, the frame memory selecting unit 35 writes a decoded image 108 into one of the frame memories of a predetermined frame memory group which corresponds to a predetermined object in accordance with the object identification signal 138. The other processing is similar to that of the image decoding apparatus of the embodiment 2 shown in FIG. 10, and accordingly, repetitive description of it is omitted here. Embodiment 5 The image coding apparatus of the embodiment 3 shown in FIG. 11 may be modified such that re-writing of image contents of a region, in which an object of a subject of coding is included, of a frame memory corresponding to the object in the second frame memory in which a decoded image of the object in the past is stored is performed after each certain interval of time or in response to a control signal from the outside. FIG. 13 is a diagrammatic view illustrating that, for example, with a decoded image of all macroblocks including a region occupied by a certain object, image contents in a macroblock or macroblocks at the same position of a frame memory in the second frame memory group which corresponds to the object are re-written. Accordingly, in the case of FIG. 13, contents of totaling four macroblocks in two vertical columns and two horizontal rows are updated. Further, where re-writing of image contents of a region, in which an object of a subject of coding is included, of a frame memory corresponding to the object in the third frame memory in which a decoded image of the object in the past is stored is performed after each certain interval of time or in response to a control signal from the outside, the writing operation into a frame memory in the second frame memory group in the foregoing description should be applied to the writing operation into a frame memory in the third frame memory group. Also with a decoding apparatus which corresponds to the image coding apparatus of the embodiment 3 shown in FIG. 11 as described above, re-writing of image contents of a region, in which an object is included, of a frame memory corresponding to the object in the second frame memory group in which a decoded image of the object in the past is stored can be controllably performed after a certain interval of time or in response to a control signal from the outside. Embodiment 6 The image coding apparatus of the embodiment 1 shown in FIG. 9 can be modified such that searching ranges of motion vector searching for a reference image from a frame memory of the first frame memory group which corresponds to an object and another reference image from another frame memory of the second frame memory group which corresponds to another object are varied for the individual objects. For example, in the image coding apparatus of the embodiment 1 shown in FIG. 9, if a background which exhibits a comparatively small amount of motion as an object is stored in advance in a frame memory of the second frame memory group which corresponds to the object whereas an operation of successively writing a decoded image of another object which exhibits a comparatively large amount of motion at any time into another frame memory of the first frame memory group which corresponds to the object is performed, then a high prediction efficiency can be maintained for both of the objects. Further, the image coding apparatus of the embodiment 3 shown in FIG. 11 may be modified such that searching ranges of motion vector searching for a reference image from s from memory of the first frame memory group which corresponds to an object, another reference image from another frame memory of the second frame memory group which corresponds to another object and a further reference image from a further frame memory of the third frame memory group which corresponds to a further object are varied for the individual objects. For example, in the image coding apparatus of the embodiment 3 shown in FIG. 11, if a background which exhibits a comparatively small amount of motion as an object is stored in advance in a frame memory of the third frame memory group which corresponds to the object whereas an operation of successively writing a decoded image of another object which exhibits a comparatively large amount of motion at any time into another frame memory of the first frame memory group or the second frame memory group which corresponds to the object is performed, then a high prediction efficiency can be maintained for all of the three objects. As described above, since searching ranges for a motion vector are set separately from each other for a plurality of frame memory groups referred to by objects. For example, for an object which exhibits a comparatively small amount of motion, the information generation amount of motion vectors can be reduced by making the searching range for a motion vector narrow. Embodiment 7. FIG. 14 is a block diagram showing an image coding apparatus according to an embodiment 7 of the present invention. Referring to FIG. 14, reference 47 denotes a differential vector generating unit. The differential vector generating unit 47 holds motion vectors in the past obtained by referring to images of individual objects from frame memories of the first frame memory group which correspond to the objects and motion vectors in the past obtained by referring to images of the individual objects from frame memories of the second frame memory group which correspond to the objects in the image coding apparatus of the embodiment 1 shown in FIG. 9 separately for certain periods of time and calculates difference vectors separately for the individual objects. The other construction is similar to that of the image coding apparatus of the embodiment 1 shown in FIG. 9, and accordingly, repetitive description of it is omitted here. Subsequently, operation will be described. The motion estimating unit 15 performs motion estimation of a current image 101 of an object of a subject of coding using an image in a frame memory corresponding to the object in one of the first frame memory group and the second frame memory group selected by motion estimation as a reference image to detect a-motion vector 123. Based on the motion vector 123, the differential vector generating unit 47 selects a candidate vector (MV1, MV2 or MV3 mentioned hereinabove) from among motion vectors of the object in the past stored in the differential vector generating unit 47 and outputs a difference vector 141 of the candidate vector from the motion vector 123. The difference vector 141 is coded into a variable length codeword by the variable length coding unit 17. Accordingly, the differential vector generating unit 47 has a memory function of holding motion vectors in the past separately for certain periods of time for the individual frame memory groups. Embodiment 8. A block diagram of a decoding apparatus corresponding to the image coding apparatus of the embodiment 7 shown in FIG. 14 is shown in FIG. 15. Referring to FIG. 15, reference numeral 48 denotes a motion vector adding unit which selects a candidate vector from among motion vectors of an object in the past stored in advance therein and adds the selected candidate vector to a difference vector 141 variable length decoded by the variable length decoding unit 22. The other construction is similar to that of the image coding apparatus of the embodiment 1 shown in FIG. 9, and accordingly, repetitive description of it is omitted here. Subsequently, operation will be described. In the image decoding apparatus of the present embodiment 8, a difference vector 141 variable length coded by the variable length decoding unit 22 is supplied to the motion vector adding unit 48, by which a candidate vector is selected from among motion vectors of an object in the past stored therein and added to the difference vector 141 to regenerate a motion vector 123. The motion vector 123 is sent to the motion compensating unit 23. The motion compensating unit 23 receives the motion vector 123, reads out an image in the memory group 43 or 44 corresponding to the object in the frame memory group selected by the frame memory selecting unit 35 as a reference image, and outputs a predicted image 115. The other processing is similar to the operation of the image decoding apparatus of the embodiment 2 shown in FIG. 10, and accordingly, repetitive description of it is omitted here. Embodiment 9. A construction of an image coding apparatus which includes a third frame memory group 49 in addition to the construction of the image coding apparatus of the embodiment 7 shown in FIG. 14 is shown in FIG. 16. The other construction is similar to that of the image coding apparatus of the embodiment 7 shown in FIG. 14, and accordingly, repetitive description of it is omitted here. Subsequently, operation will be described. The motion estimating unit 15 performs motion estimation of a current image 101 of an object of a subject of coding using an image in a frame memory corresponding to the object in one of the first frame memory group, the second frame memory group and the third frame memory group selected by motion estimation as a reference image to detect a motion vector 123. Based on the motion vector 123, the differential vector generating unit 47 selects a candidate vector (MV1, MV2 or MV3 mentioned hereinabove) from among motion vectors of the object in the past stored in the differential vector generating unit 47 and outputs a difference vector 141 of the candidate vector from the motion vector 123. The difference vector 141 is coded into a variable length codeword by the variable length coding unit 17. Also in this instance, the differential vector generating unit 47 has a memory function of holding motion vectors in the past separately for certain periods of time for the individual frame memory groups. Since the other processing is similar to the operation of the image decoding apparatus of the embodiment 2 shown in FIG. 10, repetitive description of it is omitted herein. Embodiment 10. A construction of an image decoding apparatus corresponding to the image coding apparatus of the embodiment 9 shown in FIG. 16 is shown in FIG. 17. Referring to FIG. 17, reference numeral 49 denotes a third frame memory group. Since the other construction is similar to that of the image decoding apparatus of the embodiment 8 shown in FIG. 15, repetitive description of it is omitted here. Subsequently, operation will be described. A difference vector 141 variable length coded by the variable length decoding unit 22 is supplied to the motion vector adding unit 48, by which a candidate vector is selected from among motion vectors of an object in the past stored therein and added to the difference vector 141 to regenerate a motion vector 123. The motion vector 123 is sent to the motion compensating unit 23. The motion compensating unit 23 reads out a reference image in a frame memory corresponding to the object in the selected frame memory group, and outputs a predicted image 115. As described above, if a differential vector generating unit which has a memory function of holding a number of motion vectors, which is equal to the number of the frame memory groups, in the past separately for certain periods of time for the individual frame memory groups and calculates a difference vector between a detected motion vector and a candidate vector is provided, then the information generation amount of motion vectors can be suppressed. As described above, with the image coding apparatus and the image decoding apparatus of the present invention, since only regions of the frame memories in the frame memory groups in which an object of a subject of coding is included are re-written after a certain interval of time or in response to an external control signal., there is a yet further effect that a high efficiency in background prediction can be maintained. Further, since the searching ranges for a motion vector are set separately for the plurality of frame memory groups referred to by an object, there is a yet further effect that, for example, for an object which exhibits a comparatively small amount of motion, the information generation amount of motion vectors can be reduced by making the searching range for a motion vector narrow. Furthermore, since the differential vector generating unit which has a memory function of holding a number of motion vectors, which is equal to the number of the frame memory groups, in the past separately for certain periods of time for the individual frame memory groups and calculates a difference vector between a detected motion vector and a candidate vector is provided, there is an additional effect that the information generation amount of motion vectors can be suppressed.

Claims: An image coding apparatus which outputs a coded bit stream of moving pictures comprising a plurality of frame memory groups (43, 44) for storing, individually for a plurality of objects which construct a screen, decoded images of objects in the past; a subtractor (2) for calculating the difference between a predicted image and a current image to calculate a prediction error image; an adding unit (8) for adding the predicted image from reference images and the prediction error image of the current image; a variable length coding unit (17) for variable length coding information; an image storage controller (35) for selecting, in response to a control signal, a frame memory from a predetermined one of said plurality of frame memory groups (43, 44) into which a decoded image is to be written; and a motion compensation prediction unit (21) for selecting one of forwarded direction prediction, backward direction prediction, bidirection prediction and background prediction in individual objects using reference images read out from frame memories of said plurality of frame memory groups (43, 44) provided for the individual objects to perform motion compensation prediction. An image decoding apparatus which decodes a coded bit stream of moving pictures comprising a plurality of frame memory groups (43, 44) for storing, individually for a plurality of objects which construct a screen, decoded images of the objects; a variable length decoding unit (22) for variable length decoding the coded bit stream; an image storage controller (35) for selecting, in response to a control signal, a frame memory from a predetermined one of said plurality of frame memory groups (43, 44) into which a decoded image is to be written; and a motion compensation unit (23) for selecting one of forward direction prediction, backward direction prediction, bidirection prediction and background prediction in individual objects using reference images read out from frame memories of said plurality of frame memory groups (43, 44) to generate a motion compensated image. An image coding apparatus as set forth in claim 1, wherein re-writing of image contents of a region in which an object which is a subject of coding is included in said plurality of frame memory groups (43, 44, 49) in which coded images of the object in the past are stored is performed after a certain interval of time or in response to a control signal from the outside. An image decoding apparatus as set forth in claim 2, wherein re-writing of image contents of a region in which an object which is a subject of decoding is included in said plurality of frame memory groups (43, 44, 49) in which coded images of the object in the past are stored is performed after a certain interval of time or in response to a control signal from the outside. An image coding apparatus as claimed in claim 1 or 3, wherein searching ranges for a motion vector from reference images from said plurality of frame memory groups (43, 44, 49) for the individual objects are variable for the individual objects. An image coding apparatus as claimed in claim 1 or 3, further comprising differential vector generation means (47) for storing a motion vector in the past obtained by referring to images from said plurality of frame memory groups (43, 44, 49) for the individual objects and calculating difference vectors separately for the individual objects, wherein the difference vectors are variable length coded. An image decoding apparatus as claimed in claim 2 or 4, further comprising a motion vector adding unit (48) for holding decoded motion vectors in the past obtained by referring to images in said plurality of frame memory groups (43, 44, 49) for the individual objects for a certain period of time and adding the motion vectors decoded in the past to the decoded difference vectors to regenerate motion vectors for the individual objects.

Inventors: ASAI KOHTARO, FUKUHARA TAKAHIRO, MURAKAMI TOKUMICHI, SEKIGUCHI SHUNICHI, ASAI, KOHTARO, FUKUHARA, TAKAHIRO, MURAKAMI, TOKUMICHI, SEKIGUCHI, SHUNICHI, ASAI, KOHTARO, MITSUBISHI DENKI K.K., Fukuhara, Takahiro, Mitsubishi Denki K.K., MURAKAMI, TOKUMICHI, MITSUBISHI DENKI K.K., SEKIGUCHI, Shunichi, Mitsubishi Denki K.K.
Applicants: MITSUBISHI ELECTRIC CORP, MITSUBISHI DENKI KABUSHIKI KAISHA
Application year: 1996
Main classification: H04N7
IPC codes: H04N7, G06T9