An
image processing apparatus (200) for a
charge coupled device including
analog front end circuitry having optical black and offset correction, whereby the offset and optical black correction circuit is programmable. The present invention includes a first circuit (202, 204, 206, 208, 210) to sample the incoming optical black
signal output from a CCD. This first circuit includes a correlated double sampler (202) coupled to a first
programmable gain amplifier (204). An
adder (206) connects between the first
programmable gain amplifier (204) and a second
gain amplifier (208) for adding in the optical black offset to the optical black
signal input from the CCD. A second circuit (212, 214) includes a reverse
programmable gain amplifier (212) connected to the output of the second programmable
gain amplifier (208) to amplify the optical
black level inversely proportional to the
gain from the second programmable gain
amplifier (208). The second circuit (212, 214) also includes an
integrator (214) coupled to the reverse programmable gain amplifier (212) to integrate the difference between the incoming
signal and the desired optical black value. The second circuit (212, 214) couples to the
adder (206) to add the positive and negative difference to the optical black signal. An analog-to-
digital converter (210) converts the sampled signal for further
processing at the output of the
image processing apparatus (200).