Deprecated: The each() function is deprecated. This message will be suppressed on further calls in /home/zhenxiangba/zhenxiangba.com/public_html/phproxy-improved-master/index.php on line 456
JP6092082B2 - Image processing apparatus and method, and image forming apparatus - Google Patents
[go: Go Back, main page]

JP6092082B2 - Image processing apparatus and method, and image forming apparatus - Google Patents

Image processing apparatus and method, and image forming apparatus Download PDF

Info

Publication number
JP6092082B2
JP6092082B2 JP2013242213A JP2013242213A JP6092082B2 JP 6092082 B2 JP6092082 B2 JP 6092082B2 JP 2013242213 A JP2013242213 A JP 2013242213A JP 2013242213 A JP2013242213 A JP 2013242213A JP 6092082 B2 JP6092082 B2 JP 6092082B2
Authority
JP
Japan
Prior art keywords
image
block
size
unit
enlargement
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2013242213A
Other languages
Japanese (ja)
Other versions
JP2014131262A (en
Inventor
俊洋 土井
俊洋 土井
Original Assignee
株式会社沖データ
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 株式会社沖データ filed Critical 株式会社沖データ
Priority to JP2013242213A priority Critical patent/JP6092082B2/en
Publication of JP2014131262A publication Critical patent/JP2014131262A/en
Application granted granted Critical
Publication of JP6092082B2 publication Critical patent/JP6092082B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Processing (AREA)
  • Editing Of Facsimile Originals (AREA)

Description

本発明は、画像処理装置及び方法、並びに、画像形成装置に関し、例えば、複写機やプリンタ等の画像処理装置に適用し得る。     The present invention relates to an image processing apparatus and method, and an image forming apparatus, and can be applied to an image processing apparatus such as a copying machine or a printer.

従来の複写機やプリンタなどの画像処理装置(画像形成装置)では、ユーザ指定の倍率への拡大・縮小処理や、入力された画像を指定範囲に収めるために拡大・縮小処理が行われる場合がある。例えば、複写機の場合には、ユーザ指定により25%〜400%までの任意の倍率で拡大・縮小が行われるものが存在する。   In a conventional image processing apparatus (image forming apparatus) such as a copying machine or a printer, enlargement / reduction processing to a magnification specified by a user, or enlargement / reduction processing may be performed to fit an input image within a specified range. is there. For example, in the case of a copying machine, there is one that is enlarged or reduced at an arbitrary magnification of 25% to 400% according to user designation.

従来の画像の拡大・縮小処理方法としては、例えば、単純拡大法(単純縮小法)、補間拡大・縮小法(bi−linear)法、平均縮小法、Cubic convolution法などが知られている。これらの画像の拡大・縮小方法は、いずれも隣接画素を使用した補間方式が採用されている。そして、従来の画像処理装置では、この補間方式の違いが拡大・縮小処理後の画像データの画質を決定することになる。   As a conventional image enlargement / reduction processing method, for example, a simple enlargement method (simple reduction method), an interpolation enlargement / reduction method (bi-linear) method, an average reduction method, a cubic conversion method, and the like are known. These image enlargement / reduction methods both employ an interpolation method using adjacent pixels. In the conventional image processing apparatus, the difference in the interpolation method determines the image quality of the image data after the enlargement / reduction process.

例えば、特許文献1では、bi−linear法による画像の拡大をハードウェアで実現した画像処理装置について記載されている。   For example, Patent Document 1 describes an image processing apparatus that realizes image enlargement by hardware using a bi-linear method.

特開昭61−227480号公報JP-A 61-227480

しかしながら、従来の装置を実現するには、画像幅分のラインメモリを用意する必要があり、処理する画像のサイズが大きくなるにつれ、ハードウェアのコストも高くなるという問題があった。   However, in order to realize the conventional apparatus, it is necessary to prepare a line memory corresponding to the image width, and there is a problem that the cost of hardware increases as the size of the image to be processed increases.

そのため、効率的に画像のサイズ変更(拡大及び又は縮小)を行うことができる画像処理装置及び方法、並びに、画像形成装置が望まれている。   Therefore, an image processing apparatus and method that can efficiently change the size (enlargement and / or reduction) of an image, and an image forming apparatus are desired.

第1の本発明の画像処理装置は、(1)入力画像から、複数のブロック画像を抽出して、順次読み出すブロック画像読み出し手段と、(2)前記ブロック画像読み出し手段が読み出したブロック画像のそれぞれについて、所定の倍率でサイズ変更処理を行うサイズ変更手段と、(3)前記サイズ変更手段でサイズ変更が行われたブロック画像に基づいて、前記入力画像を前記所定の倍率でサイズ変更処理したサイズ変更画像を生成するサイズ変更画像生成手段とを有し、(4)前記サイズ変更手段は、ブロック画像を構成するラインごとに、サイズ変更処理を行い、(5)前記サイズ変更手段は、サイズ変更処理前のブロック画像のラインを構成する画素の位置と、サイズ変更処理後のブロック画像のラインを構成する画素の位置との位置関係を管理するサイズ変更カウンタを用いて、ラインごとのサイズ変更処理を行うことを特徴とする。 The image processing apparatus according to the first aspect of the present invention includes (1) a block image reading unit that extracts a plurality of block images from an input image and sequentially reads them, and (2) each of the block images read by the block image reading unit. And (3) a size obtained by resizing the input image at the predetermined magnification on the basis of the block image whose size has been changed by the size changing means. have a size-changed image generating means for generating a modified image, (4) the size change means for each line constituting the block image, performs a resizing process, (5) the size changing means changes the size The positional relationship between the position of the pixels that make up the block image line before processing and the position of the pixels that make up the line of the block image after resizing processing Using size change counter that manages, and performs a resize process for each line.

第2の本発明は、画像処理装置が行う画像処理方法において、(1)ブロック画像読み出し手段、サイズ変更手段、サイズ変更画像生成手段を備え、(2)前記ブロック画像読み出し手段は、入力画像から、複数のブロック画像を抽出して、順次読み出し、(3)前記サイズ変更手段は、前記ブロック画像読み出し手段が読み出したブロック画像のそれぞれについて、所定の倍率でサイズ変更処理を行い、(4)前記サイズ変更画像生成手段は、前記サイズ変更手段でサイズ変更が行われたブロック画像に基づいて、前記入力画像を前記所定の倍率でサイズ変更処理したサイズ変更画像を生成し、(5)前記サイズ変更手段は、ブロック画像を構成するラインごとに、サイズ変更処理を行い、(6)前記サイズ変更手段は、サイズ変更処理前のブロック画像のラインを構成する画素の位置と、サイズ変更処理後のブロック画像のラインを構成する画素の位置との位置関係を管理するサイズ変更カウンタを用いて、ラインごとのサイズ変更処理を行うことを特徴とする。 According to a second aspect of the present invention, in the image processing method performed by the image processing apparatus, (1) a block image reading unit, a size changing unit, and a size-changed image generating unit are provided. (2) the block image reading unit Extracting a plurality of block images and sequentially reading them out. (3) The size changing means performs a size changing process at a predetermined magnification for each of the block images read by the block image reading means. The resized image generating means generates a resized image obtained by resizing the input image at the predetermined magnification, based on the block image whose size has been changed by the resize means, and (5) the resized image The means performs a size changing process for each line constituting the block image. (6) The size changing means Using the position of the pixels constituting the lines of the block image, resizing counter for managing the positional relationship between the position of the pixels constituting the lines of a block image after resizing processing, performing the size changing process of each line It is characterized by.

第3の本発明は、入力画像を処理する画像処理装置と、前記画像処理装置が処理した画像を媒体に形成する画像形成手段とを備える画像形成装置において、(1)前記画像処理装置は、(1−1)入力画像から、複数のブロック画像を抽出して、順次読み出すブロック画像読み出し手段と、(1−2)前記ブロック画像読み出し手段が読み出したブロック画像のそれぞれについて、所定の倍率でサイズ変更処理を行うサイズ変更手段と、(1−3)前記サイズ変更手段でサイズ変更が行われたブロック画像に基づいて、前記入力画像を前記所定の倍率でサイズ変更処理したサイズ変更画像を生成するサイズ変更画像生成手段とを有し、(1−4)前記サイズ変更手段は、ブロック画像を構成するラインごとに、サイズ変更処理を行い、(1−5)前記サイズ変更手段は、サイズ変更処理前のブロック画像のラインを構成する画素の位置と、サイズ変更処理後のブロック画像のラインを構成する画素の位置との位置関係を管理するサイズ変更カウンタを用いて、ラインごとのサイズ変更処理を行うことを特徴とする。
第4の本発明の画像処理装置は、(1)入力画像から、複数のブロック画像を抽出して、順次読み出すブロック画像読み出し手段と、(2)前記ブロック画像読み出し手段が読み出したブロック画像のそれぞれについて、所定の倍率でサイズ変更処理を行うサイズ変更手段と、(3)前記サイズ変更手段でサイズ変更が行われたブロック画像に基づいて、前記入力画像を前記所定の倍率でサイズ変更処理したサイズ変更画像を生成するサイズ変更画像生成手段とを有し、(4)前記ブロック画像読み出し手段では、前記入力画像から抽出するブロック画像のサイズが前記所定の倍率に応じて可変され、前記入力画像から抽出するブロック画像のサイズが前記所定の倍率により決定されることを特徴とする。
According to a third aspect of the present invention, there is provided an image forming apparatus comprising: an image processing apparatus that processes an input image; and an image forming unit that forms an image processed by the image processing apparatus on a medium. (1) (1-1) A block image reading unit that extracts and sequentially reads out a plurality of block images from an input image, and (1-2) each of the block images read by the block image reading unit is sized at a predetermined magnification. (1-3) generating a size-changed image obtained by resizing the input image at the predetermined magnification on the basis of the block image whose size has been changed by the size-changing unit. have a size-changed image generating means, (1-4) wherein the size changing means for each line constituting the block image, performs a resizing process, (1- ) The size changing means includes a size change counter for managing a positional relationship between the positions of the pixels constituting the line of the block image before the size changing process and the positions of the pixels constituting the line of the block image after the size changing process. And performing a size changing process for each line .
An image processing apparatus according to a fourth aspect of the present invention includes: (1) a block image reading unit that extracts a plurality of block images from an input image and sequentially reads them; and (2) a block image that is read by the block image reading unit. And (3) a size obtained by resizing the input image at the predetermined magnification on the basis of the block image whose size has been changed by the size changing means. (4) In the block image reading unit, the size of the block image extracted from the input image is varied in accordance with the predetermined magnification, and the size of the block image is read from the input image. The size of the block image to be extracted is determined by the predetermined magnification.

本発明によれば、効率的に画像のサイズ変更を行うことができる画像処理装置を提供することができる。   ADVANTAGE OF THE INVENTION According to this invention, the image processing apparatus which can change the size of an image efficiently can be provided.

第1の実施形態に係る画像処理装置を搭載した画像形成装置の機能的構成について示したブロック図である。FIG. 2 is a block diagram illustrating a functional configuration of an image forming apparatus equipped with the image processing apparatus according to the first embodiment. 第1の実施形態に係るブロック読み出し部の処理について示した説明図(その1)である。It is explanatory drawing (the 1) shown about the process of the block reading part which concerns on 1st Embodiment. 第1の実施形態に係る画像形成装置の処理について示したフローチャートである。3 is a flowchart illustrating processing of the image forming apparatus according to the first embodiment. 第1の実施形態に係る拡大・縮小部のパラメータ算出処理について示したフローチャートである。It is the flowchart shown about the parameter calculation process of the expansion / contraction part which concerns on 1st Embodiment. 第1の実施形態に係るブロック読み出し部の処理について示した説明図(その2)である。It is explanatory drawing (the 2) shown about the process of the block reading part which concerns on 1st Embodiment. 第1の実施形態に係るブロック拡大・縮小部の処理の例について示した説明図である。It is explanatory drawing shown about the example of the process of the block expansion / contraction part which concerns on 1st Embodiment. 第1の実施形態に係るブロック書き出し部の処理について示した説明図である。It is explanatory drawing shown about the process of the block writing part which concerns on 1st Embodiment. 第1の実施形態に係るブロック拡大・縮小部が1ライン分の拡大・縮小処理を行う際の処理について示したフローチャートである。It is the flowchart shown about the process at the time of the block enlarging / reducing part which concerns on 1st Embodiment performing the enlarging / reducing process for 1 line. 第2の実施形態に係る画像処理装置を搭載した画像形成装置の機能的構成について示したブロック図である。FIG. 6 is a block diagram illustrating a functional configuration of an image forming apparatus equipped with an image processing apparatus according to a second embodiment. 第2の実施形態に係る画像形成装置の処理について示したフローチャートである。6 is a flowchart illustrating processing of an image forming apparatus according to a second embodiment. 第2の実施形態に係る画像形成装置の各ブロック画像処理部の処理制限について示した説明図である。FIG. 10 is an explanatory diagram illustrating processing limitations of each block image processing unit of an image forming apparatus according to a second embodiment. 第2の実施形態に係るブロック拡大・縮小部で算出される各ブロック画像のサイズ算出について示したフローチャートである。It is the flowchart shown about the size calculation of each block image calculated in the block expansion / contraction part which concerns on 2nd Embodiment. 第2の実施形態に係るブロック拡大・縮小部が算出した各ブロック画像のサイズの具体例について示した説明図である。It is explanatory drawing shown about the specific example of the size of each block image which the block expansion / contraction part which concerns on 2nd Embodiment calculated. 第2の実施形態に係るブロック読み出し部の処理について示した説明図である。It is explanatory drawing shown about the process of the block reading part which concerns on 2nd Embodiment. 第2の実施形態に係るブロック拡大・縮小部の処理の例について示した説明図である。It is explanatory drawing shown about the example of the process of the block expansion / contraction part which concerns on 2nd Embodiment. 第2の実施形態に係るブロック書き出し部の処理について示した説明図である。It is explanatory drawing shown about the process of the block writing part which concerns on 2nd Embodiment. 第3の実施形態に係る画像処理装置を搭載した画像形成装置の機能的構成について示したブロック図である。FIG. 10 is a block diagram illustrating a functional configuration of an image forming apparatus equipped with an image processing apparatus according to a third embodiment. 第3の実施形態に係るX方向拡大・縮小部121Bの動作の例について示した説明図である。It is explanatory drawing shown about the example of operation | movement of the X direction expansion / contraction part 121B which concerns on 3rd Embodiment. 第3の実施形態に係る画像形成装置1Bの全体の動作について示したフローチャートである。10 is a flowchart illustrating an overall operation of an image forming apparatus 1B according to a third embodiment. 第3の実施形態に係る拡大・縮小処理部100Bの各部位に必要なパラメータの算出方法の全体処理について図20のフローチャートを用いて説明する。The overall processing of the parameter calculation method required for each part of the enlargement / reduction processing unit 100B according to the third embodiment will be described with reference to the flowchart of FIG. 第3の実施形態に係る画像形成装置の各ブロック画像処理部の処理制限について示した説明図である。FIG. 10 is an explanatory diagram illustrating processing limitations of each block image processing unit of an image forming apparatus according to a third embodiment. 第3の実施形態に係るブロック拡大・縮小部が算出した各ブロック画像のサイズの具体例について示した説明図である。It is explanatory drawing shown about the specific example of the size of each block image which the block expansion / contraction part which concerns on 3rd Embodiment calculated. 第3の実施形態に係るブロック読み出し部の動作について示した説明図である。It is explanatory drawing shown about the operation | movement of the block reading part which concerns on 3rd Embodiment. 第3の実施形態に係る前解像度変換部で1つのブロック画像に対して実行される処理について示した説明図である。It is explanatory drawing shown about the process performed with respect to one block image in the previous resolution conversion part which concerns on 3rd Embodiment. 第3の実施形態に係るブロック拡大・縮小部で実行される画像ブロックに対する拡大処理の例について示した説明図である。It is explanatory drawing shown about the example of the expansion process with respect to the image block performed by the block expansion / contraction part which concerns on 3rd Embodiment. 第3の実施形態に係る後フィルタ処理部、後解像度変換部、及びブロックカット処理部によるブロック画像の処理について示した説明図である。It is explanatory drawing shown about the process of the block image by the post-filter process part which concerns on 3rd Embodiment, a post-resolution conversion part, and a block cut process part. 第4実施形態に係る画像形成装置の機能的構成を示すブロック図である。It is a block diagram which shows the functional structure of the image forming apparatus which concerns on 4th Embodiment. 第4の実施形態に係るサムネイル画像出力部のディスプレイに表示される画像データに基づく画像について示した説明図である。It is explanatory drawing shown about the image based on the image data displayed on the display of the thumbnail image output part which concerns on 4th Embodiment. 第4の実施形態に係るサムネイル縮小部で行われるX方向とY方向の縮小処理の詳細について示したフローチャートである。It is the flowchart shown in detail about the reduction process of the X direction and Y direction which are performed in the thumbnail reduction part which concerns on 4th Embodiment.

(A)第1の実施形態
以下、本発明による画像処理装置及び方法、並びに、画像形成装置の第1の実施形態を、図面を参照しながら詳述する。
(A) First Embodiment Hereinafter, an image processing apparatus and method and an image forming apparatus according to a first embodiment of the present invention will be described in detail with reference to the drawings.

(A−1)第1の実施形態の構成
図1(a)は、第1の実施形態の画像形成装置1の機能的構成について示したブロック図である。図1(b)は、第1の実施形態の画像形成装置1を構成するブロック拡大・縮小部120の機能的構成について示したブロック図である。
(A-1) Configuration of First Embodiment FIG. 1A is a block diagram illustrating a functional configuration of an image forming apparatus 1 according to the first embodiment. FIG. 1B is a block diagram illustrating a functional configuration of the block enlargement / reduction unit 120 included in the image forming apparatus 1 according to the first embodiment.

画像形成装置1は、画像入力部10、前フィルタ処理部20、拡大・縮小処理部100、後フィルタ処理部30、画像出力部50、及び画像メモリ60を有している。   The image forming apparatus 1 includes an image input unit 10, a pre-filter processing unit 20, an enlargement / reduction processing unit 100, a post-filter processing unit 30, an image output unit 50, and an image memory 60.

なお、画像形成装置1では、画像入力部10及び画像出力部50を除いた構成要素(前フィルタ処理部20、拡大・縮小処理部100、後フィルタ処理部30及び画像メモリ60)によりこの実施形態の画像処理装置を構成することができる。また、画像形成装置1では、少なくとも、拡大・縮小処理部100については、ハードウェア(例えば、ASIC等の集積回路)により構成されているものとする。   In the image forming apparatus 1, this embodiment includes components (the pre-filter processing unit 20, the enlargement / reduction processing unit 100, the post-filter processing unit 30, and the image memory 60) excluding the image input unit 10 and the image output unit 50. The image processing apparatus can be configured. In the image forming apparatus 1, at least the enlargement / reduction processing unit 100 is configured by hardware (for example, an integrated circuit such as an ASIC).

画像入力部10は、当該画像形成装置1で処理する画像の入力を受付ける機能を担っている。画像入力部10が、入力画像を保持する方法については限定されないものであるが、例えば、スキャナやホストPC等の外部装置から、ネットワークや各種インタフェース(例えば、USB等)を介して入力される画像を取得するようにしてもよい。そして、画像入力部10は取得した画像のデータを画像メモリ60に格納する。図1では、画像入力部10が入力を受付けた画像を画像G101と図示している。   The image input unit 10 has a function of receiving input of an image to be processed by the image forming apparatus 1. The method of holding the input image by the image input unit 10 is not limited. For example, an image input from an external device such as a scanner or a host PC via a network or various interfaces (for example, USB). May be obtained. Then, the image input unit 10 stores the acquired image data in the image memory 60. In FIG. 1, an image received by the image input unit 10 is illustrated as an image G101.

前フィルタ処理手段としての前フィルタ処理部20は、画像G101に対して、拡大・縮小処理部100の処理前に行われるフィルタ処理を行うものである。前フィルタ処理部20は、画像メモリ60に格納された画像G101のデータに対して、フィルタ処理を行い、処理後の画像データを画像メモリ60に書き込む。前フィルタ処理部20は、例えば、ガウシアンフィルタや原稿のスクリーン箇所等を判定する判定処理で構成され、入力原稿と出力原稿のスクリーン干渉によるモアレ発生を抑えるためのフィルタ処理を行う。図1では、前フィルタ処理部20が処理した後の画像を画像G102と図示している。   The pre-filter processing unit 20 as pre-filter processing means performs a filter process that is performed before the processing of the enlargement / reduction processing unit 100 on the image G101. The pre-filter processing unit 20 performs a filter process on the data of the image G101 stored in the image memory 60 and writes the processed image data in the image memory 60. The pre-filter processing unit 20 includes, for example, a determination process for determining a Gaussian filter, a screen portion of the document, and the like, and performs a filter process for suppressing the occurrence of moire due to screen interference between the input document and the output document. In FIG. 1, an image after processing by the pre-filter processing unit 20 is illustrated as an image G102.

拡大・縮小処理部100は、前フィルタ処理部20で処理された画像G102について、拡大又は縮小の処理(サイズ変更処理)を行うものであり、ブロック読み出し部110、ブロック拡大・縮小部120、及びブロック書き出し部130を有している。図1では、拡大・縮小処理部100が処理した後の画像を画像G103として図示している。   The enlargement / reduction processing unit 100 performs enlargement or reduction processing (size change processing) on the image G102 processed by the pre-filter processing unit 20, and includes a block reading unit 110, a block enlargement / reduction unit 120, and A block writing unit 130 is provided. In FIG. 1, an image after processing by the enlargement / reduction processing unit 100 is illustrated as an image G103.

拡大・縮小処理部100が行う拡大・縮小に係る倍率(以下、「設定倍率」と呼ぶ)は、例えば、ユーザの操作により決定するようにしてもよいし、外部装置(例えば、スキャナやホストPC等)からの指示に基づいて決定するようにしてもよい。   The magnification (hereinafter referred to as “setting magnification”) related to the enlargement / reduction performed by the enlargement / reduction processing unit 100 may be determined by a user operation, for example, or may be determined by an external device (for example, a scanner or a host PC). Etc.) may be determined based on an instruction from the above.

ブロック画像読み出し手段としてのブロック読み出し部110は、前フィルタ処理部20で処理され、画像メモリ60に書き込まれた1ページの画像G102のデータを、水平(幅)方向(以下、「X方向」とも呼ぶ)および垂直(縦)方向(以下、「Y方向」とも呼ぶ)に複数に分割したブロック画像として順次読み出し、ブロック拡大・縮小部120に供給する。   The block reading unit 110 serving as a block image reading unit converts the data of one page of the image G102 processed by the pre-filter processing unit 20 and written into the image memory 60 into the horizontal (width) direction (hereinafter referred to as “X direction”). Called) and a vertical (longitudinal) direction (hereinafter also referred to as “Y direction”), sequentially read as a block image divided into a plurality of blocks, and supplied to the block enlargement / reduction unit 120.

図2は、ブロック読み出し部110で行われる画像のブロック単位の分割について示した説明図である。   FIG. 2 is an explanatory diagram showing the division of each block of the image performed by the block reading unit 110.

図2で示すように、ブロック読み出し部110では、1ページの画像G102について、X方向にN個、Y方向にM個に分割されたブロック画像がM×N個生成される。ブロック読み出し部110は、各ブロック画像を読み出す際に、左上の画素より順番にX方向にライン走査され順次読み出すものとする。具体的には、ブロック読み出し部110は、図2に示す左上のブロック画像(0、0)から(0、1)、・・・(0、N)、(1、0)、・・・(M、N)の順に読み出されるものとする。ブロック読み出し部110は、ブロック単位で画像の読み出しを行う際には、X方向の読み出し位置と、Y方向の読み出し位置を逐次変更して行う。   As shown in FIG. 2, the block reading unit 110 generates M × N block images divided into N pieces in the X direction and M pieces in the Y direction for one page of the image G102. When the block reading unit 110 reads each block image, it is assumed that the line scanning is sequentially performed in the X direction from the upper left pixel and sequentially read. Specifically, the block reading unit 110 converts the upper left block image (0, 0) shown in FIG. 2 to (0, 1),... (0, N), (1, 0),. It is assumed that data are read in the order of M, N). When reading an image in block units, the block reading unit 110 sequentially changes the X-direction reading position and the Y-direction reading position.

上述の通り、拡大・縮小処理部100では、画像G102をブロック画像単位で拡大・縮小の処理を行うが、単純に図2に示すように画像G102を分割して、拡大・縮小の処理を行うと、各ブロック画像の境界周辺の画質が劣化する(1ページ分の画像単位で処理した場合と異なる画素値となる)恐れがある。そのため、この実施形態のブロック読み出し部110は、拡大・縮小の処理を行う対象のブロック画像(図2に示すブロック画像)の周辺の画素も含めた画像を読み出すものとする。すなわち、拡大・縮小処理部100は、各画像ブロック画像について、隣接ブロックと重複部分を持つように読み出すものとする。ブロック読み出し部110の各ブロック画像の読み出し処理の具体例については、後述する動作説明で詳述する。   As described above, the enlargement / reduction processing unit 100 performs enlargement / reduction processing of the image G102 in units of block images, but simply divides the image G102 and performs enlargement / reduction processing as shown in FIG. Then, there is a risk that the image quality around the boundary of each block image is deteriorated (the pixel value is different from the case of processing in units of images for one page). Therefore, the block reading unit 110 of this embodiment reads an image including pixels around the block image (block image shown in FIG. 2) to be enlarged / reduced. That is, the enlargement / reduction processing unit 100 reads out each image block image so as to have an overlapping portion with an adjacent block. A specific example of the reading process of each block image by the block reading unit 110 will be described in detail in an operation description to be described later.

サイズ変更手段及びブロック管理手段としてのブロック拡大・縮小部120は、ブロック読み出し部110で読み出された各ブロック画像に対して任意倍率の拡大・縮小処理(サイズ変更処理)を行う。ブロック拡大・縮小部120は、X方向の拡大・縮小を行うX方向拡大・縮小部121とY方向の拡大・縮小を行うY方向拡大・縮小部122で構成され、入力されたブロック画像に対して最初にX方向の拡大・縮小を行い、次にY方向の拡大・縮小を行うものとする。   The block enlargement / reduction unit 120 serving as a size change unit and a block management unit performs an enlargement / reduction process (size change process) at an arbitrary magnification on each block image read by the block reading unit 110. The block enlargement / reduction unit 120 includes an X direction enlargement / reduction unit 121 that performs enlargement / reduction in the X direction and a Y direction enlargement / reduction unit 122 that performs enlargement / reduction in the Y direction. First, enlargement / reduction in the X direction is performed, and then enlargement / reduction in the Y direction is performed.

X方向拡大・縮小部121は、X方向拡大・縮小カウンタ121aと、X方向出力カウンタ121bを備えている。   The X direction enlargement / reduction unit 121 includes an X direction enlargement / reduction counter 121a and an X direction output counter 121b.

X方向拡大・縮小部121は、入力ブロック画像を構成するX方向の任意の1ラインについて、出力ブロック画像のラインに変換する際に、X方向出力カウンタ121bを用いて、出力ブロック画像側の処理中の画素を管理する。そして、X方向拡大・縮小部121は、X方向拡大・縮小カウンタ121aを用いて、X方向出力カウンタ121bで示される画素と、入力ブロック画像に係るライン上の画素との相対的な位置関係を管理する。   The X-direction enlargement / reduction unit 121 uses the X-direction output counter 121b to convert an arbitrary one line in the X direction constituting the input block image into a line of the output block image. Manage the pixels inside. Then, the X direction enlargement / reduction unit 121 uses the X direction enlargement / reduction counter 121a to determine the relative positional relationship between the pixel indicated by the X direction output counter 121b and the pixel on the line related to the input block image. to manage.

X方向拡大・縮小部121のX方向拡大・縮小カウンタ121aの値は、ライン先頭(ブロック画像のライン先頭)で、ブロック画像毎にあらかじめ決定されたカウンタ初期値に設定される。そして、X方向拡大・縮小部121は、入力ブロック画像のラインを、X方向拡大・縮小カウンタ121aにしたがって拡大・縮小し、出力するライン(出力ブロック画像側のライン)の画素数をX方向出力カウンタ121bでカウントする。そして、X方向拡大・縮小部121は、X方向出力カウンタ121bによりあらかじめ決定された所定の値の範囲内の画素のみを出力することで、入力されたブロック画像をX方向に拡大・縮小する。そしてX方向拡大・縮小部121は、X方向に拡大・縮小処理されたブロック画像をY方向拡大・縮小部122に入力する。   The value of the X-direction enlargement / reduction counter 121a of the X-direction enlargement / reduction unit 121 is set to a counter initial value determined in advance for each block image at the head of the line (the head of the line of the block image). The X-direction enlargement / reduction unit 121 enlarges / reduces the line of the input block image according to the X-direction enlargement / reduction counter 121a, and outputs the number of pixels of the output line (output block image side) in the X direction. The counter 121b counts. The X-direction enlargement / reduction unit 121 enlarges / reduces the input block image in the X direction by outputting only pixels within a predetermined value range determined in advance by the X-direction output counter 121b. The X direction enlargement / reduction unit 121 inputs the block image that has been enlarged / reduced in the X direction to the Y direction enlargement / reduction unit 122.

Y方向拡大・縮小部122は、X方向拡大・縮小部121と同様、Y方向拡大・縮小カウンタ122aと、Y方向出力カウンタ122bを備えている。   Similar to the X direction enlargement / reduction unit 121, the Y direction enlargement / reduction unit 122 includes a Y direction enlargement / reduction counter 122a and a Y direction output counter 122b.

Y方向拡大・縮小部122のY方向拡大・縮小カウンタ122aの値は、ライン先頭(ブロック画像のライン先頭)で、ブロック画像毎にあらかじめ決定されたカウンタ初期値に設定される。そして、Y方向拡大・縮小部122は、入力ブロック画像のラインを、Y方向拡大・縮小カウンタ122aにしたがって拡大・縮小し、出力する画素数(出力ブロック画像側のライン数)を、Y方向出力カウンタ122bでカウントする。そして、Y方向拡大・縮小部122は、Y方向出力カウンタ122bによりあらかじめ決定された所定の値の範囲内の画素(ライン)のみを出力することで、入力されたブロック画像をY方向に拡大・縮小し、出力ブロック画像としてブロック書き出し部130へ供給する。   The value of the Y-direction enlargement / reduction counter 122a of the Y-direction enlargement / reduction unit 122 is set to a counter initial value determined in advance for each block image at the head of the line (line head of the block image). The Y-direction enlargement / reduction unit 122 enlarges / reduces the line of the input block image according to the Y-direction enlargement / reduction counter 122a, and outputs the number of pixels to be output (number of lines on the output block image side) as the Y-direction output. The counter 122b counts. Then, the Y direction enlargement / reduction unit 122 outputs only pixels (lines) within a predetermined value range determined in advance by the Y direction output counter 122b, thereby enlarging / reducing the input block image in the Y direction. The image is reduced and supplied to the block writing unit 130 as an output block image.

なお、Y方向拡大・縮小部122は、単純縮小以外の拡大・縮小方法(例えば、補間拡大・縮小法)により、拡大・縮小処理を行う場合には、1ブロック画像分のメモリ(ラインメモリ)を複数備える必要がある。   Note that the Y-direction enlargement / reduction unit 122 performs memory for one block image (line memory) when performing enlargement / reduction processing by an enlargement / reduction method other than simple reduction (for example, interpolation enlargement / reduction method). It is necessary to have multiple.

サイズ変更画像生成手段としてのブロック書き出し部130は、ブロック拡大・縮小部120で拡大・縮小が行われたブロック画像を画像メモリ60(画像G103の領域)に順次書き込む。ブロック書き出し部130へ入力されるブロック画像は、前段の処理(ブロック拡大・縮小部120の処理)により、ブロック間で重複する画素がカットされる。   The block writing unit 130 serving as the size-changed image generating unit sequentially writes the block images that have been enlarged / reduced by the block enlargement / reduction unit 120 to the image memory 60 (the region of the image G103). In the block image input to the block writing unit 130, overlapping pixels between blocks are cut by the preceding process (the process of the block enlargement / reduction unit 120).

また、各ブロックの幅と高さは一定となっているので、ブロック書き出し部120は、X方向とY方向に一定の間隔でブロック画像を画像メモリ60に書き出すことで1ページ分の画像G103のデータを作成する。 Further, since the width and height of each block are constant, the block writing unit 120 writes the block image to the image memory 60 at a constant interval in the X direction and the Y direction, so that the image G103 for one page is written. Create data.

後フィルタ処理手段としての後フィルタ処理部30は、拡大・縮小処理部100の処理後に行われるフィルタ処理を行うものであり、画像メモリ60から拡大・縮小部10によって入力された画像G103のデータを読み出してフィルタ処理を行い、処理後の画像のデータを画像メモリ60に書き込む。後フィルタ処理部30は、例えば、色変換処理やエッジ強調処理等で構成され、画像データをCMYKの4色に変換し、原稿中の文字等をくっきりだすためにエッジ強調を行うなどのフィルタ処理を行う。図1では、後フィルタ処理部30が処理した後の画像をG104として図示している。   The post-filter processing unit 30 as post-filter processing means performs filter processing performed after the processing of the enlargement / reduction processing unit 100, and the data of the image G103 input by the enlargement / reduction unit 10 from the image memory 60 is processed. The data is read and filtered, and the processed image data is written in the image memory 60. The post-filter processing unit 30 is configured by, for example, color conversion processing, edge enhancement processing, and the like, and performs filter processing such as converting image data into four colors of CMYK and performing edge enhancement in order to clarify characters and the like in a document. I do. In FIG. 1, an image after processing by the post filter processing unit 30 is illustrated as G104.

画像出力部50は、後フィルタ処理部30が生成した画像G104のデータを画像メモリ60より読み出して出力する機能を担っている。画像出力部50による出力手段は限定されないものであり、例えば、画像G104を、電子写真式の画像形成部(印刷部)により記録媒体(印刷用紙等)に印刷出力(画像形成)するようにしてもよい。   The image output unit 50 has a function of reading the data of the image G104 generated by the post-filter processing unit 30 from the image memory 60 and outputting it. The output means by the image output unit 50 is not limited. For example, the image G104 is printed out (image formation) on a recording medium (printing paper or the like) by an electrophotographic image forming unit (printing unit). Also good.

なお、この実施形態では、説明を簡易にするため、画像形成装置1で処理される各画像(G101〜G104)を構成する各画素の画素値は1つの成分(例えば、明度)で示される画像であるものとして説明するが、画像形成装置1で処理される各画像の成分の数は限定されないものである。例えば、画像形成装置1で処理される各画像を、R、G、Bの3つの成分で示される場合、3つの成分画像についてそれぞれ拡大・縮小処理等を行い、画像出力部50で3つの成分画像に基づいた出力を行うようにしてもよい。   In this embodiment, in order to simplify the description, the pixel value of each pixel constituting each image (G101 to G104) processed by the image forming apparatus 1 is an image indicated by one component (for example, brightness). However, the number of components of each image processed by the image forming apparatus 1 is not limited. For example, when each image processed by the image forming apparatus 1 is represented by three components R, G, and B, each of the three component images is subjected to enlargement / reduction processing, and the image output unit 50 performs the three components. You may make it perform the output based on an image.

(A−2)第1の実施形態の動作
次に、以上のような構成を有する第1の実施形態の画像形成装置1の動作(実施形態の画像処理方法)を説明する。
(A-2) Operation of the First Embodiment Next, the operation (image processing method of the embodiment) of the image forming apparatus 1 of the first embodiment having the above-described configuration will be described.

(A−2−1)画像形成装置1全体の動作の概要
図3は、画像形成装置1の全体の動作について示したフローチャートである。
(A-2-1) Overview of Overall Operation of Image Forming Apparatus 1 FIG. 3 is a flowchart showing the overall operation of the image forming apparatus 1.

まず、画像形成装置1では、画像入力部10に画像データが入力されて、画像メモリ60に、画像G101として書き込まれたものとする。そして、拡大・縮小処理部100に設定倍率がセットされたものとする(S101)。   First, in the image forming apparatus 1, it is assumed that image data is input to the image input unit 10 and written as an image G <b> 101 in the image memory 60. It is assumed that the set magnification is set in the enlargement / reduction processing unit 100 (S101).

ここでは、画像G101は、幅7680画素、高さ5120画素の画像であるものとする。またここでは、拡大・縮小処理部100に設定倍率として133%(133/100で拡大)が設定された場合と、41%(41/100で縮小)が設定された場合とで、場合分けして説明する。   Here, it is assumed that the image G101 is an image having a width of 7680 pixels and a height of 5120 pixels. Further, here, the enlargement / reduction processing unit 100 is classified into a case where 133% (enlarged by 133/100) is set as a set magnification and a case where 41% (reduced by 41/100) is set. I will explain.

次に、前フィルタ処理部20により画像G101に対して前フィルタ処理が実行され、画像メモリ60に処理後の画像G102が書き込まれる(S102)。なお、前フィルタ処理部20の処理では画像サイズの変化はないものとする(すなわち、画像G102のサイズは、画像G101と同じであるものとする)。   Next, the pre-filter processing unit 20 performs pre-filter processing on the image G101, and the processed image G102 is written in the image memory 60 (S102). It is assumed that the image size does not change in the processing of the pre-filter processing unit 20 (that is, the size of the image G102 is the same as that of the image G101).

そして、拡大・縮小処理部100(ブロック拡大・縮小部120)により、拡大・縮小処理を行う画像G102のサイズと、設定倍率に基づいて、拡大・縮小に係る各パラメータ算出等の準備が行われる(S103)。   Then, the enlargement / reduction processing unit 100 (block enlargement / reduction unit 120) prepares for calculation of each parameter related to enlargement / reduction based on the size of the image G102 to be enlarged / reduced and the set magnification. (S103).

そして、拡大・縮小処理部100により、ブロック単位で、読み出し処理、拡大・縮小処理、及び書き出し処理が実行され、画像メモリ60に処理後の画像G103が書き込まれる(S104)。   Then, the enlargement / reduction processing unit 100 executes read processing, enlargement / reduction processing, and write-out processing in units of blocks, and the processed image G103 is written to the image memory 60 (S104).

そして、後フィルタ処理部30により、拡大・縮小処理後の画像G103について後フィルタ処理が実行され、画像メモリ60に処理後の画像G104が書き込まれる(S105)。なお、後フィルタ処理部30の処理では画像サイズの変化はないものとする(すなわち、画像G104のサイズは、画像G103と同じであるものとする)。   Then, the post-filter processing unit 30 executes post-filter processing on the image G103 after the enlargement / reduction processing, and the processed image G104 is written in the image memory 60 (S105). It is assumed that the image size does not change in the processing of the post-filter processing unit 30 (that is, the size of the image G104 is the same as that of the image G103).

そして、画像出力部50により、後フィルタ処理後の画像G104が出力されることになる(S106)。   Then, the image output unit 50 outputs the post-filter processed image G104 (S106).

(A−2−2)拡大・縮小に係る各パラメータ算出(ステップS103)
次に、上述のステップS103において、ブロック拡大・縮小部120で行われるパラメータ算出処理の詳細について、図4のフローチャートを用いて説明する。
(A-2-2) Calculation of parameters related to enlargement / reduction (step S103)
Next, details of the parameter calculation processing performed by the block enlargement / reduction unit 120 in step S103 will be described with reference to the flowchart of FIG.

まず、ブロック拡大・縮小部120は、画像G102と設定倍率に基づいて、拡大・縮小処理後に出力する画像G103のサイズ(1ページの出力画像の幅と高さ)を算出する(S201)。具体的には、ブロック拡大・縮小部120は、以下の(1)、(2)式により、画像G103のサイズを算出することができる。   First, the block enlargement / reduction unit 120 calculates the size (width and height of the output image of one page) of the image G103 output after the enlargement / reduction processing based on the image G102 and the set magnification (S201). Specifically, the block enlargement / reduction unit 120 can calculate the size of the image G103 by the following equations (1) and (2).

なお、以下の(1)、(2)式において、XOは出力する画像G103の幅(X方向)の画素数である。また、XIは、処理対象の画像G102の幅(X方向)の画素数である。さらにYOは出力する画像G103の高さ(Y方向)の画素数である。さらにまた、YIは、処理対象の画像G102の高さ(Y方向)の画素数である。また、xratio、yratioは、それぞれX方向、Y方向に係る設定倍率の分子である。さらに、xbase、ybaseは、それぞれX方向、Y方向の設定倍率の分母である。   In the following expressions (1) and (2), XO is the number of pixels in the width (X direction) of the output image G103. XI is the number of pixels in the width (X direction) of the processing target image G102. Furthermore, YO is the number of pixels in the height (Y direction) of the output image G103. Furthermore, YI is the number of pixels in the height (Y direction) of the image G102 to be processed. Further, xratio and yratio are numerators having set magnifications in the X direction and the Y direction, respectively. Further, xbase and ybase are denominators of set magnifications in the X direction and the Y direction, respectively.

XO=(XI)×(xratio)/(xbase)…(1)
YO=(YI)×(yratio)/(ybase)…(2)
なお、ブロック拡大・縮小部120は、上記の(1)、(2)式の計算を行う際に、小数点以下の値が発生する場合は小数点以下を切り捨てるものとする。なお、以下に記載の数式は特に断りなく小数点以下を切り捨てて演算を行うものとして説明する。
XO = (XI) × (xratio) / (xbase) (1)
YO = (YI) × (yratio) / (ybase) (2)
Note that the block enlargement / reduction unit 120 truncates the decimal part when a value below the decimal point is generated when the above formulas (1) and (2) are calculated. Note that the mathematical formulas described below will be described assuming that the calculation is performed with the decimal part rounded down without particular notice.

ここでの例では、上述の通り、入力する画像G102のサイズは、幅7680、高さ5120であり、設定倍率は133%である。したがって、出力する画像G103の幅XOは、上記の(1)式により、7680×133/100=10214となる。また、出力する画像G103の高さYOは、上記の(2)式により、5120×133/100=6809となる。また、設定倍率を41%とした場合、出力する画像G103の幅XOは7680×41/100=3148、高さYOは、5120×41/100=2099となる。   In this example, as described above, the size of the input image G102 is the width 7680, the height 5120, and the set magnification is 133%. Therefore, the width XO of the output image G103 is 7680 × 133/100 = 10214 according to the above equation (1). The height YO of the image G103 to be output is 5120 × 133/100 = 6809 according to the above equation (2). When the set magnification is 41%, the output image G103 has a width XO of 7680 × 41/100 = 3148 and a height YO of 5120 × 41/100 = 2999.

次に、ブロック拡大・縮小部120は、ブロック拡大・縮小部120に入力される入力ブロック画像のサイズと、ブロック拡大・縮小部120から出力される出力ブロック画像のサイズを算出する(S102)。言い換えると、第1の実施形態では、入力ブロック画像のサイズは、ブロック読み出し部110が画像G102から読み出すブロック画像のサイズとなる。また、第1の実施形態では、出力ブロック画像のサイズは、ブロック書き出し部130が画像G103に書き出すブロック画像のサイズとなる。   Next, the block enlargement / reduction unit 120 calculates the size of the input block image input to the block enlargement / reduction unit 120 and the size of the output block image output from the block enlargement / reduction unit 120 (S102). In other words, in the first embodiment, the size of the input block image is the size of the block image that the block reading unit 110 reads from the image G102. In the first embodiment, the size of the output block image is the size of the block image that the block writing unit 130 writes to the image G103.

ブロック拡大・縮小部120が算出する、入力ブロック画像及び出力ブロック画像のサイズは、設定倍率と、拡大・縮小処理部100を構成する各処理部で処理可能なブロック画像サイズの上限によって変動する。上述のブロック画像サイズ(ブロック画像の幅又は高さ)の上限は、例えば、ブロック拡大・縮小部120が備えるメモリ(例えば、ラインメモリ)等のリソースで保持可能な画素数が上限となる。例えば、ブロック拡大・縮小部120は、各画像ブロックについて、X方向及びY方向のライン単位で処理するため、ブロック拡大・縮小部120が備えるメモリに格納可能な画素数が、処理するブロック画像の幅及び高さの上限となる。そして、ここでは、ブロック拡大・縮小部120のラインメモリで保持可能な画素数は、256であるものとする。また、以下では、各ブロック画像の幅と高さは同一の画素数であるものとするが、各ブロック画像の幅と高さの比率は限定されないものである。   The sizes of the input block image and the output block image calculated by the block enlargement / reduction unit 120 vary depending on the set magnification and the upper limit of the block image size that can be processed by each processing unit constituting the enlargement / reduction processing unit 100. The upper limit of the block image size (the width or height of the block image) is, for example, the upper limit of the number of pixels that can be held by resources such as a memory (for example, a line memory) provided in the block enlargement / reduction unit 120. For example, since the block enlargement / reduction unit 120 processes each image block in units of lines in the X direction and the Y direction, the number of pixels that can be stored in the memory included in the block enlargement / reduction unit 120 is equal to the block image to be processed. It becomes the upper limit of the width and height. Here, it is assumed that the number of pixels that can be held in the line memory of the block enlargement / reduction unit 120 is 256. In the following description, it is assumed that the width and height of each block image have the same number of pixels, but the ratio of the width and height of each block image is not limited.

以上のように、ブロック拡大・縮小部120は、拡大・縮小処理部100がブロック画像単位で処理する際の処理上限を超えないように、拡大・縮小処理部100に入力するブロック画像のサイズを決定する。   As described above, the block enlargement / reduction unit 120 sets the size of the block image input to the enlargement / reduction processing unit 100 so as not to exceed the processing upper limit when the enlargement / reduction processing unit 100 performs processing in units of block images. decide.

以下では、ブロック拡大・縮小部120で処理する出力ブロック画像について、幅及び高さの上限をいずれも256画素とする。したがって、ブロック拡大・縮小部120では、入力ブロック画像について拡大処理をする場合、拡大処理後に幅及び高さが256を超えないように、入力ブロック画像のサイズを決定する必要がある。   Hereinafter, the upper limit of the width and height of the output block image processed by the block enlargement / reduction unit 120 is 256 pixels. Therefore, when performing the enlargement process on the input block image, the block enlargement / reduction unit 120 needs to determine the size of the input block image so that the width and height do not exceed 256 after the enlargement process.

具体的には、ブロック拡大・縮小部120は、例えば、以下のような処理により、適切な入力ブロック画像及び出力ブロック画像のサイズを決定することができる。   Specifically, the block enlargement / reduction unit 120 can determine appropriate sizes of the input block image and the output block image, for example, by the following processing.

まず、ブロック拡大・縮小部120が出力するブロック画像サイズは上述の条件であれば幅256、高さ256となる。上述の幅、高さは、拡大・縮小部120のX方向出力カウンタ121bとY方向出力カウンタ122bのカウント上限の値として用いる。したがって、ブロック読み出し部110で読み出すブロック画像サイズは、以下の(3)、(4)式で決定することができる。   First, the block image size output from the block enlargement / reduction unit 120 is a width 256 and a height 256 under the above-described conditions. The above-described width and height are used as upper limit values of the X direction output counter 121b and the Y direction output counter 122b of the enlargement / reduction unit 120. Therefore, the block image size read by the block reading unit 110 can be determined by the following equations (3) and (4).

以下の(3)、(4)式において、inbw、inbhはブロック拡大・縮小部120に入力されるブロック画像の幅、高さである。また、outbw、outbhはブロック拡大・縮小部120が出力するブロック画像の幅、高さである。さらに、nulwR、nulhDはブロック拡大・縮小部120での拡大・縮小時にブロック画像の右端と下端に発生する無効画素(隣接するブロック画像と重複する部分の領域)の幅、高さを表す。ブロック拡大・縮小部120が行う拡大・縮小に補間拡大・縮小法が用いられる場合、nulwR、nulhDには、例えば、「1」を適用することができる。   In the following equations (3) and (4), inbw and inbh are the width and height of the block image input to the block enlargement / reduction unit 120. Outbw and outbh are the width and height of the block image output by the block enlargement / reduction unit 120. Furthermore, ulwR and ullhD represent the width and height of invalid pixels (regions overlapping with adjacent block images) generated at the right and bottom edges of the block image when the block enlargement / reduction unit 120 performs enlargement / reduction. When the interpolation enlargement / reduction method is used for enlargement / reduction performed by the block enlargement / reduction unit 120, for example, “1” can be applied to ulwR and ulhD.

inbw=(outbw×xbase+xratio−1)
/xratio+nulwR …(3)
inbh=(outbh×ybase+yratio−1)
/yratio+nulhD …(4)
ここでの例では、上述の通り、入力する画像G102のサイズは、幅7680、高さ5120であり、設定倍率は133%である。したがって、入力ブロック画像の幅及び高さは194となる。また、設定倍率を41%とした場合、入力ブロック画像の幅及び高さは626となる。
inbw = (outbw × xbase + xratio−1)
/ Xratio + nulwR (3)
inbh = (outbh × ybase + yratio−1)
/ Yratio + nullhD (4)
In this example, as described above, the size of the input image G102 is the width 7680, the height 5120, and the set magnification is 133%. Therefore, the width and height of the input block image are 194. When the set magnification is 41%, the width and height of the input block image are 626.

次に、ブロック拡大・縮小部120は、ステップS202で算出した入力ブロック画像のサイズに基づいて、画像G102に対するブロック画像の分割数を算出する(S203)。   Next, the block enlargement / reduction unit 120 calculates the number of block image divisions for the image G102 based on the size of the input block image calculated in step S202 (S203).

具体的には、ブロック拡大・縮小部120は、以下の(5)、(6)式により、画像G102に対するX方向およびY方向の分割数を算出することができる。   Specifically, the block enlargement / reduction unit 120 can calculate the number of divisions in the X direction and the Y direction with respect to the image G102 by the following equations (5) and (6).

(X方向分割数)=(XO−1)/(outbw)+1 …(5)
(Y方向分割数)=(YO−1)/(outbh)+1 …(6)
ここでの例では、上述の通り、入力する画像G102のサイズは、幅7680、高さ5120である。したがって、設定倍率が133%(133/100)の場合、入力ブロック画像の幅及び高さは194であるため、X方向の分割数は40、Y方向の分割数は27となる。また、設定倍率を41%(41/100)とした場合、入力ブロック画像の幅及び高さは626であるため、X方向の分割数は13、Y方向の分割数は9となる。
(X direction division number) = (XO−1) / (outbw) +1 (5)
(Y direction division number) = (YO-1) / (outbh) +1 (6)
In this example, as described above, the input image G102 has a width of 7680 and a height of 5120. Therefore, when the set magnification is 133% (133/100), the width and height of the input block image are 194, so the number of divisions in the X direction is 40 and the number of divisions in the Y direction is 27. When the set magnification is 41% (41/100), the width and height of the input block image are 626, so the number of divisions in the X direction is 13, and the number of divisions in the Y direction is 9.

そして、次に、ブロック拡大・縮小部120は、ブロック画像ごとに、X方向拡大・縮小カウンタ121a、及びY方向拡大・縮小カウンタ122aの初期値と、ブロック読み出し部110が読み出す各ブロック画像のX方向とY方向の読み出し位置を算出する(S204)。Y方向拡大・縮小カウンタ122aの初期値、Y方向拡大・縮小カウンタ122aの初期値、X方向の読み出し位置、及びY方向の読み出し位置はそれぞれ以下の(7)〜(14)式で算出することができる。   Then, the block enlargement / reduction unit 120, for each block image, the initial values of the X direction enlargement / reduction counter 121a and the Y direction enlargement / reduction counter 122a and the X of each block image read by the block reading unit 110. The reading position in the direction and the Y direction is calculated (S204). The initial value of the Y direction enlargement / reduction counter 122a, the initial value of the Y direction enlargement / reduction counter 122a, the readout position in the X direction, and the readout position in the Y direction should be calculated by the following equations (7) to (14), respectively. Can do.

以下の(7)〜(14)式において、xno、ynoは、それぞれX方向のブロック番号、Y方向のブロック番号を表す。また、xcnt0[?]、ycnt0[?]は、それぞれ、X方向のブロック番号に対応するX方向拡大・縮小カウンタ121aの初期値、Y方向のブロック番号に対応するY方向拡大・縮小カウンタ122aの初期値をあらわす。   In the following formulas (7) to (14), xno and yno represent a block number in the X direction and a block number in the Y direction, respectively. Also, xcnt0 [? ], Ycnt0 [? ] Represents the initial value of the X-direction enlargement / reduction counter 121a corresponding to the block number in the X direction and the initial value of the Y-direction enlargement / reduction counter 122a corresponding to the block number in the Y direction, respectively.

なお、上述の「?」は任意のブロック番号を表すものである(以下同様)。さらに、xpoS0[?]、ypoS0[?]は、それぞれ、X方向のブロック番号に対応するX方向の読み出し位置、Y方向のブロック番号に対応するY方向の読み出し位置をあらわす。さらにまた、outbw、outbhは、上述のステップS202で算出した、出力ブロック画像の幅、高さである。また、以下の(7)〜(14)式における「%」は剰余演算を表す演算子である。ブロック拡大・縮小部120は、以下の(7)〜(14)式を用いて、X方向であれば左端のブロックから順番に、Y方向であれば最上段のブロックから順番に拡大・縮小カウンタの初期値と読み出し位置を算出する。 The above “?” Represents an arbitrary block number (the same applies hereinafter). Furthermore, xpoS0 [? ], YpoS0 [? ] Represents the X-direction read position corresponding to the X-direction block number and the Y-direction read position corresponding to the Y-direction block number, respectively. Furthermore, outbw and outbh are the width and height of the output block image calculated in step S202 described above. Further, “%” in the following formulas (7) to (14) is an operator representing a remainder operation. The block enlargement / reduction unit 120 uses the following formulas (7) to (14) to increase / decrease the counter in order from the leftmost block in the X direction and from the uppermost block in the Y direction. The initial value and the reading position are calculated.

[X方向の拡大・縮小カウンタの算出式]
xcnt0[0]=0 …(7)
xcnt0[xno]=
(outbw×xbase+xcnt0[xno−1])%xratio…(8)[Y方向の拡大・縮小カウンタの算出式]
ycnt0[0]=0…(9)
ycnt0[yno]=
(outbh×ybase+ycnt0[yno−1])%yratio…(10)
[X方向の読み出し位置]
xpoS0[0]=0 …(11)
xpoS0[xno]=xpoS0[xno−1]
+(outbw×xbase+xcnt0[xno−1])/xratio…(12)
[Y方向の読み出し位置]
ypos0[0]=0 …(13)
ypos0[yno]=ypoS0[yno−1]
+(outbh×ybase+ycnt0[yno−1])/yratio…(14)
以上のように、ブロック拡大・縮小部120では、拡大・縮小に係る各パラメータが算出される。
[Calculation formula for enlargement / reduction counter in X direction]
xcnt0 [0] = 0 (7)
xcnt0 [xno] =
(Outbw × xbase + xcnt0 [xno−1])% xratio (8) [Calculation formula of enlargement / reduction counter in Y direction]
ycnt0 [0] = 0 (9)
ycnt0 [yno] =
(Outbh × ybase + ycnt0 [yno−1])% yratio (10)
[Reading position in X direction]
xpoS0 [0] = 0 (11)
xpoS0 [xno] = xpoS0 [xno-1]
+ (Outbw × xbase + xcnt0 [xno−1]) / xratio (12)
[Reading position in Y direction]
ypos0 [0] = 0 (13)
ypos0 [yno] = ypoS0 [yno-1]
+ (Outbh × ybase + ycnt0 [yno−1]) / yratio (14)
As described above, the block enlargement / reduction unit 120 calculates each parameter related to enlargement / reduction.

(A−2−3)ブロック読み出し部110による入力ブロック画像の読み出し処理
次に、上述のステップS104において、ブロック読み出し部110で行われる入力ブロックの読み出し処理の詳細について、図5を用いて説明する。
(A-2-3) Input Block Image Reading Process by Block Reading Unit 110 Next, details of the input block reading process performed by the block reading unit 110 in step S104 described above will be described with reference to FIG. .

図5は、ブロック読み出し部110が、上述のステップS103で決定したパラメータに従って、拡大・縮小処理部100に入力される画像G102を、入力ブロック単位で読み出す場合の処理について示した説明図である。なお、図5では、入力する画像G102のサイズは、幅7680、高さ5120、設定倍率が133%の場合について示している。   FIG. 5 is an explanatory diagram showing processing when the block reading unit 110 reads the image G102 input to the enlargement / reduction processing unit 100 in units of input blocks according to the parameters determined in step S103 described above. In FIG. 5, the size of the input image G102 is shown for the case where the width is 7680, the height is 5120, and the set magnification is 133%.

図5(a)で示されるように、ブロック読み出し部110で読み出される入力ブロック画像は、隣接する入力ブロック画像と、重複部分を持つように読み出される。図5(a)では、入力される画像G102の最も左の画素のX方向の位置を0、最も上の画素のY方向の位置を0として表している。そして、ブロック読み出し部110が分割する入力ブロック画像のX方向の読み出し開始位置についてはX方向のブロック番号0、1、2、3、4、・・・に対応して、0、192、384、577、769、・・・となる。また、ブロック読み出し部110が分割する入力ブロック画像のY方向の読み出し開始位置については、Y方向のブロック番号0、1、・・・に対応して、0、192、・・・となる。例えば、X方向のブロック番号が2、Y方向のブロック番号が1の入力ブロック画像であれば、X方向とY方向の読み出し位置は(384、192)になる。また、読み出される各入力ブロック画像のサイズは、全ての入力ブロック画像で共通である(図5(b)の例では、幅194×高さ194)。そして、ブロック読み出し部110は、各入力ブロック画像について、各入力ブロック画像のX方向とY方向のブロック番号にしたがって、X方向とY方向の読み出し位置を変更しながら読み出し、読み出した入力ブロック画像をブロック拡大・縮小部120に供給する。   As shown in FIG. 5A, the input block image read by the block reading unit 110 is read so as to have an overlapping portion with an adjacent input block image. In FIG. 5A, the position of the leftmost pixel of the input image G102 in the X direction is represented as 0, and the position of the uppermost pixel in the Y direction is represented as 0. Then, the reading start position in the X direction of the input block image divided by the block reading unit 110 is 0, 192, 384, corresponding to the block numbers 0, 1, 2, 3, 4,. 577, 769, and so on. Also, the reading start position in the Y direction of the input block image divided by the block reading unit 110 is 0, 192,... Corresponding to the block numbers 0, 1,. For example, if the input block image has an X-direction block number of 2 and a Y-direction block number of 1, the readout position in the X-direction and the Y-direction is (384, 192). In addition, the size of each input block image to be read is common to all the input block images (in the example of FIG. 5B, width 194 × height 194). Then, the block readout unit 110 reads out each input block image while changing the readout position in the X direction and the Y direction according to the block number in the X direction and the Y direction of each input block image, and reads the read input block image. This is supplied to the block enlargement / reduction unit 120.

(A−2−4)ブロック拡大・縮小部120による拡大・縮小処理
次に、上述のステップS104において、ブロック拡大・縮小部120で行われる各入力ブロック画像に対する拡大・縮小処理について説明する。
(A-2-4) Enlargement / Reduction Process by Block Enlargement / Reduction Unit 120 Next, the enlargement / reduction process for each input block image performed by the block enlargement / reduction unit 120 in step S104 will be described.

図6は、ブロック拡大・縮小部120で行われる各入力ブロック画像に対する拡大・縮小処理の例について示した説明図である。図6では、図5に示す入力ブロック画像(幅194×高さ194)について、設定倍率を133%とする拡大・縮小処理が行われ、出力ブロック画像(幅256×高さ256)に変換される場合の例について示している。   FIG. 6 is an explanatory diagram showing an example of enlargement / reduction processing for each input block image performed by the block enlargement / reduction unit 120. In FIG. 6, the input block image (width 194 × height 194) shown in FIG. 5 is subjected to enlargement / reduction processing with a set magnification of 133%, and converted to an output block image (width 256 × height 256). An example is shown.

まず、ブロック拡大・縮小部120では、図6(a)に示す入力ブロック画像(幅194×高さ194)について、X方向拡大・縮小部121により、X方向に拡大されたブロック画像(ブロック画像サイズは幅256×高さ194)が生成される(図6(b)参照)。   First, in the block enlargement / reduction unit 120, the block image (block image) enlarged in the X direction by the X direction enlargement / reduction unit 121 for the input block image (width 194 × height 194) shown in FIG. The size is 256 (width × height 194) (see FIG. 6B).

そして、ブロック拡大・縮小部120では、X方向について拡大処理されたブロック画像(図6(b)に示す画像ブロック)について、Y方向拡大・縮小部122により、Y方向に拡大されたブロック画像(ブロック画像サイズは幅256×高さ256)が生成される(図6(c)参照)。そして、ブロック拡大・縮小部120では、Y方向拡大・縮小部122により処理されたブロック画像が、出力ブロック画像として、ブロック書き出し部130に供給される。   Then, in the block enlargement / reduction unit 120, the block image (image block shown in FIG. 6B) enlarged in the X direction is enlarged in the Y direction by the Y direction enlargement / reduction unit 122. As a block image size, width 256 × height 256) is generated (see FIG. 6C). Then, the block enlargement / reduction unit 120 supplies the block image processed by the Y direction enlargement / reduction unit 122 to the block writing unit 130 as an output block image.

次に、X方向拡大・縮小部121の処理の詳細について説明する。   Next, details of the processing of the X direction enlargement / reduction unit 121 will be described.

上述のX方向拡大・縮小部121による処理では、X方向拡大・縮小カウンタ121aが、各ブロック画像のライン先頭で、当該ブロック画像に係るX方向のブロック番号に対応する拡大・縮小カウンタの初期値(xcnt0[xno])に設定される。例えば、X方向のブロック番号が2であれば128に設定される。上述の拡大・縮小カウンタにしたがってライン毎に拡大処理が行われ、X方向出力カウンタ121bが所定の値(例では256)になるまで拡大して出力される。また、図6(d)に示すように、X方向の拡大・縮小処理においては、ブロック画像右端に余分な画素(無効画素)がある場合は無視(除外)される。   In the processing by the X direction enlargement / reduction unit 121 described above, the X direction enlargement / reduction counter 121a is the initial value of the enlargement / reduction counter corresponding to the block number in the X direction related to the block image at the head of the line of each block image. (Xcnt0 [xno]). For example, if the block number in the X direction is 2, it is set to 128. The enlargement process is performed for each line according to the above-described enlargement / reduction counter, and the X-direction output counter 121b is enlarged and output until a predetermined value (256 in the example) is reached. Further, as shown in FIG. 6D, in the enlargement / reduction process in the X direction, if there is an extra pixel (invalid pixel) at the right end of the block image, it is ignored (excluded).

次に、Y方向拡大・縮小部122の処理の詳細について説明する。   Next, details of the processing of the Y direction enlargement / reduction unit 122 will be described.

上述のY方向拡大・縮小部122による処理では、Y方向拡大・縮小カウンタ122aが各ブロック画像の先頭ラインで、当該ブロック画像に係るY方向のブロック番号に対応する拡大・縮小カウンタの初期値(ycnt0[yno])に設定される。例えば、Y方向のブロック番号が1であれば64に設定される。上述の拡大・縮小カウンタにしたがって、ライン毎に拡大処理が行われ、出力カウンタが所定の値(例では256)になるまで拡大して出力する。また、図6(e)に示すように、X方向の拡大・縮小処理においては、ブロック下端に余分な画素(無効画素)がある場合は無視(除外)される。   In the processing by the Y-direction enlargement / reduction unit 122 described above, the Y-direction enlargement / reduction counter 122a is the initial value of the enlargement / reduction counter corresponding to the block number in the Y direction related to the block image on the first line of each block image ( ycnt0 [yno]). For example, if the block number in the Y direction is 1, it is set to 64. In accordance with the above-described enlargement / reduction counter, enlargement processing is performed for each line, and the output counter is enlarged and output until a predetermined value (256 in the example) is reached. Further, as shown in FIG. 6E, in the enlargement / reduction process in the X direction, if there is an extra pixel (invalid pixel) at the lower end of the block, it is ignored (excluded).

そして、上述のX方向拡大・縮小部121による1ライン分の拡大・縮小処理は、具体的には、図8のようなフローチャートにより表すことができる。Y方向拡大・縮小部122の処理についても、処理対象となるラインの方向が異なるだけで、X方向拡大・縮小部121とほぼ同様の処理を適用することができるため、フローチャートを用いた説明については省略する。   Then, the enlargement / reduction processing for one line by the X-direction enlargement / reduction unit 121 can be specifically expressed by a flowchart as shown in FIG. Regarding the processing of the Y-direction enlargement / reduction unit 122, the processing similar to that of the X-direction enlargement / reduction unit 121 can be applied only by changing the direction of the line to be processed. Is omitted.

図8において、xocntはX方向出力カウンタ121b、xcntはX方向拡大・縮小カウンタ121a、xcnt0は処理対象のブロック画像に係るX方向拡大・縮小カウンタ121aの初期値を表すものとする。また、図8において、xicntは、参照する入力ブロック画像側のX方向のライン上の位置(画素)を管理するカウンタである。さらに、図8において、vo[xocnt]は、出力ブロック画像側のX方向のライン上で、xocntの位置の画素値(左端から数えてxocnt番目の画素の画素値)を示している。   In FIG. 8, xocnt represents the X direction output counter 121b, xcnt represents the X direction enlargement / reduction counter 121a, and xcnt0 represents the initial value of the X direction enlargement / reduction counter 121a associated with the block image to be processed. In FIG. 8, xicnt is a counter that manages the position (pixel) on the line in the X direction on the side of the input block image to be referred to. Furthermore, in FIG. 8, vo [xocnt] indicates the pixel value at the position of xocnt (pixel value of the xocnt-th pixel counted from the left end) on the line in the X direction on the output block image side.

まず、X方向拡大・縮小部121は、入力ブロック画像からX方向の1ライン分の画素値を抽出したものとする。そして、X方向拡大・縮小部121は、各変数の初期化(xocnt=0、xcnt=xcnt0、xicnt=0)を行う(S301)。   First, it is assumed that the X direction enlargement / reduction unit 121 extracts pixel values for one line in the X direction from the input block image. Then, the X-direction enlargement / reduction unit 121 initializes each variable (xocnt = 0, xcnt = xcnt0, xicnt = 0) (S301).

そして、X方向拡大・縮小部121は、xcnt(拡大・縮小カウンタの値)がxratio(設定倍率の分子の値)より小さいか否かを判定する。X方向拡大・縮小部121は、xcntがxratioよりも小さい場合は、後述するステップS303の処理から動作し、そうでない場合には、後述するステップS305の処理から動作する。   Then, the X direction enlargement / reduction unit 121 determines whether xcnt (a value of the enlargement / reduction counter) is smaller than xratio (a numerator value of the set magnification). The X direction enlargement / reduction unit 121 operates from the process of step S303 described later when xcnt is smaller than xratio, and operates from the process of step S305 described later otherwise.

上述のステップS302で、xcntがxratioよりも小さいと判定された場合は、X方向拡大・縮小部121は、出力画素の画素値vo[xocnt]を求めて、xocntをインクリメント(1加算)し、さらに、xcntにxbaseを加算する処理を行う(S303)。   If it is determined in step S302 described above that xcnt is smaller than xratio, the X-direction enlargement / reduction unit 121 obtains a pixel value vo [xocnt] of the output pixel, increments xocnt (adds 1), Further, a process of adding xbase to xcnt is performed (S303).

ここで、出力画素の画素値vo[xocnt]は、例えば、補間拡大・縮小法であれば、以下の(15)式により求めることができる。なお、以下の(15)式において、vi[xicnt]は、入力ブロック画像側のX方向のライン上で、xicntの位置の画素値(左端から数えてxicnt番目の画素の画素値)を示している。また、vi[xicnt+1]は、入力ブロック側のX方向のライン上で、xicnt+1の位置の画素値(左端から数えてxicnt+1番目の画素の画素値)を示している。   Here, the pixel value vo [xocnt] of the output pixel can be obtained by, for example, the following equation (15) in the case of the interpolation enlargement / reduction method. In the following equation (15), vi [xicnt] indicates the pixel value at the xicnt position (pixel value of the xicnt-th pixel counted from the left end) on the line in the X direction on the input block image side. Yes. Further, vi [xicnt + 1] indicates the pixel value at the position of xicnt + 1 (the pixel value of the xicnt + 1-th pixel counted from the left end) on the line in the X direction on the input block side.

vo[xocnt]=
((vi[xicnt])×(xratio−xcnt)
+(vi[xicnt+1])×(xcnt))/(xbase)…(15)
そして、X方向拡大・縮小部121は、xcntの値がxratio以上であるか否かを判定し、xcntの値がxratio以上の場合のみ、xcntからxratioを減算する処理、及び、入力画素位置の更新処理(xicntのインクリメント)を行う(S305)。
vo [xocnt] =
((Vi [xicnt]) × (xratio−xcnt)
+ (Vi [xicnt + 1]) × (xcnt)) / (xbase) (15)
Then, the X direction enlargement / reduction unit 121 determines whether or not the value of xcnt is greater than or equal to xratio, and only when the value of xcnt is greater than or equal to xratio, the process of subtracting xratio from xcnt, and the input pixel position Update processing (increment of xicnt) is performed (S305).

そして、X方向拡大・縮小部121は、出力カウンタxocntの値が、outbw(1出力ブロック画像におけるX方向のラインの出力画素数)に達したか否かが判定される(S306)。X方向拡大・縮小部121は、xocntがoutbwに達している場合には、当該ラインに係る処理を終了し、xocntがoutbwに達していない場合には、上述のステップS302に戻って当該ラインに係る処理を継続する。   Then, the X direction enlargement / reduction unit 121 determines whether or not the value of the output counter xocnt has reached outbw (the number of output pixels of the line in the X direction in one output block image) (S306). When xocnt has reached outbw, the X-direction enlargement / reduction unit 121 ends the process related to the line, and when xocnt has not reached outbw, the X direction enlargement / reduction unit 121 returns to step S302 to enter the line. Continue such processing.

X方向拡大・縮小部121は、各ブロック画像に係るすべてのX方向のラインについて上述のフローチャートの処理を行って、入力ブロック画像についてX方向に拡大・縮小を行うことができる。   The X-direction enlargement / reduction unit 121 can perform the above-described flowchart processing on all the X-direction lines related to each block image, and can enlarge or reduce the input block image in the X-direction.

(A−2−5)ブロック書き出し部130による書き出し処理
次に、上述のステップS104において、ブロック書き出し部130で行われるブロック画像の書き出し処理について説明する。
(A-2-5) Writing Process by Block Writing Unit 130 Next, the block image writing process performed by the block writing unit 130 in the above-described step S104 will be described.

図7は、ブロック書き出し部130による画像メモリ60へのブロック画像の書き出し動作について示した説明図である。   FIG. 7 is an explanatory diagram showing a block image writing operation to the image memory 60 by the block writing unit 130.

図7に示すように、ブロック書き出し部130に入力されたブロック画像はX方向とY方向に一定の間隔(X方向については256、Y方向については256)で1ページ分の画像G103として、画像メモリ60に書き込まれる。   As shown in FIG. 7, the block image input to the block writing unit 130 is an image G103 for one page at a constant interval in the X and Y directions (256 in the X direction and 256 in the Y direction). It is written in the memory 60.

(A−3)第1の実施形態の効果
第1の実施形態によれば、以下のような効果を奏することができる。
(A-3) Effects of First Embodiment According to the first embodiment, the following effects can be achieved.

画像形成装置1では、ページ幅又は高さ分(出力する画像G104の幅又は高さ)の画素を保持するラインメモリではなく、ページを分割したブロック画像の幅分の画素を保持するラインメモリで、任意倍率の拡大・縮小処理を行うことができる。したがって、画像形成装置1では、入力又は出力する画像のサイズ(画素数)が大きくなっても、メモリ等のリソースを追加せずに(効率的に)処理することができる。   The image forming apparatus 1 is not a line memory that holds pixels corresponding to the page width or height (width or height of the output image G104) but a line memory that holds pixels corresponding to the width of the block image obtained by dividing the page. The enlargement / reduction process at an arbitrary magnification can be performed. Therefore, in the image forming apparatus 1, even if the size (number of pixels) of the image to be input or output increases, processing can be performed (efficiently) without adding resources such as a memory.

(B)第2の実施形態
以下、本発明による画像処理装置及び方法、並びに、画像形成装置の第2の実施形態を、図面を参照しながら詳述する。
(B) Second Embodiment Hereinafter, an image processing apparatus and method and an image forming apparatus according to a second embodiment of the present invention will be described in detail with reference to the drawings.

(B−1)第2の実施形態の構成
第1の実施形態では、拡大・縮小処理部100の前段及び後段でフィルタ処理が行われ、各フィルタ処理において、それぞれ画像メモリ60に対する画像データの読み出し及び書込みが発生している。したがって、第1の実施形態の画像形成装置1では、画像メモリ60にフィルタ処理ごとに画像データを保持するためのメモリ領域を確保する必要がある。また、画像処理装置において、画像データを記憶するメモリは、通常、DRAM等の大規模なメモリが一つだけ使用されることが考えられ、単位時間当たりにアクセス可能なデータ量は有限となる。したがって、第1の実施形態の画像形成装置1において、画像メモリ60に対する画像データの読込回数及び書込み回数を低減することにより、効率的な画像処理が可能となる。
(B-1) Configuration of Second Embodiment In the first embodiment, filter processing is performed before and after the enlargement / reduction processing unit 100, and image data is read out from the image memory 60 in each filter processing. And writing has occurred. Therefore, in the image forming apparatus 1 according to the first embodiment, it is necessary to secure a memory area in the image memory 60 for holding image data for each filter process. In the image processing apparatus, it is considered that only one large-scale memory such as a DRAM is normally used as a memory for storing image data, and the amount of data that can be accessed per unit time is limited. Therefore, in the image forming apparatus 1 of the first embodiment, efficient image processing can be performed by reducing the number of times image data is read from and written to the image memory 60.

そこで、図9に示す第2の実施形態の画像形成装置1Aでは、フィルタ処理についてもブロック画像単位で行うことにより、画像メモリ60へのアクセス回数を低減する構成となっている。   Therefore, the image forming apparatus 1A according to the second embodiment shown in FIG. 9 is configured to reduce the number of accesses to the image memory 60 by performing the filtering process in units of block images.

図9(a)は、第2の実施形態に係る画像形成装置1Aの機能的構成について示したブロック図であり、上述の図1(a)と同一又は対応する部分には、同一又は対応する符号を付している。図9(b)は、第2の実施形態に係る画像形成装置1Aが備えるブロック拡大・縮小部120Aの機能的構成について示したブロック図である、上述の図1(b)と同一又は対応する部分には、同一又は対応する符号を付している。   FIG. 9A is a block diagram illustrating a functional configuration of the image forming apparatus 1A according to the second embodiment. The same or corresponding parts as those in FIG. The code | symbol is attached | subjected. FIG. 9B is a block diagram illustrating a functional configuration of the block enlargement / reduction unit 120A included in the image forming apparatus 1A according to the second embodiment, and is the same as or corresponds to the above-described FIG. The parts are given the same or corresponding symbols.

以下では、第2の実施形態について、第1の実施形態との差異を説明する。   Hereinafter, the difference between the second embodiment and the first embodiment will be described.

第2の実施形態の画像形成装置1Aは、画像入力部10、拡大・縮小処理部100A、画像出力部50及び画像メモリ60を有している。また、拡大・縮小処理部100Aには、前段から順に、ブロック読み出し部110A、前フィルタ処理部140、ブロック拡大・縮小部120A、後フィルタ処理部150、ブロックカット処理部160、及びブロック書き出し部130Aが配置されている。以下では、拡大・縮小処理部100A内でブロック画像を処理する各構成要素(ブロック読み出し部110A、前フィルタ処理部140、ブロック拡大・縮小部120A、後フィルタ処理部150、ブロックカット処理部160、及びブロック書き出し部130A)を総称して「ブロック画像処理部」と呼ぶものとする。   The image forming apparatus 1A according to the second embodiment includes an image input unit 10, an enlargement / reduction processing unit 100A, an image output unit 50, and an image memory 60. The enlargement / reduction processing unit 100A includes, in order from the previous stage, a block reading unit 110A, a pre-filter processing unit 140, a block enlargement / reduction unit 120A, a post-filter processing unit 150, a block cut processing unit 160, and a block writing unit 130A. Is arranged. Hereinafter, each component (block reading unit 110A, pre-filter processing unit 140, block enlargement / reduction unit 120A, post-filter processing unit 150, block cut processing unit 160, which processes a block image in the enlargement / reduction processing unit 100A, The block writing unit 130A) is collectively referred to as a “block image processing unit”.

すなわち、第2の実施形態の画像形成装置1Aでは、拡大・縮小処理部100Aに、ブロック単位で前フィルタ処理及び後フィルタ処理を行う構成要素が挿入されている点で、第1の実施形態と異なっている。具体的には、第2の実施形態の画像形成装置1Aでは、拡大・縮小処理部100Aにおいて、ブロック読み出し部110Aとブロック拡大・縮小部120Aとの間に、ブロック画像単位で前フィルタ処理を行う前フィルタ処理部140が挿入されている。また、第2の実施形態の拡大・縮小処理部100Aでは、ブロック拡大・縮小部120Aとブロック書き出し部130Aとの間に、ブロック単位で後フィルタ処理を行う後フィルタ処理部150、及び、後フィルタ処理に利用した不要部分をカットするブロックカット処理部160が挿入されている。なお、ブロック読み出し部110Aは、入力された画像G101について直接ブロック画像の読み出しを行う点で、第1の実施形態と異なっている。したがって、第2の実施形態では、拡大・縮小処理部100Aにより画像処理装置が構成されている。   That is, the image forming apparatus 1A according to the second embodiment is different from the first embodiment in that the enlargement / reduction processing unit 100A includes components that perform pre-filter processing and post-filter processing in units of blocks. Is different. Specifically, in the image forming apparatus 1A according to the second embodiment, the enlargement / reduction processing unit 100A performs pre-filter processing in units of block images between the block reading unit 110A and the block enlargement / reduction unit 120A. A pre-filter processing unit 140 is inserted. In the enlargement / reduction processing unit 100A of the second embodiment, a post-filter processing unit 150 that performs post-filter processing in units of blocks between the block enlargement / reduction unit 120A and the block writing unit 130A, and a post-filter A block cut processing unit 160 for cutting unnecessary portions used for processing is inserted. The block reading unit 110A is different from the first embodiment in that the block image is directly read out from the input image G101. Therefore, in the second embodiment, an image processing apparatus is configured by the enlargement / reduction processing unit 100A.

これにより、第2の実施形態の画像入力部10Aでは、第1の実施形態と異なり、前フィルタ処理を行った画像G102及び、拡大・縮小処理後の画像G103を画像メモリ60に書き込まずに処理を完了することができるので、メモリアクセスの点で効率的な処理が可能となる。   Accordingly, unlike the first embodiment, the image input unit 10A of the second embodiment processes the image G102 that has been subjected to the pre-filter process and the image G103 that has been subjected to the enlargement / reduction process without being written to the image memory 60. Thus, efficient processing is possible in terms of memory access.

ブロック読み出し部110Aは、ブロック拡大・縮小部120Aで決定されたパラメータに従って、画像G101をブロック画像単位で読み出し、前フィルタ処理部140に供給する。   The block reading unit 110A reads the image G101 in units of block images according to the parameters determined by the block enlargement / reduction unit 120A and supplies the image G101 to the pre-filter processing unit 140.

そして、第2の実施形態における前フィルタ処理手段としての前フィルタ処理部140は、ブロック画像単位でフィルタ処理を行い、フィルタ処理したブロック画像を、ブロック拡大・縮小部120Aに供給する。前フィルタ処理部140が行う、具体的なフィルタ処理については、種々の画像データのフィルタ処理(ブロック画像単位のフィルタ処理)を適用することができるため、詳しい説明を省略する。   Then, the pre-filter processing unit 140 as the pre-filter processing means in the second embodiment performs the filter processing in units of block images and supplies the filtered block image to the block enlargement / reduction unit 120A. As the specific filter processing performed by the pre-filter processing unit 140, various image data filter processing (block image unit filter processing) can be applied, and thus detailed description thereof is omitted.

ブロック拡大・縮小部120Aは、前フィルタ処理部140から供給されたブロック画像について、拡大・縮小処理を行って、後フィルタ処理部150に供給する。そして、ブロック拡大・縮小部120Aは、X方向拡大・縮小部121A及びY方向拡大・縮小部122Aを有している。X方向拡大・縮小部121A(Y方向拡大・縮小部122A)では、前フィルタ処理部140の挿入に伴って、X方向スキップカウンタ121c(Y方向スキップカウンタ122c)が追加されている点で、第1の実施形態と異なっている。X方向スキップカウンタ121c及びY方向スキップカウンタ122cは、ブロック拡大・縮小部120Aに入力される各ブロック画像の左端と上端の無効画素(第1の無効領域)をスキップする(除外する;無視する)ためのカウンタであり、出力カウンタと同様、ブロック画像のライン先頭でリセットされる。   The block enlargement / reduction unit 120A performs enlargement / reduction processing on the block image supplied from the pre-filter processing unit 140, and supplies the result to the post-filter processing unit 150. The block enlargement / reduction unit 120A includes an X direction enlargement / reduction unit 121A and a Y direction enlargement / reduction unit 122A. In the X direction enlargement / reduction unit 121A (Y direction enlargement / reduction unit 122A), the X direction skip counter 121c (Y direction skip counter 122c) is added in accordance with the insertion of the pre-filter processing unit 140. This is different from the first embodiment. The X-direction skip counter 121c and the Y-direction skip counter 122c skip (exclude; ignore) the invalid pixels (first invalid areas) at the left end and the upper end of each block image input to the block enlargement / reduction unit 120A. This counter is reset at the head of the line of the block image in the same manner as the output counter.

そして、ブロック拡大・縮小部120Aは、入力されたブロック画像について、上述のスキップカウンタ(X方向スキップカウンタ121c、Y方向スキップカウンタ122c)によりスキップされた領域を除外した領域について、第1の実施形態と同様の拡大・縮小処理を実行して、拡大・縮小処理後のブロック画像を、後フィルタ処理部150に供給する。   Then, the block enlargement / reduction unit 120A performs the first embodiment with respect to an area excluding the area skipped by the above-described skip counter (the X-direction skip counter 121c and the Y-direction skip counter 122c) for the input block image. The same enlargement / reduction process is executed, and the block image after the enlargement / reduction process is supplied to the post-filter processing unit 150.

そして、第2の実施形態における後フィルタ処理手段としての後フィルタ処理部150は、後フィルタ処理部150から供給されたブロック画像について、後フィルタ処理を行い、後フィルタ処理したブロック画像を、ブロックカット処理部160に供給する。後フィルタ処理部150が行う、具体的なフィルタ処理については、種々の画像データのフィルタ処理(ブロック画像単位のフィルタ処理)を適用することができるため、詳しい説明を省略する。   Then, the post-filter processing unit 150 as the post-filter processing unit in the second embodiment performs post-filter processing on the block image supplied from the post-filter processing unit 150, and performs block filtering on the block image that has been post-filtered. This is supplied to the processing unit 160. As the specific filter processing performed by the post-filter processing unit 150, various image data filter processing (block image unit filter processing) can be applied, and thus detailed description thereof is omitted.

そして、ブロックカット手段としてのブロックカット処理部160は、後フィルタ処理部150から供給されたブロック画像について、後フィルタ処理で発生するブロック画像外周の無効画素(第2の無効領域)をカット(除外)する処理を行い、ブロック書き出し部130Aに供給する。   Then, the block cut processing unit 160 serving as a block cut unit cuts (excludes) the invalid pixels (second invalid region) around the block image generated by the post filter processing from the block image supplied from the post filter processing unit 150. ) And supply it to the block writing unit 130A.

そして、ブロック書き出し部130Aは、ブロックカット処理されたブロック画像について、画像メモリ60(画像G104の領域)に順次書き込み、画像G104のデータを作成する。ブロック書き出し部130Aが、個々のブロック画像について行う書き出し処理自体は、第1の実施形態と同様の処理であるため、詳しい説明は省略する。   Then, the block writing unit 130A sequentially writes the block images subjected to the block cut processing to the image memory 60 (the region of the image G104) to create data of the image G104. Since the writing process itself performed by the block writing unit 130A for each block image is the same process as in the first embodiment, detailed description thereof is omitted.

(B−2)第2の実施形態の動作
次に、以上のような構成を有する第2の実施形態の画像形成装置1Aの動作(実施形態の画像処理方法)を説明する。
(B-2) Operation of Second Embodiment Next, an operation (image processing method of the embodiment) of the image forming apparatus 1A of the second embodiment having the above-described configuration will be described.

(B−2−1)画像形成装置1A全体の動作の概要
図10は、画像形成装置1Aの全体の動作について示したフローチャートである。
(B-2-1) Outline of Overall Operation of Image Forming Apparatus 1A FIG. 10 is a flowchart showing the overall operation of the image forming apparatus 1A.

まず、画像形成装置1Aでは、画像入力部10に画像G101のデータが入力されて、画像メモリ60に、画像G101として書き込まれたものとする。そして、拡大・縮小処理部100Aに設定倍率がセットされたものとする(S401)。   First, in the image forming apparatus 1A, it is assumed that the data of the image G101 is input to the image input unit 10 and is written in the image memory 60 as the image G101. Then, it is assumed that the set magnification is set in the enlargement / reduction processing unit 100A (S401).

ここでは、画像G101は、幅7680画素、高さ5120画素の画像であるものとする。またここでは、拡大・縮小処理部100に設定倍率として133%設定された場合と、41%が設定された場合とで、場合分けして説明する。   Here, it is assumed that the image G101 is an image having a width of 7680 pixels and a height of 5120 pixels. Further, here, the case where 133% is set as the set magnification in the enlargement / reduction processing unit 100 and the case where 41% is set will be described separately.

そして、拡大・縮小処理部100A(ブロック拡大・縮小部120A)により、拡大・縮小処理を行う画像G101のサイズと、設定倍率に基づいて、拡大・縮小に係る各パラメータ算出等の準備が行われる(S402)。   Then, the enlargement / reduction processing unit 100A (block enlargement / reduction unit 120A) prepares for calculation of each parameter related to enlargement / reduction based on the size of the image G101 to be enlarged / reduced and the set magnification. (S402).

そして、拡大・縮小処理部100Aにより、ブロック単位で、読み出し処理、前フィルタ処理、拡大・縮小処理、後フィルタ処理、ブロックカット処理、及び書き出し処理が行われ、画像メモリ60に処理後の画像G104が書き込まれる(S403)。   Then, the enlargement / reduction processing unit 100A performs a read process, a pre-filter process, an enlargement / reduction process, a post-filter process, a block cut process, and a write process for each block, and the processed image G104 is stored in the image memory 60. Is written (S403).

そして、画像出力部50により、処理後の画像G104が出力されることになる(S404)。   Then, the image output unit 50 outputs the processed image G104 (S404).

(B−2−2)拡大・縮小に係る各パラメータ算出(ステップS402)
次に、上述のステップS402において、ブロック拡大・縮小部120Aで行われるパラメータ算出処理の詳細について説明する。
(B-2-2) Parameter calculation related to enlargement / reduction (step S402)
Next, details of the parameter calculation process performed in the block enlargement / reduction unit 120A in step S402 described above will be described.

ここでは、前フィルタ処理部140、ブロック拡大・縮小部120A、後フィルタ処理部150は、それぞれ、288、264、262画素分の画素を保持するラインメモリを備え、前記の画素数が各処理部における出力可能なブロック画像幅の上限があるものとする。また、ここでは、前フィルタ処理部140では注目画素を中心に25×25の画素参照を行うフィルタ処理が行われ、後フィルタ処理部150では注目画素を中心に7×7の画素参照を行うフィルタ処理が行われるものとする。   Here, the pre-filter processing unit 140, the block enlargement / reduction unit 120A, and the post-filter processing unit 150 each include a line memory that holds pixels of 288, 264, and 262 pixels, and the number of pixels is the number of each processing unit. It is assumed that there is an upper limit of the block image width that can be output. Also, here, the pre-filter processing unit 140 performs a filter process for referring to a 25 × 25 pixel around the target pixel, and the post-filter processing unit 150 performs a filter for referring to a 7 × 7 pixel around the target pixel. It is assumed that processing is performed.

ブロック拡大・縮小部120Aによるパラメータ算出処理も、上述の図4のフローチャートにより説明することができる。   The parameter calculation processing by the block enlargement / reduction unit 120A can also be described with reference to the flowchart of FIG.

まず、ステップS201において、ブロック拡大・縮小部120Aは、画像G101と設定倍率に基づいて、拡大・縮小処理後に出力する画像G104のサイズ(1ページの出力画像の幅と高さ)を、第1の実施形態と同様に上記の(1)、(2)式を用いて算出する。   First, in step S201, the block enlargement / reduction unit 120A sets the size of the image G104 to be output after the enlargement / reduction processing (the width and height of the output image of one page) based on the image G101 and the set magnification. The calculation is performed using the above equations (1) and (2) as in the embodiment.

ここでの例では、上述の通り、入力する画像G101のサイズは、幅7680、高さ5120であり、設定倍率は133%である。したがって、出力する画像G104の幅XOが10214、高さがYOが6809となる。さらに、設定倍率を41%とした場合、出力する画像G104の幅XOが3148、高さYOが2099となる。   In this example, as described above, the size of the input image G101 is the width 7680, the height 5120, and the set magnification is 133%. Accordingly, the output image G104 has a width XO of 10214 and a height of YO of 6809. Furthermore, when the set magnification is 41%, the output image G104 has a width XO of 3148 and a height YO of 2099.

次に、ステップS202で、ブロック拡大・縮小部120は、拡大・縮小処理部100A内の各ブロック画像処理部で入出力されるブロック画像のそれぞれについてサイズの算出を行う。   In step S202, the block enlargement / reduction unit 120 calculates the size of each block image input / output by each block image processing unit in the enlargement / reduction processing unit 100A.

入出力ブロック画像サイズは、拡大・縮小処理部100Aの各ブロック画像処理部における入出力ブロック画像の幅と高さであり、第2の実施形態では、ブロック読み出し部110Aで読み出すブロック画像サイズ、前フィルタフィルタ処理部20が出力するブロック画像サイズ、ブロック拡大・縮小部120Aが出力するブロック画像サイズ、後フィルタ処理部150が出力するブロック画像サイズ、及びブロックカット処理部160が出力するブロック画像サイズ(ブロック書き出し部130で書き出すブロック画像サイズ)が該当する。なお、拡大・縮小処理部100Aが算出するブロック画像サイズは、拡大・縮小の倍率と各ブロック画像処理部で出力可能ブロック画像サイズの上限と各ブロック画像処理部で発生するブロック画像外周の無効部分の画素幅と高さによって変動する。   The input / output block image size is the width and height of the input / output block image in each block image processing unit of the enlargement / reduction processing unit 100A. In the second embodiment, the block image size read by the block reading unit 110A The block image size output from the filter filter processing unit 20, the block image size output from the block enlargement / reduction unit 120A, the block image size output from the post-filter processing unit 150, and the block image size output from the block cut processing unit 160 ( This corresponds to the block image size written by the block writing unit 130). The block image size calculated by the enlargement / reduction processing unit 100A includes the enlargement / reduction magnification, the upper limit of the block image size that can be output by each block image processing unit, and the invalid portion of the block image outer periphery generated by each block image processing unit. Fluctuates depending on the pixel width and height.

図11は、第2の実施形態の例において、拡大・縮小処理部100Aの各ブロック画像処理部で出力可能なブロック画像サイズの上限と、ブロック画像外周で発生する無効部分の画素幅と高さを示した説明図である。   FIG. 11 illustrates the upper limit of the block image size that can be output by each block image processing unit of the enlargement / reduction processing unit 100A and the pixel width and height of the invalid portion generated on the outer periphery of the block image in the example of the second embodiment. It is explanatory drawing which showed.

ブロック画像幅の上限については、上述した通り、前フィルタ処理部140、ブロック拡大・縮小部120A、及び後フィルタ処理部150に設定されるものであり、それぞれ、288、264、262である。ブロック画像高さの上限については、第1の実施形態と同様の制約を仮定し、ブロック書き出し部130の書き出しにおいて256の高さ制限があるものとする。   As described above, the upper limit of the block image width is set in the pre-filter processing unit 140, the block enlargement / reduction unit 120A, and the post-filter processing unit 150, and is 288, 264, and 262, respectively. As for the upper limit of the block image height, the same restrictions as in the first embodiment are assumed, and it is assumed that there is a limit of 256 heights in the writing of the block writing unit 130.

また、ブロック画像外周に発生する無効画素は、前フィルタ処理部140、後フィルタ処理部20、及びブロック拡大・縮小部120Aで発生する。具体的には、ここでの例では、前フィルタ処理部140では左端と右端と上端と下端に12画素発生し、後フィルタ処理部150では左端と右端と上端と下端に3画素発生し、ブロック拡大・縮小部120Aでは右端と下端に1画素(補間拡大・縮小法を用いた場合)発生するものとする。   In addition, invalid pixels generated in the outer periphery of the block image are generated in the pre-filter processing unit 140, the post-filter processing unit 20, and the block enlargement / reduction unit 120A. Specifically, in this example, the front filter processing unit 140 generates 12 pixels at the left end, the right end, the upper end, and the lower end, and the rear filter processing unit 150 generates 3 pixels at the left end, the right end, the upper end, and the lower end. The enlargement / reduction unit 120A generates one pixel at the right end and the lower end (when the interpolation enlargement / reduction method is used).

このように、上述のステップS202において、ブロック拡大・縮小部120Aでは、拡大・縮小処理部100A内の各ブロック画像処理部で入出力されるブロック画像サイズ上限と、ブロック画像外周で発生する無効画素数と、設定倍率とを用いて、各ブロック画像処理部における出力ブロック画像サイズが算出される。   As described above, in step S202 described above, the block enlargement / reduction unit 120A has a block image size upper limit input / output in each block image processing unit in the enlargement / reduction processing unit 100A and invalid pixels generated at the outer periphery of the block image. The output block image size in each block image processing unit is calculated using the number and the set magnification.

図12は、ブロック拡大・縮小部120Aが、上述のステップS202で各パラメータを算出する動作について示したフローチャートである。   FIG. 12 is a flowchart showing an operation in which the block enlargement / reduction unit 120A calculates each parameter in step S202 described above.

図12における変数pは、ブロック拡大・縮小部120Aが拡大・縮小処理部100A内の構成要素(各処理段)に係る処理番号を管理するために用いられる変数である。pは、図11における処理番号に該当する。したがって、図11に示すように、ブロック読み出し部110Aでは、1段目(最前段)の処理段(p=0)がブロック読み出し部110A、2段目の処理段(p=1)が前フィルタ処理部140、3段目の処理段(p=2)がブロック拡大・縮小部120A、4段目の処理段(p=3)が後フィルタ処理部150、5段目の処理段(p=4)がブロックカット処理部160、6段目(最後段)の処理段(p=5)がブロック書き出し部130Aとなっている。   A variable p in FIG. 12 is a variable used by the block enlargement / reduction unit 120A to manage the process numbers related to the components (each processing stage) in the enlargement / reduction processing unit 100A. p corresponds to the processing number in FIG. Therefore, as shown in FIG. 11, in the block reading unit 110A, the first (frontmost) processing stage (p = 0) is the block reading unit 110A, and the second processing stage (p = 1) is the pre-filter. The processing unit 140, the third processing stage (p = 2) is the block enlargement / reduction unit 120A, the fourth processing stage (p = 3) is the post-filter processing unit 150, and the fifth processing stage (p = 4) is the block cut processing unit 160, and the sixth (last) processing stage (p = 5) is the block writing unit 130A.

まず、ブロック拡大・縮小部120Aは、最後段の処理の出力ブロック画像サイズを仮決めする(S501)。この場合、ブロック拡大・縮小部120Aが仮決めに使用する値は、例えば、上述のステップS201で求めた出力画像サイズを用いるものとする。   First, the block enlargement / reduction unit 120A provisionally determines the output block image size of the last stage processing (S501). In this case, the value used for provisional determination by the block enlargement / reduction unit 120A is, for example, the output image size obtained in step S201 described above.

次に、ブロック拡大・縮小部120Aは、pに最後段の処理番号として「5」を設定する(S502)。   Next, the block enlargement / reduction unit 120A sets “5” as the process number of the last stage in p (S502).

次に、ブロック拡大・縮小部120Aは、処理番号pの処理の出力ブロック画像サイズを算出する(S503)。ここで各ブロック画像処理部における出力ブロック画像サイズの算出を行うことになるが、ブロック拡大・縮小部120Aの出力ブロック画像サイズは前段の処理の出力ブロック画像サイズから算出することができないため、各ブロック画像処理部における出力ブロック画像サイズの算出はその後段の処理における出力ブロック画像サイズより順に算出する必要がある。第2の実施形態における各処理番号ごと(ブロック画像処理部ごと)の出力ブロック画像サイズの算出は、以下の(16)〜(27)式によりもとめることができる。   Next, the block enlargement / reduction unit 120A calculates the output block image size of the process with the process number p (S503). Here, the output block image size in each block image processing unit is calculated. However, since the output block image size of the block enlargement / reduction unit 120A cannot be calculated from the output block image size of the previous processing, The calculation of the output block image size in the block image processing unit needs to be calculated in order from the output block image size in the subsequent processing. The calculation of the output block image size for each processing number (each block image processing unit) in the second embodiment can be obtained by the following equations (16) to (27).

[ブロック書き出し部130A、p=5]
outbw[p]=任意の値 …(16)
outbh[p]=任意の値 …(17)
[ブロックカット処理部160、p=4]
outbw[p]=outbw[p+1] …(18)
outbh[p]=outbh[p+1] …(19)
[後フィルタ処理部150、p=3]
outbw[p]=
outbw[p+1]+nulwL[p]+nulwR[p] …(20)
outbh[p]=
outbh[p+1]+nulhU[p]+nulhD[p] …(21)
[ブロック拡大・縮小部120A、p=2]
outbw[p]=outbw[p+1] …(22)
outbh[p]=outbh[p+1] …(23)
[前フィルタ処理部140、p=1]
outbw[p]=
(outbw[p+1]×xbase+xratio−1)/xratio
+nulwL[p]+nulwR[p]+nulwL[p+1]
+nulwR[p+1] …(24)
outbh[p]=
(outbh[p+1]×ybase+yratio−1)/yratio
+nulhU[p]+nulhD[p]+nulhU[p+1]
+nulhD[p+1] …(25)
[ブロック読み出し部110A、p=0]
outbw[p]=outbw[p+1] …(26)
outbh[p]=outbh[p+1] …(27)
上式のように各ブロック画像処理部における出力ブロック画像の幅(outbw[p])と出力画像の高さ(outbw[p])が算出される。なお、最後段の処理であるブロック書き出し部130の出力ブロック画像サイズは、直近にステップS501、又はS506で決定された値とする。
[Block writing unit 130A, p = 5]
outbw [p] = arbitrary value (16)
outbh [p] = arbitrary value (17)
[Block cut processing unit 160, p = 4]
outbw [p] = outbw [p + 1] (18)
outbh [p] = outbh [p + 1] (19)
[Post-filter processing unit 150, p = 3]
outbw [p] =
outbw [p + 1] + nullL [p] + nullR [p] (20)
outbh [p] =
outbh [p + 1] + nullh [p] + nullhD [p] (21)
[Block enlargement / reduction unit 120A, p = 2]
outbw [p] = outbw [p + 1] (22)
outbh [p] = outbh [p + 1] (23)
[Pre-filter processing unit 140, p = 1]
outbw [p] =
(Outbw [p + 1] × xbase + xratio−1) / xratio
+ NulwL [p] + nulwR [p] + nulwL [p + 1]
+ NulwR [p + 1] (24)
outbh [p] =
(Outbh [p + 1] × ybase + yratio−1) / yratio
+ NullU [p] + nullh [p] + nullh [p + 1]
+ NullhD [p + 1] (25)
[Block reading unit 110A, p = 0]
outbw [p] = outbw [p + 1] (26)
outbh [p] = outbh [p + 1] (27)
As shown in the above equation, the width (outbw [p]) of the output block image and the height (outbw [p]) of the output image in each block image processing unit are calculated. Note that the output block image size of the block writing unit 130, which is the last stage process, is the value most recently determined in step S501 or S506.

そして、ブロック拡大・縮小部120Aは、各処理番号pに係る出力ブロック画像サイズが、各ブロック画像処理部において出力可能なブロック画像サイズの上限を超えていないかを判定し(S504)、上限を超えていると判定した場合には後述するステップS505から動作し、そうでない場合には、後述するステップS506から動作する。   Then, the block enlargement / reduction unit 120A determines whether or not the output block image size associated with each processing number p exceeds the upper limit of the block image size that can be output in each block image processing unit (S504). If it is determined that the number has exceeded, the operation starts from step S505, which will be described later. Otherwise, the operation starts from step S506, which will be described later.

そして、処理番号pに係る出力ブロック画像サイズが、上述の上限を超えている場合、ブロック拡大・縮小部120Aは、最後段の出力ブロック画像サイズの変更(例えば、幅及び高さで1画素ずつ小さいサイズへの変更)を行ってから(S506)、上述のステップS502に戻って動作する。   When the output block image size related to the process number p exceeds the above upper limit, the block enlargement / reduction unit 120A changes the output block image size in the last stage (for example, one pixel at a time in width and height). After changing to a smaller size (S506), the operation returns to step S502 described above.

そして、ブロック拡大・縮小部120Aは、処理番号pに係る出力ブロック画像サイズが、上述の上限を超えていない場合、全ての処理番号について、出力ブロック画像サイズの算出が終了したか否かを判定(pが0かを判定)する(S505)。   Then, the block enlargement / reduction unit 120A determines whether or not the calculation of the output block image size is completed for all the process numbers when the output block image size related to the process number p does not exceed the above-described upper limit. (It is determined whether p is 0) (S505).

ブロック拡大・縮小部120Aは、全ての処理番号について出力ブロック画像サイズの算出が終了した場合には処理を終了し、そうでない場合には、pをデクリメント(1減算)して(S507)、上述のステップS503から動作する。   The block enlargement / reduction unit 120A ends the process when the calculation of the output block image size is completed for all the process numbers, and decrements (subtracts 1) from p otherwise (S507). The operation starts from step S503.

以上のように、ブロック拡大・縮小部120Aは、拡大・縮小処理部100A内の各ブロック画像処理部の出力ブロック画像のサイズを、最後段の処理部から順に算出し、全ての処理部について制限内になるまで上述の図12のフローチャートのループ処理を繰り返す。   As described above, the block enlargement / reduction unit 120A calculates the size of the output block image of each block image processing unit in the enlargement / reduction processing unit 100A in order from the last processing unit, and restricts all the processing units. The loop process of the flowchart of FIG.

上述の図11の制限に基づいて、ブロック拡大・縮小部120Aが、上述の図12のフローチャートの処理を行い、各ブロック画像処理部の出力ブロック画像のサイズを算出した結果は、例えば、図13のような内容となる。   Based on the restriction of FIG. 11, the block enlargement / reduction unit 120A performs the process of the flowchart of FIG. 12 and calculates the size of the output block image of each block image processing unit. It becomes the contents like.

そして、ステップS203において、ブロック拡大・縮小部120Aは、上述のステップS202で算出した入力ブロック画像のサイズに基づいて、第1の実施形態と同様の処理により、画像G101に対するブロック画像の分割数を算出する。   In step S203, the block enlargement / reduction unit 120A determines the number of divisions of the block image with respect to the image G101 based on the size of the input block image calculated in step S202 described above, by the same processing as in the first embodiment. calculate.

ここでの例では、上述の通り、入力する画像G101のサイズは、幅7680、高さ5120である。したがって、設定倍率が133%の場合、入力ブロック画像の幅及び高さは194であるため、X方向の分割数は40、Y方向の分割数は27となる。また、設定倍率を41%とした場合、入力ブロック画像の幅及び高さは626であるため、X方向の分割数は13、Y方向の分割数は9となる。   In this example, as described above, the size of the input image G101 is the width 7680 and the height 5120. Therefore, when the set magnification is 133%, the width and height of the input block image are 194, so the number of divisions in the X direction is 40 and the number of divisions in the Y direction is 27. When the set magnification is 41%, the width and height of the input block image are 626, so the number of divisions in the X direction is 13, and the number of divisions in the Y direction is 9.

そして、ステップS204において、ブロック拡大・縮小部120Aは、ブロック画像ごとに、X方向拡大・縮小カウンタ121a、及びY方向拡大・縮小カウンタ122aの初期値と、ブロック読み出し部110が読み出す各ブロック画像のX方向とY方向の読み出し位置を算出する。ブロック拡大・縮小部120AによるステップS204の処理は、第1の実施形態とほぼ同様であるが、前フィルタ処理部140と後フィルタ処理部150が、拡大・縮小処理部100Aに挿入されたことを考慮して、各値を求める必要がある。   In step S204, the block enlargement / reduction unit 120A sets the initial values of the X direction enlargement / reduction counter 121a and the Y direction enlargement / reduction counter 122a and the block image read by the block reading unit 110 for each block image. The reading positions in the X direction and the Y direction are calculated. The processing in step S204 by the block enlargement / reduction unit 120A is substantially the same as that in the first embodiment, except that the pre-filter processing unit 140 and the post-filter processing unit 150 are inserted into the enlargement / reduction processing unit 100A. It is necessary to obtain each value in consideration.

第2の実施形態において、Y方向拡大・縮小カウンタ122aの初期値、Y方向拡大・縮小カウンタ122aの初期値、X方向の読み出し位置、及びY方向の読み出し位置はそれぞれ以下の(28)〜(31)式で算出することができる。 In the second embodiment, the initial value of the Y direction enlargement / reduction counter 122a, the initial value of the Y direction enlargement / reduction counter 122a, the readout position in the X direction, and the readout position in the Y direction are respectively (28) to (28) 31).

以下の(28)〜(31)式において、bnulwとbnulhは、ブロック拡大・縮小部120Aの処理でブロック画像左端と上端に発生する無効画素数を表している。また、anulwとanulhはブロック拡大・縮小部120Aの後段の処理でブロック画像左端と上端に発生する無効画素数を表している。   In the following equations (28) to (31), bnulw and bnullh represent the number of invalid pixels generated at the left end and the upper end of the block image in the process of the block enlargement / reduction unit 120A. Anulw and anulh represent the number of invalid pixels generated at the left end and the upper end of the block image in the subsequent processing of the block enlargement / reduction unit 120A.

[X方向の拡大・縮小カウンタの算出式]
xcnt0[0]=(xratio−(anulw×xbase)%xratio)%xratio …(28)
[Y方向の拡大・縮小カウンタの算出式]
ycnt0[0]=(yratio−(anulh×ybase)%yratio)%yratio …(29)
[X方向の読み出し位置]
xpos0[0]= −(anulw×xbase+xratio−1)
/xratio−bnulw …(30)
[Y方向の読み出し位置]
ypos0[0]=−(anulh×ybase+yratio−1)
/yratio−bnulh …(31)
以上説明したS201〜S204で算出したパラメータを使用して、拡大・縮小処理部100Aを動作させることで、1ページの画像データを複数のブロックに分割して任意倍率の拡大・縮小と前後のフィルタ処理を行うことができる。
[Calculation formula for enlargement / reduction counter in X direction]
xcnt0 [0] = (xratio− (anulw × xbase)% xratio)% xratio (28)
[Calculation formula for enlargement / reduction counter in Y direction]
ycnt0 [0] = (yratio− (anulh × ybase)% yratio)% yratio (29)
[Reading position in X direction]
xpos0 [0] = − (anulw × xbase + xratio−1)
/ Xratio-bulw (30)
[Reading position in Y direction]
ypos0 [0] = − (anulh × ybase + yratio−1)
/ Yratio-bnull (31)
By operating the enlargement / reduction processing unit 100A using the parameters calculated in S201 to S204 described above, image data of one page is divided into a plurality of blocks, and enlargement / reduction at an arbitrary magnification and front and rear filters are performed. Processing can be performed.

(B−2−3)ブロック読み出し部110Aによる入力ブロック画像の読み出し処理
次に、上述のステップS403において、ブロック読み出し部110Aで行われる入力ブロックの読み出し処理の詳細について、図14を用いて説明する。
(B-2-3) Input Block Image Reading Process by Block Reading Unit 110A Next, details of the input block reading process performed by the block reading unit 110A in the above-described step S403 will be described with reference to FIG. .

図14は、ブロック読み出し部110Aが、上述のステップS403で決定したパラメータに従って、拡大・縮小処理部100Aに入力される画像G101を、入力ブロック単位で読み出す場合の処理について示した説明図である。なお、図14では、入力する画像G101のサイズは、幅7680、高さ5120、設定倍率が133%の場合について示している。   FIG. 14 is an explanatory diagram showing processing when the block reading unit 110A reads the image G101 input to the enlargement / reduction processing unit 100A in units of input blocks according to the parameters determined in step S403 described above. In FIG. 14, the size of the input image G101 is shown for a case where the width is 7680, the height is 5120, and the set magnification is 133%.

図14に示すように、ブロック読み出し部110Aで読み出されるブロック画像は、隣接ブロックと重複部分を持つように読み出される。図14では、読み出す1ページの画像データの最も左の画素のX方向の位置を0、最も上の画素のY方向の位置を0としている。そして、ブロック読み出し部110Aが、分割するブロック画像のX方向とY方向の読み出し開始位置は、X方向の読み出し開始位置についてはX方向のブロック番号0、1、2、3、4、・・・に対応して、−15、178、370、563、755、・・・となり、Y方向の読み出し開始位置についてはY方向のブロック番号0、1、・・・に対応して、−15、178となる。例えば、X方向のブロック番号が2、Y方向のブロック番号が1であれば、X方向とY方向の読み出し位置は(370、178)になる。また、図14では、ブロック読み出し部110Aにより読み出される各ブロック画像のサイズは、全てのブロック画像で共通である(例では、幅222×高さ222)。なお、図14に示すように、ブロック読み出し部110Aは、ページの外周近辺で読み出されるブロック画像については、ページ外の領域より読み出す必要があり、上述のページ外の領域のデータは、白データ(白色の画素値)で置換したり、ページ外との境界に位置する画素を使って置換するようにしてもよい。   As illustrated in FIG. 14, the block image read by the block reading unit 110 </ b> A is read so as to have an overlapping portion with an adjacent block. In FIG. 14, the position in the X direction of the leftmost pixel of one page of image data to be read is 0, and the position in the Y direction of the uppermost pixel is 0. Then, the reading start position in the X direction and the Y direction of the block image to be divided by the block reading unit 110A is the block numbers 0, 1, 2, 3, 4,. -15, 178, 370, 563, 755,..., And the reading start position in the Y direction corresponds to block numbers 0, 1,. It becomes. For example, if the block number in the X direction is 2 and the block number in the Y direction is 1, the read positions in the X direction and the Y direction are (370, 178). In FIG. 14, the size of each block image read by the block reading unit 110A is common to all block images (in the example, width 222 × height 222). As shown in FIG. 14, the block reading unit 110A needs to read a block image read in the vicinity of the outer periphery of the page from an area outside the page, and the data in the area outside the page is white data ( (White pixel value) or may be replaced using a pixel located at the boundary with the outside of the page.

そして、ブロック読み出し部110Aは、各ブロック画像について、各ブロック画像のX方向とY方向のブロック番号にしたがって、X方向とY方向の読み出し位置を変更しながら読み出し、読み出したブロック画像を前フィルタ処理部140に供給する。   Then, the block readout unit 110A reads out each block image while changing the readout position in the X direction and the Y direction according to the block number in the X direction and the Y direction of each block image, and performs the pre-filter processing on the read block image To the unit 140.

(B−2−4)ブロック拡大・縮小部120Aによる拡大・縮小処理
次に、上述のステップS403においてブロック拡大・縮小部120Aで行われる処理の詳細について説明する。
(B-2-4) Enlargement / Reduction Process by Block Enlargement / Reduction Unit 120A Next, details of the process performed by the block enlargement / reduction unit 120A in step S403 will be described.

図15は、ブロック拡大・縮小部120Aで行われる各ブロック画像に対する処理の例について示した説明図である。なお、図15では、入力する画像G101のサイズは、幅7680、高さ5120、設定倍率が133%の場合について示している。   FIG. 15 is an explanatory diagram showing an example of processing for each block image performed by the block enlargement / reduction unit 120A. In FIG. 15, the size of the input image G101 is shown for the case where the width is 7680, the height is 5120, and the set magnification is 133%.

前フィルタ処理部140に入力されたブロック画像(図15(a)参照、ブロック画像のサイズは幅222×高さ222)は、前フィルタ処理部140で、注目画素を中心に25×25の画素参照を行うフィルタ処理が行われ、フィルタ処理された画像がブロック拡大・縮小部120Aに供給される。   The block image (see FIG. 15A, the block image size is width 222 × height 222) input to the pre-filter processing unit 140 is 25 × 25 pixels centered on the target pixel in the pre-filter processing unit 140. The filtering process for performing the reference is performed, and the filtered image is supplied to the block enlargement / reduction unit 120A.

前フィルタ処理部140によるフィルタ処理により前フィルタ処理部140の処理後のブロック画像は、図15(b)に示すように左端、右端、上端、下端に無効な画素が各12画素発生する。   The block image processed by the pre-filter processing unit 140 by the filter process by the pre-filter processing unit 140 generates 12 invalid pixels at the left end, right end, upper end, and lower end as shown in FIG. 15B.

そして、ブロック拡大・縮小部120Aに入力されたブロック画像は、拡大・縮小部で拡大処理が行われ、拡大されたブロック画像が、後フィルタ処理部150に供給される。   The block image input to the block enlargement / reduction unit 120A is subjected to enlargement processing by the enlargement / reduction unit, and the enlarged block image is supplied to the post-filter processing unit 150.

ブロック拡大・縮小部120Aに入力されたブロック画像(幅222×高さ222)は、まず、X方向拡大・縮小部121AによりX方向について拡大され(図15(c)参照、ブロック画像サイズは幅262×高さ222)、さらに、Y方向拡大・縮小部122Aにより、Y方向ついて拡大されて出力される(図15(d)参照、ブロック画像サイズは幅262×高さ262)。   The block image (width 222 × height 222) input to the block enlargement / reduction unit 120A is first enlarged in the X direction by the X direction enlargement / reduction unit 121A (see FIG. 15C, the block image size is the width). 262 × height 222), and further, the Y-direction enlargement / reduction unit 122A enlarges and outputs the Y-direction (see FIG. 15D, the block image size is width 262 × height 262).

X方向拡大・縮小部121Aによる前記のX方向の拡大では、X方向拡大・縮小カウンタ121aが各ブロックのライン先頭で、当該ブロック画像のX方向のブロック番号に対応する初期値に設定される。例えば、X方向のブロック番号が2であれば94に設定される。ブロック左端よりカウントが開始されるX方向スキップカウンタ121cが所定の値(例では12)になるまで入力画素を無視した後(前段の処理で発生したブロック左端の無効画素12画素は前記の動作により削除される)、X方向拡大・縮小カウンタ121aにしたがってライン毎拡大が行われ、X方向出力カウンタ121bが所定の値(例では262)になるまで拡大して出力する(図15(e)参照、前記の動作により前段の処理で発生したブロック右端の無効画素12画素および余分な画素が削除される)。   In the X-direction enlargement by the X-direction enlargement / reduction unit 121A, the X-direction enlargement / reduction counter 121a is set to the initial value corresponding to the X-direction block number of the block image at the head of each block line. For example, if the block number in the X direction is 2, it is set to 94. After the input pixels are ignored until the X-direction skip counter 121c, which starts counting from the left end of the block, reaches a predetermined value (12 in the example) (the 12 invalid pixels at the left end of the block generated in the previous stage processing are Are deleted), line-by-line enlargement is performed according to the X-direction enlargement / reduction counter 121a, and the X-direction output counter 121b is enlarged and output until it reaches a predetermined value (262 in the example) (see FIG. 15E). The 12 invalid pixels and extra pixels at the right end of the block generated in the previous stage processing are deleted by the above operation).

Y方向拡大・縮小部122AによるY方向の拡大では、Y方向拡大・縮小カウンタ122aが各ブロックの先頭ラインで、当該ブロック画像のY方向のブロック番号に対応する初期値に設定される。例えば、Y方向のブロック番号が1であれば30に設定される。ブロック上端よりカウントが開始されるY方向スキップカウンタ122cが所定の値(例では12)になるまで入力画素を無視した後(前段の処理で発生したブロック上端の無効画素12画素は前記の動作により削除される)、Y方向拡大・縮小カウンタ122aにしたがって拡大が行われ、Y方向出力カウンタ122bが所定の値(例では262)になるまで拡大して出力する(図15(f)参照、前記の動作により前段の処理で発生したブロック下端の無効画素12画素および余分な画素が削除される)。   In the Y-direction enlargement by the Y-direction enlargement / reduction unit 122A, the Y-direction enlargement / reduction counter 122a is set to the initial value corresponding to the block number in the Y direction of the block image at the head line of each block. For example, if the block number in the Y direction is 1, it is set to 30. After the input pixels are ignored until the Y-direction skip counter 122c, which starts counting from the upper end of the block, reaches a predetermined value (12 in the example) (the 12 invalid pixels at the upper end of the block generated in the previous processing are Is deleted), the enlargement is performed according to the Y-direction enlargement / reduction counter 122a, and the Y-direction output counter 122b is enlarged and output until it reaches a predetermined value (262 in the example) (see FIG. 15 (f), The 12 invalid pixels at the bottom of the block and the extra pixels generated in the previous process are deleted by the above operation).

以上説明したように、ブロック拡大・縮小部120Aは入力されるブロック画像を拡大するとともに、前段の前フィルタ処理部140のフィルタ処理により生じたブロック画像端部の無効画素を削除し、各ブロック画像のサイズを同じ大きさにして出力する。出力されたブロック画像は後フィルタ処理部150に供給される。   As described above, the block enlargement / reduction unit 120A enlarges the input block image, deletes the invalid pixels at the end of the block image generated by the filter processing of the previous-stage filter processing unit 140, and each block image Output with the same size. The output block image is supplied to the post-filter processing unit 150.

(B−2−5)後フィルタ処理部150及びブロックカット処理部160の処理
次に、上述のステップS403において、後フィルタ処理部150及びブロックカット処理部160で行われる処理の詳細について説明する。
(B-2-5) Processing of Post Filter Processing Unit 150 and Block Cut Processing Unit 160 Details of processing performed by the post filter processing unit 150 and the block cut processing unit 160 in step S403 described above will be described below.

図16は、後フィルタ処理部150及びブロックカット処理部160で行われる各ブロック画像に対する処理の例について示した説明図である。   FIG. 16 is an explanatory diagram showing an example of processing for each block image performed by the post-filter processing unit 150 and the block cut processing unit 160.

後フィルタ処理部150に入力されたブロック画像(図16(a)参照、ブロック画像のサイズは幅262×高さ262)は、後フィルタ処理部150で注目画素を中心に7×7の画素参照を行うフィルタ処理を行われる。そして、後フィルタ処理部150で、後フィルタ処理された画像が、ブロックカット処理部160に供給される。後フィルタ処理部150による後フィルタ処理により、処理後のブロック画像には、図16(b)に示すように、左端、右端、上端、及び下端に無効な画素が各3画素発生する。   The block image (refer to FIG. 16A, the block image size is width 262 × height 262) input to the post-filter processing unit 150 is a 7 × 7 pixel reference centered on the target pixel in the post-filter processing unit 150. A filtering process is performed. Then, the image that has been post-filtered by the post-filter processing unit 150 is supplied to the block cut processing unit 160. As a result of post-filter processing by the post-filter processing unit 150, three invalid pixels are generated at the left end, right end, upper end, and lower end of the processed block image, as shown in FIG. 16B.

ブロックカット処理部160に入力されたブロック画像(ブロック画像のサイズは幅262×高さ262)は、ブロックカット処理部160で前段の処理で発生したブロック画像端部の無効画素(例では左端、右端、上端、下端に各3画素)が削除(カット)され、無効画素がカットされたブロック画像(図16(c)参照;サイズは幅256×高さ256)がブロック書き出し部130Aに供給される。   The block image (the size of the block image is width 262 × height 262) input to the block cut processing unit 160 is an invalid pixel (in the example, the left end in the example) at the end of the block image generated by the previous process in the block cut processing unit 160. A block image (see FIG. 16C; the size is width 256 × height 256) from which invalid pixels are cut is supplied to the block writing unit 130A. The

(B−2−6)ブロック書き出し部130Aによる書き出し処理
ブロック書き出し部130Aは、第1の実施形態と同様の処理により、供給されたブロック画像をX方向とY方向に一定の間隔(X方向については256、Y方向については256)で画像メモリ60に書き込み、1ページ分の画像G104のデータを作成する。
(B-2-6) Write processing by block writing unit 130A The block writing unit 130A performs a process similar to that of the first embodiment to distribute the supplied block images at constant intervals in the X and Y directions (about the X direction). Is written to the image memory 60 in 256 for the Y direction, and data for the image G104 for one page is created.

(B−3)第2の実施形態の効果
第2の実施形態によれば、第1の実施形態の効果に加えて以下のような効果を奏することができる。
(B-3) Effects of Second Embodiment According to the second embodiment, the following effects can be obtained in addition to the effects of the first embodiment.

第2の実施形態では、前フィルタ処理及び後フィルタ処理についても、ブロック拡大・縮小部120Aで、ブロック画像単位に処理している。したがって、第1の実施形態の画像形成装置1では、図1に示すように画像データが入力されてから出力されるまで、画像メモリ60に対して4つ画像データ(G101〜G104)の処理(読み書き)が発生しているが、第2の実施形態の画像形成装置1Aでは、図9に示すように、2つの画像データ(G101、G104)の処理だけで処理が完了する。   In the second embodiment, the pre-filter process and the post-filter process are also processed in block image units by the block enlargement / reduction unit 120A. Therefore, in the image forming apparatus 1 of the first embodiment, as shown in FIG. 1, four image data (G101 to G104) are processed in the image memory 60 until the image data is input and output ( However, in the image forming apparatus 1A of the second embodiment, the processing is completed only by processing the two image data (G101, G104) as shown in FIG.

したがって、第2の実施形態の画像形成装置1Aでは、第1の実施形態よりも、画像メモリ60へのアクセス量を低減して処理を高速化することができる。また、第2の実施形態の画像形成装置1Aでは、画像メモリ60に確保必要な容量を低減することができる。   Therefore, in the image forming apparatus 1A according to the second embodiment, the access amount to the image memory 60 can be reduced and the processing speed can be increased as compared with the first embodiment. Further, in the image forming apparatus 1A according to the second embodiment, it is possible to reduce the capacity required for the image memory 60.

(C)第3の実施形態
以下、本発明による画像処理装置及び方法、並びに、画像形成装置の第3の実施形態を、図面を参照しながら詳述する。
(C) Third Embodiment Hereinafter, an image processing apparatus and method and an image forming apparatus according to a third embodiment of the present invention will be described in detail with reference to the drawings.

(C−1)第3の実施形態の構成
図17は、本発明の第3の実施形態における画像形成装置の構成を示す概略図であり、上述の図9と同一又は対応する部分に同一又は対応する符号を付している。
(C-1) Configuration of Third Embodiment FIG. 17 is a schematic diagram showing a configuration of an image forming apparatus according to the third embodiment of the present invention, and the same or corresponding parts as those in FIG. Corresponding symbols are attached.

以下、第3の実施形態について第2の実施形態と異なる点について説明する。   Hereinafter, differences of the third embodiment from the second embodiment will be described.

第3の実施形態では、拡大・縮小処理部100Aが拡大・縮小処理部100Bに置き換わっている点で第2の実施形態と異なっている。また、第3の実施形態の拡大・縮小処理部100Bでは、ブロック拡大・縮小部120Aがブロック拡大・縮小部120Bに置き換わり、さらに、前解像度変換部170、後解像度変換部180、及び量子化処理部190が追加されている点で第2の実施形態と異なっている。また、第3の実施形態のブロック拡大・縮小部120Bでは、X方向拡大・縮小部121A及びY方向拡大・縮小部122Aが、X方向拡大・縮小部121B及びY方向拡大・縮小部122Bに置き換わっている点で第2の実施形態と異なっている。   The third embodiment is different from the second embodiment in that the enlargement / reduction processing unit 100A is replaced with an enlargement / reduction processing unit 100B. In the enlargement / reduction processing unit 100B of the third embodiment, the block enlargement / reduction unit 120A is replaced with the block enlargement / reduction unit 120B, and further, the front resolution conversion unit 170, the rear resolution conversion unit 180, and the quantization process This is different from the second embodiment in that a part 190 is added. In the block enlargement / reduction unit 120B of the third embodiment, the X direction enlargement / reduction unit 121A and the Y direction enlargement / reduction unit 122A are replaced with the X direction enlargement / reduction unit 121B and the Y direction enlargement / reduction unit 122B. This is different from the second embodiment.

拡大・縮小処理部100Bでは、ブロック読み出し部110Aと前フィルタ処理部140との間(ブロック拡大・縮小部120Bより前段の位置)に、前解像度変換部170が挿入されている。また、拡大・縮小処理部100Bでは、後フィルタ処理部150とブロックカット処理部160との間(ブロック拡大・縮小部120Bより後段の位置)に、後解像度変換部180が挿入されている。さらに、拡大・縮小処理部100Bでは、ブロックカット処理部160とブロック書き出し部130Aとの間(ブロック拡大・縮小部120Bより後段の位置)に、量子化処理部190が挿入されている。   In the enlargement / reduction processing unit 100B, a previous resolution conversion unit 170 is inserted between the block reading unit 110A and the previous filter processing unit 140 (position before the block enlargement / reduction unit 120B). Further, in the enlargement / reduction processing unit 100B, a post-resolution conversion unit 180 is inserted between the post-filter processing unit 150 and the block cut processing unit 160 (position after the block enlargement / reduction unit 120B). Further, in the enlargement / reduction processing unit 100B, a quantization processing unit 190 is inserted between the block cut processing unit 160 and the block writing unit 130A (position after the block enlargement / reduction unit 120B).

第1の実施形態や第2の実施形態の前フィルタ処理部140で特定の解像度の画像データに対して処理を行いたい場合には解像度変換処理(逓倍の解像度変換または逓倍分の1の解像度変換)を前フィルタ処理の前に行う必要がある(例えば、画像データの縦と横の解像度を同じにすることで原稿のスクリーン判定やモアレ発生を抑えるフィルタ処理について縦横で同じ処理にできるので処理設定や構成が簡易になる)。また、後フィルタ処理部150の処理後の画像データの解像度や画素当たりのビット数が画像出力部50の期待する解像度や画素当たりのビット数と異なる場合には後フィルタ処理の後に解像度変換(逓倍の解像度変換)や量子化処理を行う必要がある。前記の解像度変換や量子化処理についておのおの画像メモリから画像データの読み出しや書き出しを行った場合には、画像メモリに必要なサイズが大きくなるうえに、処理速度の低下を招く。そのため、第3の実施形態では、ブロック拡大・縮小部120B及び前フィルタ処理部140の前段に前フィルタ処理部140を挿入して、切り出されたブロック画像について出力したいサイズのブロック画像と比率だけを合せる解像度変換をおこなっている。そして、第3の実施形態では、ブロック拡大・縮小部120B及び後フィルタ処理部150の後段に、後解像度変換部180を挿入して、ブロック拡大・縮小部120Bから出力されたブロック画像について出力したいサイズの画像に変換する解像度変換をしている。   When the pre-filter processing unit 140 according to the first embodiment or the second embodiment wants to perform processing on image data having a specific resolution, resolution conversion processing (multiplication resolution conversion or one-multiplication resolution conversion) ) Must be performed before pre-filter processing (for example, by making the same vertical and horizontal resolution of image data, it is possible to make the same processing in the vertical and horizontal directions for the filter processing that suppresses screen determination and moire generation of the document. And the configuration is simplified). If the resolution of the image data after processing by the post-filter processing unit 150 and the number of bits per pixel are different from the resolution expected by the image output unit 50 and the number of bits per pixel, resolution conversion (multiplication) is performed after the post-filter processing. Resolution conversion) and quantization processing. When the resolution conversion and the quantization processing are performed, image data is read from or written to the image memory, and the required size of the image memory increases and the processing speed is reduced. Therefore, in the third embodiment, the pre-filter processing unit 140 is inserted before the block enlargement / reduction unit 120B and the pre-filter processing unit 140, and only the block image of the size to be output and the ratio of the cut-out block image are obtained. The resolution is converted. In the third embodiment, the post-resolution conversion unit 180 is inserted after the block enlargement / reduction unit 120B and the post-filter processing unit 150 to output the block image output from the block enlargement / reduction unit 120B. The resolution is converted to a size image.

前解像度変換部170は、ブロック読み出し部110Aより入力されるブロック画像データの解像度変換(逓倍の解像度変換または逓倍分の1の解像度変換)を行うものである。前解像度変換部170は、例えば、入力された横300DPI×縦600DPIの解像度のブロック画像データを横600DPI×縦600DPIの解像度の画像データに変換する。そして、解像度が変換されたブロック画像データは前フィルタ処理部140に供給される。   The pre-resolution conversion unit 170 performs resolution conversion (multiplication resolution conversion or 1 / multiplication resolution conversion) of block image data input from the block reading unit 110A. For example, the pre-resolution conversion unit 170 converts the input block image data having a resolution of 300 DPI × 600 DPI into image data having a resolution of 600 DPI × 600 DPI. Then, the block image data whose resolution is converted is supplied to the pre-filter processing unit 140.

ブロック拡大・縮小部120BのX方向拡大・縮小部121B及びY方向拡大・縮小部122Bは、前解像度変換部170の追加に伴い、X方向とY方向の画像ブロック毎にスキップ幅を微調整する値(以下、「微調整スキップ値」と呼ぶ)により微調整されたスキップ幅を、スキップカウンタ(X方向スキップカウンタ121c、Y方向スキップカウンタ122c)にセットする点で第2の実施形態と異なっている。   The X direction enlargement / reduction unit 121B and the Y direction enlargement / reduction unit 122B of the block enlargement / reduction unit 120B finely adjust the skip width for each image block in the X direction and the Y direction in accordance with the addition of the previous resolution conversion unit 170. Unlike the second embodiment, the skip width finely adjusted by the value (hereinafter referred to as “fine adjustment skip value”) is set in the skip counter (X direction skip counter 121c, Y direction skip counter 122c). Yes.

言い換えると、ブロック拡大・縮小部120B(X方向拡大・縮小部121B及びY方向拡大・縮小部122B)は、第2の実施形態と同様、入力されたブロック画像の左端と上端の画素について、スキップカウンタが所定の値の範囲の画素を無視して残りの画素のみを拡大・縮小カウンタにしたがって拡大・縮小し、出力カウンタが所定の値の範囲内の場合のみ出力を行うよう動作する。但し、ブロック拡大・縮小部120Bは、スキップカウンタの値により無視する所定の値の範囲は、全ての画像ブロックで共通の所定値に、X方向とY方向のブロック毎の微調整スキップ値を加算した値の範囲を無視(スキップ)する処理(以下、この微調整処理を「スキップ値微調整処理」とも呼ぶものとする)するものとする。言い換えると、ブロック拡大・縮小部120Bでは、ブロックごとにスキップカウンタに設定される値が可変となる(共通の所定値に対して微調整(補正)された値が設定される)。   In other words, the block enlargement / reduction unit 120B (the X direction enlargement / reduction unit 121B and the Y direction enlargement / reduction unit 122B) skips the pixels at the left end and the upper end of the input block image, as in the second embodiment. The counter ignores the pixels in the predetermined value range, enlarges / reduces only the remaining pixels according to the enlargement / reduction counter, and operates so as to output only when the output counter is within the predetermined value range. However, the block enlargement / reduction unit 120B adds a fine adjustment skip value for each block in the X direction and the Y direction to a predetermined value common to all image blocks in the range of the predetermined value that is ignored by the skip counter value. It is assumed that a process of ignoring (skip) the range of the value (hereinafter, this fine adjustment process is also referred to as “skip value fine adjustment process”). In other words, in the block enlargement / reduction unit 120B, the value set in the skip counter is variable for each block (a value finely adjusted (corrected) with respect to a common predetermined value is set).

図18は、X方向拡大・縮小部121Bの動作の例について示した説明図である。図18では前解像度変換がない場合と前解像度変換がある場合(X方向の解像度を2倍に変換)のそれぞれについて、ブロック拡大縮小部120Bに入力されるブロック画像のX方向の読み出し位置とX方向のスキップ範囲を記載する。   FIG. 18 is an explanatory diagram showing an example of the operation of the X direction enlargement / reduction unit 121B. In FIG. 18, the X-direction readout position of the block image input to the block enlargement / reduction unit 120B and the X Describe the skip range of the direction.

図18(a)〜図18(c)は、それぞれ異なる画像ブロック(X方向の読み出し位置が−14、178、371のブロック画像(X方向0、1、2番目のブロック画像))について、X方向拡大・縮小部121Bがスキップ値微調整処理をおこなわずに、X方向の読み出し位置を設定した場合(第2の実施形態と同様の処理を行った場合の処理)について示した説明図である。図18(d)〜図18(f)は、それぞれ図18(a)〜図18(c)と同様の画像ブロックについて、X方向拡大・縮小部121Bがスキップ値微調整処理を行った上で、X方向の読み出し位置を設定した場合について示した説明図である。   18 (a) to 18 (c) show X images for different image blocks (block images whose read positions in the X direction are -14, 178, and 371 (X direction 0, first, and second block images)). It is explanatory drawing shown about the case where the direction expansion / reduction part 121B sets the reading position of a X direction, without performing a skip value fine adjustment process (process when the process similar to 2nd Embodiment is performed). . 18D to 18F show the image blocks similar to those in FIGS. 18A to 18C after the X-direction enlargement / reduction unit 121B performs the skip value fine adjustment processing. FIG. 6 is an explanatory diagram showing a case where a reading position in the X direction is set.

図18(a)〜図18(c)に示すように、X方向の読み出し位置が−14、178、371のブロック画像(X方向0、1、2番目のブロック画像)をX方向拡大・縮小部121Bで左端の12画素を無視して拡大・縮小を行う場合には、前解像度変換がない場合については、X方向スキップカウンタ121cで無視する所定の値の範囲を12とすれば良い。   As shown in FIGS. 18A to 18C, X-direction enlargement / reduction of block images (X direction 0, 1st, and 2nd block images) whose read positions in the X direction are −14, 178, and 371 are performed. In the case where enlargement / reduction is performed by ignoring the leftmost 12 pixels in the unit 121B, the range of a predetermined value ignored by the X-direction skip counter 121c may be set to 12 when there is no previous resolution conversion.

しかし、前記と同様の処理を前解像度変換部170でX方向の解像度を2倍に変換して行う場合には、前解像度変換がない場合の読み出し位置を1/2した位置より読み出せば良いが、整数とならない位置(2番目のブロックの読み出し位置371を1/2すると185.5になる)からは読み出せないため、X方向の読み出し位置−7、89、185から読み出す。したがって、0番目と1番目のブロック画像については、前解像度変換がない場合と同様、スキップカウンタで無視する所定の値の範囲を12とすれば良いが、2番目のブロック画像は、ブロック拡大縮小部120Bで換算した読み出し位置が1ずれるため、スキップカウンタで無視する所定の値の範囲を13とする必要がある。前記の所定の値とのずれ分をX方向とY方向のブロック毎の微調整スキップ値に設定することで、前解像度変換部170による解像度変換に対応できる。   However, when the same processing as described above is performed with the previous resolution conversion unit 170 converting the resolution in the X direction to twice, it is only necessary to read from the position where the read position when there is no previous resolution conversion is halved. However, since reading is not possible from a position that does not become an integer (when the reading position 371 of the second block is halved to 185.5), reading is performed from reading positions −7, 89, and 185 in the X direction. Therefore, for the 0th and 1st block images, as in the case where there is no previous resolution conversion, the range of the predetermined value to be ignored by the skip counter may be set to 12, but the 2nd block image Since the reading position converted by the unit 120B is shifted by 1, it is necessary to set the range of the predetermined value ignored by the skip counter to 13. By setting the amount of deviation from the predetermined value as a fine adjustment skip value for each block in the X direction and the Y direction, it is possible to cope with resolution conversion by the previous resolution conversion unit 170.

後解像度変換部180は、後フィルタ処理部150より入力される画像データの解像度変換(逓倍の解像度変換)を行うものであり、例えば、入力された横600DPI×縦600DPIの解像度の画像データを横600DPI×縦1200DPIの解像度の画像データに変換する。後解像度変換部180は、解像度を変換したブロック画像をブロックカット処理部160に供給する。   The post-resolution conversion unit 180 performs resolution conversion (multiplication resolution conversion) of the image data input from the post-filter processing unit 150. For example, the post-resolution conversion unit 180 converts the input image data having a resolution of horizontal 600 DPI × vertical 600 DPI into horizontal. The image data is converted to image data having a resolution of 600 DPI × 1200 DPI. The post-resolution conversion unit 180 supplies the block image whose resolution has been converted to the block cut processing unit 160.

量子化処理部190は、ブロックカット処理部160より供給されたブロック画像に対して量子化処理を行う。例えば、量子化処理部190に供給された画素当たり8bitのブロック画像をあらかじめ設定された閾値等と比較することで画素当たり1bitの画像データに量子化するようにしてもよい。1bitに量子化された画像データは8画素単位で8bitのデータにまとめられ、ブロック書き出し部130Aへ供給される。例えば、画像出力部50が電子写真式のプリンタ等である場合には、画像処理装置1に、量子化処理部190を搭載し、現像剤(トナー剤)の色ごとの画像データを生成することができる。   The quantization processing unit 190 performs quantization processing on the block image supplied from the block cut processing unit 160. For example, an 8-bit block image per pixel supplied to the quantization processing unit 190 may be quantized to 1-bit image data per pixel by comparing with a preset threshold value or the like. The image data quantized to 1 bit is collected into 8 bit data in units of 8 pixels and supplied to the block writing unit 130A. For example, when the image output unit 50 is an electrophotographic printer or the like, the image processing apparatus 1 includes the quantization processing unit 190 and generates image data for each color of the developer (toner agent). Can do.

(C−2)第3の実施形態の動作
次に、以上のような構成を有する第3の実施形態の画像形成装置1Bの動作(実施形態の画像処理方法)を説明する。以下では、第3の実施形態の画像形成装置1Bの動作について、第2の実施形態の動作との差異を中心に説明する。
(C-2) Operation of Third Embodiment Next, the operation (image processing method of the embodiment) of the image forming apparatus 1B of the third embodiment having the above-described configuration will be described. Hereinafter, the operation of the image forming apparatus 1B according to the third embodiment will be described focusing on the difference from the operation according to the second embodiment.

(C−2−1)画像形成装置1B全体の動作の概要
図19は、画像形成装置1Bの全体の動作について示したフローチャートである。
(C-2-1) Overview of Overall Operation of Image Forming Apparatus 1B FIG. 19 is a flowchart showing the overall operation of image forming apparatus 1B.

まず、画像形成装置1Aでは、画像入力部10に画像G101のデータが入力されて、画像メモリ60に、画像G101として書き込まれたものとする。そして、拡大・縮小処理部100Bに設定倍率がセットされたものとする(S501)。   First, in the image forming apparatus 1A, it is assumed that the data of the image G101 is input to the image input unit 10 and is written in the image memory 60 as the image G101. Then, it is assumed that the set magnification is set in the enlargement / reduction processing unit 100B (S501).

ここでは、画像G101は、幅7680画素、高さ5120画素の画像であるものとする。またここでは、拡大・縮小処理部100Bに設定倍率として133%設定された場合と、41%が設定された場合とで、場合分けして説明する。   Here, it is assumed that the image G101 is an image having a width of 7680 pixels and a height of 5120 pixels. Here, the case where 133% is set as the set magnification in the enlargement / reduction processing unit 100B and the case where 41% is set will be described separately.

次に、拡大・縮小処理部100Bにより、拡大・縮小処理を行う画像G101のサイズと、設定倍率に基づいて、拡大・縮小に係る各パラメータ算出等の準備が行われる(S502)。   Next, the enlargement / reduction processing unit 100B prepares for calculation of each parameter related to enlargement / reduction based on the size of the image G101 to be enlarged / reduced and the set magnification (S502).

次に、拡大・縮小処理部100Bの各処理部により、ブロック単位で、読み出し処理、前フィルタ処理、前解像度変換処理、拡大・縮小処理、後フィルタ処理、後解像度変換処理、ブロックカット処理、量子化処理、及び書き出し処理が行われ、画像メモリ60に処理後の画像データG104が書き込まれる(S503)。   Next, each processing unit of the enlargement / reduction processing unit 100B performs read processing, pre-filter processing, pre-resolution conversion processing, enlargement / reduction processing, post-filter processing, post-resolution conversion processing, block cut processing, quantum cut processing in units of blocks. Processing and writing processing are performed, and the processed image data G104 is written in the image memory 60 (S503).

そして、画像出力部50により、処理後の画像データG104が出力されることになる(S504)。   Then, the processed image data G104 is output by the image output unit 50 (S504).

(C−2−2)拡大・縮小に係る各パラメータ算出(ステップS502)
次に第3の実施形態の拡大・縮小部300に必要なパラメータの算出方法について、幅3840ピクセル、高さ5120ピクセルの画像データ(横300DPI×縦600DPI)を133%の倍率で拡大する場合と41%の倍率で縮小する場合を例に挙げ説明する。
(C-2-2) Parameter calculation for enlargement / reduction (step S502)
Next, with respect to a method for calculating parameters necessary for the enlargement / reduction unit 300 of the third embodiment, image data (width 300 DPI × height 600 DPI) having a width of 3840 pixels and a height of 5120 pixels is enlarged at a magnification of 133%. A case where reduction is performed at a magnification of 41% is described as an example.

また、前フィルタ処理部140では注目画素を中心に25×25の画素参照を行うフィルタ処理が行われ、後フィルタ処理部150では注目画素を中心に5×5の画素参照を行うフィルタ処理が行われ、前解像度変換部170ではX方向の解像度を2倍にする処理が行われ、後解像度変換部180ではY方向の解像度を2倍にする処理が行われ、量子化処理部190では画素当たり8bitの画像データを画素当たり1bitの画像データに変換する処理が行われるものとする。   Further, the pre-filter processing unit 140 performs a filter process for referring to a 25 × 25 pixel around the target pixel, and the post-filter processing unit 150 performs a filter process for referring to a 5 × 5 pixel around the target pixel. The pre-resolution conversion unit 170 performs processing for doubling the X-direction resolution, the post-resolution conversion unit 180 performs processing for doubling the Y-direction resolution, and the quantization processing unit 190 performs per-pixel processing. It is assumed that a process of converting 8-bit image data into 1-bit image data per pixel is performed.

さらに、前フィルタ処理部140、ブロック拡大・縮小部120B、後フィルタ処理部150、後解像度変換処理部330は、それぞれ、288、264、262、262画素分の画像を保持するラインメモリを備え、各処理部における出力可能なブロック幅は前記の値が上限であるものとする。   Further, the pre-filter processing unit 140, the block enlargement / reduction unit 120B, the post-filter processing unit 150, and the post-resolution conversion processing unit 330 include line memories that hold images of 288, 264, 262, and 262 pixels, respectively. The block width that can be output in each processing unit is assumed to have the above value as the upper limit.

拡大・縮小処理部100Bの各部位に必要なパラメータの算出方法の全体処理について図20のフローチャートを用いて説明する。   The overall processing of the parameter calculation method necessary for each part of the enlargement / reduction processing unit 100B will be described with reference to the flowchart of FIG.

まず、ステップS601において、ブロック拡大・縮小部120Bは、画像G101と設定倍率に基づいて、拡大・縮小処理後に出力する画像データG104のサイズ(1ページの出力画像の幅と高さ)を算出する。   First, in step S601, the block enlargement / reduction unit 120B calculates the size (width and height of the output image of one page) of the image data G104 output after the enlargement / reduction processing based on the image G101 and the set magnification. .

第3の実施形態のブロック拡大・縮小部120Bでは、拡大・縮小によるサイズ変動に加え、前解像度変換部170、後解像度変換部180、量子化処理部190の各処理部によるサイズ変動を考慮する必要がある。以下の説明では、上述の各処理部のX方向の入力画像幅と出力画像幅(BYTE数)の比をxbase、xratio、Y方向の入力画像高さと出力画像高さの比をybase、yratioとして説明する。なお、以下では、上述の各処理部のそれぞれに係る、前記の各パラメー夕(xbase、xratio、ybase、yratio)については、図21の表の通りとなっているものとする。   In the block enlargement / reduction unit 120B of the third embodiment, in addition to the size change due to enlargement / reduction, the size change due to each processing unit of the pre-resolution conversion unit 170, the post-resolution conversion unit 180, and the quantization processing unit 190 is considered. There is a need. In the following description, the ratio between the input image width in the X direction and the output image width (the number of BYTEs) of each processing unit described above is xbase, xratio, and the ratio between the input image height in the Y direction and the output image height is ybase, yratio. explain. In the following description, it is assumed that the parameters (xbase, xratio, ybase, yratio) relating to each of the above-described processing units are as shown in the table of FIG.

したがって、ブロック拡大・縮小部120Bでは、前記の各パラメー夕(xbase、xratio、ybase、yratio)について、上述の各処理部のパラメータを累乗して、処理全体でのX方向倍率の分母(以下、「xbase_t」と呼ぶ)と分子(以下、「xratio_t」と呼ぶ)、Y方向倍率の分母(以下、「ybase_t」と呼ぶ)と分子(以下、「xratio_y」と呼ぶ)を求める。そして、ブロック拡大・縮小部120Bは、拡大・縮小処理後に出力する画像データG104のサイズ(1ページの出力画像の幅と高さ)を、以下の(32)、(33)式を用いて算出する。   Therefore, in the block enlargement / reduction unit 120B, for each of the above parameters (xbase, xratio, ybase, yratio), the parameter of each of the above processing units is raised to the power, and the denominator (hereinafter, “Xbase_t”) and numerator (hereinafter referred to as “xratio_t”), Y direction magnification denominator (hereinafter referred to as “ybase_t”) and numerator (hereinafter referred to as “xratio_y”) are obtained. Then, the block enlargement / reduction unit 120B calculates the size (width and height of the output image of one page) of the image data G104 output after the enlargement / reduction processing using the following equations (32) and (33). To do.

なお、以下の(32)、(33)式において、XOは出力する画像データG104の幅(X方向)の画素数である。また、XIは、処理対象の画像G101の幅(X方向)の画素数である。さらにYOは出力する画像データG104の高さ(Y方向)の画素数である。さらにまた、YIは、処理対象の画像G101の高さ(Y方向)の画素数である。   In the following equations (32) and (33), XO is the number of pixels in the width (X direction) of the output image data G104. XI is the number of pixels in the width (X direction) of the image G101 to be processed. Furthermore, YO is the number of pixels in the height (Y direction) of the output image data G104. Furthermore, YI is the number of pixels in the height (Y direction) of the image G101 to be processed.

XO=(XI)×(xratio_s)/(xbase_s)…(32)
YO=(YI)×(yratio_s)/(ybase_s)…(33)
前述した入力画像G101(幅3840、高さ5120)を133%に拡大する場合の例では、出力画像幅XOが3840×(2×133×1×1)/(1×100×1×8)=1276、出力画像高さYOが5120×(1×133×2×1)/(1×100×1×1)=13619となる。また、41%に縮小する場合の例では、出力画像幅XOが3840×(2×41×1×1)/(1×100×1×8)=393、出力画像高さYOが5120×(1×41×2×1)/(1×100×1×1)=4198となる。
XO = (XI) × (xratio_s) / (xbase_s) (32)
YO = (YI) × (yratio_s) / (ybase_s) (33)
In the example of enlarging the input image G101 (width 3840, height 5120) to 133%, the output image width XO is 3840 × (2 × 133 × 1 × 1) / (1 × 100 × 1 × 8). = 1276, and the output image height YO is 5120 × (1 × 133 × 2 × 1) / (1 × 100 × 1 × 1) = 13619. In the example of reduction to 41%, the output image width XO is 3840 × (2 × 41 × 1 × 1) / (1 × 100 × 1 × 8) = 393, and the output image height YO is 5120 × ( 1 × 41 × 2 × 1) / (1 × 100 × 1 × 1) = 4198.

次に、ステップS602において、ブロック拡大・縮小部120Bは、入力ブロック累積無効サイズを算出する。入力ブロック累積無効サイズは、各処理部に入力されるブロック画像に含まれる無効画素のサイズであり、各処理部において、各処理部の上流(前段)の処理部で発生する無効画素のサイズを累積することで求まる。また、各処理部では、前段の処理部が解像度変換を行う処理の場合には、その解像度変換の内容も考慮する必要がある。さらに、各処理部では、前段の処理部がブロック拡大・縮小部120Bやブロックカット処理部160である場合は、その処理部で累積して発生した無効画素は削除されるため0となる。したがって、下式を使って上流のブロック読み出し部110Aから順番に算出を行うことで各処理部の累積無効サイズを算出できる。   In step S602, the block enlargement / reduction unit 120B calculates an input block cumulative invalid size. The input block cumulative invalid size is the size of invalid pixels included in the block image input to each processing unit. In each processing unit, the size of invalid pixels generated in the processing unit upstream (previous stage) of each processing unit. It is obtained by accumulating. Further, in each processing unit, when the processing unit in the previous stage performs the resolution conversion, it is necessary to consider the content of the resolution conversion. Furthermore, in each processing unit, when the preceding processing unit is the block enlargement / reduction unit 120B or the block cut processing unit 160, the invalid pixels accumulated in the processing unit are deleted and thus become 0. Accordingly, the cumulative invalid size of each processing unit can be calculated by calculating in order from the upstream block reading unit 110A using the following equation.

したがって、ブロック拡大・縮小部120Bでは、「前段の処理部がブロック拡大・縮小部120Bやブロックカット処理部160である場合」には、左端、右端、上端、下端のそれぞれの累積無効サイズを、以下の(34)式〜(37)式により求めることができる。   Therefore, in the block enlargement / reduction unit 120B, when “the previous processing unit is the block enlargement / reduction unit 120B or the block cut processing unit 160”, the accumulated invalid sizes of the left end, the right end, the upper end, and the lower end are set as follows. It can obtain | require by the following (34) Formula-(37) Formula.

以下の(34)式〜(37)式のnulwL、nulwR、nulhU、nulhDは各処理部で発生する無効画素のサイズである(図21の表参照)。第3の実施形態の動作例(図21の表に従う例)においては、各処理部の左端/右端/上端/下端の累積無効サイズは、ブロック読み出し部110Aと前解像度変換部170で0/0/0/0、前フィルタ処理部140で0/1/0/0、ブロック拡大縮小部120Bが12/13/12/12、後フィルタ処理部150で0/0/0/0、後解像度変換部180で2/2/2/2、ブロックカット処理部160で2/2/4/4、量子化処理部190とブロック書き出し部130Aで0/0/0/0となる。なお、前記の累積無効サイズの左端と上端の値の範囲がブロック拡大縮小部120Bにおいてブロック画像の左端と上端で(微調整スキップ値による無視する部分を除く)無視する範囲である。   In the following equations (34) to (37), ulwL, ulwR, ulhU, and ulhD are sizes of invalid pixels generated in each processing unit (see the table in FIG. 21). In the operation example of the third embodiment (example according to the table of FIG. 21), the cumulative invalid size of the left end / right end / upper end / lower end of each processing unit is 0/0 by the block reading unit 110A and the previous resolution conversion unit 170. / 0/0, 0/1/0/0 in the pre-filter processing unit 140, 12/13/12/12 in the block enlargement / reduction unit 120B, 0/0/0/0 in the post-filter processing unit 150, and post-resolution conversion 2/2/2/2 in the unit 180, 2/4/4 in the block cut processing unit 160, and 0/0/0/0 in the quantization processing unit 190 and the block writing unit 130A. Note that the range of the left end and top end values of the cumulative invalid size is a range that is ignored at the left end and top end of the block image in the block enlargement / reduction unit 120B (except for the portion ignored by the fine adjustment skip value).

[前段処理部がブロック拡大縮小部120B又はブロックカット処理部160以外の場合]
(左端累積無効サイズ)=
((前段処理部の左端累積無効サイズ)×(前段処理部のxratio)
+(前段処理部のxbase)−1)/(前段処理部のxbase)
+(前段処理部のnulwL) …(34)
(右端累積無効サイズ)=
((前段処理部の右端累積無効サイズ)×(前段処理部のxratio)
+(前段処理部のxbase)−1)/(前段処理部のxbase)
+(前段処理部のnulwR) …(35)
(上端累積無効サイズ)=
((前段処理部の上端累積無効サイズ)×(前段処理部のyratio)
+(前段処理部のybase)−1)/(前段処理部のybase)
+(前段処理部のnulhU) …(36)
(下端累積無効サイズ)=
((前段処理部の下端累積無効サイズ)×(前段処理部のyratio)
+(前段処理部のybase)−1)/(前段処理部のybase)
+(前段処理部のnulhD) …(37)
上述のように、前段の処理部がブロック拡大・縮小部120Bやブロックカット処理部160である場合は、その処理部で累積して発生した無効画素は削除されるため0となるため、左端、右端、上端、下端のそれぞれの累積無効サイズは、以下の(38)式〜(41)式のようになる。
[When the pre-stage processing unit is other than the block enlargement / reduction unit 120B or the block cut processing unit 160]
(Leftmost cumulative invalid size) =
((Left end cumulative invalid size of the pre-processing unit) x (x ratio of the pre-processing unit)
+ (Xbase of the pre-processing unit) -1) / (xbase of the pre-processing unit)
+ (NullwL of the pre-processing unit) (34)
(Right-end cumulative invalid size) =
((Right-end cumulative invalid size of pre-processing unit) x (x-ratio of pre-processing unit)
+ (Xbase of the pre-processing unit) -1) / (xbase of the pre-processing unit)
+ (NullwR of the pre-processing unit) (35)
(Upper end cumulative invalid size) =
((Upper end cumulative invalid size of previous processing unit) × (yatio of previous processing unit)
+ (Ybase of pre-processing unit) -1) / (ybase of pre-processing unit)
+ (NullU of the pre-processing unit) (36)
(Bottom bottom invalid size) =
((Lower-end cumulative invalid size of the pre-processing unit) × (yatio of the pre-processing unit)
+ (Ybase of pre-processing unit) -1) / (ybase of pre-processing unit)
+ (NullhD of the pre-processing unit) (37)
As described above, when the preceding processing unit is the block enlargement / reduction unit 120B or the block cut processing unit 160, the invalid pixels accumulated by the processing unit are deleted and become 0, so the left edge, The cumulative invalid sizes at the right end, the upper end, and the lower end are expressed by the following equations (38) to (41), respectively.

[前段処理部がブロック拡大縮小部120Bまたブロックカット処理部160の場合]
(左端累積無効サイズ)=0 …(38)
(右端累積無効サイズ)=0 …(39)
(上端累積無効サイズ)=0 …(40)
(下端累積無効サイズ)=0 …(41)
次にS603では、拡大・縮小処理部100Bは、各処理部の入出力ブロック画像サイズを算出する。拡大・縮小処理部100Bは、第2の実施形態とほぼ同様の処理(上述の図4のステップS202、図12のフローチャートの処理)により、各処理部における出力ブロック画像サイズを最後段の処理部より算出し、算出した各処理部における出力ブロック画像サイズが全ての処理部で制限内になるまで算出を繰り返し行うことで、各処理部における出力ブロック画像サイズを算出する。なお、第3の実施形態の拡大・縮小処理部100Bでは、前解像度変換部170、後解像度変換部180、量子化処理部190が追加されたことで、各処理部における出力ブロック画像に係る算出処理を変更する必要があるため、以下ではその差異部分を中心に説明する。
[When the pre-processing unit is the block enlargement / reduction unit 120B or block cut processing unit 160]
(Left end cumulative invalid size) = 0 (38)
(Right-end cumulative invalid size) = 0 (39)
(Upper end cumulative invalid size) = 0 (40)
(Lower end cumulative invalid size) = 0 (41)
In step S603, the enlargement / reduction processing unit 100B calculates the input / output block image size of each processing unit. The enlargement / reduction processing unit 100B determines the output block image size in each processing unit by the processing substantially the same as that of the second embodiment (step S202 in FIG. 4 and the flowchart in FIG. 12). The output block image size in each processing unit is calculated by repeatedly calculating until the output block image size in each processing unit is within the limit in all processing units. In addition, in the enlargement / reduction processing unit 100B of the third embodiment, the calculation related to the output block image in each processing unit is performed by adding the pre-resolution conversion unit 170, the post-resolution conversion unit 180, and the quantization processing unit 190. Since it is necessary to change the processing, the difference will be mainly described below.

第3の実施形態における各処理番号ごと(ブロック画像処理部ごと)の出力ブロック画像サイズについて、上述の図12のフローチャートに従って算出すると以下の(42)〜(47)式により求めることができる。   When the output block image size for each processing number (each block image processing unit) in the third embodiment is calculated according to the flowchart of FIG. 12 described above, it can be obtained by the following equations (42) to (47).

なお、以下の(42)式〜(47)式において、inc_nulwL/R[p]、inc_nulhU/D[p]は、上述のステップS602で求めた各処理部の左端/右端/上端/下端の累積無効サイズである。また、outbw[p]、outbh[p]は、第2の実施形態と同様、各処理部で出力するブロック画像の幅と高さである。   In the following equations (42) to (47), inc_nullL / R [p] and inc_nullU / D [p] are the cumulative values of the left end / right end / upper end / lower end of each processing unit obtained in step S602 described above. Invalid size. Also, outbw [p] and outbh [p] are the width and height of the block image output by each processing unit, as in the second embodiment.

ブロック書き出し部130Aの出力ブロックサイズは、以下の(42)式、(43)式のように任意の値を設定することができる。   The output block size of the block writing unit 130A can be set to an arbitrary value as in the following expressions (42) and (43).

outbw[p]=任意の値 …(42)
outbh[p]=任意の値 …(43)
後フィルタ処理部150、及び前フィルタ処理部140の出力ブロックサイズは以下の(44)式、(45)式により求めることができる。
outbw [p] = arbitrary value (42)
outbh [p] = arbitrary value (43)
The output block sizes of the post filter processing unit 150 and the pre filter processing unit 140 can be obtained by the following formulas (44) and (45).

outbw[p]=(outbw[p+1]×xbase[p+1]
+xratio[p+1]−1)/xratio[p+1]
+inc_nulwL[p+1]+inc_nulwR[p+1]
+nulwL[p+1]+nulwR[p+1]…(44)
outbh[p]=(outbh[p+1]×ybase[p+1]
+yratio[p+1]−1)/yratio[p+1]
+inc_nulhU[p+1]+inc_nulhD[p+1]
+nulhU[p+1]+nulhD[p+1]…(45)
量子化処理部190、ブロックカット処理部160、後フィルタ処理部150、ブロック拡大縮小部120B、前解像度変換部170、及びブロック読み出し部110Aの出力ブロックサイズは以下の(46)式、(47)式により求めることができる。
outbw [p] = (outbw [p + 1] × xbase [p + 1]
+ Xratio [p + 1] -1) / xratio [p + 1]
+ Inc_nullL [p + 1] + inc_nullR [p + 1]
+ NulwL [p + 1] + nulwR [p + 1] (44)
outbh [p] = (outbh [p + 1] × ybase [p + 1]
+ Yratio [p + 1] -1) / yratio [p + 1]
+ Inc_nullU [p + 1] + inc_nullhD [p + 1]
+ Nullh [p + 1] + nullh [p + 1] (45)
The output block sizes of the quantization processing unit 190, the block cut processing unit 160, the post filter processing unit 150, the block enlargement / reduction unit 120B, the pre-resolution conversion unit 170, and the block reading unit 110A are the following equations (46) and (47). It can be obtained by an expression.

outbw[p]=(outbw[p+1]×xbase[p+1]
+xratio[p+1]−1)/xratio[p+1]…(46)
outbh[p]=(outbh[p+1]×ybase[p+1]
+yratio[p+1]−1)/yratio[p+1]…(47)
以上のような処理により、拡大・縮小処理部100Bで算出される各処理部の出力ブロック画像サイズは、例えば、図22のようになる。
outbw [p] = (outbw [p + 1] × xbase [p + 1]
+ Xratio [p + 1] -1) / xratio [p + 1] (46)
outbh [p] = (outbh [p + 1] × ybase [p + 1]
+ Yratio [p + 1] -1) / yratio [p + 1] (47)
With the processing as described above, the output block image size of each processing unit calculated by the enlargement / reduction processing unit 100B is, for example, as shown in FIG.

ステップS604では、ブロック拡大縮小部120Bは、X方向およびY方向の分割数を算出する(第1の実施形態と同様)。第3の実施形態においては、133%に拡大する場合の例では、X方向の分割数は40、Y方向の分割数は54、41%に縮小する場合の例では、X方向の分割数は33、Y方向の分割数は17になる。   In step S604, the block enlargement / reduction unit 120B calculates the number of divisions in the X direction and the Y direction (similar to the first embodiment). In the third embodiment, in the example of enlargement to 133%, the number of divisions in the X direction is 40, the number of divisions in the Y direction is 54, and in the example of reduction to 41%, the number of divisions in the X direction is 33, the number of divisions in the Y direction is 17.

ステップS605では、拡大・縮小処理部100Bは、各処理部に係るストライド値を算出する。ストライド値とは、拡大・縮小処理部100Bの各処理部に入力されるブロック画像のデータの中で、隣接ブロックと重複なく出力される部分(最終的にブロック書き出し部130Aで書き込まれる有効部分)の幅と高さである。拡大・縮小処理部100Bは、各処理部におけるストライド値は、ブロック書き出し部130Aが出力するブロック画像サイズを用いて、例えば、以下の(48)式〜(51)式を用いて求めることができる。   In step S605, the enlargement / reduction processing unit 100B calculates a stride value for each processing unit. The stride value is a portion of block image data input to each processing unit of the enlargement / reduction processing unit 100B that is output without overlapping with an adjacent block (an effective portion that is finally written by the block writing unit 130A). Width and height. The enlargement / reduction processing unit 100B can obtain the stride value in each processing unit using, for example, the following equations (48) to (51) using the block image size output by the block writing unit 130A. .

なお、以下の(48)式〜(51)式において、xstride[p]、ystride[p]はそれぞれ、各処理部のX方向とY方向のストライド値である。   In the following formulas (48) to (51), xstride [p] and ystride [p] are the stride values in the X direction and Y direction of each processing unit, respectively.

ブロック書き出し部130Aのストライド値は、以下の(48)式、(49)式を用いて求めることができる。   The stride value of the block writing unit 130A can be obtained using the following equations (48) and (49).

xstride[p]=(出力ブロック幅) …(48)
ystride[p]=(出力ブロック幅) …(49)
ブロック書き出し部130Aのストライド値は、以下の(48)式、(49)式を用いて求めることができる。
xstride [p] = (output block width) (48)
ystride [p] = (output block width) (49)
The stride value of the block writing unit 130A can be obtained using the following equations (48) and (49).

拡大・縮小処理部100Bを構成するブロック書き出し部130A以外の各処理部のストライド値は、以下の(50)式、(51)式を用いて求めることができる。   The stride value of each processing unit other than the block writing unit 130A constituting the enlargement / reduction processing unit 100B can be obtained using the following equations (50) and (51).

xstride[p]=(xstride[p+1]×xbase[p]
+xratio[p]−1)/xratio[p] …(50)
ystride[p]=(ystride[p+1]×ybase[p]
+yratio[p]−1)/yratio[p] …(51)
以下、拡大・縮小処理部100Bで、133%に拡大する場合と41%に縮小する場合とに分けて、各処理部のX方向とY方向のストライド値について説明する。
xstride [p] = (xstride [p + 1] × xbase [p]
+ Xratio [p] -1) / xratio [p] (50)
ystride [p] = (ystride [p + 1] × ybase [p]
+ Yratio [p] -1) / yratio [p] (51)
Hereinafter, the stride values in the X direction and the Y direction of each processing unit will be described separately for the case where the enlargement / reduction processing unit 100B enlarges to 133% and the case where the enlargement / reduction processing unit 100B reduces to 41%.

まず、拡大・縮小処理部100Bで、133%に拡大する場合の各処理部のX方向でのストライド値(xstride)、及びY方向のストライド値(ystride)の例について説明する。この場合、ブロック書き出し部130A及び量子化処理部190では、xstride=32、ystride=256となる。また、この場合、ブロックカット処理部160では、xstride=256、ystride=256となる。さらに、この場合、後解像度変換部180及び後フィルタ処理部150では、xstride=256、ystride=128となる。さらにまた、ブロック拡大縮小部120B、及び前フィルタ処理部140では、xstride=193、ystride=97となる。また、前解像度変換部170、及びブロック読み出し部110Aでは、xstride=97、ystride=97となる。   First, an example of the stride value (xstride) in the X direction and the stride value (ystride) in the Y direction of each processing unit when the enlargement / reduction processing unit 100B enlarges to 133% will be described. In this case, in the block writing unit 130A and the quantization processing unit 190, xstride = 32 and ystride = 256. In this case, the block cut processing unit 160 has xstride = 256 and ystride = 256. Further, in this case, in the post-resolution conversion unit 180 and the post-filter processing unit 150, xstride = 256 and ystride = 128. Furthermore, in the block enlargement / reduction unit 120B and the pre-filter processing unit 140, xstride = 193 and ystride = 97. In the previous resolution conversion unit 170 and the block reading unit 110A, xstride = 97 and ystride = 97.

次に、拡大・縮小処理部100Bで、41%に縮小する場合の各処理部のX方向でのストライド値(xstride)、及びY方向のストライド値(ystride)の例について説明する。この場合、ブロック書き出し部130A、及び量子化処理部190では、xstride=12、ystride=256となる。また、この場合、ブロックカット処理部160では、xstride=96、ystride=256となる。さらに、この場合、後解像度変換部180、及び後フィルタ処理部150では、xstride=96、ystride=128となる。さらにまた、この場合、ブロック拡大縮小部120B、及び前フィルタ処理部140では、xstride=235、ystride=313となる。また、この場合、前解像度変換部170、及びブロック読み出し部110Aでは、xstride=118、ystride=313となる。   Next, an example of the stride value (xstride) in the X direction and the stride value (ystride) in the Y direction of each processing unit when the enlargement / reduction processing unit 100B reduces to 41% will be described. In this case, in the block writing unit 130A and the quantization processing unit 190, xstride = 12, ystride = 256. In this case, in the block cut processing unit 160, xstride = 96 and ystride = 256. Further, in this case, in the post-resolution conversion unit 180 and the post-filter processing unit 150, xstride = 96 and ystride = 128. Furthermore, in this case, in the block enlargement / reduction unit 120B and the pre-filter processing unit 140, xstride = 235 and ystride = 313. In this case, in the previous resolution converting unit 170 and the block reading unit 110A, xstride = 118 and ystride = 313.

次に、ステップS606では、拡大・縮小処理部100Bは、ブロック画像毎のX方向とY方向の拡大・縮小カウンタ初期値、ブロック読み出し部110Aが読み出す各ブロック画像のX方向とY方向の読み出し位置、及びブロック画像毎のX方向とY方向の微調整スキップ値を算出する。拡大・縮小処理部100Bは、例えば、以下の(52)式〜(65)式を用いて、上述の各値を算出することができる。   Next, in step S606, the enlargement / reduction processing unit 100B sets the initial values of the enlargement / reduction counters in the X and Y directions for each block image, and the read positions in the X and Y directions of each block image read by the block reading unit 110A. The fine adjustment skip values in the X direction and the Y direction for each block image are calculated. The enlargement / reduction processing unit 100B can calculate the above-described values using, for example, the following equations (52) to (65).

なお、以下の(52)式〜(65)式において、xno、ynoはX方向のブロック番号とY方向のブロック番号をあらわし、xcnt[]、ycnt[]はX方向の拡大・縮小カウンタの初期値とY方向の拡大・縮小カウンタをあらわす。また、xpos0[]、ypos0[]はX方向の読み出し位置とY方向の読み出し位置をあらわす。さらに、modw[]、modh[]はX方向の微調整スキップ値とY方向の微調整スキップ値をあらわす。さらにまた、xstride、ystirdeはブロック拡大縮小部120Bの後段処理部のストライド値をあらわす。また、xbase、xratioはブロック拡大縮小部120BのX方向の倍率の分母と分子をあらわし、ybase、yratioはブロック拡大縮小部120BのY方向の倍率の分母と分子をあらわす。さらに、bnulwとbnulhはブロック拡大縮小部120Bに入力されるブロック画像に含まれる左端と上端の無効画素の幅と高さ(左端累積無効サイズと上端累積無効サイズと同じ)である。さらにまた、anulwとanulhはブロック拡大縮小部120Bの後段の処理でブロック画像に発生する無効画素数をあらわす。   In the following formulas (52) to (65), xno and yno represent the block number in the X direction and the block number in the Y direction, and xcnt [] and ycnt [] are initial values of the enlargement / reduction counter in the X direction. Represents the value and the enlargement / reduction counter in the Y direction. Further, xpos0 [] and ypos0 [] represent a reading position in the X direction and a reading position in the Y direction. Furthermore, modw [] and mod [] represent the fine adjustment skip value in the X direction and the fine adjustment skip value in the Y direction. Furthermore, x stride and y stirde represent the stride value of the subsequent processing unit of the block enlargement / reduction unit 120B. Further, xbase and xratio represent the denominator and numerator of the X magnification of the block enlargement / reduction unit 120B, and ybase and yratio represent the denominator and numerator of the Y magnification of the block enlargement / reduction unit 120B. Further, bnulw and bnulh are the width and height of the left and top invalid pixels included in the block image input to the block enlargement / reduction unit 120B (the same as the leftmost cumulative invalid size and the top cumulative invalid size). Furthermore, anulw and anulh represent the number of invalid pixels generated in the block image in the subsequent processing of the block enlargement / reduction unit 120B.

拡大・縮小処理部100Bは、例えば、以下の(52)式、(53)式を用いて、ブロック画像毎のX方向の拡大・縮小カウンタ初期値を求めることができる。   The enlargement / reduction processing unit 100B can obtain the initial value of the enlargement / reduction counter in the X direction for each block image using, for example, the following equations (52) and (53).

xcnt0[0]=(xratio−(anulw×xbase)
%xratio)%xratio …(52)
xcnt0[xno]=(xstride×xbase+xcnt0[xno−1])
%xratio …(53)
拡大・縮小処理部100Bは、例えば、以下の(54)式、(55)式を用いて、ブロック画像毎のX方向の拡大・縮小カウンタ初期値を求めることができる。
xcnt0 [0] = (xratio− (anulw × xbase)
% Xratio)% xratio (52)
xcnt0 [xno] = (xstride × xbase + xcnt0 [xno−1])
% Xratio (53)
The enlargement / reduction processing unit 100B can obtain the initial value of the enlargement / reduction counter in the X direction for each block image using, for example, the following expressions (54) and (55).

ycnt0[0]=(yratio−(anulh×ybase)
%yratio)%yratio …(54)
ycnt0[yno]=(ystride×ybase+ycnt0[yno−1])
%yratio …(55)
拡大・縮小処理部100Bは、例えば、以下の(56)式〜(57)式を用いて、ブロック読み出し部110Aが読み出す各ブロック画像のX方向の読み出し位置を求めることができる
xpos0’[0]=−(anulw×xbase+xratio−1)
/xratio−bnulw …(56)
xpos0’[xno]=xpos0’[xno−1]
+(xstride×xbase+xcnt0[xno−1])
/xratio …(57)
xpos0[xno]=(xpos0’[xno]
×(前解像度変換部170のxbase))
/(前解像度変換部170のxratio) …(58)
拡大・縮小処理部100Bは、例えば、以下の(59)式〜(61)式を用いて、ブロック読み出し部110Aが読み出す各ブロック画像のX方向の読み出し位置を求めることができる。
ycnt0 [0] = (yratio− (anulh × ybase)
% Yratio)% yratio (54)
ycnt0 [yno] = (ystride × ybase + ycnt0 [yno−1])
% Yratio (55)
The enlargement / reduction processing unit 100B can obtain the reading position in the X direction of each block image read by the block reading unit 110A using, for example, the following equations (56) to (57): xpos0 ′ [0] = − (Anulw × xbase + xratio−1)
/ Xratio-bulw (56)
xpos0 '[xno] = xpos0' [xno-1]
+ (Xstride × xbase + xcnt0 [xno−1])
/ Xratio (57)
xpos0 [xno] = (xpos0 ′ [xno]
X (xbase of previous resolution conversion unit 170))
/ (Xratio of the previous resolution converter 170) (58)
The enlargement / reduction processing unit 100B can obtain the reading position in the X direction of each block image read by the block reading unit 110A using, for example, the following equations (59) to (61).

ypos0’[0]=−(anulh×ybase+yratio−1)
/yratio−bnulh …(59)
ypos0’[yno]=ypos0’[yno−1]
+(ystride×ybase+ycnt0O[yno−1])
/yratio …(60)
ypos0[yno]=(ypos0’[yno]
×(前解像度変換部170のybase))
/(前解像度変換部170のyratio) …(61)
拡大・縮小処理部100Bは、例えば、以下の(62)式、(63)式を用いて、X方向の微調整スキップ値を求めることができる。
ypos0 ′ [0] = − (anulh × ybase + yratio−1)
/ Yratio-bullh (59)
ypos0 '[yno] = ypos0' [yno-1]
+ (Ystride × ybase + ycnt0O [yno-1])
/ Yratio (60)
ypos0 [yno] = (ypos0 ′ [yno]
X (ybase of previous resolution conversion unit 170))
/ (Yatio of the previous resolution converter 170) (61)
The enlargement / reduction processing unit 100B can obtain the fine adjustment skip value in the X direction using, for example, the following equations (62) and (63).

modw[0]=((anulw×xbase+xratio−1)
/xratio)%(前解像度変換部170のxratio)
modw[xno]=(modw[xno−1] …(62)
+(xstride×xbase+xcnt0[xno−1])
/xratio)%(前解像度変換部170xのratio) …(63)
拡大・縮小処理部100Bは、例えば、以下の(64)式、(65)式を用いて、Y方向の微調整スキップ値を求めることができる。
modw [0] = ((anulw × xbase + xratio−1)
/ Xratio)% (xratio of the previous resolution conversion unit 170)
modw [xno] = (modw [xno-1] (62)
+ (Xstride × xbase + xcnt0 [xno−1])
/ Xratio)% (ratio of the previous resolution conversion unit 170x) (63)
The enlargement / reduction processing unit 100B can obtain the fine adjustment skip value in the Y direction using, for example, the following equations (64) and (65).

modh[0]=((anulh×ybase+yratio−1)
/yratio)%(前解像度変換部170のyratio)
modh[yno]=(modh[yno−1] …(64)
+(ystride×ybase+ycnt0[yno−1])
/yratio)%(前解像度変換部170のyratio) …(65)
以上のように、ブロック拡大・縮小部120Bでは、上記の式を用いて、第1、第2の実施形態と同様に、X方向であれば左端のブロックから順番に、Y方向であれば上端のブロックから順番に上述の各値を算出する。
mod [0] = ((anulh × ybase + yratio−1)
/ Yratio)% (yratio of the previous resolution conversion unit 170)
mod [yno] = (modh [yno-1] (64)
+ (Ystride × ybase + ycnt0 [yno−1])
/ Yratio)% (yratio of the previous resolution conversion unit 170) (65)
As described above, in the block enlargement / reduction unit 120B, using the above formula, in the same manner as in the first and second embodiments, the block is sequentially from the leftmost block in the X direction and the upper end in the Y direction. Each of the above values is calculated in order from the block.

画像処理装置1では、以上説明したステップS601〜S606で算出したパラメータを使用して、拡大・縮小処理部100Bを動作させることで、1ページの画像データを複数のブロックに分割して任意倍率の拡大・縮小と前後のフィルタ処理と前後の解像度変換処理と量子化処理を行うことができる。   The image processing apparatus 1 operates the enlargement / reduction processing unit 100B using the parameters calculated in steps S601 to S606 described above, thereby dividing one page of image data into a plurality of blocks and having an arbitrary magnification. Enlargement / reduction, front / rear filter processing, front / rear resolution conversion processing, and quantization processing can be performed.

次に、拡大・縮小処理部100Bが、上述のステップS601〜S606で算出した各パラメータを用いた具体的な動作(133%に拡大する場合の例)について説明する。   Next, a specific operation (an example in the case of enlarging to 133%) using each parameter calculated by the above-described steps S601 to S606 will be described.

まず、ブロック読み出し部110Aの動作について図23を用いて説明する。   First, the operation of the block reading unit 110A will be described with reference to FIG.

図23は、拡大・縮小処理部100Bで133%の拡大処理を実行する場合において、ブロック読み出し部110Aにより、画像メモリ60に記憶された1ページの画像をX方向とY方向に分割したブロック画像として読み出す動作の具体例である。   FIG. 23 shows a block image obtained by dividing the image of one page stored in the image memory 60 into the X direction and the Y direction by the block reading unit 110A when the enlargement / reduction processing unit 100B executes 133% enlargement processing. It is a specific example of the operation | movement read out as.

図23に示すように、で示すように、ブロック読み出し部110Aで読み出されるブロック画像は隣接ブロックと重複部分を持つように読み出される。ブロック読み出し部110Aで、読み出す1ページの画像データの最も左の画素のX方向の位置を0、最も上の画素のY方向の位置を0とすると、分割したブロック画像のX方向とY方向の読み出し開始位置は、X方向の読み出し開始位置についてはX方向のブロック番号0、1、2、3、4、・・・に対応して、−7、89、185、281、378、・・・とY方向の読み出し開始位置についてはY方向のブロック番号0、1、・・・に対応して、−14、82となる。例えば、X方向のブロック番号が2、Y方向のブロック番号が1であれば、X方向とY方向の読み出し位置は(185、82)になる。また、読み出される各ブロック画像のサイズは、全てのブロック画像で共通である(例では、横112×縦125)。なお、ページの外周近辺で読み出されるブロック画像については、ページ外の領域より読み出す必要があり、前記のページ外の領域のデータは、白データ(ダミーデータ)で置換したり、ページ外との境界に位置する画素を使って置換する。   As shown in FIG. 23, as shown in FIG. 23, the block image read out by the block reading unit 110A is read so as to have an overlapping portion with an adjacent block. When the position of the leftmost pixel in the image data of one page to be read is set to 0 and the position of the uppermost pixel in the Y direction is set to 0 in the block reading unit 110A, the X and Y directions of the divided block image are set to 0. The read start position corresponds to block numbers 0, 1, 2, 3, 4,... In the X direction for the read start position in the X direction, and is −7, 89, 185, 281, 378,. The read start position in the Y direction is −14, 82 corresponding to the block numbers 0, 1,. For example, if the block number in the X direction is 2 and the block number in the Y direction is 1, the read positions in the X direction and the Y direction are (185, 82). In addition, the size of each block image to be read is common to all the block images (in the example, horizontal 112 × vertical 125). It should be noted that the block image read out near the outer periphery of the page needs to be read out from the area outside the page, and the data in the area outside the page is replaced with white data (dummy data) or the boundary with the outside of the page Replace with the pixel located at.

ブロック読み出し部110Aは、各ブロック画像について、各ブロック画像のX方向とY方向のブロック番号にしたがって、X方向とY方向の読み出し位置を変更しながら読み出し、読み出したブロック画像を前解像度変換部170に供給する。   The block readout unit 110A reads out each block image while changing the readout position in the X direction and the Y direction in accordance with the block numbers in the X direction and the Y direction of each block image, and reads the read block image into the pre-resolution conversion unit 170. To supply.

前解像度変換部170に入力されたブロック画像(ブロック画像のサイズは横112×縦125)は、前解像度変換部170でX方向に2倍に拡大され、拡大された画像が前フィルタ処理部140に供給される。   The block image (the size of the block image is horizontal 112 × vertical 125) input to the pre-resolution converter 170 is doubled in the X direction by the pre-resolution converter 170, and the enlarged image is the pre-filter processor 140. To be supplied.

図24は、前解像度変換部170で1つのブロック画像に対して実行される処理について示した説明図である。   FIG. 24 is an explanatory diagram showing processing executed on one block image by the previous resolution conversion unit 170.

図24(a)は、前解像度変換部170に供給されるブロック画像について示した説明図である。図24(b)は、前解像度変換部170で解像度の拡大処理(X方向の拡大処理)が行われたブロック画像について示した説明図である。図24(c)は、前フィルタ処理部140における画像ブロックの処理について示した説明図である。   FIG. 24A is an explanatory diagram showing a block image supplied to the previous resolution conversion unit 170. FIG. 24B is an explanatory diagram showing a block image that has undergone resolution enlargement processing (X-direction enlargement processing) by the previous resolution conversion unit 170. FIG. 24C is an explanatory diagram showing image block processing in the pre-filter processing unit 140.

図24(a)、図24(b)に示すように、解像度変換後のブロック画像のサイズは横224×縦125になる。また、この実施形態では、前解像度変換部170は、上述の拡大処理(X方向の解像度を2倍拡大する処理)を線形補間拡大法で行うものとする。この場合、前解像度変換部170は、ブロック画像の右端に1画素無効画素が発生する(右端の1画素は右隣りの画素を参照できないため)。   As shown in FIGS. 24A and 24B, the size of the block image after the resolution conversion is 224 × 125 in the horizontal direction. In this embodiment, the pre-resolution conversion unit 170 performs the above-described enlargement processing (processing that doubles the resolution in the X direction) by a linear interpolation enlargement method. In this case, the pre-resolution conversion unit 170 generates a one-pixel invalid pixel at the right end of the block image (because the rightmost pixel cannot refer to the right adjacent pixel).

そして、図24(c)に示すように、前フィルタ処理部140に入力されたブロック画像(ブロック画像のサイズは横224×縦125)は、前フィルタ処理部140により、注目画素を中心に25×25の画素参照を行うフィルタ処理が施される。そして、前フィルタ処理部140は、そのフィルタ処理後のブロック画像を、ブロック拡大・縮小部220に供給する。図23(c)に示すように、上述のフィルタ処理により前フィルタ処理部140の処理後のブロック画像には、左端、右端、上端、下端に無効な画素が各12画素発生する。また、上述の通り、右端については前段の前解像度変換部170でも無効画素が1画素発生するため、前解像度変換部170と前フィルタ処理部140とで、あわせて13画素が無効画素となる。   Then, as shown in FIG. 24C, the block image (the size of the block image is 224 × 125 in the horizontal direction) input to the pre-filter processing unit 140 is converted to 25 by the pre-filter processing unit 140 around the target pixel. A filter process for referring to × 25 pixels is performed. Then, the pre-filter processing unit 140 supplies the block image after the filter processing to the block enlargement / reduction unit 220. As shown in FIG. 23C, in the block image after the processing by the pre-filter processing unit 140 by the above-described filter processing, 12 invalid pixels are generated at the left end, the right end, the upper end, and the lower end, respectively. In addition, as described above, since one invalid pixel is generated in the previous-stage previous resolution conversion unit 170 at the right end, a total of 13 pixels become invalid pixels in the previous resolution conversion unit 170 and the previous filter processing unit 140.

ブロック拡大・縮小部220に供給されたブロック画像は、ブロック拡大縮小部120Bで拡大・縮小処理(ここでは133%拡大の処理)が行われ、拡大されたブロック画像が後フィルタ処理部150に供給される。   The block image supplied to the block enlargement / reduction unit 220 is subjected to enlargement / reduction processing (here, 133% enlargement processing) by the block enlargement / reduction unit 120B, and the enlarged block image is supplied to the post-filter processing unit 150. Is done.

図25は、ブロック拡大・縮小部120Bで実行される画像ブロックに対する拡大処理の例について示した説明図である。   FIG. 25 is an explanatory diagram showing an example of enlargement processing for an image block executed by the block enlargement / reduction unit 120B.

図25(a)は、ブロック拡大・縮小部120Bに供給されたブロック画像について示した説明図である。図25(b)は、ブロック拡大・縮小部120BでX方向について拡大処理されたブロック画像の例について示した説明図である。図25(c)は、ブロック拡大・縮小部120BでY方向について拡大処理されたブロック画像の例について示した説明図である。図25(d)は、ブロック拡大・縮小部120Bで行われるX方向の拡大処理の例について示した説明図である。図25(e)は、ブロック拡大・縮小部120Bで行われるY方向の拡大処理の例について示した説明図である。   FIG. 25A is an explanatory diagram showing a block image supplied to the block enlargement / reduction unit 120B. FIG. 25B is an explanatory diagram showing an example of a block image enlarged in the X direction by the block enlargement / reduction unit 120B. FIG. 25C is an explanatory diagram showing an example of a block image enlarged in the Y direction by the block enlargement / reduction unit 120B. FIG. 25D is an explanatory diagram showing an example of the enlargement process in the X direction performed by the block enlargement / reduction unit 120B. FIG. 25E is an explanatory diagram showing an example of the enlargement process in the Y direction performed by the block enlargement / reduction unit 120B.

図25(a)〜図25(c)に示すように、ブロック拡大・縮小部120Bに供給されたブロック画像(横224×縦125)は、まず、X方向拡大・縮小部121BによりX方向について拡大され(ブロック画像サイズは横260×縦125)、次にY方向拡大・縮小部122BによりY方向ついて拡大されて出力される(ブロック画像サイズは横260×縦125)。   As shown in FIGS. 25 (a) to 25 (c), the block image (width 224 × length 125) supplied to the block enlargement / reduction unit 120B is first processed in the X direction by the X direction enlargement / reduction unit 121B. The image is enlarged (the block image size is 260 × 125 in the horizontal direction), and then enlarged and output in the Y direction by the Y-direction enlargement / reduction unit 122B (the block image size is 260 × vertical 125).

図25(d)に示すように、X方向拡大・縮小部121Bで行われるX方向の拡大では、X方向のX方向拡大・縮小カウンタ121aが各ブロック画像のライン先頭で、当該ブロックのX方向のブロック番号に対応する拡大・縮小カウンタの初期値に設定される。X方向拡大・縮小部121Bでは、例えば、X方向のブロック番号が2であれば、X方向拡大・縮小カウンタ121aが61に設定される。   As shown in FIG. 25D, in the X-direction enlargement performed by the X-direction enlargement / reduction unit 121B, the X-direction enlargement / reduction counter 121a is at the head of the line of each block image, and the X-direction of the block. Is set to the initial value of the enlargement / reduction counter corresponding to the block number. In the X direction enlargement / reduction unit 121B, for example, if the block number in the X direction is 2, the X direction enlargement / reduction counter 121a is set to 61.

X方向拡大・縮小部121Bは、ブロック画像の左端よりカウントが開始されるX方向スキップカウンタ121cが全ブロックで共通の所定の値(ここでの例では12)と、当該ブロック画像のX方向のブロック番号に対応する微調整スキップ値(例では1)の合計値(ここでの例では12+1=13)になるまで入力画素を無視した後(前段の処理で発生したブロック画像左端の無効画素12画素と読み出し位置の都合により発生する余分な1画素は前記の動作により削除される)、及びX方向拡大・縮小カウンタ121aにしたがってライン毎に拡大が行われる。そして、X方向拡大・縮小部121Bは、X方向出力カウンタ121bが所定の値(ここでの例では、260)になるまで拡大して出力する(前記の動作により前段の処理で発生したブロック右端の無効画素12画素および余分な画素が削除される)。   In the X direction enlargement / reduction unit 121B, the X direction skip counter 121c that starts counting from the left end of the block image has a predetermined value (12 in this example) common to all blocks, and the X direction skip counter 121c in the X direction of the block image. After the input pixels are ignored until the total value (12 + 1 = 13 in this example) of the fine adjustment skip value (1 in the example) corresponding to the block number (the invalid pixel 12 at the left end of the block image generated in the previous processing) One extra pixel generated due to the convenience of the pixel and the reading position is deleted by the above operation), and enlargement is performed for each line according to the X direction enlargement / reduction counter 121a. Then, the X-direction enlargement / reduction unit 121B enlarges and outputs until the X-direction output counter 121b reaches a predetermined value (260 in this example) (the right end of the block generated in the preceding process by the above operation) 12 invalid pixels and extra pixels are deleted).

Y方向拡大・縮小部122Bは、Y方向の拡大処理を行う際に、Y方向拡大・縮小カウンタ122aが各ブロックの先頭ラインで当該ブロック画像のY方向のブロック番号に対応するY方向拡大・縮小カウンタ122aの初期値に設定される。例えば、Y方向のブロック番号が1であれば、Y方向拡大・縮小カウンタ122aの初期値は98に設定される。Y方向拡大・縮小部122Bは、ブロック上端よりカウントが開始されるスキップカウンタが所定の値(例では12)になるまで入力画素を無視した後(前段の処理で発生したブロック上端の無効画素12画素は前記の動作により削除される)、Y方向拡大・縮小カウンタ122aにしたがって拡大が行われる。そして、Y方向拡大・縮小部122Bでは、Y方向出力カウンタ122bが所定の値(例では132)になるまで拡大して出力する(前記の動作により前段の処理で発生したブロック画像下端の無効画素12画素および余分な画素が削除される)。   When the Y-direction enlargement / reduction unit 122B performs the Y-direction enlargement process, the Y-direction enlargement / reduction counter 122a performs Y-direction enlargement / reduction corresponding to the block number in the Y direction of the block image on the first line of each block. The initial value of the counter 122a is set. For example, if the block number in the Y direction is 1, the initial value of the Y direction enlargement / reduction counter 122a is set to 98. The Y-direction enlargement / reduction unit 122B ignores the input pixel until the skip counter that starts counting from the upper end of the block reaches a predetermined value (12 in the example) (the invalid pixel 12 at the upper end of the block generated in the previous processing). The pixels are deleted by the above operation), and the enlargement is performed according to the Y direction enlargement / reduction counter 122a. Then, the Y direction enlargement / reduction unit 122B enlarges and outputs until the Y direction output counter 122b reaches a predetermined value (132 in the example) (the invalid pixel at the lower end of the block image generated in the preceding process by the above operation). 12 pixels and extra pixels are deleted).

以上のように、ブロック拡大・縮小部120Bは供給されるブロック画像を拡大するとともに、前段の前フィルタ処理部140のフィルタ処理により生じたブロック画像端部の無効画素と読み出しの都合により発生する余分な画素を削除する。そして、ブロック拡大・縮小部120Bは、各ブロック画像のサイズを同じ大きさにして出力する。そして、ブロック拡大・縮小部120Bから出力されるブロック画像は後フィルタ処理部150に供給される。   As described above, the block enlargement / reduction unit 120B enlarges the supplied block image, and the extra pixels generated due to the ineffective pixels at the end of the block image generated by the filter processing of the preceding filter processing unit 140 and the convenience of reading. Delete the pixels. The block enlargement / reduction unit 120B outputs the block images having the same size. The block image output from the block enlargement / reduction unit 120B is supplied to the post-filter processing unit 150.

図26は、後フィルタ処理部150、後解像度変換部180、及びブロックカット処理部160によるブロック画像の処理について示した説明図である。   FIG. 26 is an explanatory diagram showing block image processing performed by the post-filter processing unit 150, the post-resolution conversion unit 180, and the block cut processing unit 160.

図26(a)は、後フィルタ処理部150に供給されるブロック画像について示した説明図である。図26(b)は、後フィルタ処理部150で後フィルタ処理されたブロック画像について示した説明図である。図26(c)は、後解像度変換部180により解像度変換されたブロック画像について示した説明図である。図26(d)は、ブロックカット処理部160により一部がカット処理されたブロック画像について示した説明図である。   FIG. 26A is an explanatory diagram showing a block image supplied to the post-filter processing unit 150. FIG. 26B is an explanatory diagram showing a block image that has been post-filtered by the post-filter processing unit 150. FIG. 26C is an explanatory diagram showing a block image whose resolution has been converted by the post-resolution conversion unit 180. FIG. 26D is an explanatory diagram showing a block image partially cut by the block cut processing unit 160.

図26(a)、図26(b)に示すように、後フィルタ処理部150は、供給されたブロック画像(ブロック画像のサイズは横260×縦132)について、注目画素を中心に5×5の画素参照を行うフィルタ処理を行う。そして、後フィルタ処理部150は、そのフィルタ処理されたブロック画像を後解像度変換部180に供給する。図26(b)に示すように、後フィルタ処理部150によるブロック画像のフィルタ処理により、処理後のブロック画像には、左端、右端、上端、下端に無効な画素が各2画素発生する。   As shown in FIGS. 26A and 26B, the post-filter processing unit 150 performs 5 × 5 centering on the pixel of interest for the supplied block image (the size of the block image is 260 × 132). Filter processing for referring to the pixels is performed. Then, the post-filter processing unit 150 supplies the filtered block image to the post-resolution conversion unit 180. As shown in FIG. 26B, by the filter processing of the block image by the post-filter processing unit 150, two invalid pixels are generated at the left end, the right end, the upper end, and the lower end in the processed block image.

図26(c)に示すように、後解像度変換部180は、供給されたブロック画像(ブロック画像のサイズは横260×縦132)について、Y方向に2倍に拡大し、拡大さしたブロック画像を、ブロックカット処理部160に供給する。図26(c)に示すように、後解像度変換部180により解像度変換されたブロック画像のサイズは、横260×縦264になる。また、この実施形態では、後解像度変換部180は、ブロック画像について、上述の2倍拡大処理を単純拡大法により行うようにしてもよい。この場合、後解像度変換部180により拡大処理されるブロック画像で、その拡大処理に伴って無効となる画素は発生しない。なお、後解像度変換部180により拡大処理されたブロック画像の上端および下端の無効画素については、前記のY方向の拡大によって引き伸ばされるため、上端および下端で各4画素の無効画素が発生することになる。   As illustrated in FIG. 26C, the post-resolution conversion unit 180 enlarges the supplied block image (the size of the block image is 260 × 132 in the Y direction) twice in the Y direction, and enlarges the block image. Is supplied to the block cut processing unit 160. As shown in FIG. 26C, the size of the block image whose resolution is converted by the post-resolution conversion unit 180 is 260 × 264. In this embodiment, the post-resolution conversion unit 180 may perform the above-described double enlargement process on the block image by a simple enlargement method. In this case, in the block image that is enlarged by the post-resolution conversion unit 180, invalid pixels are not generated along with the enlargement process. Note that the invalid pixels at the upper end and the lower end of the block image enlarged by the post-resolution conversion unit 180 are expanded by the enlargement in the Y direction, so that four invalid pixels are generated at the upper end and the lower end. Become.

図26(d)に示すように、ブロックカット処理部160は、供給されたブロック画像(ブロック画像のサイズは横260×縦264)について、前段の処理で発生したブロック画像端部の無効画素(ここでは、左端及び右端に各2画素、上端及び下端に各4画素)が削除(カット)される。そして、ブロックカット処理部160は、無効画素がカットされたブロック画像(ブロック画像のサイズは横256×縦256)を、ブロック書き出し部130Aに供給する。   As shown in FIG. 26 (d), the block cut processing unit 160, with respect to the supplied block image (the size of the block image is horizontal 260 × vertical 264), invalid pixels (at the end of the block image generated in the previous stage processing) Here, 2 pixels each at the left and right ends and 4 pixels each at the top and bottom are deleted (cut). Then, the block cut processing unit 160 supplies the block image (block image size is 256 × vertical 256) from which invalid pixels are cut to the block writing unit 130A.

ブロック書き出し部130Aは、第1の実施形態、第2の実施形態と同様、供給されたブロック画像をX方向とY方向に一定の間隔(X方向については256、Y方向については256)で画像メモリ60に書き込み、1ページ分の画像データG104を作成する。   As in the first and second embodiments, the block writing unit 130A images the supplied block images at regular intervals in the X and Y directions (256 for the X direction and 256 for the Y direction). Write to the memory 60 to create image data G104 for one page.

(C−3)第3の実施形態の効果
第3の実施形態によれば、以下のような効果を奏することができる。
(C-3) Effects of Third Embodiment According to the third embodiment, the following effects can be achieved.

第3の実施形態の画像処理装置1Bでは、任意倍率の拡大・縮小処理(拡大・縮小処理部100B)の前後で、解像度変換や量子化処理(前解像度変換部170、後解像度変換部180、及び量子化処理部190による処理)を行う場合でも、第2の実施形態と同様に、画像メモリ60から画像データの読み出しや書き出しについては、2つの画像データ(G101、G104)の処理だけで良い。したがって、第3の実施形態の画像形成装置1Bでは、任意倍率の拡大・縮小処理の前後で、解像度変換や量子化処理を行う場合に、第2の実施形態と同様に、画像メモリ60へのアクセス量を低減して処理の高速化及び必要なメモリ容量の低減を実現することができる。言い換えると、第3の実施形態の画像処理装置1Bでは、任意倍率の拡大・縮小処理の前後で、解像度変換や量子化処理を行う場合に、像画像メモリ60で必要となるメモリ容量を小さくでき、処理を高速化できる。   In the image processing apparatus 1B according to the third embodiment, resolution conversion and quantization processing (pre-resolution conversion unit 170, post-resolution conversion unit 180, before and after enlargement / reduction processing (enlargement / reduction processing unit 100B) at an arbitrary magnification, Even when the processing by the quantization processing unit 190 is performed, reading and writing of image data from the image memory 60 may be performed only by processing of two image data (G101 and G104) as in the second embodiment. . Therefore, in the image forming apparatus 1B of the third embodiment, when resolution conversion and quantization processing are performed before and after enlargement / reduction processing at an arbitrary magnification, as in the second embodiment, It is possible to reduce the access amount to increase the processing speed and the required memory capacity. In other words, the image processing apparatus 1B according to the third embodiment can reduce the memory capacity required for the image image memory 60 when performing resolution conversion and quantization processing before and after enlargement / reduction processing at an arbitrary magnification. , Can speed up the process.

また、第3の実施形態の画像処理装置1Bでは、解像度変換処理(前解像度変換部170、後解像度変換部180による処理)により、画像入力部10が出力する画像データの解像度や画像出力部50が期待する画像データの解像度に合わせて処理を行うことが可能である。   Further, in the image processing apparatus 1B of the third embodiment, the resolution of the image data output by the image input unit 10 and the image output unit 50 by resolution conversion processing (processing by the pre-resolution conversion unit 170 and the post-resolution conversion unit 180). Can be processed in accordance with the expected resolution of the image data.

(D)第4の実施形態
以下、本発明による画像処理装置及び方法、並びに、画像形成装置の第4の実施形態を、図面を参照しながら詳述する。
(D) Fourth Embodiment Hereinafter, an image processing apparatus and method and an image forming apparatus according to a fourth embodiment of the present invention will be described in detail with reference to the drawings.

(D−1)第4の実施形態の構成
図27は、本発明の第4実施形態における画像形成装置1Cの機能的構成を示すブロック図であり、上述の図17と同一又は対応する部分に同一又は対応する符号を付している。
(D-1) Configuration of Fourth Embodiment FIG. 27 is a block diagram showing a functional configuration of an image forming apparatus 1C according to the fourth embodiment of the present invention, and is the same as or corresponding to the portion shown in FIG. The same or corresponding symbols are attached.

第4の実施形態では、拡大・縮小処理部100Bが拡大・縮小処理部100Cに置き換わり、サムネイル画像出力部70が追加されている点で第3の実施形態と異なっている。そして、第3の実施形態のブロック拡大・縮小部120Cには、サイズ再変更手段としてのサムネイル縮小部200、及び再変更画像生成手段としてのサムネイル書き出し部210が追加されている点で第3の実施形態と異なっている。   The fourth embodiment is different from the third embodiment in that the enlargement / reduction processing unit 100B is replaced with the enlargement / reduction processing unit 100C and a thumbnail image output unit 70 is added. In the block enlargement / reduction unit 120C of the third embodiment, a thumbnail reduction unit 200 as a size re-changing unit and a thumbnail writing unit 210 as a re-changed image generation unit are added. It is different from the embodiment.

例えば、本発明の画像処理装置を複合機に適用した場合を想定する。そして、当該画像処理装置で、印刷用紙(媒体)に印刷(画像形成)するための画像出力部の他に、ディスプレイ(オペレーションパネルのタッチパネルディスプレイ)等の表示装置を備える場合、スキャンした原稿のサムネイル(縮小画像)を当該ディスプレイに表示出力する構成が必要となる場合がある。この場合、当該画像処理装置ででは、印刷用紙に印刷するために必要な画像データの他に、ディスプレイに表示するためのサムネイルの画像データも生成する必要がある。   For example, a case is assumed where the image processing apparatus of the present invention is applied to a multifunction machine. When the image processing apparatus includes a display device such as a display (touch panel display of an operation panel) in addition to an image output unit for printing (image formation) on printing paper (medium), the thumbnail of the scanned document There may be a case where a configuration for displaying (reduced image) on the display is required. In this case, in the image processing apparatus, in addition to the image data necessary for printing on the printing paper, it is necessary to generate thumbnail image data to be displayed on the display.

そこで、第4の実施形態の画像処理装置1Cは、画像出力部50とは異なる形式の画像データを生成して出力するための構成要素として、サムネイル縮小部200、サムネイル書き出し部210、及びサムネイル画像出力部70を有している。   Therefore, the image processing apparatus 1C according to the fourth embodiment includes a thumbnail reduction unit 200, a thumbnail writing unit 210, and a thumbnail image as components for generating and outputting image data in a format different from that of the image output unit 50. An output unit 70 is provided.

ここでは、例として、画像出力部50は、印刷用紙(媒体)に印刷(画像形成)する画像形成手段として機能するものとする。そして、サムネイル画像出力部70は、サムネイル画像(画像出力部50に供給される画像データG104に対応する縮小画像)をディスプレイに表示出力する表示出力手段として機能するものとして説明する。すなわち、サムネイル画像出力部70では、画像出力部50で出力される画像よりも小さいサイズに縮小された画像が出力されるものとして説明する。   Here, as an example, it is assumed that the image output unit 50 functions as an image forming unit that performs printing (image formation) on printing paper (medium). The thumbnail image output unit 70 will be described as functioning as a display output unit that displays and outputs a thumbnail image (a reduced image corresponding to the image data G104 supplied to the image output unit 50) on a display. That is, description will be made assuming that the thumbnail image output unit 70 outputs an image reduced to a size smaller than the image output by the image output unit 50.

サムネイル縮小部200は、ブロックカット処理部160から供給されるブロック画像についてブロック画像毎にサムネイル用の縮小を行い、縮小を行ったブロック画像をサムネイル書き出し部210に供給する。   The thumbnail reduction unit 200 performs thumbnail reduction for each block image of the block image supplied from the block cut processing unit 160 and supplies the reduced block image to the thumbnail writing unit 210.

サムネイル書き出し部210は、サムネイル縮小部200で縮小されたブロック画像を、画像メモリ60に順次書き込み、1画面分の画像データG201として生成する。   The thumbnail writing unit 210 sequentially writes the block images reduced by the thumbnail reduction unit 200 to the image memory 60 to generate image data G201 for one screen.

サムネイル書き出し部210に入力されるブロック画像は、前段の処理(この実施形態ではブロック処理部230)の動作により、ブロック間で重複する画素がカットされる。また、サムネイル書き出し部210に供給される各ブロック画像の幅と高さは一定となっているので、サムネイル書き出し部210は、X方向とY方向に一定の間隔でブロック画像を画像メモリ60に書き出すことで1ページ分の画像データG201を作成することができる。   In the block image input to the thumbnail writing unit 210, overlapping pixels between blocks are cut by the operation of the preceding stage (in this embodiment, the block processing unit 230). Further, since the width and height of each block image supplied to the thumbnail writing unit 210 are constant, the thumbnail writing unit 210 writes block images to the image memory 60 at regular intervals in the X direction and the Y direction. Thus, image data G201 for one page can be created.

サムネイル画像出力部70としてのディスプレイは、例えば、コピー機や複合機等のオペレーションパネル等に用いられる表示装置であり、サムネイル書き出し部210が書き出した画像データG201を画像メモリ60より読み出し、画像データG201に対応するサムネイル画像を表示出力する。   The display as the thumbnail image output unit 70 is, for example, a display device used for an operation panel or the like of a copier or a multifunction peripheral. The image data G201 written by the thumbnail writing unit 210 is read from the image memory 60, and the image data G201 is read out. A thumbnail image corresponding to is displayed and output.

図28は、サムネイル画像出力部70のディスプレイに表示される画像データG201に基づく画像について示した説明図である。   FIG. 28 is an explanatory diagram showing an image based on the image data G201 displayed on the display of the thumbnail image output unit 70.

なお、ここでは、例えば、ユーザ操作(例えば、画像処理装置1Cが備えるサムネイル画像出力部70としてのディスプレイ等を含むオペレーションパネルに対する操作)に応じて、ブロック拡大・縮小部120Cに設定される画像データG104の倍率を受付けるようにしてもよい。   Here, for example, image data set in the block enlargement / reduction unit 120C according to a user operation (for example, an operation on an operation panel including a display as the thumbnail image output unit 70 provided in the image processing apparatus 1C). You may make it accept the magnification of G104.

図28(a)、図28(b)、図28(c)は、それぞれ、ブロック拡大・縮小部120Cに設定する倍率(例えば、ユーザに指定された倍率)を100%、41%、133%とした場合に、サムネイル画像出力部70に表示される画像データG201の画像について示している。   28 (a), 28 (b), and 28 (c), the magnifications set in the block enlargement / reduction unit 120C (for example, magnifications designated by the user) are 100%, 41%, and 133%, respectively. In this case, the image of the image data G201 displayed on the thumbnail image output unit 70 is shown.

すなわち、サムネイル縮小部200では、入力されるブロック画像を、サムネイル画像出力部70のディスプレイのサイズ(垂直方向及び水平方向の画素数)に応じた解像度に縮小する(通常ディスプレイに表示される画像の解像度は印刷に用いられる画像の解像度より低いため縮小のみ行われる)。サムネイル縮小部200のディスプレイの解像度は、適用するデバイスによって異なるため、サムネイル縮小部200では、任意倍率の縮小を行う必要が生じる。しかし、サムネイル縮小部200が、完全に任意の倍率での縮小を行うことに対応してしまうと、出力するブロック画像のサイズがブロック画像毎に変わったり、前段のブロック拡大縮小部120B同様にブロック毎に拡大・縮小カウンタの初期値等が必要となる等複雑な構成(例えば、ブロック拡大・縮小部120Bと同様の公正)が必要となる。そのため、サムネイル縮小部200では、下記のように、入力されるブロック画像のサイズに基づいて、倍率の分母を決定し、決定した倍率の分母と目標とする倍率(ユーザから設定を受付けた倍率、すなわち、ブロック拡大・縮小部120Cに設定される倍率)より倍率の分子を決定することが好ましい。   That is, the thumbnail reduction unit 200 reduces the input block image to a resolution corresponding to the display size (the number of pixels in the vertical and horizontal directions) of the thumbnail image output unit 70 (the image displayed on the normal display). Since the resolution is lower than the resolution of the image used for printing, only reduction is performed). Since the display resolution of the thumbnail reduction unit 200 varies depending on the device to which it is applied, the thumbnail reduction unit 200 needs to perform reduction at an arbitrary magnification. However, if the thumbnail reduction unit 200 completely supports reduction at an arbitrary magnification, the size of the block image to be output changes for each block image, or a block similar to the block enlargement / reduction unit 120B in the previous stage. A complicated configuration (for example, the same fairness as that of the block enlargement / reduction unit 120B) is required such that the initial value of the enlargement / reduction counter is required every time. Therefore, the thumbnail reduction unit 200 determines the denominator of the magnification based on the size of the input block image as described below, and determines the denominator of the determined magnification and the target magnification (the magnification received from the user, That is, it is preferable to determine the numerator of magnification from the magnification set in the block enlargement / reduction unit 120C.

なお、以下の(66)式〜(69)式において、xbase_t、xratio_tは、それぞれサムネイル縮小部200に適用されるX方向の倍率の分母と分子の値を表している。また、ybase_t、yratio_tは、それぞれサムネイル縮小部200に適用されるY方向の倍率の分母と分子の値を表している。さらに、xscale、yscaleは、それぞれ、サムネイル縮小部200で目標となるX方向の倍率、Y方向の倍率を示している。ここでは、xscale、yscaleに、それぞれサムネイル縮小部200に供給されるブロック画像の解像度(すなわち、画像出力部50に供給される画像データG104の解像度)と、サムネイル画像出力部70のディスプレイの解像度との比率に基づく倍率が適用されるものとする。   In the following formulas (66) to (69), xbase_t and xratio_t represent the denominator and the numerator value of the magnification in the X direction applied to the thumbnail reduction unit 200, respectively. Further, ybase_t and yratio_t represent the denominator and numerator value of the magnification in the Y direction applied to the thumbnail reduction unit 200, respectively. Furthermore, xscale and yscale indicate the magnification in the X direction and the magnification in the Y direction, respectively, which are targets for the thumbnail reduction unit 200. Here, xscale and yscale are respectively the resolution of the block image supplied to the thumbnail reduction unit 200 (that is, the resolution of the image data G104 supplied to the image output unit 50), and the display resolution of the thumbnail image output unit 70. A magnification based on the ratio of

(サムネイル縮小部200のX方向の倍率分母xbase_t)=
(サムネイル縮小部200に入力されるブロック幅) …(66)
(サムネイル縮小部200のX方向の倍率分子xratio_t)=
(サムネイル縮小部200のX方向の倍率分母xbase_t)
×(目標とするX方向の倍率xscale) …(67)
(サムネイル縮小部200のY方向の倍率分母ybase_t)=
(サムネイル縮小部200に入力されるブロック高さ) …(68)
(サムネイル縮小部200のY方向の倍率分子yratio_t)=
(サムネイル縮小部200のY方向の倍率分母ybase_t)
×(目標とするY方向の倍率yscale) …(69)
サムネイル縮小部200では、上記の倍率を適用することで、ブロック毎の拡大・縮小カウンタの初期値は全てのブロックで一定となる。したがって、サムネイル縮小部200は、X方向の縮小カウンタとY方向の縮小カウンタのみの簡易な構成でX方向とY方向について各々任意倍率に近い縮小処理を行うことができる(サムネイル画像は、ユーザに対して補助的な表示を行うのが目的であり、前記の表示装置が期待する解像度に近い解像度に縮小できれば支障がない)。
(X-direction magnification denominator xbase_t of thumbnail reduction unit 200) =
(Block width input to thumbnail reduction unit 200) (66)
(X-direction magnification molecule xratio_t of thumbnail reduction unit 200) =
(X-direction magnification denominator xbase_t of thumbnail reduction unit 200)
X (target magnification xscale in X direction) (67)
(Y-direction magnification denominator ybase_t of thumbnail reduction unit 200) =
(Block height input to thumbnail reduction unit 200) (68)
(Y-direction magnification molecule yratio_t of thumbnail reduction unit 200) =
(Y-direction magnification denominator ybase_t of thumbnail reduction unit 200)
× (Target Y-direction magnification yscale) (69)
In the thumbnail reduction unit 200, by applying the magnification described above, the initial value of the enlargement / reduction counter for each block becomes constant for all blocks. Therefore, the thumbnail reduction unit 200 can perform reduction processing close to arbitrary magnifications in the X direction and the Y direction with a simple configuration including only the reduction counter in the X direction and the reduction counter in the Y direction. The purpose is to provide auxiliary display, and there is no problem if the display device can be reduced to a resolution close to that expected by the display device).

(D−2)第4の実施形態の動作
以下では、第4の実施形態の画像形成装置1Cの動作について、第3の実施形態の動作との差異を中心に説明する。第4の実施形態では、上述の通り、第3の実施形態の画像形成装置1Bに、サムネイル画像の処理構成(サムネイル縮小部200、サムネイル書き出し部210、及びサムネイル画像出力部70)が追加されただけであるので、これらの構成要素の動作についてのみ説明する。
(D-2) Operation of Fourth Embodiment Hereinafter, the operation of the image forming apparatus 1 </ b> C of the fourth embodiment will be described focusing on the difference from the operation of the third embodiment. In the fourth embodiment, as described above, the thumbnail image processing configuration (the thumbnail reduction unit 200, the thumbnail writing unit 210, and the thumbnail image output unit 70) is added to the image forming apparatus 1B of the third embodiment. Therefore, only the operation of these components will be described.

まず、サムネイル縮小部200で行われるX方向とY方向の縮小処理の詳細について、図29のフローチャートを用いて説明する。   First, details of the reduction processing in the X direction and the Y direction performed by the thumbnail reduction unit 200 will be described with reference to the flowchart of FIG.

図29のフローチャートは、サムネイル縮小部200が行うブロック画像の1ライン分のデータについてのX方向の縮小処理を説明するものである。なお、図29において、xcnt_tは、サムネイル縮小部200の処理で用いられる縮小カウンタである。   The flowchart in FIG. 29 illustrates the X-direction reduction processing for the data for one line of the block image performed by the thumbnail reduction unit 200. In FIG. 29, xcnt_t is a reduction counter used in the processing of the thumbnail reduction unit 200.

まず、ステップS701では、サムネイル縮小部200は、ライン先頭で縮小カウンタxcnt_tを0にリセットする。   First, in step S701, the thumbnail reduction unit 200 resets the reduction counter xcnt_t to 0 at the head of the line.

ステップS702で、サムネイル縮小部200は、縮小カウンタxcnt_tの値が倍率の分子(xratio_t)の値より小さいか判定を行い、小さければステップS703へ進み画素の出力を行い、それ以外の場合は画素の出力を行わずにステップS705へ進む。   In step S702, the thumbnail reduction unit 200 determines whether the value of the reduction counter xcnt_t is smaller than the value of the numerator (xratio_t) of the magnification. If it is smaller, the process proceeds to step S703 and outputs the pixel. The process proceeds to step S705 without performing output.

ステップS703では、サムネイル縮小部200は、画素の出力を行い、縮小カウンタxcnt_tに倍率の分母値xbase_tを加算し、ステップS704へ進む。サムネイル縮小部200が出力する画素(画素値)は、例えば、単純縮小法であれば現画素となる。   In step S703, the thumbnail reduction unit 200 outputs a pixel, adds the denominator value xbase_t of the magnification to the reduction counter xcnt_t, and proceeds to step S704. For example, the pixel (pixel value) output from the thumbnail reduction unit 200 is the current pixel in the simple reduction method.

ステップS704では、サムネイル縮小部200は、上述のSステップ703で更新された縮小カウンタxcnt_tの値が倍率の分子の値xbase_t以上であるか判定を行い、xbase_t以上であればステップS705(入力画素位置の更新)へ進み、それ以外の場合はステップS706へ進む。   In step S704, the thumbnail reduction unit 200 determines whether the value of the reduction counter xcnt_t updated in step S703 described above is greater than or equal to the numerator value xbase_t of the magnification. Update), otherwise the process proceeds to step S706.

ステップS705では、サムネイル縮小部200は、縮小カウンタxcnt_tの値から倍率の分子xrasio_tの値を減算し、入力画素位置を更新し(現画素の右隣りの画素を次の現画素とし)、ステップS706へ進む。   In step S705, the thumbnail reduction unit 200 subtracts the value of the numerator xrasio_t of the magnification from the value of the reduction counter xcnt_t, updates the input pixel position (the pixel immediately adjacent to the current pixel is set as the next current pixel), and step S706. Proceed to

ステップS706では、サムネイル縮小部200は、1ライン終了したか判定(処理中のラインの全ての画素を出力したか否かの判定)を行い、1ライン終了した場合は1ライン処理を終了し(次の入力画素ラインの処理を行う)、達していない場合は上述のステップS702に戻る。   In step S706, the thumbnail reduction unit 200 determines whether one line has been completed (determines whether all the pixels in the line being processed have been output). If one line has been completed, the one-line processing ends ( The process of the next input pixel line is performed). If not reached, the process returns to step S702 described above.

以上のように、サムネイル縮小部200は、1つのブロック画像の全てのX方向のラインについて縮小処理を行う。サムネイル縮小部200は、同様の処理を各ブロック画像のX方向及びY方向について行い、各ブロック画像を縮小して出力することになる。   As described above, the thumbnail reduction unit 200 performs the reduction process for all the X-direction lines of one block image. The thumbnail reduction unit 200 performs the same processing in the X direction and the Y direction of each block image, and reduces and outputs each block image.

次に、ブロック拡大・縮小部120Cの全体の具体的動作について説明する。   Next, the specific operation of the entire block enlargement / reduction unit 120C will be described.

以下の動作説明では、第3の実施形態と同様に、幅3840ピクセル、高さ5120ピクセルの画像データG101(横300DPI×縦600DPI)を133%の倍率で拡大する場合と41%の倍率で縮小する場合を例に挙げ説明する。   In the following description of the operation, as in the third embodiment, image data G101 (width 300 DPI × length 600 DPI) having a width of 3840 pixels and a height of 5120 pixels is enlarged at a magnification of 133% and reduced at a magnification of 41%. An example of the case will be described.

なお、以下では、また、xbase_t、xratio_tは、それぞれX方向の倍率の分母と分子の値を表すものとする。また、ybase_t、yratio_tは、それぞれY方向の倍率の分母と分子の値を表すものとする。   In the following description, xbase_t and xratio_t represent the denominator and the numerator value of the magnification in the X direction, respectively. Further, ybase_t and yratio_t represent the denominator and the numerator value of the magnification in the Y direction, respectively.

また、以下の動作説明では、第3の実施形態と同様、前フィルタ処理部140では注目画素を中心に25×25の画素参照を行うフィルタ処理が行われ、後フィルタ処理部150では注目画素を中心に5×5の画素参照を行うフィルタ処理が行われ、前解像度変換部170ではX方向の解像度を2倍にする処理が行われ、後解像度変換部180ではY方向の解像度を2倍にする処理が行われ、量子化処理部190では画素当たり8bitの画像データを画素当たり1bitの画像データに変換する処理が行われるもとする。また、以下の動作説明では、前フィルタ処理部140、ブロック拡大・縮小部120B、後フィルタ処理部150、後解像度変換処理部330は、それぞれ、288、264、262、262画素分の画像データ(画素値)を保持するラインメモリを備え、各処理部における出力可能なブロック幅は前記の値が上限であるものとする。   In the following description of the operation, as in the third embodiment, the pre-filter processing unit 140 performs a filter process for referring to 25 × 25 pixels around the target pixel, and the post-filter processing unit 150 selects the target pixel. Filter processing for referring to a 5 × 5 pixel is performed at the center, the pre-resolution conversion unit 170 performs processing for doubling the X-direction resolution, and the post-resolution conversion unit 180 doubles the Y-direction resolution. It is assumed that the quantization processing unit 190 performs a process of converting 8-bit image data per pixel into 1-bit image data per pixel. In the following description of the operation, the pre-filter processing unit 140, the block enlargement / reduction unit 120B, the post-filter processing unit 150, and the post-resolution conversion processing unit 330 are image data for 288, 264, 262, and 262 pixels, respectively ( It is assumed that a line memory that holds (pixel value) is provided, and that the block width that can be output in each processing unit is the above value.

なお、拡大・縮小処理部100Cのサムネイル縮小部200、サムネイル書き出し部210以外の処理部に必要なパラメータの算出や動作については、第3の実施形態と同様であるので説明を省略する。   Note that the calculation and operation of parameters necessary for the processing units other than the thumbnail reduction unit 200 and the thumbnail writing unit 210 of the enlargement / reduction processing unit 100C are the same as those in the third embodiment, and a description thereof will be omitted.

また、以下では、拡大・縮小処理部100Cのサムネイル縮小部200およびサムネイル書き出し部210の動作について、サムネイル画像出力部70の期待する画像データの解像度(ディスプレイの仕様としての解像度)が横60DPI、縦60DPIであった場合を例に挙げ説明する。   In the following, regarding the operations of the thumbnail reduction unit 200 and the thumbnail writing unit 210 of the enlargement / reduction processing unit 100C, the resolution of the image data expected by the thumbnail image output unit 70 (resolution as the display specifications) is 60 DPI horizontally. A case where it is 60 DPI will be described as an example.

ブロック拡大・縮小部120Cで133%の拡大処理が行われる場合、サムネイル縮小部200に供給されるブロック画像サイズ(ブロックカット処理部160から出力されるブロック画像のサイズ)は、横256×縦256(上述の図22(a)に記載の通り)となる。また、ブロック拡大・縮小部120Cで41%の縮小処理が行われる場合、サムネイル縮小部200に供給されるブロック画像サイズは、横96×縦256(上述の図22(b)に記載の通り)となる。   When the enlargement process of 133% is performed in the block enlargement / reduction unit 120C, the block image size supplied to the thumbnail reduction unit 200 (the size of the block image output from the block cut processing unit 160) is 256 × 256 in length. (As described in FIG. 22A). Further, when 41% reduction processing is performed in the block enlargement / reduction unit 120C, the block image size supplied to the thumbnail reduction unit 200 is 96 × 256 (as described in FIG. 22B above). It becomes.

ブロック拡大・縮小部120Cで133%の拡大処理が行われる場合、サムネイル縮小部200で適用される倍率の分母は、X方向の倍率の分母xbase_tが256、Y方向の倍率の分母ybase_tが256となる。また、ブロック拡大・縮小部120Cで41%の縮小処理が行われる場合、サムネイル縮小部200で適用される倍率の分母は、X方向の倍率の分母xbase_tが96、Y方向の倍率の分母ybase_tが256となる。   When the enlargement process of 133% is performed by the block enlargement / reduction unit 120C, the denominator of the magnification applied by the thumbnail reduction unit 200 is 256, the denominator xbase_t of the magnification in the X direction, and 256 the denominator ybase_t of the magnification in the Y direction. Become. In addition, when 41% reduction processing is performed in the block enlargement / reduction unit 120C, the denominator of the magnification applied by the thumbnail reduction unit 200 is 96 in the denominator xbase_t in the X direction and ybase_t in the Y direction. 256.

ここでは、上述の通りサムネイル縮小部200に供給されるブロック画像の解像度は横600DPI、縦1200DPIである。したがって、この場合、サムネイル縮小部200で行う縮小のX方向の目標倍率xscaleは0.1、Y方向の目標倍率yscaleは0.05となる。   Here, as described above, the resolution of the block image supplied to the thumbnail reduction unit 200 is horizontal 600 DPI and vertical 1200 DPI. Therefore, in this case, the target magnification xscale in the X direction for reduction performed by the thumbnail reduction unit 200 is 0.1, and the target magnification yscale in the Y direction is 0.05.

したがってここでは、ブロック拡大・縮小部120Cで133%の拡大処理が行われる場合、サムネイル縮小部200で適用されるX方向の倍率の分子xratio_tは256×0.1=25、Y方向の倍率の分子yratio_tは256×0.05=12となる。また、ブロック拡大・縮小部120Cで41%の縮小処理が行われる場合、X方向の倍率の分子xratio_tは96×0.1=9、Y方向の倍率の分子yratio_tは256×0.05=12となる。   Therefore, here, when the enlargement process of 133% is performed by the block enlargement / reduction unit 120C, the numerator xratio_t of the magnification in the X direction applied by the thumbnail reduction unit 200 is 256 × 0.1 = 25, and the magnification in the Y direction is The molecule yratio_t is 256 × 0.05 = 12. Further, when 41% reduction processing is performed in the block enlargement / reduction unit 120C, the numerator xratio_t with the magnification in the X direction is 96 × 0.1 = 9, and the numerator ratio_t with the magnification in the Y direction is 256 × 0.05 = 12. It becomes.

したがって、ブロック拡大・縮小部120Cで133%の拡大処理が行われる場合、サムネイル縮小部200で行うX方向の縮小の倍率の値(xratio_t/xbase_t)が0.09765625、Y方向の縮小の倍率の値(yratio_t/ybase_t)が0.046875となる。また、ブロック拡大・縮小部120Cで41%の縮小処理が行われる場合、サムネイル縮小部200で行うX方向の縮小の倍率の値(xratio_t/xbase_t)が0.09375、Y方向の縮小の倍率の値(yratio_t/ybase_t)が0.046875となる。   Accordingly, when the enlargement process of 133% is performed in the block enlargement / reduction unit 120C, the value of the reduction factor (xratio_t / xbase_t) in the X direction performed by the thumbnail reduction unit 200 is 0.09765625, and the reduction factor in the Y direction. The value (yratio_t / ybase_t) is 0.046875. In addition, when 41% reduction processing is performed in the block enlargement / reduction unit 120C, the reduction ratio value (xratio_t / xbase_t) in the X direction performed by the thumbnail reduction unit 200 is 0.09375, and the reduction ratio in the Y direction is The value (yratio_t / ybase_t) is 0.046875.

したがって、ブロック拡大・縮小部120Cで133%の拡大処理が行われる場合、サムネイル縮小部200が出力するブロック画像サイズは、横25×縦12となる。   Accordingly, when the enlargement process of 133% is performed in the block enlargement / reduction unit 120C, the block image size output by the thumbnail reduction unit 200 is 25 × 12.

また、ブロック拡大・縮小部120Cで41%の縮小処理が行われる場合、サムネイル縮小部200が出力するブロック画像サイズは、横9×縦12となる。 Further, when 41% reduction processing is performed in the block enlargement / reduction unit 120C, the block image size output by the thumbnail reduction unit 200 is 9 × 12 in width.

そして、サムネイル縮小部200が出力するブロック画像が、サムネイル書き出し部210に供給される。   Then, the block image output by the thumbnail reduction unit 200 is supplied to the thumbnail writing unit 210.

ブロック拡大・縮小部120Cで133%の拡大処理が行われる場合、サムネイル書き出し部210は、X方向に25、Y方向に12の一定の間隔で画素値(各ブロック画像の画素値)をメモリ60に書き出し、1ページ分のサムネイル表示用の画像データG201を作成する。また、ブロック拡大・縮小部120Cで41%の縮小処理が行われる場合、サムネイル書き出し部210は、X方向に9、Y方向に12の一定の間隔で画素値(各ブロック画像の画素値)をメモリ60に書き出し、1ページ分のサムネイル表示用の画像データG201を作成する。   When the enlargement process of 133% is performed by the block enlargement / reduction unit 120C, the thumbnail writing unit 210 stores the pixel values (pixel values of each block image) at a constant interval of 25 in the X direction and 12 in the Y direction. The image data G201 for displaying thumbnails for one page is created. When 41% reduction processing is performed by the block enlargement / reduction unit 120C, the thumbnail writing unit 210 sets pixel values (pixel values of each block image) at regular intervals of 9 in the X direction and 12 in the Y direction. Write to the memory 60 and create image data G201 for thumbnail display for one page.

以上の処理により、ブロック拡大・縮小部120Cで133%の拡大処理が行われる場合、サムネイル表示用の画像データG201の画像は、横998×縦639の画像となる。また、ブロック拡大・縮小部120Cで41%の縮小処理が行われる場合、サムネイル表示用の画像データG201の画像は、横296×縦197の画像となる。   With the above processing, when the enlargement process of 133% is performed in the block enlargement / reduction unit 120C, the image of the thumbnail display image data G201 is an image of horizontal 998 × height 639. Further, when 41% reduction processing is performed in the block enlargement / reduction unit 120C, the image of the thumbnail display image data G201 is a horizontal 296 × vertical 197 image.

(D−3)第4の実施形態の効果
第4の実施形態によれば、以下のような効果を奏することができる。
(D-3) Effects of the fourth embodiment According to the fourth embodiment, the following effects can be achieved.

第4の実施形態の画像処理装置1Cでは、印刷用の画像データとサムネイル用の画像データなど複数の異なる解像度の画像データを作成する場合においても、各々を作成するためだけにメモリ60から、画像データを読み込んで処理する必要がない。   In the image processing apparatus 1C according to the fourth embodiment, even when image data having a plurality of different resolutions such as image data for printing and image data for thumbnails are generated, the image is stored from the memory 60 only for generating each. There is no need to read and process data.

例えば、第1〜第3の実施形態において、画像出力部50とは別に、画像出力部50が期待する画像データと解像度等が異なる画像データを期待する画像出力部(例えば、サムネイル画像出力部70)があった場合、各ブロック画像の処理部は、その解像度等が異なる画像出力部が期待する画像データに係るブロック画像についても処理する必要がある。しかし、第4の実施形態の画像処理装置1Cでは、ブロックカット処理部160までの段は、画像出力部50とサムネイル画像出力部70とで共有しているため、それ以後の段の処理部(サムネイル縮小部200、サムネイル書き出し部210)のみを備えることにより、サムネイル画像出力部70が期待する解像度の画像データを生成することができる。   For example, in the first to third embodiments, in addition to the image output unit 50, an image output unit that expects image data whose resolution is different from the image data expected by the image output unit 50 (for example, the thumbnail image output unit 70). ), It is necessary for the processing unit of each block image to process the block image related to the image data expected by the image output unit having a different resolution or the like. However, in the image processing apparatus 1C according to the fourth embodiment, the steps up to the block cut processing unit 160 are shared by the image output unit 50 and the thumbnail image output unit 70, and therefore the processing units ( By providing only the thumbnail reduction unit 200 and the thumbnail writing unit 210), it is possible to generate image data having a resolution expected by the thumbnail image output unit 70.

したがって、画像処理装置1Cでは、複数の異なる解像度の画像データを作成する場合において、画像メモリ60で必要となるメモリ容量の低減や、処理の高速化を実現することができる。   Therefore, in the image processing apparatus 1C, when creating image data having a plurality of different resolutions, it is possible to reduce the memory capacity required for the image memory 60 and increase the processing speed.

また、画像処理装置1Cにおいて、作成されるサムネイル用の画像データは、ユーザの倍率指定等の処理結果が反映されたデータとなるので、ユーザが取得する印刷等の内容を適切に表示出力することができる。   Further, in the image processing apparatus 1C, the created thumbnail image data is data that reflects the processing result such as the user's magnification designation, so that the contents such as printing acquired by the user are appropriately displayed and output. Can do.

(D)他の実施形態
本発明は、上記の各実施形態に限定されるものではなく、以下に例示するような変形実施形態も挙げることができる。
(D) Other Embodiments The present invention is not limited to the above-described embodiments, and may include modified embodiments as exemplified below.

(D−1)上記の各実施形態の画像形成装置としては、例えば、コピー機、複合機、FAX等の画像データに対して任意倍率を含む画像処理を行う装置に適用可能である。 (D-1) The image forming apparatus of each of the embodiments described above can be applied to an apparatus that performs image processing including arbitrary magnification on image data, such as a copier, a multifunction peripheral, and a FAX.

また、本発明の画像処理装置で処理した画像を出力する手段は、印刷等の画像形成に限定されず、ディスプレイに表示出力したり、電子データとして外部装置(例えばホストPC等)や記録媒体(例えば、CD−ROMやHDD等)に記録するようにしてもよい。例えば、上記の各実施形態の画像形成装置に搭載された画像処理装置は、画像形成装置に限定されず、他の画像処理を行う装置(例えば、デジタルカメラ、スキャナ、デジタルビデオレコーダ等)に適用するようにしてもよい。   The means for outputting an image processed by the image processing apparatus of the present invention is not limited to image formation such as printing, but is displayed on a display or output as external data (for example, a host PC) or a recording medium (electronic data). For example, it may be recorded on a CD-ROM or HDD. For example, the image processing apparatus mounted on the image forming apparatus of each of the above embodiments is not limited to the image forming apparatus, and is applied to apparatuses that perform other image processing (for example, digital cameras, scanners, digital video recorders, etc.). You may make it do.

(D−2)上記の各実施形態の画像形成装置(画像処理装置)では、画像をブロック画像に分割する際に、X方向及びY方向について拡大・縮小処理を行っているが、いずれか一方の方向(X方向又はY方向)に対してのみ拡大・縮小処理を行うようにしてもよい。その場合、当該画像形成装置(画像処理装置)では、拡大・縮小処理を行う方向(X方向又はY方向)についてのみブロック画像単位の分割を行うようにしてもよい。(D−3)上記の各実施形態の画像形成装置(画像処理装置)において、前フィルタ処理部及び又は後フィルタ処理部については、省略するようにしてもよい。 (D-2) In the image forming apparatus (image processing apparatus) of each of the above embodiments, when the image is divided into block images, the enlargement / reduction process is performed in the X direction and the Y direction. The enlargement / reduction process may be performed only in the direction (X direction or Y direction). In this case, the image forming apparatus (image processing apparatus) may perform block image unit division only in the direction (X direction or Y direction) in which the enlargement / reduction process is performed. (D-3) In the image forming apparatus (image processing apparatus) of each of the above embodiments, the pre-filter processing unit and / or the post-filter processing unit may be omitted.

(D−3)第3の実施形態では、前解像度変換部170、後フィルタ処理部150、及び量子化処理部190を有しているが、これらのうち一部を省略するようにしてもよい。 (D-3) In the third embodiment, the pre-resolution conversion unit 170, the post-filter processing unit 150, and the quantization processing unit 190 are included, but some of them may be omitted. .

1…画像形成装置、10…画像入力部、20…前フィルタ処理部、100…拡大・縮小処理部、110…ブロック読み出し部、120…ブロック拡大・縮小部、121…X方向拡大・縮小部、121a…X方向拡大・縮小カウンタ、121b…X方向出力カウンタ、122…Y方向拡大・縮小部、122a…Y方向拡大・縮小カウンタ、122b…Y方向出力カウンタ、130…ブロック書き出し部、30…後フィルタ処理部、50…画像出力部、60…画像メモリ。   DESCRIPTION OF SYMBOLS 1 ... Image forming apparatus, 10 ... Image input part, 20 ... Pre filter process part, 100 ... Enlargement / reduction process part, 110 ... Block reading part, 120 ... Block enlargement / reduction part, 121 ... X direction enlargement / reduction part, 121a ... X direction enlargement / reduction counter, 121b ... X direction output counter, 122 ... Y direction enlargement / reduction unit, 122a ... Y direction enlargement / reduction counter, 122b ... Y direction output counter, 130 ... block writing unit, 30 ... after Filter processing unit, 50... Image output unit, 60.

Claims (27)

入力画像から、複数のブロック画像を抽出して、順次読み出すブロック画像読み出し手段と、
前記ブロック画像読み出し手段が読み出したブロック画像のそれぞれについて、所定の倍率でサイズ変更処理を行うサイズ変更手段と、
前記サイズ変更手段でサイズ変更が行われたブロック画像に基づいて、前記入力画像を前記所定の倍率でサイズ変更処理したサイズ変更画像を生成するサイズ変更画像生成手段とを有し、
前記サイズ変更手段は、ブロック画像を構成するラインごとに、サイズ変更処理を行い、
前記サイズ変更手段は、サイズ変更処理前のブロック画像のラインを構成する画素の位置と、サイズ変更処理後のブロック画像のラインを構成する画素の位置との位置関係を管理するサイズ変更カウンタを用いて、ラインごとのサイズ変更処理を行う
ことを特徴とする画像処理装置。
A block image reading means for extracting a plurality of block images from the input image and sequentially reading them;
For each block image read by the block image reading means, a size changing means for performing a size changing process at a predetermined magnification;
Resized image generating means for generating a resized image obtained by resizing the input image at the predetermined magnification based on the block image whose size has been changed by the size changing means ;
The size changing means performs a size changing process for each line constituting the block image,
The size changing means uses a size change counter that manages the positional relationship between the positions of the pixels constituting the line of the block image before the size changing process and the positions of the pixels constituting the line of the block image after the size changing process. An image processing apparatus that performs size change processing for each line .
前記サイズ変更手段は、ブロック画像ごとに前記サイズ変更カウンタの初期値を求め、各ブロックを構成するラインについてサイズ変更処理を行う場合、各ラインの先頭の処理時に前記サイズ変更カウンタの値を、当該ブロックに係る初期値にリセットすることを特徴とする請求項に記載の画像処理装置。 The size changing means obtains an initial value of the size change counter for each block image, and when performing the size change processing for the lines constituting each block, the size change counter value is The image processing apparatus according to claim 1 , wherein the image processing apparatus is reset to an initial value relating to a block. 当該画像処理装置で処理される各ブロック画像のサイズを管理するものであって、前記サイズ変更手段による変換処理後のブロック画像のサイズが、前記サイズ変更手段の処理上限を超えない範囲となるように、前記ブロック画像読み出し手段が読み出すブロック画像のサイズを決定するブロック管理手段をさらに備えることを特徴とする請求項に記載の画像処理装置。 Manages the size of each block image processed by the image processing apparatus, so that the size of the block image after the conversion processing by the size changing means is within a range not exceeding the processing upper limit of the size changing means. The image processing apparatus according to claim 2 , further comprising a block management unit that determines a size of a block image to be read by the block image reading unit. 前記ブロック画像読み出し手段が読み出すブロック画像のそれぞれには、当該ブロック画像と隣接するブロック画像と間で重複する領域が存在し、
前記サイズ変更画像生成手段は、サイズ変更処理後の各ブロック画像について無効部分の出力を除外する処理を行うことを特徴とする請求項のいずれかに記載の画像処理装置。
Each of the block images read by the block image reading means has an overlapping area between the block image and an adjacent block image,
The image processing apparatus according to any one of claims 1 to 3 , wherein the size-changed image generation unit performs a process of excluding an invalid portion output for each block image after the size change process.
前記ブロック画像読み出し手段に供給される入力画像について、前記ブロック画像読み出し手段の処理前に、前フィルタ処理を行う前フィルタ処理手段と、
前記サイズ変更画像生成手段が生成したサイズ変更画像について、後フィルタ処理を行う後フィルタ処理手段と
をさらに有することを特徴とする請求項1〜のいずれかに記載の画像処理装置。
For the input image supplied to the block image reading unit, a pre-filter processing unit that performs a pre-filter process before the processing of the block image reading unit;
The image processing apparatus according to any one of claims 1 to 4, wherein the resized image that the resized image generating means has generated, further comprising a filter processing unit after performing the post-filtering.
前記ブロック画像読み出し手段により読み出されたブロック画像について、フィルタ処理対象の領域の周辺画素の参照が必要な前フィルタ処理を行う前フィルタ処理手段と、
前記サイズ変更手段がサイズ変更処理を行ったブロック画像のそれぞれについて、フィルタ処理対象の領域の周辺画素の参照が必要な後フィルタ処理を行う後フィルタ処理手段と
有することを特徴とする請求項に記載の画像処理装置。
For the block image read by the block image reading means, pre-filter processing means for performing pre-filter processing that requires reference to peripheral pixels in the region to be filtered,
For each block image the size changing means makes a resizing process, to claim 1, characterized in that it comprises a filtering means after the reference of the peripheral pixel in the region of the filter processing target to filter after required The image processing apparatus described.
前記ブロック画像読み出し手段が読み出すブロック画像のそれぞれには、当該ブロック画像と隣接するブロック画像との間で重複する領域が存在し、
前記サイズ変更画像生成手段は、サイズ変更処理後の各ブロック画像について、隣接するブロック画像と重複する第1の無効領域の出力を除外する処理を行い、
前記後フィルタ処理手段の処理後のブロック画像について、隣接するブロック画像と重複する第2の無効領域の出力を除外するブロックカット手段をさらに備える
ことを特徴とする請求項に記載の画像処理装置。
Each of the block images read by the block image reading means has an overlapping area between the block image and an adjacent block image,
The size-changed image generation means performs a process of excluding the output of the first invalid area that overlaps with an adjacent block image for each block image after the size change process,
The image processing apparatus according to claim 6 , further comprising: a block cut unit that excludes an output of a second invalid area that overlaps an adjacent block image with respect to a block image that has been processed by the post filter processing unit. .
当該画像処理装置で処理される各ブロック画像のサイズを管理するものであって、前記前フィルタ処理手段に供給されるブロック画像のサイズ、前記サイズ変更手段による変換処理後のブロック画像のサイズ、前記後フィルタ処理手段に供給されるブロック画像のサイズ、及び前記ブロックカット手段に供給されるブロック画像のサイズが、それぞれの処理に係る処理上限を超えない範囲となるように、前記ブロック画像読み出し手段が読み出すブロック画像のサイズを決定するブロック管理手段をさらに備えることを特徴とする請求項に記載の画像処理装置。 Managing the size of each block image processed by the image processing apparatus, the size of the block image supplied to the pre-filter processing means, the size of the block image after the conversion processing by the size changing means, The block image reading means is arranged so that the size of the block image supplied to the post-filter processing means and the size of the block image supplied to the block cut means are within a range not exceeding the processing upper limit related to each processing. The image processing apparatus according to claim 7 , further comprising a block management unit that determines a size of a block image to be read. 前記サイズ変更手段よりも前段、及び又は、前記サイズ変更手段よりも後段で、ブロック画像の解像度変換を行う解像度変換手段をさらに有することを特徴とする請求項1に記載の画像処理装置。   The image processing apparatus according to claim 1, further comprising a resolution conversion unit that performs resolution conversion of a block image before the size change unit and / or after the size change unit. 前記サイズ変更画像生成手段に供給されるブロック画像に対して、量子化処理を行う量子化処理部をさらに備えることを特徴とする請求項に記載の画像処理装置。 The image processing apparatus according to claim 9 , further comprising a quantization processing unit that performs a quantization process on the block image supplied to the size-changed image generation unit. 前記サイズ変更手段よりも後段で、ブロック画像のサイズを再度変更するサイズ再変更処理を行うサイズ再変更手段と、
前記サイズ再変更手段でサイズ再変更処理が施されたブロック画像に基づいて、前記サイズ変更画像と異なるサイズのサイズ再変更画像を生成するサイズ再変更画像生成手段と をさらに備えることを特徴とする請求項又は10に記載の画像処理装置。
A size re-changing unit for performing a size re-changing process for changing the size of the block image again at a later stage than the size changing unit;
Resize image generating means for generating a resize image having a different size from the resize image based on the block image subjected to the resize process by the resize means, further comprising: The image processing apparatus according to claim 9 or 10 .
前記サイズ再変更手段は、ブロック画像の縮小処理を行うことを特徴とする請求項11に記載の画像処理装置。 The image processing apparatus according to claim 11 , wherein the resizing unit performs a block image reduction process. 画像処理装置が行う画像処理方法において、
ブロック画像読み出し手段、サイズ変更手段、サイズ変更画像生成手段を備え、
前記ブロック画像読み出し手段は、入力画像から、複数のブロック画像を抽出して、順次読み出し、
前記サイズ変更手段は、前記ブロック画像読み出し手段が読み出したブロック画像のそれぞれについて、所定の倍率でサイズ変更処理を行い、
前記サイズ変更画像生成手段は、前記サイズ変更手段でサイズ変更が行われたブロック画像に基づいて、前記入力画像を前記所定の倍率でサイズ変更処理したサイズ変更画像を生成し、
前記サイズ変更手段は、ブロック画像を構成するラインごとに、サイズ変更処理を行い、
前記サイズ変更手段は、サイズ変更処理前のブロック画像のラインを構成する画素の位置と、サイズ変更処理後のブロック画像のラインを構成する画素の位置との位置関係を管理するサイズ変更カウンタを用いて、ラインごとのサイズ変更処理を行う
ことを特徴とする画像処理方法。
In the image processing method performed by the image processing apparatus,
A block image reading unit, a size changing unit, and a size-changing image generating unit;
The block image reading means extracts a plurality of block images from the input image, sequentially reads them,
The size changing means performs a size changing process at a predetermined magnification for each of the block images read by the block image reading means,
The size-changed image generation unit generates a size-changed image obtained by resizing the input image at the predetermined magnification based on the block image whose size has been changed by the size-changing unit .
The size changing means performs a size changing process for each line constituting the block image,
The size changing means uses a size change counter that manages the positional relationship between the positions of the pixels constituting the line of the block image before the size changing process and the positions of the pixels constituting the line of the block image after the size changing process. An image processing method comprising performing a size change process for each line .
入力画像を処理する画像処理装置と、前記画像処理装置が処理した画像を媒体に形成する画像形成手段とを備える画像形成装置において、
前記画像処理装置は、
入力画像から、複数のブロック画像を抽出して、順次読み出すブロック画像読み出し手段と、
前記ブロック画像読み出し手段が読み出したブロック画像のそれぞれについて、所定の倍率でサイズ変更処理を行うサイズ変更手段と、
前記サイズ変更手段でサイズ変更が行われたブロック画像に基づいて、前記入力画像を前記所定の倍率でサイズ変更処理したサイズ変更画像を生成するサイズ変更画像生成手段とを有し、
前記サイズ変更手段は、ブロック画像を構成するラインごとに、サイズ変更処理を行い、
前記サイズ変更手段は、サイズ変更処理前のブロック画像のラインを構成する画素の位置と、サイズ変更処理後のブロック画像のラインを構成する画素の位置との位置関係を管理するサイズ変更カウンタを用いて、ラインごとのサイズ変更処理を行う
ことを特徴とする画像形成装置。
An image forming apparatus comprising: an image processing apparatus that processes an input image; and an image forming unit that forms an image processed by the image processing apparatus on a medium.
The image processing apparatus includes:
A block image reading means for extracting a plurality of block images from the input image and sequentially reading them;
For each block image read by the block image reading means, a size changing means for performing a size changing process at a predetermined magnification;
Based on the block image resizing is performed in the size changing means, the input image have a size-changed image generating means for generating a resized image size changing process at the predetermined magnification,
The size changing means performs a size changing process for each line constituting the block image,
The size changing means uses a size change counter that manages the positional relationship between the positions of the pixels constituting the line of the block image before the size changing process and the positions of the pixels constituting the line of the block image after the size changing process. An image forming apparatus that performs a size changing process for each line .
入力画像から、複数のブロック画像を抽出して、順次読み出すブロック画像読み出し手段と、A block image reading means for extracting a plurality of block images from the input image and sequentially reading them;
前記ブロック画像読み出し手段が読み出したブロック画像のそれぞれについて、所定の倍率でサイズ変更処理を行うサイズ変更手段と、For each block image read by the block image reading means, a size changing means for performing a size changing process at a predetermined magnification;
前記サイズ変更手段でサイズ変更が行われたブロック画像に基づいて、前記入力画像を前記所定の倍率でサイズ変更処理したサイズ変更画像を生成するサイズ変更画像生成手段とを有し、Resized image generating means for generating a resized image obtained by resizing the input image at the predetermined magnification based on the block image whose size has been changed by the size changing means;
前記ブロック画像読み出し手段では、前記入力画像から抽出するブロック画像のサイズが前記所定の倍率に応じて可変され、前記入力画像から抽出するブロック画像のサイズが前記所定の倍率により決定されるIn the block image reading means, the size of the block image extracted from the input image is varied according to the predetermined magnification, and the size of the block image extracted from the input image is determined by the predetermined magnification.
ことを特徴とする画像処理装置。An image processing apparatus.
前記サイズ変更手段は、ブロック画像を構成するラインごとに、サイズ変更処理を行い、The size changing means performs a size changing process for each line constituting the block image,
前記サイズ変更手段は、サイズ変更処理前のブロック画像のラインを構成する画素の位置と、サイズ変更処理後のブロック画像のラインを構成する画素の位置との位置関係を管理するサイズ変更カウンタを用いて、ラインごとのサイズ変更処理を行うことを特徴とする請求項15に記載の画像処理装置。The size changing means uses a size change counter that manages the positional relationship between the positions of the pixels constituting the line of the block image before the size changing process and the positions of the pixels constituting the line of the block image after the size changing process. The image processing apparatus according to claim 15, wherein size change processing is performed for each line.
前記サイズ変更手段は、ブロック画像ごとに前記サイズ変更カウンタの初期値を求め、各ブロックを構成するラインについてサイズ変更処理を行う場合、各ラインの先頭の処理時に前記サイズ変更カウンタの値を、当該ブロックに係る初期値にリセットすることを特徴とする請求項16に記載の画像処理装置。The size changing means obtains an initial value of the size change counter for each block image, and when performing the size change processing for the lines constituting each block, the size change counter value is The image processing apparatus according to claim 16, wherein the image processing apparatus is reset to an initial value relating to a block. 当該画像処理装置で処理される各ブロック画像のサイズを管理するものであって、前記サイズ変更手段による変換処理後のブロック画像のサイズが、前記サイズ変更手段の処理上限を超えない範囲となるように、前記ブロック画像読み出し手段が読み出すブロック画像のサイズを決定するブロック管理手段をさらに備えることを特徴とする請求項17に記載の画像処理装置。Manages the size of each block image processed by the image processing apparatus, so that the size of the block image after the conversion processing by the size changing means is within a range not exceeding the processing upper limit of the size changing means. The image processing apparatus according to claim 17, further comprising a block management unit that determines a size of a block image read by the block image reading unit. 前記ブロック画像読み出し手段が読み出すブロック画像のそれぞれには、当該ブロック画像と隣接するブロック画像と間で重複する領域が存在し、Each of the block images read by the block image reading means has an overlapping area between the block image and an adjacent block image,
前記サイズ変更画像生成手段は、サイズ変更処理後の各ブロック画像について無効部分の出力を除外する処理を行うことを特徴とする請求項16〜18のいずれかに記載の画像処理装置。The image processing apparatus according to any one of claims 16 to 18, wherein the size-changed image generation unit performs a process of excluding an invalid portion output for each block image after the size change process.
前記ブロック画像読み出し手段に供給される入力画像について、前記ブロック画像読み出し手段の処理前に、前フィルタ処理を行う前フィルタ処理手段と、For the input image supplied to the block image reading unit, a pre-filter processing unit that performs a pre-filter process before the processing of the block image reading unit;
前記サイズ変更画像生成手段が生成したサイズ変更画像について、後フィルタ処理を行う後フィルタ処理手段とPost-filter processing means for performing post-filter processing on the size-changed image generated by the size-change image generating means;
をさらに有することを特徴とする請求項15〜19のいずれかに記載の画像処理装置。The image processing apparatus according to claim 15, further comprising:
前記ブロック画像読み出し手段により読み出されたブロック画像について、フィルタ処理対象の領域の周辺画素の参照が必要な前フィルタ処理を行う前フィルタ処理手段と、For the block image read by the block image reading means, pre-filter processing means for performing pre-filter processing that requires reference to peripheral pixels in the region to be filtered,
前記サイズ変更手段がサイズ変更処理を行ったブロック画像のそれぞれについて、フィルタ処理対象の領域の周辺画素の参照が必要な後フィルタ処理を行う後フィルタ処理手段とPost-filter processing means for performing post-filter processing that requires reference to surrounding pixels of the region to be filtered for each of the block images subjected to the size change processing by the size changing means;
有することを特徴とする請求項15又は16に記載の画像処理装置。The image processing apparatus according to claim 15 or 16, further comprising:
前記ブロック画像読み出し手段が読み出すブロック画像のそれぞれには、当該ブロック画像と隣接するブロック画像との間で重複する領域が存在し、Each of the block images read by the block image reading means has an overlapping area between the block image and an adjacent block image,
前記サイズ変更画像生成手段は、サイズ変更処理後の各ブロック画像について、隣接するブロック画像と重複する第1の無効領域の出力を除外する処理を行い、The size-changed image generation means performs a process of excluding the output of the first invalid area that overlaps with an adjacent block image for each block image after the size change process,
前記後フィルタ処理手段の処理後のブロック画像について、隣接するブロック画像と重複する第2の無効領域の出力を除外するブロックカット手段をさらに備えるThe block image after the processing by the post-filter processing unit is further provided with a block cut unit that excludes the output of the second invalid area that overlaps the adjacent block image.
ことを特徴とする請求項21に記載の画像処理装置。The image processing apparatus according to claim 21.
当該画像処理装置で処理される各ブロック画像のサイズを管理するものであって、前記前フィルタ処理手段に供給されるブロック画像のサイズ、前記サイズ変更手段による変換処理後のブロック画像のサイズ、前記後フィルタ処理手段に供給されるブロック画像のサイズ、及び前記ブロックカット手段に供給されるブロック画像のサイズが、それぞれの処理に係る処理上限を超えない範囲となるように、前記ブロック画像読み出し手段が読み出すブロック画像のサイズを決定するブロック管理手段をさらに備えることを特徴とする請求項22に記載の画像処理装置。Managing the size of each block image processed by the image processing apparatus, the size of the block image supplied to the pre-filter processing means, the size of the block image after the conversion processing by the size changing means, The block image reading means is arranged so that the size of the block image supplied to the post-filter processing means and the size of the block image supplied to the block cut means are within a range not exceeding the processing upper limit related to each processing. The image processing apparatus according to claim 22, further comprising block management means for determining a size of a block image to be read. 前記サイズ変更手段よりも前段、及び又は、前記サイズ変更手段よりも後段で、ブロック画像の解像度変換を行う解像度変換手段をさらに有することを特徴とする請求項21に記載の画像処理装置。The image processing apparatus according to claim 21, further comprising a resolution conversion unit that performs resolution conversion of a block image at a stage before the size changing unit and / or at a stage after the size changing unit. 前記サイズ変更画像生成手段に供給されるブロック画像に対して、量子化処理を行う量子化処理部をさらに備えることを特徴とする請求項24に記載の画像処理装置。The image processing apparatus according to claim 24, further comprising a quantization processing unit that performs a quantization process on the block image supplied to the size-changed image generation unit. 前記サイズ変更手段よりも後段で、ブロック画像のサイズを再度変更するサイズ再変更処理を行うサイズ再変更手段と、A size re-changing unit for performing a size re-changing process for changing the size of the block image again at a later stage than the size changing unit;
前記サイズ再変更手段でサイズ再変更処理が施されたブロック画像に基づいて、前記サイズ変更画像と異なるサイズのサイズ再変更画像を生成するサイズ再変更画像生成手段と をさらに備えることを特徴とする請求項24又は25に記載の画像処理装置。Resize image generating means for generating a resize image having a different size from the resize image based on the block image subjected to the resize process by the resize means, further comprising: The image processing apparatus according to claim 24 or 25.
前記サイズ再変更手段は、ブロック画像の縮小処理を行うことを特徴とする請求項26に記載の画像処理装置。27. The image processing apparatus according to claim 26, wherein the resize changing unit performs a block image reduction process.
JP2013242213A 2012-11-30 2013-11-22 Image processing apparatus and method, and image forming apparatus Active JP6092082B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2013242213A JP6092082B2 (en) 2012-11-30 2013-11-22 Image processing apparatus and method, and image forming apparatus

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
JP2012262769 2012-11-30
JP2012262769 2012-11-30
JP2013242213A JP6092082B2 (en) 2012-11-30 2013-11-22 Image processing apparatus and method, and image forming apparatus

Publications (2)

Publication Number Publication Date
JP2014131262A JP2014131262A (en) 2014-07-10
JP6092082B2 true JP6092082B2 (en) 2017-03-08

Family

ID=51409245

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2013242213A Active JP6092082B2 (en) 2012-11-30 2013-11-22 Image processing apparatus and method, and image forming apparatus

Country Status (1)

Country Link
JP (1) JP6092082B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10681266B2 (en) * 2018-06-12 2020-06-09 Carl Zeiss Ag Method, apparatus, and system for processing digital images
CN111860694A (en) * 2020-07-31 2020-10-30 地平线(上海)人工智能技术有限公司 Image processing method, method and device for generating instructions for image processing

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3154461B2 (en) * 1994-03-28 2001-04-09 キヤノン株式会社 Image processing device
JP4137097B2 (en) * 2005-07-25 2008-08-20 キヤノン株式会社 Image processing apparatus, image processing method, and computer-readable storage medium
JP2007281591A (en) * 2006-04-03 2007-10-25 Fuji Xerox Co Ltd Image processing apparatus and program
JP5205405B2 (en) * 2010-03-17 2013-06-05 京セラドキュメントソリューションズ株式会社 Image processing apparatus and image processing method

Also Published As

Publication number Publication date
JP2014131262A (en) 2014-07-10

Similar Documents

Publication Publication Date Title
JP4568460B2 (en) Image processing apparatus and recording medium
JP5485277B2 (en) Video interpolating apparatus and method using region segmentation
JP6453694B2 (en) Image composition apparatus, image composition method, image composition program, and recording medium
EP2979242A1 (en) Method and apparatus for generating a super-resolved image from a single image
JP4157568B2 (en) Method and apparatus for increasing image resolution
CN102611856B (en) Image converter, image conversion method and electronic installation
JP5388559B2 (en) Image processing apparatus, image processing method, program for executing image processing method, and storage medium
JP6092082B2 (en) Image processing apparatus and method, and image forming apparatus
JP2010074732A (en) Image processor, image processing method, and program for performing the image processing method
JP5853466B2 (en) Image processing system and image processing program
US7933465B2 (en) Processing data supply method and image processing apparatus
JP4725336B2 (en) Image processing apparatus and image processing program
JP6880867B2 (en) Image processing equipment, image processing methods and programs
US8379268B2 (en) Image enlargement method, image enlargement apparatus, and image forming apparatus
US7885484B2 (en) Image processing method and image processing apparatus
JP2885999B2 (en) Image processing apparatus and method
JP2008228251A (en) Image processor, image processing method, and image processing program
US7809199B2 (en) Image processing apparatus
JP6287071B2 (en) Image processing device
JP4732183B2 (en) Image processing apparatus, image processing method, and program for causing computer to execute the method
JP2011053456A (en) Image display method, program, image display device, and imaging apparatus with the image display device
JP3590534B2 (en) Display image data generating apparatus and recording medium
JP4316476B2 (en) Image processing apparatus and image forming apparatus
JP2007110419A (en) Image magnification method
JP2013008247A (en) Image processing apparatus, image processing method, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20150316

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20160310

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20160510

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20160708

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20170110

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20170208

R150 Certificate of patent or registration of utility model

Ref document number: 6092082

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

S111 Request for change of ownership or part of ownership

Free format text: JAPANESE INTERMEDIATE CODE: R313111

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350