Patent ID: 7499593

Claim:
A video decoding apparatus of receiving and decoding a bit sequence obtained by encoding a block composed of M×N (M and N are natural numbers) pieces of image data, comprising: a decoding section of decoding the encoded image data to output decoded data, and when detecting a code indicating a block boundary present in the bit sequence, outputting a boundary detection signal; a count section of counting a number of pieces of data decoded by the decoding section; a validity determining section of determining whether the decoded data is valid or invalid, based on a count value of the count section and the boundary detection signal; and an output data generating section of selecting and outputting only valid data among the decoded data, based on a result of the determination by the validity determining section, wherein, when the count value is M×N or less and the code indicating the block boundary is detected, the decoding section starts a decoding process of the next block after ending an M×N-th decoding process of the bit sequence, if the code indicating the block boundary is not detected when the count value is M×(N+1) or more, the decoding section continues a decoding process until the code indicating the block boundary is detected, and the validity determining section determines that M×N-th or earlier data among the decoded data are valid and M×(N+1)-th or later data among the decoded data are invalid.