A data encoding apparatus, and method and a camera system using the same, improved
in speed of processing. The predetermined write addresses in accordance with an
input sequence of data are generated corresponding to the data and stored at corresponding
addresses of a storage unit, an address the latest in a read sequence from the
storage unit among the write addresses of the non-zero data is detected at an EOB
(encoding of data block) detection unit, read addresses are sequentially generated,
the data is read from the addresses of the storage unit and output to an encoding
unit, when the read address and the detection address of the EOB detection unit
do not coincide, the data is sequentially encoded at the encoding unit, when they
coincide, the data of this address is encoded, a code EOB is generated, and the
encoding is terminated.