# US 2008/0304762 A1 · Image processing apparatus and method

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2008/0304762 A1
- Document ID: US20080304762A1
- Status: Published application
- Kind: A1
- Application number: 12/133,884
- Filed: 2008-06-05
- Published: 2008-12-11
- Earliest claimed: 2007-06-06
- Assignees: Canon Kabushiki Kaisha
- Inventors: Yuki Matsumoto
- Web page: https://patentgrep.com/patent/US20080304762A1

## CPC

- H04N 19/70: characterised by syntax aspects related to video coding, e.g. related to compression standards
- G06V 30/162: Quantising the image signal
- H04N 19/103: Selection of coding mode or of prediction mode
- H04N 19/13: Adaptive entropy coding, e.g. adaptive variable length coding [AVLC] or context adaptive binary arithmetic coding [CABAC]
- H04N 19/17: the unit being an image region, e.g. an object
- G06V 30/10: Character recognition
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION
- G06V: IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING

## Abstract

An image, in which a character image and a photographic image are mixed, is efficiently encoded while preventing image quality deterioration. Hence, image data including foreground pixels and background pixels is input. In the image data, first image data is generated by setting a pixel value that does not occur as the foreground pixel to the pixel value of the background pixel based on the histogram of pixel values that occur as foreground pixels, and the first image data is encoded. In the image data, second image data is generated by setting a value based on the pixel value of the background pixel to the pixel value of the foreground pixel, and the second image data is encoded.

## Claims

### Claim 1

An image processing apparatus comprising:
an input section, arranged to input image data including foreground pixels and background pixels;
a first generator, arranged to generate first image data by setting a pixel value that does not occur as the foreground pixel to a pixel value of the background pixel based on a histogram of pixel values that occur as the foreground pixels in the image data;
a first encoder, arranged to encode the first image data;
a second generator, arranged to generate second image data by setting a value based on the pixel value of the background pixel to the pixel value of the foreground pixel in the image data; and
a second encoder, arranged to encode the second image data.

### Claim 2 (depends on 1)

The apparatus according to claim 1, wherein said first encoder executes lossless encoding.

### Claim 3 (depends on 1)

The apparatus according to claim 1, wherein said second encoder executes lossy encoding.

### Claim 4 (depends on 1)

The apparatus according to claim 1, wherein said first generator sets to the pixel value of the background pixel a value adjacent to a minimum pixel value or a maximum pixel value that occurs in the foreground pixel.

### Claim 5 (depends on 1)

The apparatus according to claim 1, wherein said first generator sets to the pixel value of the background pixel a value closest to a median of pixel values that occur in the foreground pixels.

### Claim 6 (depends on 1)

The apparatus according to claim 1, wherein said first generator sets to the pixel value of the background pixel a value closest to a luminance value having a highest frequency of occurrence among pixel values that occur in the foreground pixels.

### Claim 7

An image processing apparatus comprising:
a separator, arranged to separate pixels of interest of image data into foreground pixels and background pixels based on a value of the pixel of interest and values of a plurality of pixels surrounding the pixel of interest;
a first generator, arranged to generate from the image data a foreground image in which a transparent color is set to a pixel other than the foreground pixel based on a histogram of a pixel value that occurs as the foreground pixel;
a lossless encoder, arranged to execute lossless encoding of the foreground image;
a second generator, arranged to generate from the image data a background image in which a background pixel value is set to a pixel other than the background pixel;
a lossy encoder, arranged to execute lossy encoding of the background image; and
a synthesizer, arranged to synthesize encoded data obtained in the lossless encoding and encoded data obtained in the lossy encoding, thereby generating encoded data of the image data.

### Claim 8 (depends on 7)

The apparatus according to claim 7, wherein said separator compares the value of the pixel of interest with the values of the plurality of surrounding pixels, separates the pixel of interest as the foreground pixel when there is a surrounding pixel having a same value as the pixel of interest, and separates the pixel of interest as the background pixel when there is no surrounding pixel having a same value as the pixel of interest.

### Claim 9 (depends on 7)

The apparatus according to claim 7, wherein said separator calculates differences between the value of the pixel of interest and the values of the plurality of surrounding pixels, separates the pixel of interest as the foreground pixel when there is a surrounding pixel having the difference smaller than a first threshold, and separates the pixel of interest as the background pixel when there is no surrounding pixel having the difference smaller than the first threshold.

### Claim 10 (depends on 7)

The apparatus according to claim 7, wherein said separator comprises:
a comparator, arranged to compare the value of the pixel of interest with the values of the plurality of surrounding pixels;
a first classification section, arranged to classify, if there is a surrounding pixel having a same value as the pixel of interest, by calculating an edge strength between the pixel of interest and the plurality of surrounding pixels, the pixel of interest as the foreground pixel when the edge strength exceeds a second threshold, and classify the pixel of interest as the background pixel when the edge strength does not exceed the second threshold;
an updater, arranged to update a determination value of a foreground pixel based on the value of the pixel of interest classified as the foreground pixel by said first classification section; and
a second classification section, arranged to classify, if there is no surrounding pixel having a same value as the pixel of interest, the pixel of interest as the foreground pixel when the value of the pixel of interest coincides with the determination value, and classify the pixel of interest as a background pixel when the value of the pixel of interest does not coincide with the determination value.

### Claim 11 (depends on 7)

The apparatus according to claim 7, wherein said first generator comprises:
a counter, arranged to count the number of effective signal levels included in the image data for each color component;
a third generator, arranged to generate an index table based on the number of signal levels for said each color components;
a converter, arranged to convert the value of the foreground pixel into an index value based on the index table when the number of signal levels is smaller than a third threshold for said each color components.

### Claim 12

An image processing method comprising the steps of:
inputting image data including foreground pixels and background pixels;
generating first image data by setting a pixel value that does not occur as the foreground pixel to a pixel value of the background pixel based on a histogram of pixel values that occur as the foreground pixels in the image data;
encoding the first image data;
generating second image data by setting a value based on the pixel value of the background pixel to the pixel value of the foreground pixel in the image data; and
encoding the second image data.

### Claim 13

An image processing method comprising the steps of:
separating pixels of interest of image data into foreground pixels and background pixels based on a value of the pixel of interest and values of a plurality of pixels surrounding the pixel of interest;
generating from the image data a foreground image in which a transparent color is set to a pixel other than the foreground pixel based on a histogram of a pixel value that occurs as the foreground pixel;
executing lossless encoding of the foreground image;
generating from the image data a background image in which a background pixel value is set to a pixel other than the background pixel;
executing lossy encoding of the background image; and
synthesizing encoded data obtained in the lossless encoding and encoded data obtained in the lossy encoding, thereby generating encoded data of the image data.

### Claim 14 (depends on 1)

A computer-readable storage medium storing a computer executable program for causing a computer to implement an image processing apparatus according to claim 1.

### Claim 15 (depends on 7)

A computer-readable storage medium storing a computer executable program for causing a computer to implement an image processing apparatus according to claim 7.
