JP4162101B2 - Image gradation conversion method - Google Patents

Image gradation conversion method Download PDF

Info

Publication number
JP4162101B2
JP4162101B2 JP30663297A JP30663297A JP4162101B2 JP 4162101 B2 JP4162101 B2 JP 4162101B2 JP 30663297 A JP30663297 A JP 30663297A JP 30663297 A JP30663297 A JP 30663297A JP 4162101 B2 JP4162101 B2 JP 4162101B2
Authority
JP
Japan
Prior art keywords
gradation
calculation
frequency
minimum
coring
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.)
Expired - Fee Related
Application number
JP30663297A
Other languages
Japanese (ja)
Other versions
JPH11126255A (en
Inventor
裕 宮口
陽一郎 三木
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Panasonic Corp
Panasonic Holdings Corp
Original Assignee
Panasonic Corp
Matsushita Electric Industrial Co Ltd
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 Panasonic Corp, Matsushita Electric Industrial Co Ltd filed Critical Panasonic Corp
Priority to JP30663297A priority Critical patent/JP4162101B2/en
Publication of JPH11126255A publication Critical patent/JPH11126255A/en
Application granted granted Critical
Publication of JP4162101B2 publication Critical patent/JP4162101B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Description

【0010】
【発明の属する技術分野】
本発明は、ディジタル処理技術で画像の階調を変換する方法に関する。
【0020】
【従来の技術】
ディジタル方式の画像処理技術では、画像の絵柄に応じて画像の階調を変換する処理を高画質化の一手法としている。
【0030】
図34に、画像階調変換の基本原理を模式的に示す。この図において、横軸は入力画像VMinのとり得る階調度の範囲を示し、縦軸は出力画像VMout のとり得る階調度の範囲を示す。
【0040】
入力画像VMinに画像階調変換を施さなければ、どの階調度でも一定のゲインで画像信号が出力される。この場合、図34の直線L0 で示すように、入力画像VMinの階調度と出力画像VMout の階調度とは線形的な関係になる。
【0050】
しかし、明るい絵柄の画像に対しては、たとえば図34の曲線LB で示すような非線形的な階調特性とし、階調度の低い画像信号よりも階調度の高い画像信号の方のゲインを相対的に高くしたほうが、画像全体の階調の精細度が向上する。逆に、絵柄が暗いときは、たとえば図34の曲線LA で示すような非線形的な階調特性にして、階調度の低い画像信号の方を階調度の高い画像信号よりも高くすることで、画質を向上できる。
【0060】
従来において、テレビ受像機等における動画像処理システムは、マイクロプロセッサを標準装備しているものの、テレビ画像の伝送レートが非常に高いため、上記のような階調変換処理をゲートアレイまたはASIC等の専用ハードウェア回路に委ねている。
【0070】
この種の専用ハードウェア回路は、入力した画像信号を画素単位で逐次的または時系列的に扱って、階調変換のための所定のアルゴリズムを実行し、階調変換された出力画像信号を得るようにしている。
【0080】
【発明が解決しようとする課題】
しかしながら、上記のような従来の専用ハードウェア回路を用いる方法では、階調変換のアルゴリズムまたはロジックが特化ないし固定されるため、マルチメディア時代の多種多様な画像フォーマットにフレキシブルに対応できないという不都合がある。たとえば、NTSC信号用の専用ハードウェア回路は、NTSC信号についてのみ一定の階調変換を行えるだけであり、他のフォーマットたとえばPAL方式の画像信号を扱えるものではない。
【0090】
したがって、NTSC信号、衛星放送、ハイビジョン信号、パソコン出力信号等の種々多様な映像信号に対応可能な階調変換機能を1台のテレビ受像機に装備するとなると、映像信号の種類別の専用ハードウェア回路を全部内蔵しなくてはならず、非常に高価で大型な装置となってしまう。
【0100】
しかも、従来のように入力画像信号を画素単位で逐次的または時系列的に処理する方式では、ハイビジョンのように画像信号の伝送レートが高くなると、階調変換のような複雑な処理が難しくなり、それだけロジックも複雑化し、回路規模も大きくなる。そして、専用ハードウェア回路は、ロジックが複雑化するほど、ゲート数が指数関数的に増大するため、設計およびシュミレーションが難しくなり、開発期間が大いに長びくという不具合もある。
【0110】
本発明は、かかる問題点に鑑みてなされたもので、多種多様な画像フォーマットに1つのハードウェアシステムで効率よく対応できるようにした画像階調変換方法を提供することを目的とする。
【0120】
また、本発明は、動画像に対して多様かつ高度な階調変換を容易に行える画像階調変換方法を提供することを目的とする。
【0130】
【課題を解決するための手段】
上記の目的を達成するために、本発明の第1の観点における画像階調変換方法は、走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサによって、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算工程と、前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記度数に応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換工程とを有し、前記階調変換工程が、各々のプロセッシング・エレメントによって、各対応する入力画素データについて前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行うコアリング工程と、各々の前記コアリング演算の演算前後の値の差分を求めてクリップするクリップ工程と、各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算工程と、前記第1の乗算工程の演算結果を全て加え合わせる第1の加算工程と、最終回の前記コアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算工程と、前記第1の加算工程の演算結果と前記第2の乗算工程の演算結果とを加え合わせる第2の加算工程とを含む。
【0140】
また、本発明の第2の観点における画像階調変換方法は、走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサによって、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算工程と、前記SIMD型並列プロセッサにより、各々の前記階調度範囲毎に前記度数に応じた階調変換曲線の傾きを求める傾き演算工程と、前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記傾きに応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換工程とを有し、前記階調変換工程が、各々のプロセッシング・エレメントによって、各対応する入力画素データについて前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行うコアリング工程と、各々の前記コアリング演算の演算前後の値の差分を求めてクリップするクリップ工程と、各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算工程と、前記第1の乗算工程の演算結果を全て加え合わせる第1の加算工程と、最終回の前記コアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算工程と、前記第1の加算工程の演算結果と前記第2の乗算工程の演算結果とを加え合わせる第2の加算工程とを含む。
【0150】
また、本発明の第3の観点における画像階調変換方法は、走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサによって、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算工程と、前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記度数に応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換工程と、前記入力画像信号の最小階調度および最大階調度を求める最小及び最大階調度演算工程と、前記最小階調度と前記最大階調度との間の階調度範囲を等間隔で予め設定した数に分割することによって前記複数の階調度範囲を決定する階調度範囲演算工程とを有し、前記階調変換工程が、各々のプロセッシング・エレメントによって、各対応する入力画素データについて前記最小階調度の値をコアリングレベルとするコアリング演算を行う第1のコアリング工程と、前記第1のコアリング工程の演算結果について前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行う第2のコアリング工程と、各々の前記第2のコアリング演算の演算前後の値の差分を求めてクリップするクリップ工程と、各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算工程と、前記第1の乗算工程の演算結果を全て加え合わせる第1の加算工程と、最終回の前記第2のコアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算工程と、前記第1の加算工程の演算結果と前記第2の乗算工程の演算結果とを加え合わせる第2の加算工程と、前記第2の加算工程の演算結果と前記最小階調度とを加え合わせる第3の加算工程と、前記第3の加算工程の演算結果と前記最大階調度とを比較し、小さい方を選択する最小値演算工程とを含む。
【0160】
また、本発明の第4の観点における画像階調変換方法は、走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサによって、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算工程と、前記SIMD型並列プロセッサにより、各々の前記階調度範囲毎に前記度数に応じた階調変換曲線の傾きを求める傾き演算工程と、前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記傾きに応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換工程と、前記入力画像信号の最小階調度および最大階調度を求める最小及び最大階調度演算工程と、前記最小階調度と前記最大階調度との間の階調度範囲を等間隔で予め設定した数に分割することによって前記複数の階調度範囲を決定する階調度範囲演算工程とを有し、前記階調変換工程が、各々のプロセッシング・エレメントによって、各対応する入力画素データについて前記最小階調度の値をコアリングレベルとするコアリング演算を行う第1のコアリング工程と、前記第1のコアリング工程の演算結果について前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行う第2のコアリング工程と、各々の前記第2のコアリング演算の演算前後の値の差分を求めてクリップするクリップ工程と、各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算工程と、前記第1の乗算工程の演算結果を全て加え合わせる第1の加算工程と、最終回の前記第2のコアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算工程と、前記第1の加算工程の演算結果と前記第2の乗算工程の演算結果とを加え合わせる第2の加算工程と、前記第2の加算工程の演算結果と前記最小階調度とを加え合わせる第3の加算工程と、前記第3の加算工程の演算結果と前記最大階調度とを比較し、小さい方を選択する最小値演算工程とを含む。
【0170】
本発明の画像階調変換方法においては、上記のような構成により、非線形処理用の特殊なメモリを使用しなくても、SIMD型並列プロセッサの演算処理によって非線形の諧調変換を実現し、動画像に対して多様かつ高度な階調変換を行うことができる。
【0180】
本発明の好適な一態様においては、1フィールドまたは1フレーム分の入力画像信号を単位として度数演算工程を行う。この場合、好ましくは、所定数のフィールドまたはフレーム置きに、および/または1フィールドまたは1フレーム内の一部の入力画像領域についてのみ、度数演算工程を行ってよい。
【0190】
本発明の好適な一態様においては、所定の間隔を置いた画素および所定の間隔を置いた走査線についてのみ度数演算工程を行う。
【0200】
本発明の好適な一態様において、度数演算工程は、各々のプロセッシング・エレメントが、垂直走査期間中に各対応する垂直方向の画素列について各々の階調度範囲毎に度数を演算する垂直方向の度数演算工程と、その後に続く垂直ブランキング期間中に、全部または一部の前記プロセッシング・エレメントが協働して、垂直方向の全部または一部の画素列分の度数を各々の階調度範囲毎に水平方向で合計して、当該フィールドまたはフレームにおける各々の階調度範囲分の度数を演算する水平方向の度数演算工程とを含む。
【0210】
この場合、好ましくは、各々のプロセッシング・エレメントが、複数の階調度範囲にそれぞれ対応した複数の度数演算値記憶部を有し、垂直方向の度数演算工程では、垂直方向の各対応する画素列において各入力画素がいずれの前記階調度範囲に入るのかを判定して、その該当する前記階調度範囲に対応する度数演算記憶部の内容に「1」を加算するとともに、他の全ての度数演算値保持部の内容に「0」に加えてよい。
【0220】
あるいは、水平方向における度数合計演算を複数回に分割し、相前後する2つの水平方向の度数合計演算では、前の度数合計演算で得られた全てのプロセッシング・エレメントの演算結果をいったん並列プロセッサより出力して、その出力した全演算結果の中で所定のプロセッシング・エレメントに対応する演算結果だけを並列プロセッサに入力して後の度数合計演算の演算対象としてもよい。
【0230】
本発明の好適な一態様においては、各回の度数演算工程で求めた度数を所定数の後続フィールドまたはフレームの入力画像信号に対する階調変換工程に用いる。
【0240】
本発明の好適な一態様においては、度数に所定の下限値または上限値を設定し、いずれかの階調度範囲における度数が下限値より少ないかまたは上限値より多いときは、その度数のうちの下限値を下回る分または上限値を超える分について他の階調度範囲における度数との間で分配を行って、下限値または上限値以内に補正する。
【0250】
本発明の好適な一態様においては、入力画像信号の最小階調度および最大階調度を求める最小及び最大階調度演算工程と、最小階調度と最大階調度との間の階調度範囲を等間隔で予め設定した数に分割することによって複数の階調度範囲を決定する階調度範囲演算工程とが更に含まれる。
【0260】
この場合、更に好ましくは、1フィールドまたは1フレーム分の入力画像信号を単位として上記最小及び最大階調度演算工程が行われる。また、更に好ましくは、所定数のフィールドまたはフレーム置きに上記最小及び最大階調度演算工程が行われる。あるいは、1フィールドまたは1フレーム内の一部の入力画像領域についてのみ上記最小及び最大階調度演算工程が行われる。
【0270】
また、所定の間隔を置いた画素および所定の間隔を置いた走査線についてのみ最小及び最大階調度演算工程を行ってもよい。
【0280】
本発明の好適な一態様において、各回の最小及び最大階調度演算工程で求められる最小階調度および最大階調度は、前回の最小及び最大階調度演算工程で求められた最小階調度および最大階調度に第1の係数k(0≦k≦1)を掛けたものと、今回のフィールドまたはフレームにおける入力画像信号の最小階調値および最大階調度に第2の係数(1−k)を掛けたものとの和である。
【0290】
本発明の好適な一態様において、上記最小及び最大階調度演算工程は、各々のプロセッシング・エレメントが、垂直走査期間中に各対応する垂直方向の画素列について最小階調度および最大階調度を演算する垂直方向の最小及び最大階調度演算工程と、その後に続く垂直ブランキング期間中に、全部または一部の前記プロセッシング・エレメントが協働して、垂直方向の全部または一部の画素列分の最小階調度および最大階調度を水平方向で比較して、当該フィールドまたはフレーム分の最小階調度および最大階調度を演算する水平方向の最小及び最大階調度演算工程とを含む。
【0300】
本発明の好適な一態様においては、各々のプロセッシング・エレメントが、最小階調度に対応した最小階調度記憶部を有し、垂直方向の最小階調度演算工程では、垂直ブランキング期間中に予め最小階調度記憶部に入力画像信号のとりうる最大階調度をセットし、その後の垂直走査期間中に垂直方向の各対応する画素列について各画素毎に順次最小階調度記憶部の内容と比較し、小さい方を最小階調度記憶部の新たな内容として保存する。
【0310】
本発明の好適な一態様においては、各々のプロセッシング・エレメントが、最大階調度に対応した最大階調度記憶部を有し、垂直方向の最大階調度演算工程では、垂直ブランキング期間中に予め最大階調度記憶部に入力画像信号のとりうる最小階調度をセットし、その後の垂直走査期間中に垂直方向の各対応する画素列について各画素毎に順次最大階調度記憶部の内容と比較し、大きい方を最大階調度記憶部の新たな内容として保存する。
【0320】
また、水平方向における最小階調度および最大階調度の演算をトーナメント方式で行ってもよい。
【0330】
この場合、好適には、トーナメント方式による最小階調度および最大階調度の演算を複数回のトーナメントに分割し、相前後する2つのトーナメントの間では前のトーナメントで得られた全てのプロセッシング・エレメントの演算結果をいったん並列プロセッサより出力し、その出力した全演算結果の中で所定のプロセッシング・エレメントに対応する演算結果だけを並列プロセッサに入力して後のトーナメントの演算対象としてよい。
【0340】
本発明の好適な一態様によれば、上記第3または第4の観点における画像階調変換方法において、階調変換工程は、各々の階調度範囲毎に階調変換曲線の傾きを度数に比例させ、相隣接する2つの階調度範囲の境界で出力画像の階調度を連続させる工程を含む。
【0350】
本発明の好適な一態様においては、1つの画面上に表示されるべき複数の画像に対応する複数の入力画像信号について、前記度数演算工程を各入力画像信号毎に、かつ交互に行う。
【0355】
請求項24に記載の発明は、請求項1または2に記載の画像階調変換方法において、前記階調変換工程が、各々のプロセッシング・エレメントによって、各対応する入力画素データについて前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行うコアリング工程と、各々の前記コアリング演算の演算前後の値の差分を求めてクリップするクリップ工程と、各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算工程と、前記第1の乗算工程の演算結果を全て加え合わせる第1の加算工程と、最終回の前記コアリング演算の演算結果とそれに対応する前記度数または前記階調変換の傾きとを乗算する第2の乗算工程と、前記第1の加算工程の演算結果と前記第2の乗算工程の演算結果とを加え合わせる第2の加算工程とを含む。
【0380】
本発明の第1の観点における記録媒体は、走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサに、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算手順と、前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記度数に応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する諧調変換手順とを実行させ、前記階調変換手順において、各々のプロセッシング・エレメントによって、各対応する入力画素データについて前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行うコアリング手順と、各々の前記コアリング演算の演算前後の値の差分を求めてクリップするクリップ手順と、各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算手順と、前記第1の乗算手順の実行による演算結果を全て加え合わせる第1の加算手順と、最終回の前記コアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算手順と、前記第1の加算手順の実行による演算結果と前記第2の乗算手順の実行による演算結果とを加え合わせる第2の加算手順とを実行させるためのプログラムを記録してなる。
【0390】
本発明の第2の観点における記録媒体は、走査線上の画素に割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサに、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算手順と、前記SIMD型並列プロセッサにより、各々の前記階調度範囲毎に前記度数に応じた階調変換曲線の傾きを求める傾き演算手順と、前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記傾きに応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換手順と実行させ、前記階調変換手順において、各々のプロセッシング・エレメントによって、各対応する入力画素データについて前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行うコアリング手順と、各々の前記コアリング演算の演算前後の値の差分を求めてクリップするクリップ手順と、各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算手順と、前記第1の乗算手順の実行による演算結果を全て加え合わせる第1の加算手順と、最終回の前記コアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算手順と、前記第1の加算手順の実行による演算結果と前記第2の乗算手順の実行による演算結果とを加え合わせる第2の加算手順とを実行させるためのプログラムを記録してなる。
【0400】
【発明の実施の形態】
以下、図1〜図33を参照して本発明の実施例を説明する。
【0410】
図1に、本発明の画像階調変換方法で用いるSIMD(Single-Instruction Multiple-Data )型並列プロセッサの構成例を示す。
【0420】
このSIMD型並列プロセッサは画像信号を走査線単位で入力、並列演算処理および出力するSVP(Scan-line Video Processor )として構成されている。
【0430】
このSVP10は、1チップ上にSVPコア12と命令発生部(IG)14とを搭載している。SVPコア12は、データ入力レジスタ(DIR)16、SIMD型ディジタル信号処理部18およびデータ出力レジスタ(DOR)20の3層構造からなっている。
【0440】
DIR16は、外部制御回路からの制御信号(Control)と外部クロック回路からのクロック(SWCK)とIG14からのアドレス(ADDRESS)とにしたがって動作し、たとえば水平走査線3本分までの画像データD0 〜DN-1 (たとえば48ビット×864画素)を繰り返し入力する。
【0450】
SIMD型ディジタル信号処理部18は、1水平走査線上の画素数Nに等しい数(たとえば864個)のプロセッシング・エレメントPE0 〜PEN-1 を並列配置(接続)してなる。これらのプロセッシング・エレメントPE0 ,PE1 ,…PEN-1 は、IG14からの命令すなわちアドレス(ADDRESS)およびマイクロ命令(MICROINSTRUCTION)と外部クロック回路からのクロック(PCLK)とにしたがって並列動作し、各々対応する画素データD0 ,D1 ,…DN-1 について同一の画像処理演算を1水平走査期間内に実行する。
【0460】
DOR20は、外部制御回路からの制御信号(Control)と外部クロック回路からのクロック(SRCK)とIG14からのアドレス(ADDRESS)とにしたがって動作し、1水平走査期間毎にプロセッシング・エレメントPE0 〜PEN-1 からの演算処理結果のデータを水平走査線1本分の画像データD0'〜DN-1'(たとえば32ビット×864画素)に揃えて出力する。
【0470】
DIR16、処理部18およびDOR20にそれぞれ供給されるクロック(SWCK) 、(PCLK)および(SRCK) は互いに非同期であってよい。また、DIR16から処理部18へのデータ転送、および処理部18からDOR20へのデータ転送は、それぞれ水平ブランキング期間内に行われる。
【0480】
このように、DIR16、処理部18およびDOR20によりそれぞれ1水平走査線分のデータ入力、並列演算処理およびデータ出力がパイプライン方式で非同期かつ並列的に実行され、リアルタイムな画像処理が行われる。
【0490】
IG14は、SVPコア12をSIMD型並列プロセッサとして動作させるため、所要のプログラムを保持するRAMまたはROMからなるプログラムメモリと、SVPコア12における処理途中の各種中間データを一時的に格納するためのレジスタ等を内蔵しており、外部からのモード信号(IMODE)やフラグ信号(IGFLAG−A/B)等にしたがって、飛び越し、サブルーチンコール、割り込み等も行えるようになっている。
【0495】
本実施例において、フラグ信号(IGFLAG−A)は入力画像信号より抽出された水平同期信号(HSYNC)に同期しており、モード信号(IMODE)は3つのモード0,1,2のいずれかを選択的に指示する。
【0500】
なお、IG14内の上記プログラムメモリには、本実施例による階調変換処理を行うためのプログラムが格納される。
【0510】
ここで、図2につきSVPコア12の内部の作用を概略的に説明する。SVPコア12内の各部の動作は、上記したようにIG14からのアドレス(ADDRESS)およびマイクロ命令(MICROINSTRUCTION)や外部クロック回路からのクロック(PCLK) 等によって制御される。
【0520】
図2において、DIR16は1ライン分の入力画像データD0 〜DN-1 を蓄積できる記憶容量(たとえば48ビット×864ワード)を有し、画素単位でブロック化されている。入力画像データD0 〜DN-1 がDIR16内を転送される途中、各画素データ…,DK-2,DK-1,DK,DK+1,DK+2,…は1個ずつ次々と引き落とされるようにしてDIR16の各ブロック…,K−2,K−1,K,K+1,K+2,…のレジスタ群に取り込まれる。
【0530】
処理部18の各プロセッシング・エレメントPEK は、各々が所定の容量(たとえば192ビット)を有する一対のレジスタ・ファイルRF0,RF1 と、1個の1ビット演算論理ユニット(ALU)24と、複数個(たとえば4個)のワーキング・レジスタWRs(M,A,B,C)26と、左右隣の複数個(たとえば左右各4個)のプロセッシング・エレメント(PEK-4,PEK-3,PEK-2,PEK-1 ,PEK+1,PEK+2,PEK+3,PEK+4 )とデータをやりとりするL/R(左右)通信部(LRCOM)28とを有している。
【0540】
一方のレジスタ・ファイルRF0 はDIR16の対応するブロックのレジスタ群に接続され、他方のレジスタ・ファイルRF1 はDOR20の対応するブロックのレジスタ群に接続されている。レジスタ・ファイルRF0,RF1 の片方または双方から読み出された1ビットのデータは、ワーキング・レジスタ(M,A,B,C)のいずれかに与えられるとともに、L/R通信部28のマルチプレクサ30およびラッチ回路32を介して隣接する左右各4個のプロセッシング・エレメント(PEK-4,PEK-3,PEK-2,PEK-1 ,PEK+1,PEK+2,PEK+3,PEK+4 )へ送られる。
【0550】
これと同時に、それら隣の各プロセッサ・エレメント(PEK-4,PEK-3,PEK-2,PEK-1 ,PEK+1,PEK+2,PEK+3,PEK+4 )からのデータも当該プロセッサ・エレメントPEK のL/R通信部28のマルチプレクサ34,36に送られてきて、それらのデータの中のいずれか1つが選択されてワーキング・レジスタ(M,A,B,C)のいずれかに入力される。図2では、左隣のプロセッサ・エレメント(PEK-4,PEK-3,PEK-2,PEK-1 )からのデータの中のいずれか1つが選択され、ワーキング・レジスタ(A)に入力されたことを示している。
【0560】
ALU24は、ワーキング・レジスタ(M,A,B,C)より与えられるデータについて所要の演算を実行し、その演算結果を出力する。ALU24の演算結果のデータは、レジスタ・ファイルRF0,RF1 のいずれかに書き込まれる。概して、各水平走査期間における最後の演算結果のデータは最終演算処理結果の画素データDK'として出力側のレジスタ・ファイルRF1 に書き込まれ、直後の水平ブランキング期間中にこのレジスタ・ファイルRF1 からDOR20の対応するブロックのレジスタに移される。
【0570】
DOR20は、1ライン分の出力画像データD0'〜DN-1'を蓄積できる記憶容量(たとえば32ビット×864ワード)を有し、画素単位でブロック化されている。各ブロック毎に処理部18よりDOR20に送られてきた演算処理結果の画素データD0'〜DN-1'は、1水平走査期間をかけて左端の画素データD0'を先頭に後続の画素データD1', D2', …が数珠繋ぎに続くように順にDOR20の各ブロックから送出される。
【0580】
処理部18は、レジスタ・ファイルRF0,RF1 に2ライン分の画像データを蓄積することが可能であり、これによってラインメモリの機能も実現可能となっている。また、処理部18は、1水平走査期間中に複数チャンネルの画像データについて時分割的に各個別の処理を実行することも可能である。
【0590】
なお、図1に示すように、DOR20の出力端子は、外部データ・パス21を介してDIR16の入力端子に接続されるとともに、内部データ・パス23を介してIG14のデータ入力端子に接続されている。後述するように、SVP10は、各プロセッシング・エレメントPEの演算結果のデータをいったんDOR20より出力してから、DIR16経由で、あるいはIG14経由で(この場合はマイクロ命令の一部として)再び任意のプロセッシング・エレメントPEのレジスタ・ファイルRF0,RF1 に戻したり、さらには演算に使用したりすることができるようになっている。
【0600】
以下に、このSVP10において実施される本実施例の階調変換方法について説明する。
【0605】
この実施例では、一例として、階調変換の対象となる画像信号をカラーテレビジョン信号の輝度信号Yとし、その輝度レベルを階調度とし、1フィールドにおける有効走査画面の解像度をたとえば240ライン×720画素とする。もっとも、色信号Cまたは色差信号R−Y,B−Yを処理対象とし、色レベルを階調度とすることも可能であり、画面の解像度も任意のフォーマットが可能である。
【0610】
図3に、本実施例における階調変換方法の原理を示す。本実施例では、入力画像信号Yinの階調度(輝度レベル)に対して等しい幅RNKwd を有し、かつ連続した4つの階調度範囲RNG0 ,RNG1 ,RNG2 ,RNG3 を設定する。
【0620】
ここで、これら4つの階調度範囲RNG0 〜RNG3 の幅RNKwd および最小階調度MINd および最大階調度MAXd は、入力画像信号Yinのとりうる最も大きな階調度範囲[0〜LIMIT ]内で入力画像の階調に応じて一定の周期たとえば1フィールドまたはその整数倍の周期で動的に変化する値とする。なお、入力画像信号Yinが8ビット・データである場合、最大限界階調度LIMIT は「255」である。
【0630】
本実施例の方法では、入力画像の階調度を画素毎に上記4つの階調度範囲RNG0 〜RNG3 のいずれかに分類し、それぞれの階調度範囲RNG0 〜RNG3 に入る(該当する)画素を計数して、それぞれの度数HSTd0 ,HSTd1 ,HSTd2 ,HSTd3 を求め、次いでそれらの度数HSTd0 ,HSTd1 ,HSTd2 ,HSTd3 にそれぞれ応じた階調変換曲線の傾き(以下、ゲインと称する。)A0 ,A1 ,A2 ,A3 を求める。
【0640】
ここで、各階調度範囲RNGにおけるゲインAは、ヒストグラムの母数となる画素数および分類区分数(階調度範囲の個数)に応じた係数で各HSTに比例しており、図3に示すように、各隣接する2つの階調度範囲の境界で階調度特性(曲線)が連続している。
【0650】
そして、図3に示すような非線形特性にしたがって入力画像信号Yinの階調度を変換することにより、所望の階調度の出力画像信号Yout を得る。本実施例では、このような非線形の階調変換をSVP10の演算処理によって実現する。
【0660】
次に、図4〜図21につき、本実施例の階調変換を実現するためのSVP10の処理動作について説明する。
【0670】
図4〜図7に、SVP10の処理手順をフローチャートで示す。図8および図9に、SVP10内における全体の処理およびデータの流れをそれぞれブロック図およびタイミング図で示す。また、図10〜図21は、SVP10における各段階の処理を説明するための図である。
【0680】
図4において、階調変換処理に先立ち、初期化を行う(ステップS0 )。初期化では、先ず、DIR16およびDOR20における入力/出力ポートにたとえば図10に示すようなビット配分(割り付け)を設定する。
【0690】
図10において、入力側のDIR16では、48ビットの入力端子のうち最下位の8ビット[0〜7]が入力画像信号Yinを入力するための入力ポートに充てられるとともに、その上位に3組の10ビット・ポートS0in[10〜19],S1in[20〜29],S2in[30〜39]が設定される。
【0700】
出力側のD0R20では、32ビットの出力端子のうち、最下位の10ビット・ポートS0out [0〜9]が出力画像信号Yout を出力するための出力ポートに充てられるとともに、その上位に2組の10ビット・ポートS1out [10〜19],S2out [20〜29]が設定される。
【0710】
D0R20の出力ポートS0out ,S1out ,S2out は、外部データパス21(26,24,22)を介してD1R16の入力ポートS0in,S1in,S2inに接続される。
【0720】
また、後述するように、本実施例では、4つの階調度範囲RNG0 〜RNG3 にそれぞれ対応する4つのゲイン(A0 ,A1 ,A2 ,A3 )のデータがDOR20の内部出力端子から出力され、内部データパス23を介してIG14内の所定のレジスタ(AUXFB)に転送されるようになっている。したがって、この初期化で、DOR20の内部出力端子に各ゲイン(A0 ,A1 ,A2 ,A3 )のデータを出力するためのポートを設定しておく。また、これと対応して、IG14側でも、各ゲイン(A0 ,A1 ,A2 ,A3 )の値(データ)を格納するためのレジスタ領域(AUXFB)を設定しておく。
【0730】
さらに、この初期化(ステップS0 )では、図11に示すように、各プロセッシング・エレメントPEに設けられているレジスタ・ファイルRF0 ,RF1 の記憶領域内に各種のレジスタ領域を設定する。
【0740】
一方のレジスタ・ファイルRF0 において、[MINa],[MAXa]は、垂直方向の最小階調度演算および最大階調度演算における演算途中または結果のデータを格納するためのレジスタ領域である。これらのレジスタ領域[MINa],[MAXa]は、この初期化で、および水平方向の統計処理の途中で、初期値にリセットされる。[MINa]の初期値は、画像信号のとりうる可能な最大階調値「255」であり、[MAXa]の初期値は画像信号のとりうる可能な最小階調値「0」である。
【0750】
[HSTa0 ]〜[HSTa3 ]は、垂直方向の度数演算における演算途中または結果のデータを格納するためのレジスタ領域である。これらのレジスタ領域[HSTa0 ]〜[HSTa3 ]も、初期化と水平方向の統計処理の中で、それぞれ初期値「0」にリセットされる。
【0760】
また、[RNKwc ]は、階調度範囲幅演算における演算途中または結果のデータを格納するためのレジスタ領域である。[Ax0 ]〜[Ax3 ]は、階調度範囲RNG0 〜RNG3 毎のゲインA0 〜A3 の演算結果を格納するためのレジスタ領域である。[S0 ],[T0 ]は、非線形処理(LUT)における演算途中または結果のデータを格納するためのレジスタ領域である。
【0770】
他方のレジスタ・ファイルRF1 において、[Y]は、入力画像データYin中の各対応する画素データを格納するためのレジスタ領域である。[MINb ],[MINc ]は、水平方向の一次および二次統計処理における最小階調度のデータをそれぞれ格納するためのレジスタ領域である。[MAXb ],[MAXc ]は、水平方向の一次および二次統計処理における最大階調度のデータをそれぞれ格納するためのレジスタ領域である。
【0780】
また、[HSTb0 ]〜[HSTb3 ]は、水平方向の一次統計処理における各度数データをそれぞれ格納するためのレジスタ領域である。[HSTc0 ]〜[HSTc3 ]は、水平方向の二次統計処理における各度数のデータを格納するためのレジスタ領域である。
【0790】
[K0 ],[K1 ]は、水平方向のデータ移動操作において移動の向きを指示するフラグビットを格納するためのレジスタ領域である。[MINd ],[MAXd ],[RNKwd ]は、非線形処理(LUT)で用いる最小階調度、最大階調度および階調度範囲幅の値をそれぞれ格納するためのレジスタ領域である。また、[S1 ],[T1 ]は、非線形処理(LUT)における計算途中の各種データを格納するためのレジスタ領域である。[F1 ]は、垂直方向の度数演算処理で発生する符号ビット(sign bit)を格納するためのレジスタ領域である。
【0800】
上記のレジスタ・ファイルRF0 ,RF1 における各レジスタ領域には、所定のビット幅が割り当てられる。また、各レジスタ領域を各独立した記憶領域に設定できることはもろろん、機能的に異なるレジスタ領域を同一の記憶領域上で時分割的に使用(共用)することも可能である。
【0805】
レジスタ・ファイルRF0 ,RF1 の領域設定は、必ずしもプログラム実行時に行わなくてもよく、プログラム作成時にプログラムに埋め込む形で行ってもよい。
【0810】
再び図4において、初期化を終了した後は、フラグA端子を監視して水平同期信号(HSYNC)を待ち(ステップS1 )、水平同期信号が入ったならステップS2 に入る。
【0820】
このステップS2 では、正味の水平走査期間(映像信号期間)が始まる前に、前の水平走査期間の処理結果である各プロセッシング・エレメントPEの出力画素データY(DK')をレジスタ・ファイルRF0 のレジスタ領域[T0 ]からDOR20の対応レジスタに転送する。
【0830】
もっとも、画面の開始直後は、該レジスタ領域[T0 ]が空になっている。図9から理解されるように、RF0 ([T0 ])からDOR20への実質的な出力画素データの転送(Yの出力)は、3番目の水平同期信号から開始される。
【0840】
ステップS2 の後は、モード信号を基に今回の水平走査期間のモード(IMODE)を判別する(ステップS3 )。この実施例では、3つのモード0,1,2が設定され、垂直走査期間中はモード1,2の水平走査期間が1水平走査線ずつ交互に繰り返され、垂直ブランキング期間ではモード0になる。
【0850】
したがって、垂直走査期間中は、モード(IMODE)は1または2であり、0にはならない。したがって、ステップS4 に移り、まだ水平ブランキング期間が続いている間に、DIR16より1水平走査線分の入力画像信号Yinを処理部18に取り込み、この入力画像信号Yinを構成する各画素データY(DK )を各プロセッシング・エレメントPEK におけるレジスタ・ファイルRF1 のレジスタ領域[Y]に格納する。
【0860】
もっとも、各フィールドの開始直後は、DIR16は空になっている。図9から理解されるように、DIR16からRF1 ([Y])への実質的な入力画素データの取り込み(Yの入力)は2番目の水平同期信号から開始される。
【0870】
次に、ステップS5 で、今回のモードが1もしくは2のいずれであるかを判別する。モード1の場合は、後述する非線形処理(LUT)(ステップS8 )だけを実行する。モード2の場合は、先ず垂直方向における最小階調度および最大階調度を求める統計処理(ステップS6 )および各階調度範囲RNG0 〜RNG3 毎の度数を求める統計処理(ステップS7 )を順次行い、その後に非線形処理(LUT)(ステップS8 )を行う。
【0880】
図12に、垂直方向における最小階調度、最大階調度および度数を求める統計処理の手法を概念的に示す。上記したように、このSVP10では、1水平走査線単位で入力画像信号がDIR16より処理部18に転送され、その入力画像信号中の各画素データが各対応するプロセッシング・エレメントPEに取り込まれる。つまり、各プロセッシング・エレメントPEは、画面上の対応する列の画素データを垂直方向に1ライン周期で順次受け取る。
【0890】
本実施例によれば、図12に示すように、各プロセッシング・エレメントPEが、垂直方向の各対応する列の各画素データを1個入力する度に最小階調度、最大階調度および度数の値を逐次更新していく仕方でMIN演算、MAX演算および度数演算を実行し、垂直走査期間の終了時には垂直方向における最小階調度MINa、最大階調度MAXaおよび各階調度範囲RNG0 〜RNG3 毎の度数HSTa0 〜HSTa3 の統計値を得るようにしている。
【0900】
図13に、垂直方向における最小階調度MINaおよび最大階調度MAXaを得るための各プロセッシング・エレメントPEの処理(ステップS6 )をブロック図で示す。
【0910】
上記したように、レジスタ・ファイルRF0 のレジスタ領域[MINa],[MAXa]には初期値としてそれぞれ「255」,「0」がセットされている。図13に示すように、各プロセッサ・エレメントPEは、各ライン毎に入力した各対応する列の画素データ(Y)について、このデータの階調度をレジスタ領域[MINa]の内容と比較して値の小さい方をレジスタ領域[MINa]に残すとともに、このデータの階調度をレジスタ領域[MAXa]の内容と比較して値の大きい方をレジスタ領域[MAXa]に残す。このMIN演算およびMAX演算は、各プロセッサ・エレメントPE内のALU24およびワーキング・レジスタWRsを用いて行われる。
【0920】
上記のような垂直方向の逐次更新式MIN,MAX演算を水平走査線単位で繰り返す。この結果、最後(下端)の水平走査線に対するMIN,MAX演算を終えた時点で、レジスタ領域[MINa],[MAXa]の内容は垂直方向の各対応する画素列について統計をとった最小階調度MINaおよび最大階調度MAXaの値となっている。
【0930】
本実施例では、上記垂直方向のMIN,MAX演算処理をモード1の水平走査線については行わず、モード2の水平走査線に対してのみ行う。つまり、水平走査線2本につき1回の割合で、1フィールドの有効走査線全体では240本のうち120本について行う。通常の画像では、隣接するビットの階調度が近似しているので、適当な間隔で水平走査線を間引いても、統計値MINa,MAXaの誤差は少ない。このような水平走査線の間引きにより、垂直方向における統計処理の冗長性を少なくし、効率化をはかることができる。
【0940】
図14に、垂直方向における各階調度範囲RNG0 〜RNG3 毎の度数HSTa0 〜HSTa3 を得るための各プロセッシング・エレメントPEの処理(ステップS7 )をブロック図で示す。また、図15に、入力画素データ(Y)の4段階の値(階調度)に対するこのブロック図の各部の値を示す。
【0950】
図14において、入力画素データ(Y)をレジスタ領域[Y]からレジスタ領域[S0 ]に転送したうえでこのレジスタ領域[S0 ]の内容(Y)からレジスタ領域[MINd ]の内容を減算し(H2 )、その減算結果(差)をレジスタ領域[S0 ]の新たな内容とする。ここで、レジスタ領域[MINd ]には、前回の最小階調度演算処理における最終統計値としての最小階調度MINdの値(データ)が格納されている。
【0960】
次に、レジスタ領域[S0 ]の内容からレジスタ領域[RNKwd ]の内容を減算し(H3 )、その減算結果(差)をレジスタ領域[S0 ]の新たな内容とする。そして、この減算演算(H3 )よりマイナス符号(−)を示す論理値「1」の符号ビット(sign bit)が出力されたときは、この値1をレジスタ領域[F1 ]にセットする。
【0970】
したがって、入力画素データ(Y)の値(階調度)が(MINd+RNKwd )よりも小さいときは、レジスタ領域[F1 ]の内容が1となる。これにより、加算演算(H5 )でレジスタ領域[HSTa0 ]に1が加算され、レジスタ領域[HSTa0 ]の内容が1つ増える。
【0980】
この時、後段の減算演算(H6 ),(H10)ではマイナス符号(−)を示す1の符号ビット(sign bit)が出力され、排他的論理和演算(H7 ),(H11)および反転演算(H13)の出力は0となる。これにより、加算演算(H8 ),(H12),(H14)ではそれぞれレジスタ領域[HSTa1 ],[HSTa2 ],[HSTa3 ]に0が加算され、これらのレジスタ領域の内容は変わらない。
【0990】
入力画素データ(Y)の値(階調度)が(MINd+RNKwd )以上で、かつ(MINd+RNKwd ×2)より小さいときは、減算演算(H3 )の出力符号はプラス(+)になるが、減算演算(H6 ),(H10)の出力符号はマイナス(−)に維持される。この場合、排他的論理和演算(H7 )の出力が1になり、加算演算(H8 )ではレジスタ領域[HSTa1 ]に1が加算され、このレジスタ領域[HSTa1 ]の内容が1つ増える。一方、他の加算演算(H5 ),(H12),(H14)ではそれぞれレジスタ領域[HSTa0 ],[HSTa2 ],[HSTa3 ]に0が加算され、これらのレジスタ領域の内容は変わらない。
【1000】
そして、入力画素データ(Y)の値が(MINd+RNKwd ×2)以上で、かつ(MINd+RNKwd ×3)よりも小さいときは、レジスタ領域[HSTa2 ]の内容だけが1つ増える。また、Yの値が(MINd+RNKwd ×3)以上では、レジスタ領域[HSTa3 ]の内容だけが1つ増える。
【1010】
上記のような演算処理により、垂直走査期間が終了した時点で、各レジスタ領域[HSTa0 ],[HSTa1 ],[HSTa2 ],[HSTa3 ]の内容は垂直方向の各対応する画素列について統計をとった各階調度範囲RNG0 〜RNG3 毎の画素計数値つまり度数HSTa0 〜HSTa3 を表す値(データ)となっている。
【1020】
もっとも、上記した垂直方向のMIN,MAX演算処理と同様に、この垂直方向における度数演算処理も、モード1の水平走査線については行わず、モード2の水平走査線に対してのみ行われる。
【1030】
次に、図4において、非線形処理(LUT)(ステップS8 )は、各水平走査線期間において、つまりモード1,2のいずれにおいても、入力画像信号Yinに対して実行され、その演算結果として、図3に示すような非線形特性で階調変換された出力画像信号Yout が得られる。この非線形処理(LUT)については、図20につき後で詳細に説明する。
【1040】
図4において、ステップS3 で水平走査線期間のモードが0になった時、つまり垂直ブランキング期間に入った時は、垂直ブランキング期間中の処理(VBLANK)(図5〜図7)に移行する。
【1050】
以下に説明するように、垂直ブランキング期間中には、上記した垂直方向の統計処理の演算結果を受け継いで水平方向の統計処理が実行されることにより、直前のフィールドにおける最終統計値としての最小階調度、最大階調度および度数が決定される。さらに、これらの最終統計値を基に所定の演算が行われることによって、線形処理(LUT)で必要な階調度幅RNKwd および各階調度範囲RNG0 〜RNG3 毎のゲインA0 〜A3 が求められる。
【1060】
本実施例では、SVPの特性に鑑みて、水平方向の統計処理を一次および二次の2段階に分けることにより、統計データの情報圧縮化ないし処理効率の向上をはかっている。
【1070】
図12には、水平方向の一次統計処理の手法も概念的に示されている。上記したように、垂直走査期間が終了した時点で、各プロセッシング・エレメントPEのレジスタ領域[MINa],[MAXa],[HSTa0 ]〜[HSTa3 ]には、垂直走査期間内で垂直方向の各対応する画素列について統計をとった最小階調度MINa、最大階調度MAXa、各度数HSTa0 〜HSTa3 の値(データ)がそれぞれ格納されている。
【1080】
この水平一次統計処理では、各々の統計項目(MIN,MAX,HST0 〜HST3 )について水平方向に画素6個分の間隔(ピッチ)を置いて垂直方向における統計データ(MINa,MAXa,HSTa0 〜HSTa3 )を抽出し、その抽出した垂直統計データを画素6個分だけ離れて隣接する各3列分のデータに区分けし、各区分毎にMIN演算、MAX演算および度数演算を行って、各統計項目につき水平方向における40個の一次統計データ(MINb、MAXb、HSTb0 〜HSTb3 )を求める。
【1090】
図16に、水平一次統計処理における処理部18内の作用を示す。この統計処理は4つの命令(B1 )〜(B4 )によって実行される。
【1100】
1回目の命令(B1 )は条件付き移動命令(KMOV)であり、各プロセッシング・エレメントPEは自己のレジスタ領域[K1 ] にセットされている値に応じて2つ左先(K1 が1のとき)もしくは右先(K1 が0のとき)のプロセッシング・エレメントPEからデータを受け取る。この水平方向のデータ移動操作はL/R通信部28を用いて行われる。
【1110】
本実施例では、画素6個置きの間隔で3列単位の統計をとるため、プロセッシング・エレメントPE6 ,PE24,PE42,PE60,…PE708 を各区分の中心点とし、各区分内でこの中心点から左側のプロセッシング・エレメントPEにはK1 =1(→の向き)をセットし、右側のプロセッシング・エレメントPEにはK1 =0(←の向き)をセットしている。
【1120】
2回目の命令(B2 )も条件付き移動命令(KMOV)であり、上記と同様な水平方向における2画素(PE)分のデータ移動操作を行う。この結果、各プロセッシング・エレメントPE6 ,PE24,…の左右2つ先の位置に、左右に6個離れたプロセッシング・エレメント(PE0 ,PE12),(PE18,PE30),…からのデータが到達する。
【1130】
次に、第3および第4の命令(B3 ),(B4 )でMIN,MAXまたは加算(ADD)演算を2回続けて実行することで、各プロセッシング・エレメントPE6 ,PE24,…は、自己のデータと左右6個離れたプロセッシング・エレメント(PE0 ,PE12),(PE18,PE30),…からのデータ(合計3個のデータ)との間での最小階調度MINb、最大階調度MAXbまたは度数HSTb0 〜HSTb3 を演算する。これらの演算結果は、レジスタ領域[MINb]、[MAXb]、[HSTb0 ]〜[HSTb3 ]に格納される。
【1140】
このように、この水平方向の一次統計処理では、水平方向に一定の間隔を置いた3個の垂直統計データを1組の区分とし、各区分内でトーナメント方式によるMIN,MAX演算を行って各区分毎の最小階調度MINb、最大階調度MAXbを求めるとともに、各区分内の合計演算により各区分毎の度数HSTb0 〜HSTb3 を求める。
【1150】
他のプロセッシング・エレメントPEも、同じ命令(B3 ),(B4 )にしたがってMIN演算、MAX演算または加算演算を行うが、結果として不要な演算結果を得る。
【1160】
上記のような処理部18における水平方向の一次統計処理は、各々の統計項目(MIN、MAX、HST0 〜HST3 )について行われる。本実施例では、2回に分けて、垂直ブランキング期間の最初の水平走査期間ではMIN、MAXおよびHST0 の各々について上記水平一次統計処理を行い(ステップS10)、次(2番目)の水平走査期間ではHST1 、HST2 およびHST3 の各々について上記水平一次統計処理を行う(ステップS13)。
【1170】
なお、各々の統計項目(MIN、MAX、HST0 〜HST3 )について上記水平方向の一次統計処理結果つまり水平一次統計データMINb、MAXb、HSTb0 〜HSTb3 が得られた時点で、各垂直統計データ(MINa,MAXa,HSTa0 〜HSTa3 )は用済みとなり、レジスタ領域[MINa]の内容が初期値「255」に、レジスタ領域[MAXa],[HSTa0 ]〜[HSTa3 ]の内容が初期値「0」にリセットされる(ステップS10,S13)。
【1180】
上記のように、水平方向の一次統計処理の結果として、処理部18内では、40個の統計区分のそれぞれの中心点に位置するプロセッシング・エレメントPE6 ,PE24,PE42,…PE708 のレジスタ領域[MINb]、[MAXb]、[HSTb0 ]〜[HSTb3 ]に、この一次統計処理の目的とする各40個の最小階調度MINb、最大階調度MAXb、度数HSTb0 〜HSTb3 の統計データが保持されている。
【1190】
他のプロセッシング・エレメントPEは、それらのプロセッシング・エレメントPE6 ,PE24,PE42,…と同じ命令にしたがって動作するものの、この統計処理では不要なデータを各々のレジスタ領域[MINb]、[MAXb]、[HSTb0 ]〜[HSTb3 ]に保持している。
【1200】
そこで、次に、このような不所望な演算結果のデータを捨てて、目的とする水平方向の一次統計データ(MINb、MAXb、HSTb0 〜HSTb3 )だけを抽出する処理を行う。
【1210】
この抽出処理は、以下に説明するように、SVP10においてDOR20からDIR16へのデータ転送によって行われる。
【1220】
すなわち、垂直ブランキング期間の2番目の水平走査期間の開始時(厳密にはまだ水平ブランキング期間が続いている間)に、処理部18の全てのプロセッシング・エレメントPE0 〜PEN-1 におけるレジスタ領域[MINb]、[MAXb]、[HSTb0 ]の内容がDOR20に一斉に転送される(ステップS12)。その中で、40個のプロセッシング・エレメントPE6 ,PE24,PE42,…PE708 のレジスタ領域[MINb]、[MAXb]、[HSTb0 ]からDOR20の対応レジスタに転送された分のデータが、目的とする各40個の水平一次統計データ(MINb、MAXb、HSTb0 )である。
【1230】
そして、2番目の水平走査期間中に、処理部18のプロセッシング・エレメントPEが残りの統計項目(HSTb1 、HSTb2 、HSTb3 )の各々について水平方向の一次統計演算(ステップS13、図16)を行うのと並行して、図9および図19の*1に示すように、DOR20に蓄積されているデータが読み出しクロックSRCKのタイミング(伝送レート)で外部データパス21上に出力される。
【1240】
この際、DOR20においては、図10に示すように、出力ポートS0out よりMINbが、S1out よりMAXbが、S2out よりHSTb0 がそれぞれデータパス26,24,22上に出力される。
【1250】
一方、DIR16においては、図9および図19の*1に示すように、書き込みクロックSWCKがDOR20の読み出しクロックSRCKに同期しており、40個のプロセッシング・エレメントPE6 ,PE24,PE42,…PE708 の演算結果(MINb、MAXb、HSTb0 )が入力ポートS0in,S1in,S2inに来た時だけライトイネーブル信号(DIRWE)がアクティブとなる。
【1260】
こうして、DIR16は、DOR20より転送されるデータのうち不所望なデータを拒んで(入力することなく)、目的とする各40個の水平一次統計データ(MINb、MAXb、HSTb0 )だけを入力することになる。
【1270】
上記のようにして垂直ブランキング期間の2番目の水平走査期間中にDIR16に取り込まれた水平方向における各40個の一次統計データ(MINb、MAXb、HSTb0 )は、次の3番目の水平走査期間の開始時にDIR16から処理部18に転送される(ステップS16)。
【1280】
この場合、各40個の水平一次統計データ(MINb、MAXb、HSTb0 )は、処理部18の先頭40個のプロセッシング・エレメントPE0 ,PE1 ,…PE39のレジスタ領域[MINc]、[MAXc]、[HSTc0 ]に詰めて格納される。他のプロセッシング・エレメントPE40〜PE719 のレジスタ領域[MINc]、[MAXc]、[HSTc0 ]は実質的に空のままである。
【1290】
かくして、この3番目の水平走査期間中に、これら40個のプロセッシング・エレメントPE0 ,PE1 ,…PE39において、統計項目(MIN、MAX、HST0 )の各々について後述するような水平方向における二次統計処理が行われる(ステップS17)。
【1300】
残りの水平一次統計データ(HSTb1 、HSTb2 、HSTb3 )についても、1水平走査期間だけ時間を遅らせて上記と同様な動作が行われる。
【1310】
すなわち、垂直ブランキング期間の3番目の水平走査期間の開始時に、処理部18の全てのプロセッシング・エレメントPE0 〜PEN-1 におけるレジスタ領域[HSTb1 ]、[HSTb2 ]、[HSTb3 ]の内容がDOR20に一斉に転送される(ステップS15)。
【1320】
そして、3番目の水平走査期間中に、図9および図19の*2に示すように、DOR20に蓄積されているデータが読み出しクロックSRCKのタイミング(伝送レート)で外部データパス21上に出力される。
【1330】
この際、DOR20においては、図10に示すように、出力ポートS0out よりHSTb3 が、S1out よりHSTb2 が、S2out よりHSTb1 がそれぞれデータパス26,24,22上に出力される。
【1340】
一方、DIR16においては、図9および図19の*2に示すように、書き込みクロックSWCKがDOR20の読み出しクロックSRCKに同期しており、40個のプロセッシング・エレメントPE6 ,PE24,PE42,…PE708 の演算結果(HSTb3 ,HSTb2 、HSTb1 )が入力ポートS0in,S1in,S2inに来た時だけライトイネーブル信号(DIRWE)がアクティブとなる。
【1350】
こうして、DIR16は、DOR20より転送されるデータのうち不所望なデータを拒んで(入力することなく)、目的とする各40個の水平一次統計データ(HSTb1 ,HSTb2 、HSTb3 )だけを入力することになる。
【1360】
上記のようにして垂直ブランキング期間の3番目の水平走査期間中にDIR16に取り込まれた水平方向における各40個の一次統計データ(HSTb1 ,HSTb2 、HSTb3 )は、次の4番目の水平走査期間の開始時にDIR16から処理部18に転送され、先頭40個のプロセッシング・エレメントPE0 ,PE1 ,…PE39のレジスタ領域[HSTc1 ]、[HSTc2 ]、[HSTc3 ]に詰めて格納される(ステップS21)。
【1370】
かくして、この4番目の水平走査期間中に、これら40個のプロセッシング・エレメントPE0 ,PE1 ,…PE39において、統計項目(HSTc1 ,HSTc2 、HSTc3 )の各々について後述するような水平方向における二次統計処理が行われる(ステップS22)。
【1380】
図17および図18に、水平方向の二次統計処理のための処理部18内の作用を示す。図17は最小階調度および最大階調度演算に係る処理であり、図18は度数演算に係る処理である。
【1390】
図17に示すように、水平二次統計処理における最小階調度および最大階調度演算は、実質的には上記40個のプロセッシング・エレメントPE0 ,PE1 ,…PE39の間で、各々のレジスタ領域[MINc]、[MAXc]に格納されている水平一次統計データ(MINc、MAXc)についてトーナメント方式で行われる。このトーナメントは15個の命令(C1 )〜(C15)にしたがって実行される。
【1400】
たとえば、最小階調度演算のトーナメントは次のようになる。各プロセッシング・エレメントPEにおいて、最初のステップ(C1 )では、隣合う2つのデータ同士でMIN演算が行われ、小さい方がレジスタ領域[MINc ]に残る。
【1410】
第2のステップ(C2 )では、1つ置きに隣合うデータ同士でMIN演算が行われ、小さい方がレジスタ領域[MINc ]に残る。
【1420】
第3のステップ(C3 )では、各プロセッシング・エレメントPEのデータMINc を画素(PE)2個分だけ右方向にシフトさせ、計算途中データ保管レジスタ領域[S0 ]に格納する。
【1430】
第4のステップ(C4 )では、各プロセッシング・エレメントPEが、左側2つ先のデータS0 と自己のデータMINcとの間でMIN演算を行い、小さい方を自己のレジスタ領域[MINc ]に残す。この段階で、プロセッシング・エレメントPE4 ,PE12,PE20,PE28,PE36のレジスタ領域[MINc ]に各8ブロック(PE0 〜PE7 )、(PE8 〜PE15)、(PE16〜PE23)、……(PE32〜PE39)での最小階調度のデータが得られる。
【1440】
第5〜第7のステップ(C5 )〜(C7 )では、21番目のプロセッシング・エレメントPE20を中心として、その左側では右向きに、その右側では左向きに1回につき画素(PE)2個分だけデータMINcをシフトさせる。
【1450】
この3回の条件付き移動命令によって、13番目のプロセッシング・エレメントPE12からのデータMINcがプロセッシング・エレメントPE20の左側2つ離れた位置(PE18)に到達するとともに、29番目のプロセッシング・エレメントPE28からのデータMINcがプロセッシング・エレメントPE20の右側2つ先の位置(PE22)に到達する。
【1460】
また、5番目のプロセッシング・エレメントPE4 のデータMINcが6つ右側の位置(PE10)まで移動するとともに、35番目のプロセッシング・エレメントPE36のデータMINcが6つ左側の位置(PE30)まで移動する。
【1470】
以下、21番目のプロセッシング・エレメントPE20に着目すると、第8のステップ(C8 )では左側2つ先(PE18)に到達したPE12のデータMINcと自己のデータMINcとの間でMIN演算を行って小さい方を自己のレジスタ領域[MINc]に残し、次の第9のステップ(C9 )では右側2つ先(PE22)に到達したPE28のデータMINcと自己のデータMINcとの間でMIN演算を行って小さい方を自己のレジスタ領域[MINc]に残す。
【1480】
次いで、第10〜13のステップ(C10)〜(C13)では、4回の条件付き移動命令を通じて5番目のプロセッシング・エレメントPE4 のデータMINcを移動前の位置(PE10)から左側2つ先の位置(PE18)まで引き寄せるとともに、35番目のプロセッシング・エレメントPE36のデータMINcを移動前の位置(PE30)から右側2つ先の位置(PE22)まで引き寄せる。
【1490】
そして、第14および第15のステップ(C14),(C15)で、それら左右2つ先(PE18,PE22)に到達したPE4 ,PE36のデータMINcと自己のデータMINcとの間でMIN演算を行い、その中で最も小さいものを自己のレジスタ[MINc]に残す。
【1500】
上記のようなトーナメントの結果、21番目のプロセッシング・エレメントPE20のレジスタ領域[MINc]に最後に残るデータMINcが水平二次統計処理で求められた最小階調度であり、ひいては直前のフィールドについて求められた最小階調度である。
【1510】
最大階調度演算のトーナメントも、MIN演算がMAX演算に置き換わるだけで、上記と同様の仕方で行われる。その結果、21番目のプロセッシング・エレメントPE20のレジスタ領域[MAXc]に、水平二次統計処理で求められた最大階調度のデータつまり直前のフィールドにおける最大階調度MAXcのデータが得られる。
【1520】
なお、最小階調度および最大階調度演算のトーナメントにおいて、他の各プロセッシング・エレメントPEも、21番目のプロセッシング・エレメントPE20と同じ命令にしたがって動作するが、結果として不所望な演算結果を各レジスタ領域[MINc],[MAXc]に得ることになる。
【1530】
図18に示すように、水平二次統計処理における度数演算は、上記40個のプロセッシング・エレメントPE0 ,PE1 ,…PE39のレジスタ領域[HSTc0 ]、[HSTc1 ]、[HSTc2 ]、[HSTc3 ]に格納されている水平一次統計データ(HSTc0 、HSTc1 、HSTc2 、HSTc3 )をそれぞれ合計するものである。
【1540】
この合計演算は、14個の命令(D1 )〜(D14)にしたがって実行される。第1のステップ(D1 )で各隣合う2つ(PE0 ,PE1 )、(PE2 ,PE3 )、……(PE38,PE39)の小ブロックにおける度数の合計(20個)が求められ、第2のステップ(D2 )で各隣合う4つ(PE0 〜PE3 )、(PE4 〜PE7 )、……(PE36〜PE39)の中ブロックにおける度数の合計(10個)が求められ、第3のステップ(D3 )で各隣合う8つ(PE0 〜PE7 )、(PE8 〜PE15)、……(PE32〜PE39)の大ブロックにおける度数の合計(5個)が求められる。
【1550】
そして、第7、第8、第13および第14ステップ(D7 ),(D8 ),(D13)、(D14)で、これら5個の大ブロックを合わせた分の度数の合計が求められ、その最終合計値が21番目のプロセッシング・エレメントPE20のレジスタ領域[HSTc0 ]、[HSTc1 ]、[HSTc2 ]、[HSTc3 ]に得られる。
【1560】
第4〜第6のステップ(D4 )〜(D6 )および第9〜第12のステップ(D9 )〜(D12)では、21番目のプロセッシング・エレメントPE20を中心として両側4個の大ブロックの合計値を中心側に引き寄せるための条件付き移動命令が実行される。
【1570】
なお、上記したような水平二次統計処理における度数演算は、統計項目(HSTc0 、HSTc1 、HSTc2 、HSTc3 )の各々について行われる。
【1580】
本実施例では、水平一次統計処理と関連し、水平二次統計処理についても統計項目(MIN,MAX,HST0 〜HST3 )を2組に分け、垂直ブランキング期間の3番目の水平走査期間ではMINc,MAXc,HSTc0 の各々について上記水平二次統計処理の演算を行い(ステップS17)、4番目の水平走査期間でHSTc1 ,HSTc2 ,HSTc3 の各々について上記水平二次統計処理の演算を行う(ステップS22)。
【1590】
さらに、3番目の水平走査期間中に、上記のような水平二次統計処理(ステップS17)に続けて、当該フィールド分の最小階調度MINc,最大階調度MAXcをテンポラリフィルタに通して前回の最小および最大階調度演算で求められた最小階調度MINd,最大階調度MAXdとそれぞれ一定の比率で混合したものを、改めて今回の最小および最大階調度演算で求めた最小階調度MINc,最大階調度MAXcとする(ステップS18)。
【1600】
このテンポラリ・フイタルタリング処理は、図8に示すように、乗算器30,32と加算器34とで実現される。後述するように、前回の最小および最大階調度演算で求められた最小階調度MINd,最大階調度MAXdは、IG14の内部レジスタ(AUXFB)を介してSVP10の各プロセッシング・エレメントPEのレジスタ領域[MINd],[MAXd]に格納されている。
【1610】
このレジスタ領域[MINd],[MAXd]に乗算器30で所定の比率または係数k(0≦k≦1)たとえば3/4を掛けたものと、レジスタ領域[MINc],[MAXc]の内容に乗算器32で(1−k)たとえば1/4を掛けたものとを加算器34で加算し、その加算結果をレジスタ領域[MINc],[MAXc]の新たな内容とする。乗算器30,32および加算器34は、各プロセッシング・エレメントPE内のALU24およびワーキング・レジスタWRs 等によって実現される。
【1620】
このように、今回の最小階調度MINc,最大階調度MAXcに前回の最小階調度MINd,最大階調度MAXdが一定の割合で加味(混合)され、これが毎回繰り返されることで、何らかのノイズに起因して実体に合わない異常な最小階調度MINcまたは最大階調度MAXcが生成されても、上記のようなテンポラリ・フィタルタリング処理でこのエラーが効果的にマスクされ、非線形処理(LUT)の信頼性が保証されるようになっている。
【1630】
さらに、垂直ブランキング期間の第3の水平走査期間では、上記のようなテンポラリ・フイルタ(30,32,34)に通した後の最小階調度MINc、最大階調度MAXcについて減算器36で差分(MAXc−MINc)を求め、この差分の値を全階調度範囲幅RNKwcの演算値としてレジスタ領域[RNKwc]に格納する(ステップS18)。
【1640】
上記のようにして垂直ブランキング期間の第3の水平走査期間における処理が終了した時点で、SVP10の処理部18では21番目のプロセッシング・エレメントPE20のレジスタ領域[MINc]、[MAXc]、[RNKwc]の内容が目的とする最小階調度MINc、最大階調度MAXc、階調度範囲幅RNKwcであって、他の各プロセッシング・エレメントPEのレジスタ領域[MINc]、[MAXc]、[RNKwc]の内容は不要なデータである。
【1650】
そこで、第4の水平走査期間の開始時に、全プロセッシング・エレメントPE0 〜PEN-1 のレジスタ領域[MINc]、[MAXc]、[RNKwc]の内容をいったんDOR20に移し(ステップS20)、DOR20の内部出力端子より内部データ・パス23を介してIG14に転送する。
【1660】
この際、レジスタ領域[RNKwc ]の内容については、最下位2ビットを捨てて値を1/4に割算したもの(RNKwc /4)をDOR0に移す(ステップS20)。この値(RNKwc /4)は階調度範囲幅RNKwdに相当する。
【1670】
IG14においては、図9および図19の*3に示すように、DOR20の読み出しクロックSRCKのタイミングでDOR20からのデータつまりプロセッシング・エレメントPE0 〜PEN-1 のレジスタ領域[MINc]、[MAXc]、[RNKwc]の内容が入力ポートに与えられるが、外部タイミング制御部からのライトイネーブル信号AUXFBWEが21番目のクロックSRCKのタイミングでアクティブとなる。
【1680】
これによって、IG14は、目的とする21番目のプロセッシング・エレメントPE20のレジスタ領域[MINc]、[MAXc]、[RNKwc]からの最小階調度MINc、最大階調度MAXc、階調度範囲幅RNKwc/4のデータを最終統計値(MINd、MAXd、RNKwd)として取り込む。
【1690】
こうしてIG14の内部レジスタ(AUXFB)に格納された最終統計データ(MINd、MAXd、RNKwd)は、この直後に、非線形処理(LUT)で用いるためにマイクロ命令の一部として各プロセッシング・エレメントPEのレジスタ領域[MINd]、[MAXd]、[RNKwd]に転送される。
【1700】
垂直ブランキング期間の4番目の水平走査期間では、上記水平二次統計処理(ステップS22)により残りの各度数(HSTc1 ,HSTc2 ,HSTc3 )を演算した後、各階調度範囲RNG0 ,RNG1 ,RNG2 ,RNG3 毎に各最終度数統計値(HSTc0 ,HSTc1 ,HSTc2 ,HSTc3 )を各対応するゲイン(A0 ,A1 ,A2 ,A3 )に変換する(ステップS23)。本実施例において、この度数−ゲイン変換は下記の演算式▲1▼によって行われる。
【1710】
Ai =(4/14400)*(HSTci *64)*64
=1.138*HSTci
≒(9/8)*HSTci ………▲1▼
【1720】
ここで、この演算式▲1▼における定数「4」はヒストグラムの区分数つまり階調度範囲の個数(4)であり、定数「14400」はヒストグラムの母数つまり1フィールド内の統計処理対象となる画素数(240/2)×(720/6)である。また、括弧内の定数「64」は計算量を軽減するようHSTci の下位6ビットを切り捨て計算することにより生じる補正値であり、括弧外の定数「64」は少数点以下6ビットまでの値を64倍して整数表現するためのものである。
【1730】
この度数−ゲイン変換の演算結果(A0 ,A1 ,A2 ,A3 )はそれぞれレジスタ領域[Ax0 ],[Ax1 ],[Ax2 ],[Ax3 ]に格納される。
【1740】
なお、度数HSTまたはゲインAに所定の下限値または上限値を設定し、いずれかの階調度範囲RNGにおける度数HSTまたはゲインAが該下限値より少ないかまたは該上限値より多いときは、その度数またはゲインのうちの該下限値を下回る分の値または超える分の値を他の階調度範囲における度数またはゲインに適当な配分で分配することも可能である。
【1750】
すなわち、1つの階調度範囲に度数が過度に集中すると、階調度範囲における階調変換曲線の傾き(ゲイン)だけが極端に低くまたは大きくなって、全体的な非線形処理精度が低下するおそれがある。
【1760】
そこで、上記のように、足りない分または多すぎる分について他の階調度範囲との間で分配を行い、当該階調度範囲における度数またはゲインを上記下限値または上限値以内に制御または補正することが好ましい。
【1770】
上記の度数−ゲイン変換は上記水平二次統計処理(ステップS22)に引き続いて行われた演算であるから、21番目のプロセッシング・エレメントPE20のレジスタ領域[Ax0 ],[Ax1 ],[Ax2 ],[Ax3 ]の内容が目的とするゲインA0 ,A1 ,A2 ,A3 のデータであり、他の各プロセッシング・エレメントPEのレジスタ領域レジスタ領域[Ax0 ],[Ax1 ],[Ax2 ],[Ax3 ]の内容は不要なデータである。
【1780】
そこで、5番目の水平走査期間の開始時に、全プロセッシング・エレメントPE0 〜PEN-1 のレジスタ領域[Ax0 ],[Ax1 ],[Ax2 ],[Ax3 ]の内容をいったんDOR20に移し、DOR20の内部出力端子より内部データ・パス23を介してIG14に転送する。
【1790】
IG14においては、図9および図19の*4に示すように、DOR20の読み出しクロックSRCKのタイミングでDOR20からのデータつまりプロセッシング・エレメントPE0 〜PEN-1 のレジスタ領域[Ax0 ],[Ax1 ],[Ax2 ],[Ax3 ]の内容が入力ポートに与えられるが、外部タイミング制御部からのライトイネーブル信号AUXHBWEが第21番目のクロックの時だけアクティブとなる。
【1800】
これによって、IG14は、目的とする21番目のプロセッシング・エレメントPE20のレジスタ領域[Ax0 ],[Ax1 ],[Ax2 ],[Ax3 ]からのゲイン(A0 ,A1 ,A2 ,A3 )のデータを取り込む。
【1810】
こうしてIG14の内部レジスタ(AUXFB)に格納されたゲインデータ(A0 ,A1 ,A2 ,A3 )は、後述する非線形処理(LUT)が実行される時にマイクロ命令の一部としてこのIG14から各プロセッシング・エレメントPEに逐次供給される。
【1820】
次に、図20につき、本実施例における階調変換のための非線形処理(LUT)(ステップS8 )を説明する。
【1830】
この非線形処理演算は、水平走査線単位で処理部18の各プロセッシング・エレメントPEが各対応する画素データについて所定の演算を施すことにより、入力画像信号Yinに対して継続的に行われる。
【1840】
この非線形処理演算で用いるパラメータは、直前のフィールドないし垂直ブランキング期間中に得られた最小階調度MINd、最大階調度MAXd、階調度範囲幅RNKwdおよび各階調度範囲(RNG0 ,RNG1 ,RNG2 ,RNG3 )毎のゲイン(A0 ,A1 ,A2 ,A3 )である。このうち、MINd、MAXd、RNKwdは各プロセッシング・エレメントPEのレジスタ領域[MINd]、[MAXd]、[RNKwd]にそれぞれ格納されており、(A0 ,A1 ,A2 ,A3 )はIG14の内部レジスタ(AUXFB)に格納されている。
【1850】
図20において、この非線形処理演算は、各対応する入力画素データY(yin)について最小階調度MINdの値をコアリングレベルとするコアリング演算を行う第1のコアリング(L2 )と、この第1のコアリングの演算結果について階調度範囲RNGの個数(この例では4個)に応じた回数(4回)だけ続けて階調度範囲の幅RNKwdの値をコアリングレベルとするコアリング演算を行う第2のコアリング(L4 ,L9 ,L14)と、各々の第2のコアリング(L4 ,L9 ,L14)の演算前後の値の差分を求めてクリップするクリップまたは減算(L5 ,L10,L15)と、各々のクリップ(L5 ,L10,L15)の演算結果と各対応するゲイン(A0 ,A1 ,A2 )とを乗算する第1の乗算(L6 ,L11,L16)と、これら第1の乗算の演算結果を全て加え合わせる第1の加算(L12,L17)と、最終回の第2のコアリング(L14)の演算結果とそれに対応するゲイン(A3 )とを乗算する第2の乗算(L19)と、第1の加算(L12,L17)の演算結果と第2の乗算(L19)の演算結果とを加え合わせる第2の加算(L20)と、この第2の加算(L20) の演算結果と最小階調度MINdとを加え合わせる第3の加算(L21)と、この第3の加算(L21)の演算結果と最大階調度MAXdとを比較して小さい方を選択するMIN演算(L22)とを含んでいる。
【1860】
以下に、この非線形処理のための各プロセッシング・エレメントPEの動作を詳細に説明する。
【1870】
先ず、入力画素データY(yin)をレジスタ領域[Y]から[S0 ]に移し、このレジスタ領域[S0 ]の内容(y0 つまりyin)に対してレジスタ領域[MINd]の内容をコアリングレベルとするコアリング(CORE)L2 を演算して、演算結果をレジスタ領域[S0 ]に残す。
【1880】
次に、このレジスタ領域[S0 ]の内容(y1)をレジスタ領域[S1 ]に転送(L3 )して保存しておく。
【1890】
次に、レジスタ領域[S0 ]の内容(y1 )に対してレジスタ領域[RNKwd]の内容(RNKwd)をコアリングレベルとするコアリング(CORE)L4 を演算して、演算結果(y2 )をレジスタ領域[S0 ]に残す。
【1900】
次いで、レジスタ領域[S1 ]の内容(y1 )からレジスタ領域[S0 ]の内容(y2 )を減算(L5 )してクリップし、その演算結果(y3 )をレジスタ領域[S1 ]に格納する。
【1910】
次いで、レジスタ領域[S1 ]の内容(y3 )にレジスタ領域[A0 ]の内容(A0 )を乗算(L6 )して、その演算結果(y4 つまりA0 *y3 )をレジスタ領域[T0 ]に格納する。
【1920】
ここで、レジスタ領域[S1 ]の内容とレジスタ領域[A0 ]の内容との乗算は、図21に示すように、8ビット・データ同士の乗算であり、本来的には16ビットの乗算結果が得られる。このデータ長は大きすぎるので、点線で示す下位4ビット部分については演算から外し、最上位12ビットを有効出力とする。これでも、少数点2桁(ビット)まで計算しているので、精度は確保される。
【1930】
この演算結果(y4 )は、レジスタ領域[T0 ]にいったん格納した後、直ちにレジスタ領域[T1 ]に転送(L7 )する。
【1940】
次に、レジスタ領域[S0 ]の内容[y2 ]をレジスタ領域[S1 ]に転送(L8 )して保存しておく。
【1950】
そして、レジスタ領域[S0 ]の内容(y2 )に対してレジスタ領域[RNKwd]の内容(RNKwd)をコアリングレベルとするコアリング(CORE)L9 を演算して、演算結果(y5 )をレジスタ領域[S0 ]に残す。
【1960】
次いで、レジスタ領域[S1 ]の内容(y2 )からレジスタ領域[S0 ]の内容(y5 )を減算(L10)してクリップし、その演算結果(y6 )をレジスタ領域[S1 ]に格納する。
【1970】
次いで、レジスタ領域[S1 ]の内容(y6 )にレジスタ領域[A1 ]の内容(A1 )を乗算(L11)して、その演算結果(A1 *y6 )をレジスタ領域[T0 ]に格納する。この乗算(L11)でも、演算結果を12ビットで出力する。
【1980】
次に、このレジスタ領域[T0 ]の内容(A1 *y6 )にレジスタ領域[T1 ]の内容(y4 )を加算(L12)して足し合わせ、その演算結果(y7 )をレジスタ領域[T1 ]に残す。
【1990】
次に、レジスタ領域[S0 ]の内容[y5 ]をレジスタ領域[S1 ]に転送(L13)して保存しておく。
【2000】
そして、レジスタ領域[S0 ]の内容(y5 )に対してレジスタ領域[RNKwd]の内容(RNKwd)をコアリングレベルとするコアリング(CORE)L14を演算して、演算結果(y8 )をレジスタ領域[S0 ]に残す。
【2010】
次いで、レジスタ領域[S1 ]の内容(y5 )からレジスタ領域[S0 ]の内容(y8 )を減算(L15)してクリップし、その演算結果(y9 )をレジスタ領域[S1 ]に格納する。
【2020】
次いで、レジスタ領域[S1 ]の内容(y9 )にレジスタ領域[A2 ]の内容(A2 )を乗算(L16)して、その演算結果(A2 *y9 )をレジスタ領域[T0 ]に格納する。この乗算(L16)でも、演算結果を12ビットで出力する。
【2030】
次に、このレジスタ領域[T0 ]の内容(A2 *y9 )にレジスタ領域[T1 ]の内容(y7 )を加算(L17)して足し合わせ、その演算結果(y10)をレジスタ領域[T1 ]に残す。
【2040】
次に、レジスタ領域[S1 ]の内容(y8 )にレジスタ領域[A3 ]の内容(A3 )を乗算(L19)して、その演算結果(A3 *y8 )をレジスタ領域[T0 ]に格納する。
【2050】
次に、このレジスタ領域[T0 ]の内容(A3 *y8 )にレジスタ領域[T1 ]の内容(y10)を加算(L20)して足し合わせ、その演算結果(y11)をレジスタ領域[T0 ]に残す。
【2060】
次に、レジスタ領域[T0 ]の内容(y11)にレジスタ領域[MINd]の内容(MINd)を加算(L21)し、その演算結果をレジスタ領域[T0 ]の新たな内容とする。
【2070】
最後に、レジスタ領域[T0 ]の内容とレジスタ領域[MAXd]の内容(MAXd)との間でMIN演算(L22)を行って、上限をMAXdでクリップし、最終の演算結果(y12)を得る。この演算結果(y12)は出力画素データyout としてレジスタ領域[T0 ]に格納される。
【2080】
そして、このレジスタ領域[T0 ]に格納された演算結果y12(yout )は、次の水平走査期間の開始時(正確には水平ブランキング期間がまだ終了する前)にDOR20の対応レジスタに転送され(ステップS2 )、その水平走査期間中に他の全てのプロセッシング・エレメントPEからの演算結果と一緒に出力画像信号Yout としてDOR20より出力される。
【2090】
なお、上記演算式▲1▼に示すように、各階調度範囲RNG0 ,RNG1 ,RNG2 ,RNG3 において各ゲインA0 ,A1 ,A2 ,A3 と各度数HSTd0 ,HSTd1 ,HSTd2 ,HSTd3 とは一定の係数を介して互いに比例関係にある。この関係からすれば、上記非線形処理において各ゲインA0 ,A1 ,A2 ,A3 に代えて各度数HSTd0 ,HSTd1 ,HSTd2 ,HSTd3 を用いることも可能である。
【2100】
すなわち、各乗算L6 ,L11,L16,L19において、レジスタ領域[S1 ]の内容に、レジスタ領域[A0 ],[A1 ],[A2 ],[A3 ]の内容(A0 ,A1 ,A2 ,A3 )ではなくレジスタ領域[HSTd0 ],[HSTd1 ],[HSTd2 ],[HSTd3 ]の内容(HSTd0 ,HSTd1 ,HSTd2 ,HSTd3 )を乗算し、乗算の演算結果を上記係数(9/8)で乗算しても、同様の結果が得られる。
【2110】
したがって、上記のような統計処理で求められた最小階調度MINd,最小階調度MAXd,階調度範囲幅RNKwdおよび度数(HSTd0 ,HSTd1 ,HSTd2 ,HSTd3 )をパラメータとして本実施例による非線形の階調変換を行うことも可能である。
【2120】
上記した実施例では、図22に示すように、各フィールド(たとえば画面1)に対する統計処理(1,2)で求められた統計値(MINd,MAXd,RNKwd ,A0 〜A3 )のうち、MINd,MAXdおよびRNKwd はその直後の1つのフィールド(画面2)における非線形処理に用いられるとともに度数演算工程(統計処理2)にも用いられ、A0 〜A3 はその直後の1つのフィールド(画面2)における非線形処理に用いられる。
【2130】
もっとも、各統計処理の対象となるフィールドまたはフレームと、その統計処理によって得られる統計値を用いる非線形処理ないし度数演算工程の対象となるフィールドまたはフレームとの関係は任意に設定可能である。たとえば、統計処理(1,2)を2フィールドに1回の割合で行い、その統計値を後続の複数のフィールドに対する非線形処理に用いることも可能である。
【2140】
上記した方法では、統計処理の対象となる画像(フィールド)と階調変換を受ける画像(フィールド)とが異なるが、1〜2フィールドの時間差なので、通常のアプリケーションでは特に階調変換精度に影響するほどのことではない。
【2150】
もっとも、図23に示すように、入力画像信号Yinをフィールドメモリまたはフレームメモリに通して1フィールドまたはフレーム(1F)だけ遅延させてから階調変換を行ってもよい。この場合は、図24に示すように、統計処理の対象となる画面と階調変換を受ける対象の画面とを一致させることができる。
【2160】
また、1つの表示画面を複数たとえば2分割して2つの画像A,Bを同時に表示する場合は、図25に示すように、各入力画像信号Yin(A),Yin(B)に対して統計処理および階調変換を別個に行う。特に、統計処理は各画面毎に交互に行う。階調変換は、各入力画像信号Yin(A),Yin(B)に対して並列的または時分割的に行う。
【2170】
また、上記実施例では、全階調度範囲の限界点および階調度範囲幅RNKwdを規定する最小階調度MINdおよび最大階調度MAXdを画像の階調に応じて動的に制御(更新)することで、階調度範囲RNGの個数を比較的少なめの4個に設定し、演算処理の軽減化を実現している。
【2180】
しかし、図26に示すように、階調度範囲RNGの個数を多め(たとえば8個)に設定することももちろん可能であり、動的な最小階調度MINdおよび最大階調度MAXdを用いることなく各階調度範囲RNGの位置および範囲幅RNKwdを一定(固定)値とすることも可能である。
【2190】
このように最小階調度MINdおよび最大階調度MAXdを用いない場合、非線形処理演算(図20)は、第1のコアリング(L2 )、第3の加算(L21)、最終段のMIN演算(L22)が不要となる。もっとも、第2のコアリング、クリップおよび第1の乗算の演算回数が増える。
【2200】
この場合の非線形処理演算は、各対応する入力画素データについて階調度範囲RNGの個数に応じた回数だけ続けて階調度範囲の幅の値RNKwd をコアリングレベルとするコアリング演算を行うコアリングと、各々のコアリングの演算前後の値の差分を求めてクリップするクリップまたは減算と、各々のクリップの演算結果と各対応するゲイン(または度数)とを乗算する第1の乗算と、これら第1の乗算の演算結果を全て加え合わせる第1の加算と、最終回のコアリングの演算結果とそれに対応するゲイン(または度数)とを乗算する第2の乗算と、第1の加算の演算結果と第2の乗算の演算結果とを加え合わせる第2の加算とを含むことになる。
【2210】
上記した実施例では、フィールドまたはフレームの垂直方向および水平方向において統計処理の対象となる水平走査線および画素列を効果的に間引いて処理の効率化をはかっている。もっとも、このような間引きのパターンは種々の変形が可能であり、上記実施例の間引き方法は一例にすぎない。実際のアプリケーションでは、画面の一部、典型的には中央部付近の領域についてのみ統計処理を行う方法としてもよい。
【2220】
図27〜図33に、上記した本実施例における階調変換の手順を実行させるためのプログラムリストを示す。
【2230】
本実施例では、IG14内のプログラムメモリにこのプログラムがコード化された状態で格納される。このIG14のプログラムメモリには、所定のインタフェース(図示せず)を介して外部ROMまたは外部コントローラ等よりプログラムデータがロードされる。
【2240】
このプログラムの1つ1つの命令に対してSVP10の全プロセッシング・エレメントPE0 〜PEN-1 が一斉に同一の演算処理を行うため、画像信号の伝送レートが高くても、精度の高い統計処理および階調変換を走査線単位で効率よく実行することができる。
【2250】
そして、SVP10の機能を利用することで、統計処理および階調変換における個々の処理を高度化かつ多様化することができる。つまり、プログラムの内容を適宜変更・変形することで、SVP10には何の手を加えずに多種多様なアプリケーションに対応することができる。また、システムの設計はプログラムの書き換えだけで済み、シュミレーションも非常に簡単である。
【2260】
【発明の効果】
以上説明したように、本発明の画像階調変換方法によれば、多種多様な画像フォーマットに1つのハードウェアシステムで効率よく対応することができ、しかも動画像に対して多様かつ高度な階調変換を容易に行うことかできる。
【図面の簡単な説明】
【図1】本発明の画像階調変換方法で用いるSIMD型並列プロセッサ(SVP)の構成例を示すブロック図である。
【図2】実施例におけるSVPの要部(コア)の構成を模式的に示す図である。
【図3】実施例における階調変換方法の原理を説明するための階調変換特性曲線およびヒストグラムの例を示す図である。
【図4】実施例におけるSVPの処理手順(垂直走査期間中の処理)を示すフローチャートである。
【図5】実施例におけるSVPの処理手順(垂直ブランキンク期間中の処理)を示すフローチャートである。
【図6】実施例におけるSVPの処理手順(垂直ブランキンク期間中の処理)を示すフローチャートである。
【図7】実施例におけるSVPの処理手順(垂直ブランキンク期間中の処理)を示すフローチャートである。
【図8】実施例におけるSVP内の全体の処理およびデータの流れを示すブロック図である。
【図9】実施例におけるSVP内の全体の処理およびデータの流れを示すタイミング図である。
【図10】実施例におけるSVPの出力ポートと入力ポートとの間の接続関係を示すブロック図である。
【図11】実施例におけるSVP内の各プロセッシング・エレメントのレジスタ・ファイルに設けられるレジスタ領域を示す図である。
【図12】実施例における垂直方向の統計処理の手法を概念的に示す図である。
【図13】実施例において垂直方向の最小階調度および最大階調度を求めるためのプロセッシング・エレメントの処理を示すブロック図である。
【図14】実施例において垂直方向の度数を求めるためのプロセッシング・エレメントの処理を示すブロック図である。
【図15】入力画素データの各段階の階調度に対する図14の各部におけるデータの値を示す図である。
【図16】実施例における水平方向の一次統計処理の作用を説明するための図である。
【図17】実施例における水平方向の二次統計処理(最小階調度,最大階調度の演算)の作用を説明するための図である。
【図18】実施例における水平方向の二次統計処理(度数の演算)の作用を説明するための図である。
【図19】図9の一部の作用を時間軸方向で拡大して示すタイミング図である。
【図20】実施例における階調変換のための非線形処理の作用を示す図である。
【図21】実施例の非線形処理の中の乗算出力に対する丸めを示す図である。
【図22】実施例における画面の流れと各処理との関係を示す図である。
【図23】実施例においてフレームメモリにより入力画像信号を1フィールドまたは1フレーム遅らせてから階調変換を行う方法を示す図である。
【図24】図23の方法における画面の流れと各処理との関係を示す図である。
【図25】1つの画面を2つに分割して左右に2つの画面を表示する場合の実施例における処理方法を説明するための図である。
【図26】実施例における階調変換曲線フォーマットおよびヒストグラムの一変形例を示す図である。
【図27】実施例における階調変換方法を実施するためのプログラムのリストである。
【図28】実施例における階調変換方法を実施するためのプログラムのリストである。
【図29】実施例における階調変換方法を実施するためのプログラムのリストである。
【図30】実施例における階調変換方法を実施するためのプログラムのリストである。
【図31】実施例における階調変換方法を実施するためのプログラムのリストである。
【図32】実施例における階調変換方法を実施するためのプログラムのリストである。
【図33】実施例における階調変換方法を実施するためのプログラムのリストである。
【図34】画像の階調変換の原理を説明するための図である。
【符号の説明】
10 SVP
12 SVPコア
14 IG(命令発生部)
16 DIR(データ入力レジスタ)
18 処理部
20 DOR(データ出力レジスタ)
PE プロセッシング・エレメント
RF0 ,RF1 レジスタ・ファイル
[0010]
BACKGROUND OF THE INVENTION
The present invention relates to a method for converting the gradation of an image by digital processing technology.
[0020]
[Prior art]
In the digital image processing technique, a process for converting the gradation of an image according to an image pattern is a technique for improving image quality.
[0030]
FIG. 34 schematically shows the basic principle of image gradation conversion. In this figure, the horizontal axis indicates the range of gradation levels that can be taken by the input image VMin, and the vertical axis shows the range of gradation levels that can be taken by the output image VMout.
[0040]
If image gradation conversion is not performed on the input image VMin, an image signal is output with a constant gain at any gradation. In this case, as indicated by a straight line L0 in FIG. 34, the gradation of the input image VMin and the gradation of the output image VMout have a linear relationship.
[0050]
However, for a bright picture image, for example, a non-linear gradation characteristic as shown by a curve LB in FIG. 34 is used, and the gain of an image signal having a higher gradation than that of an image signal having a lower gradation is relatively set. The higher the resolution is, the more precise the gradation of the whole image is. On the contrary, when the picture is dark, for example, a non-linear gradation characteristic as shown by the curve LA in FIG. 34 is used, and the image signal with a low gradation is made higher than the image signal with a high gradation, The image quality can be improved.
[0060]
Conventionally, a moving image processing system in a television receiver or the like is equipped with a microprocessor as a standard, but since the transmission rate of television images is very high, the gradation conversion processing as described above is performed by a gate array or an ASIC. It is entrusted to a dedicated hardware circuit.
[0070]
This type of dedicated hardware circuit handles the input image signal sequentially or in time series in units of pixels, executes a predetermined algorithm for tone conversion, and obtains a tone-converted output image signal I am doing so.
[0080]
[Problems to be solved by the invention]
However, in the method using the conventional dedicated hardware circuit as described above, since the algorithm or logic of gradation conversion is specialized or fixed, there is a disadvantage that it cannot flexibly cope with various image formats in the multimedia era. is there. For example, a dedicated hardware circuit for NTSC signals can only perform constant gradation conversion only for NTSC signals, and cannot handle other formats such as PAL image signals.
[0090]
Therefore, when one TV receiver is equipped with a gradation conversion function that can handle various video signals such as NTSC signals, satellite broadcasts, high-definition signals, and PC output signals, dedicated hardware for each type of video signal is provided. The entire circuit must be built in, resulting in a very expensive and large device.
[0100]
In addition, in the conventional method of processing the input image signal in units of pixels sequentially or in time series, when the transmission rate of the image signal is high as in HD, complicated processing such as gradation conversion becomes difficult. As a result, the logic becomes more complicated and the circuit scale becomes larger. The dedicated hardware circuit has an inconvenience that the number of gates exponentially increases as the logic becomes more complicated, which makes it difficult to design and simulate and greatly increases the development period.
[0110]
The present invention has been made in view of such problems, and an object of the present invention is to provide an image gradation conversion method that can efficiently cope with various image formats with a single hardware system.
[0120]
It is another object of the present invention to provide an image gradation conversion method capable of easily performing various and advanced gradation conversions on a moving image.
[0130]
[Means for Solving the Problems]
  In order to achieve the above object, the present inventionIn the first aspectThe image gradation conversion method includes a plurality of processing elements that are assigned to pixels on a scanning line in a one-to-one correspondence relationship and perform the same operation in accordance with a common command. The gradation level of the input image signal is classified into one of a plurality of gradation levels each having a predetermined width for each pixel by a SIMD type parallel processor having a function of processing in units, and each gradation level range is entered. The frequency calculation step of counting pixels to determine the frequency, and the SIMD parallel processor performs an arithmetic operation on the input image signal according to the gradation degree range and the frequency to calculate the frequency of the input image signal. A gradation conversion process for converting the gradation.Then, the gradation conversion step is continued by the number of times corresponding to the number of the gradation range for each corresponding input pixel data by each processing element, and the value of the width of the gradation range is set as the coring level. A coring step for performing a coring operation, a clipping step for obtaining a difference between values before and after the calculation of each coring operation, a calculation result of each of the clip operations, and the corresponding frequency or gradation A first multiplication step of multiplying the slope of the conversion curve, a first addition step of adding all the calculation results of the first multiplication step, and a calculation result of the last coring calculation and the corresponding A second multiplication step of multiplying the frequency or the gradient of the gradation conversion curve, and the operation result of the first addition step and the operation result of the second multiplication step are added together. And a second adding step that.
[0140]
  Also,An image gradation conversion method according to a second aspect of the present invention includes a plurality of processing elements that are assigned to pixels on a scanning line in a one-to-one correspondence relationship and that perform the same operation according to a common command. Classifying the gradation of the input image signal into one of a plurality of gradation ranges each having a predetermined width for each pixel by a SIMD parallel processor having a function of processing the input image signal in units of scanning lines; A frequency calculation step for calculating the frequency by counting the pixels in each gradation level range, and a slope for determining the gradient of the gradation conversion curve corresponding to the frequency for each gradation range by the SIMD type parallel processor. The calculation step and the SIMD type parallel processor perform non-linear processing according to the gradation range and the inclination on the input image signal by calculation. A gradation conversion step for converting the gradation level of the input image signal, and the gradation conversion step is performed by the number of times corresponding to the number of the gradation range for each corresponding input pixel data by each processing element. Subsequently, a coring step of performing a coring operation using the value of the width of the gradation range as a coring level, a clipping step of obtaining and clipping a difference between values before and after the calculation of each coring operation, A first multiplication step of multiplying the calculation result of the clip calculation by the corresponding frequency or the slope of the gradation conversion curve; and a first addition step of adding all the calculation results of the first multiplication step. A second multiplication step of multiplying the calculation result of the last coring operation by the corresponding frequency or the gradient of the gradation conversion curve, and the first addition step And a second adding step of adding together the calculated result of the calculation results and the second multiplication step.
[0150]
  The image gradation conversion method according to the third aspect of the present invention includes a plurality of processing elements that are assigned to pixels on a scanning line in a one-to-one correspondence and that perform the same operation according to a common command. And a SIMD parallel processor having a function of processing an input image signal in units of scanning lines, and classifying the gradation of the input image signal into one of a plurality of gradation ranges each having a predetermined width for each pixel. Then, a frequency calculation step for counting the number of pixels in each gradation level range to obtain a frequency, and a non-linear process corresponding to the gradation level range and the frequency for the input image signal by the SIMD type parallel processor. A gradation conversion step for converting the gradation level of the input image signal by calculation, and a minimum and maximum level for obtaining a minimum gradation level and a maximum gradation level of the input image signal; A gradation calculation step, and a gradation range calculation step of determining the plurality of gradation ranges by dividing a gradation range between the minimum gradation and the maximum gradation by a predetermined number at equal intervals. The gradation conversion step includes: a first coring step of performing a coring operation with each processing element using a value of the minimum gradation degree as a coring level for each corresponding input pixel data; A second coring step of performing a coring operation in which the value of the width of the gradation range is set as a coring level continuously for a number of times corresponding to the number of the gradation ranges of the calculation result of the first coring step; A clipping step for obtaining and clipping a difference between values before and after each of the second coring calculations, and a calculation result of each of the clip calculations and the corresponding frequency or A first multiplication step of multiplying the gradient of the gradation conversion curve, a first addition step of adding all the calculation results of the first multiplication step, and a calculation of the second coring operation of the last round A second multiplication step of multiplying the result and the corresponding frequency or the slope of the gradation conversion curve, and a result of adding the calculation result of the first addition step and the calculation result of the second multiplication step. The second addition step, a third addition step of adding the operation result of the second addition step and the minimum gradation, and the operation result of the third addition step and the maximum gradation, Minimum value calculation process to select the smaller one andincluding.
[0160]
  The image gradation conversion method according to the fourth aspect of the present invention includes a plurality of processing elements that are assigned to pixels on a scanning line in a one-to-one correspondence and that perform the same operation according to a common command. And a SIMD parallel processor having a function of processing an input image signal in units of scanning lines, and classifying the gradation of the input image signal into one of a plurality of gradation ranges each having a predetermined width for each pixel. Then, the frequency calculation step of calculating the frequency by counting the pixels in each gradation level range, and the SIMD type parallel processor, the slope of the gradation conversion curve corresponding to the frequency is obtained for each gradation range. The obtained slope calculation step and the SIMD type parallel processor perform non-linear processing on the input image signal according to the gradation range and the slope by calculation. A gradation conversion step for converting the gradation of the input image signal; a minimum and maximum gradation calculation step for obtaining a minimum gradation and a maximum gradation of the input image signal; the minimum gradation and the maximum gradation; A gradation degree range calculating step for determining the plurality of gradation degree ranges by dividing the gradation degree range between them into a predetermined number at equal intervals, wherein the gradation conversion step includes each processing element. The first coring step for performing a coring operation using the minimum gradation value as the coring level for each corresponding input pixel data, and the calculation result of the first coring step in the gradation range. A second coring step of performing a coring operation in which the value of the width of the gradation range is used as a coring level in succession for a number of times, and each of the second corin A clipping step of finding and clipping a difference between values before and after the calculation, and a first multiplication step of multiplying the calculation result of each of the clip calculations and the corresponding frequency or the slope of the gradation conversion curve, Multiplying the first addition step of adding all the calculation results of the first multiplication step, the calculation result of the second coring operation of the last round, and the corresponding frequency or the slope of the gradation conversion curve The second multiplication step, the second addition step of adding the calculation result of the first addition step and the calculation result of the second multiplication step, the calculation result of the second addition step and the minimum A third addition step of adding the gradient, a minimum value calculation step of comparing the calculation result of the third addition step with the maximum gradation and selecting the smaller one;including.
[0170]
  In the image gradation conversion method of the present invention, with the above-described configuration, nonlinear gradation conversion is realized by the arithmetic processing of the SIMD type parallel processor without using a special memory for nonlinear processing, and a moving image Therefore, various and advanced gradation conversions can be performed.
[0180]
  In a preferred aspect of the present invention, the frequency calculation step is performed in units of input image signals for one field or one frame. In this case, preferably, the frequency calculation step may be performed every predetermined number of fields or frames and / or only for a part of input image areas in one field or one frame.
[0190]
  In a preferred aspect of the present invention, the frequency calculation step is performed only for pixels having a predetermined interval and scanning lines having a predetermined interval.
[0200]
  In a preferred aspect of the present invention, the frequency calculating step includes a vertical frequency in which each processing element calculates a frequency for each gradation range for each corresponding vertical pixel column during the vertical scanning period. During the calculation process and the subsequent vertical blanking period, all or some of the processing elements cooperate to obtain the frequency for all or part of the pixel columns in the vertical direction for each gradation range. A horizontal frequency calculation step of calculating the frequency for each gradation range in the field or frame in the horizontal direction.
[0210]
  In this case, preferably, each processing element has a plurality of frequency calculation value storage units respectively corresponding to a plurality of gradation degree ranges, and in the vertical frequency calculation step, in each corresponding pixel column in the vertical direction. It is determined which gradation level range each input pixel falls in, and “1” is added to the content of the frequency calculation storage unit corresponding to the corresponding gradation level range, and all other frequency calculation values You may add "0" to the content of a holding | maintenance part.
[0220]
  Alternatively, the frequency total calculation in the horizontal direction is divided into a plurality of times, and in the two horizontal frequency total calculations in succession, the calculation results of all the processing elements obtained in the previous frequency total calculation are once obtained from the parallel processor. It is also possible to output and output only the operation result corresponding to a predetermined processing element among all the output operation results to be input to the parallel processor as a calculation target for the subsequent frequency total operation.
[0230]
  In a preferred aspect of the present invention, the frequency obtained in each frequency calculation step is used in a gradation conversion step for an input image signal of a predetermined number of subsequent fields or frames.
[0240]
  In a preferred aspect of the present invention, a predetermined lower limit value or upper limit value is set for the frequency, and when the frequency in any gradation range is less than the lower limit value or greater than the upper limit value, The portion below the lower limit value or the portion above the upper limit value is distributed with the frequency in the other gradation range, and is corrected within the lower limit value or the upper limit value.
[0250]
  In a preferred aspect of the present invention, the minimum and maximum gradation calculation steps for obtaining the minimum gradation and the maximum gradation of the input image signal, and the gradation range between the minimum gradation and the maximum gradation are equally spaced. And a gradation range calculation step of determining a plurality of gradation levels by dividing into a preset number.
[0260]
  In this case, more preferably, the minimum and maximum gradation calculation steps are performed in units of input image signals for one field or one frame. More preferably, the minimum and maximum gradation calculation steps are performed every predetermined number of fields or frames. Alternatively, the minimum and maximum gradation calculation steps are performed only for a part of input image areas in one field or one frame.
[0270]
  In addition, the minimum and maximum gradation degree calculation steps may be performed only for pixels having a predetermined interval and scanning lines having a predetermined interval.
[0280]
  In a preferred aspect of the present invention, the minimum gradation and the maximum gradation obtained in each minimum and maximum gradation calculation step are the minimum gradation and the maximum gradation obtained in the previous minimum and maximum gradation calculation steps. Multiplied by the first coefficient k (0 ≦ k ≦ 1) and the minimum gradation value and the maximum gradation of the input image signal in the current field or frame are multiplied by the second coefficient (1-k). It is the sum of things.
[0290]
  In a preferred aspect of the present invention, in the minimum and maximum gradation calculation steps, each processing element calculates a minimum gradation and a maximum gradation for each corresponding vertical pixel column during a vertical scanning period. During the vertical minimum and maximum gradation calculation step and the subsequent vertical blanking period, all or some of the processing elements cooperate to minimize the minimum or all of the pixel columns in the vertical direction. A horizontal minimum and maximum gradation calculation step of calculating the minimum gradation and the maximum gradation for the field or frame by comparing the gradation and the maximum gradation in the horizontal direction.
[0300]
  In a preferred aspect of the present invention, each processing element has a minimum gradation storage unit corresponding to the minimum gradation, and in the vertical minimum gradation calculation step, the minimum is stored in advance during the vertical blanking period. Set the maximum gradation that the input image signal can take in the gradation storage unit, and sequentially compare with the contents of the minimum gradation storage unit for each pixel for each corresponding pixel column in the vertical direction during the subsequent vertical scanning period, The smaller one is stored as new contents in the minimum gradation storage unit.
[0310]
  In a preferred aspect of the present invention, each processing element has a maximum gradation storage unit corresponding to the maximum gradation, and in the vertical maximum gradation calculation step, a maximum is stored in advance during the vertical blanking period. Set the minimum gradation that the input image signal can take in the gradation storage unit, and sequentially compare the content of the maximum gradation storage unit for each pixel for each corresponding pixel column in the vertical direction during the subsequent vertical scanning period, The larger one is stored as new contents in the maximum gradation storage unit.
[0320]
  Further, the calculation of the minimum gradation and the maximum gradation in the horizontal direction may be performed by a tournament method.
[0330]
  In this case, preferably, the calculation of the minimum gradation and the maximum gradation according to the tournament method is divided into a plurality of tournaments, and between two successive tournaments, all the processing elements obtained in the previous tournament The operation result may be output once from the parallel processor, and only the operation result corresponding to a predetermined processing element among all the output operation results may be input to the parallel processor and used as an operation target for the subsequent tournament.
[0340]
  According to a preferred aspect of the present invention, in the image gradation conversion method according to the third or fourth aspect, the gradation conversion step is proportional to the slope of the gradation conversion curve for each gradation degree range. And the step of making the gradation of the output image continuous at the boundary between two adjacent gradation ranges.
[0350]
  In a preferred aspect of the present invention, the frequency calculation step is alternately performed for each input image signal for a plurality of input image signals corresponding to a plurality of images to be displayed on one screen.
[0355]
According to a twenty-fourth aspect of the present invention, in the image gradation conversion method according to the first or second aspect, in the gradation conversion step, the gradation level range is determined for each corresponding input pixel data by each processing element. A coring process for performing a coring operation in which the value of the width of the gradation range is used as a coring level in succession for the number of times, and a difference between values before and after each coring operation is obtained and clipped. All the calculation results of the clipping step, the first multiplication step of multiplying the calculation result of each clip calculation by the corresponding frequency or the slope of the gradation conversion curve, and the first multiplication step are added together A first addition step, a second multiplication step of multiplying the calculation result of the last coring operation by the corresponding frequency or gradient of the gradation transformation, And a second adding step of adding together the operation result of the first addition step of the operation result and the second multiplication step.
[0380]
  The recording medium in the first aspect of the present invention is:It has a plurality of processing elements that are assigned to the pixels on the scanning line in a one-to-one correspondence and perform the same operation according to a common command, and has a function of processing the input image signal in units of scanning lines In a SIMD type parallel processor, the gradation of the input image signal is classified into one of a plurality of gradation ranges each having a predetermined width for each pixel, and the number of pixels that fall within each of the gradation ranges is counted. AskFrequency calculationA procedure and a non-linear process corresponding to the gradation range and the frequency are arithmetically performed on the input image signal by the SIMD parallel processor to convert the gradation of the input image signal.Tone conversionFollow the stepsIn the gradation conversion procedure, each processing element continues the number of times corresponding to the number of gradation levels for each corresponding input pixel data, and sets the width value of the gradation range as a coring level. A coring procedure for performing a coring operation, a clip procedure for obtaining and clipping a difference between values before and after each of the coring operations, an operation result of each of the clip operations, and the corresponding frequency or gradation A first multiplication procedure for multiplying the slope of the conversion curve, a first addition procedure for adding all the calculation results obtained by executing the first multiplication procedure, and a calculation result of the last coring calculation and corresponding to it A second multiplication procedure for multiplying the frequency or the gradient of the gradation conversion curve, an operation result obtained by executing the first addition procedure, and the second multiplication A program for executing a second summing steps summing the calculation result of the execution of the steps formed by the recording.
[0390]
  The recording medium in the second aspect of the present invention is:A SIMD type parallel processor having a plurality of processing elements assigned to pixels on a scanning line and performing the same operation according to a common command, and having a function of processing an input image signal in units of scanning lines; The gradation level of the input image signal is classified into one of a plurality of gradation degree ranges each having a predetermined width for each pixel, and the number of pixels that fall within each gradation degree range is counted to obtain the frequency.Frequency calculationBy using the procedure and the SIMD type parallel processor, the gradient of the gradation conversion curve corresponding to the frequency is obtained for each gradation range.Inclination calculationA procedure and the SIMD type parallel processor perform non-linear processing according to the gradation range and the inclination on the input image signal by calculation, thereby converting the gradation of the input image signal.Tone conversionProcedure and executionIn the gradation conversion procedure, each processing element continues the number of times corresponding to the number of gradation levels for each corresponding input pixel data, and sets the width value of the gradation range as a coring level. A coring procedure for performing a coring operation, a clip procedure for obtaining and clipping a difference between values before and after each of the coring operations, an operation result of each of the clip operations, and the corresponding frequency or gradation A first multiplication procedure for multiplying the slope of the conversion curve, a first addition procedure for adding all the calculation results obtained by executing the first multiplication procedure, and a calculation result of the last coring calculation and corresponding to it A second multiplication procedure for multiplying the frequency or the gradient of the gradation conversion curve, an operation result obtained by executing the first addition procedure, and the second multiplication A program for executing a second summing steps summing the calculation result of the execution of the steps formed by the recording.
[0400]
DETAILED DESCRIPTION OF THE INVENTION
Hereinafter, embodiments of the present invention will be described with reference to FIGS.
[0410]
FIG. 1 shows a configuration example of a single-instruction multiple-data (SIMD) type parallel processor used in the image gradation conversion method of the present invention.
[0420]
This SIMD type parallel processor is configured as an SVP (Scan-line Video Processor) for inputting, parallel computing and outputting image signals in units of scanning lines.
[0430]
The SVP 10 has an SVP core 12 and an instruction generator (IG) 14 mounted on one chip. The SVP core 12 has a three-layer structure of a data input register (DIR) 16, a SIMD type digital signal processing unit 18, and a data output register (DOR) 20.
[0440]
The DIR 16 operates in accordance with a control signal (Control) from the external control circuit, a clock (SWCK) from the external clock circuit, and an address (ADDRESS) from the IG 14, for example, image data D 0 to three horizontal scanning lines. DN-1 (for example, 48 bits × 864 pixels) is repeatedly input.
[0450]
The SIMD type digital signal processing unit 18 is formed by arranging (connecting) processing elements PE0 to PEN-1 in a number (for example, 864) equal to the number N of pixels on one horizontal scanning line. These processing elements PE0, PE1,... PEN-1 operate in parallel according to an instruction from IG14, that is, an address (ADDRESS) and a microinstruction (MICROINSTRUCTION), and a clock (PCLK) from an external clock circuit, respectively. The same image processing operation is executed for the pixel data D0, D1,... DN-1 within one horizontal scanning period.
[0460]
The DOR 20 operates according to the control signal (Control) from the external control circuit, the clock (SRCK) from the external clock circuit, and the address (ADDRESS) from the IG 14, and the processing elements PE 0 to PEN- Data of the arithmetic processing result from 1 is output in alignment with image data D0 ′ to DN-1 ′ (for example, 32 bits × 864 pixels) for one horizontal scanning line.
[0470]
The clocks (SWCK), (PCLK), and (SRCK) supplied to the DIR 16, the processing unit 18, and the DOR 20 may be asynchronous with each other. The data transfer from the DIR 16 to the processing unit 18 and the data transfer from the processing unit 18 to the DOR 20 are performed within the horizontal blanking period, respectively.
[0480]
In this way, data input, parallel operation processing and data output for one horizontal scanning line are executed asynchronously and in parallel in a pipeline manner by the DIR 16, the processing unit 18 and the DOR 20, respectively, and real-time image processing is performed.
[0490]
In order to operate the SVP core 12 as a SIMD type parallel processor, the IG 14 stores a program memory including a RAM or a ROM for holding a required program, and a register for temporarily storing various intermediate data being processed in the SVP core 12 Etc., and jumps, subroutine calls, interrupts, etc. can be performed in accordance with an external mode signal (IMODE), a flag signal (IGFLAG-A / B), or the like.
[0495]
In this embodiment, the flag signal (IGFLAG-A) is synchronized with the horizontal synchronization signal (HSYNC) extracted from the input image signal, and the mode signal (IMODE) indicates one of the three modes 0, 1, and 2. Selectively direct.
[0500]
The program memory in the IG 14 stores a program for performing gradation conversion processing according to this embodiment.
[0510]
Here, the internal operation of the SVP core 12 will be schematically described with reference to FIG. As described above, the operation of each part in the SVP core 12 is controlled by the address (ADDRESS) from the IG 14, the microinstruction (MICROINSTRUCTION), the clock (PCLK) from the external clock circuit, and the like.
[0520]
In FIG. 2, the DIR 16 has a storage capacity (for example, 48 bits × 864 words) that can store input image data D0 to DN-1 for one line, and is divided into blocks. While the input image data D0 to DN-1 are transferred in the DIR 16, the pixel data..., DK-2, DK-1, DK, DK + 1, DK + 2,. In this way, each block of the DIR 16..., K-2, K-1, K, K + 1, K + 2,.
[0530]
Each processing element PEK of the processing unit 18 includes a pair of register files RF0 and RF1 each having a predetermined capacity (for example, 192 bits), one 1-bit arithmetic logic unit (ALU) 24, and a plurality of ( For example, four working registers WRs (M, A, B, C) 26 and a plurality of processing elements (PEK-4, PEK-3, PEK-2, right and left) adjacent to the left and right (for example, four each on the left and right) PEK-1, PEK + 1, PEK + 2, PEK + 3, PEK + 4) and an L / R (left / right) communication unit (LRCOM) 28 for exchanging data.
[0540]
One register file RF0 is connected to the register group of the corresponding block of DIR16, and the other register file RF1 is connected to the register group of the corresponding block of DOR20. The 1-bit data read from one or both of the register files RF0 and RF1 is given to any of the working registers (M, A, B, and C) and the multiplexer 30 of the L / R communication unit 28. And four processing elements (PEK-4, PEK-3, PEK-2, PEK-1, PEK + 1, PEK + 2, PEK + 3, PEK + 4) adjacent to each other through the latch circuit 32 Sent to.
[0550]
At the same time, the data from each of the adjacent processor elements (PEK-4, PEK-3, PEK-2, PEK-1, PEK + 1, PEK + 2, PEK + 3, PEK + 4) The data is sent to the multiplexers 34 and 36 of the L / R communication unit 28 of the element PEK, and any one of those data is selected to be one of the working registers (M, A, B, C). Entered. In FIG. 2, one of the data from the processor elements (PEK-4, PEK-3, PEK-2, PEK-1) on the left is selected and input to the working register (A). It is shown that.
[0560]
The ALU 24 performs a required operation on the data given from the working registers (M, A, B, C) and outputs the operation result. The data of the calculation result of the ALU 24 is written in one of the register files RF0 and RF1. In general, the data of the last calculation result in each horizontal scanning period is written in the register file RF1 on the output side as the pixel data DK 'of the final calculation processing result, and the DOR 20 from this register file RF1 during the immediately following horizontal blanking period. To the corresponding block register.
[0570]
The DOR 20 has a storage capacity (for example, 32 bits × 864 words) that can store output image data D0 ′ to DN-1 ′ for one line, and is divided into pixels. The pixel data D0 'to DN-1' obtained as a result of the arithmetic processing sent from the processing section 18 to the DOR 20 for each block is the pixel data D1 following the pixel data D0 'at the left end over one horizontal scanning period. .., D2 ',... Are sent from each block of the DOR 20 in order so as to follow the daisy chain.
[0580]
The processing unit 18 can store image data for two lines in the register files RF0 and RF1, thereby realizing a line memory function. The processing unit 18 can also execute each individual process on the image data of a plurality of channels in a time division manner during one horizontal scanning period.
[0590]
As shown in FIG. 1, the output terminal of the DOR 20 is connected to the input terminal of the DIR 16 through the external data path 21 and is connected to the data input terminal of the IG 14 through the internal data path 23. Yes. As will be described later, the SVP 10 once outputs the operation result data of each processing element PE from the DOR 20, and then again performs arbitrary processing via the DIR 16 or the IG 14 (in this case, as a part of the micro instruction). It can be returned to the register file RF0, RF1 of the element PE or used for calculation.
[0600]
Hereinafter, the gradation conversion method of the present embodiment implemented in the SVP 10 will be described.
[0605]
In this embodiment, as an example, an image signal to be subjected to gradation conversion is a luminance signal Y of a color television signal, the luminance level is gradation, and the resolution of an effective scanning screen in one field is, for example, 240 lines × 720. Let it be a pixel. However, the color signal C or the color difference signals RY and BY can be processed, the color level can be a gradation, and the screen resolution can be in any format.
[0610]
FIG. 3 shows the principle of the gradation conversion method in this embodiment. In this embodiment, four continuous gradation ranges RNG0, RNG1, RNG2, and RNG3 having the same width RNKwd with respect to the gradation (luminance level) of the input image signal Yin are set.
[0620]
Here, the width RNKwd, the minimum gradation MINd, and the maximum gradation MAXd of these four gradation ranges RNG0 to RNG3 are within the maximum gradation range [0 to LIMIT] that the input image signal Yin can take. Depending on the key, it is a value that dynamically changes at a constant period, for example, one field or an integer multiple thereof. When the input image signal Yin is 8-bit data, the maximum limit gradation LIMIT is “255”.
[0630]
In the method of this embodiment, the gradation of the input image is classified into one of the above four gradation ranges RNG0 to RNG3 for each pixel, and the pixels that fall in (corresponding to) the respective gradation ranges RNG0 to RNG3 are counted. Thus, the respective frequencies HSTd0, HSTd1, HSTd2, HSTd3 are obtained, and then the gradients of the gradation conversion curves (hereinafter referred to as gains) A0, A1, A2, AST, corresponding to the frequencies HSTd0, HSTd1, HSTd2, HSTd3 Find A3.
[0640]
Here, the gain A in each gradation range RNG is proportional to each HST with a coefficient corresponding to the number of pixels and the number of classification sections (the number of gradation ranges) as the parameters of the histogram, as shown in FIG. The gradation characteristic (curve) is continuous at the boundary between two adjacent gradation degree ranges.
[0650]
Then, the output image signal Yout having a desired gradation degree is obtained by converting the gradation degree of the input image signal Yin according to the nonlinear characteristic as shown in FIG. In this embodiment, such nonlinear gradation conversion is realized by the arithmetic processing of the SVP 10.
[0660]
Next, the processing operation of the SVP 10 for realizing the gradation conversion of this embodiment will be described with reference to FIGS.
[0670]
4 to 7 are flowcharts showing the processing procedure of the SVP 10. 8 and 9 are a block diagram and a timing diagram, respectively, showing the overall processing and data flow in the SVP 10. 10 to 21 are diagrams for explaining the processing at each stage in the SVP 10.
[0680]
In FIG. 4, initialization is performed prior to gradation conversion processing (step S0). In initialization, first, for example, bit allocation (allocation) as shown in FIG. 10 is set to the input / output ports in the DIR 16 and the DOR 20.
[0690]
In FIG. 10, in the DIR 16 on the input side, the least significant 8 bits [0 to 7] of the 48-bit input terminals are allocated to the input port for inputting the input image signal Yin, and three sets are arranged in the upper order. The 10-bit ports S0in [10-19], S1in [20-29], S2in [30-39] are set.
[0700]
In the D0R20 on the output side, the least significant 10-bit port S0out [0-9] among the 32-bit output terminals is allocated to the output port for outputting the output image signal Yout, and two sets are arranged at the higher order. The 10-bit ports S1out [10-19] and S2out [20-29] are set.
[0710]
The output ports S0out, S1out, S2out of D0R20 are connected to the input ports S0in, S1in, S2in of D1R16 via the external data path 21 (26, 24, 22).
[0720]
As will be described later, in this embodiment, data of four gains (A0, A1, A2, A3) respectively corresponding to the four gradation ranges RNG0 to RNG3 are output from the internal output terminal of the DOR 20, and the internal data The data is transferred to a predetermined register (AUXFB) in the IG 14 via the path 23. Therefore, a port for outputting data of each gain (A0, A1, A2, A3) is set to the internal output terminal of the DOR 20 by this initialization. Correspondingly, a register area (AUXFB) for storing the value (data) of each gain (A0, A1, A2, A3) is also set on the IG 14 side.
[0730]
Further, in this initialization (step S0), as shown in FIG. 11, various register areas are set in the storage areas of the register files RF0 and RF1 provided in each processing element PE.
[0740]
In one register file RF0, [MINa] and [MAXa] are register areas for storing data in the middle of the calculation in the vertical direction minimum gradation calculation and maximum gradation calculation or as a result data. These register areas [MINa] and [MAXa] are reset to initial values in this initialization and in the middle of horizontal statistical processing. The initial value of [MINa] is the maximum possible gradation value “255” that the image signal can take, and the initial value of [MAXa] is the minimum possible gradation value “0” that the image signal can take.
[0750]
[HSTa0] to [HSTa3] are register areas for storing data in the middle of the calculation in the vertical direction or the result. These register areas [HSTa0] to [HSTa3] are also reset to the initial value "0" during initialization and horizontal statistical processing.
[0760]
[RNKwc] is a register area for storing data in the middle of the gradation range calculation or as a result. [Ax0] to [Ax3] are register areas for storing calculation results of gains A0 to A3 for each gradation range RNG0 to RNG3. [S0] and [T0] are register areas for storing data in the middle of the calculation in the nonlinear processing (LUT) or as a result.
[0770]
In the other register file RF1, [Y] is a register area for storing each corresponding pixel data in the input image data Yin. [MINb] and [MINc] are register areas for storing data of the minimum gradation in the primary and secondary statistical processing in the horizontal direction, respectively. [MAXb] and [MAXc] are register areas for storing data of the maximum gradation in the horizontal primary and secondary statistical processing, respectively.
[0780]
[HSTb0] to [HSTb3] are register areas for storing the respective frequency data in the primary statistical processing in the horizontal direction. [HSTc0] to [HSTc3] are register areas for storing the data of each frequency in the secondary statistical processing in the horizontal direction.
[0790]
[K0] and [K1] are register areas for storing flag bits indicating the direction of movement in the horizontal data movement operation. [MINd], [MAXd], and [RNKwd] are register areas for storing values of minimum gradation, maximum gradation, and gradation range width used in nonlinear processing (LUT), respectively. [S1] and [T1] are register areas for storing various data being calculated in the nonlinear processing (LUT). [F1] is a register area for storing a sign bit generated in the frequency calculation process in the vertical direction.
[0800]
A predetermined bit width is assigned to each register area in the register files RF0 and RF1. In addition, each register area can be set as an independent storage area, as well as functionally different register areas can be used (shared) on the same storage area in a time-sharing manner.
[0805]
The area settings of the register files RF0 and RF1 do not necessarily have to be performed when the program is executed, but may be performed in the form of being embedded in the program when the program is created.
[0810]
In FIG. 4 again, after the initialization is completed, the flag A terminal is monitored to wait for the horizontal synchronization signal (HSYNC) (step S1). If the horizontal synchronization signal is input, step S2 is entered.
[0820]
In step S2, before the net horizontal scanning period (video signal period) starts, the output pixel data Y (DK ') of each processing element PE, which is the processing result of the previous horizontal scanning period, is stored in the register file RF0. Transfer from the register area [T0] to the corresponding register of DOR20.
[0830]
However, immediately after the start of the screen, the register area [T0] is empty. As can be seen from FIG. 9, the transfer of substantial output pixel data (output of Y) from RF0 ([T0]) to the DOR 20 is started from the third horizontal synchronizing signal.
[0840]
After step S2, the mode (IMODE) of the current horizontal scanning period is determined based on the mode signal (step S3). In this embodiment, three modes 0, 1, and 2 are set. During the vertical scanning period, the horizontal scanning periods of modes 1 and 2 are alternately repeated for each horizontal scanning line, and mode 0 is set during the vertical blanking period. .
[0850]
Therefore, during the vertical scanning period, the mode (IMODE) is 1 or 2, and does not become 0. Accordingly, the process proceeds to step S4, and while the horizontal blanking period continues, the input image signal Yin for one horizontal scanning line is taken into the processing unit 18 from the DIR 16, and each pixel data Y constituting the input image signal Yin is acquired. (DK) is stored in the register area [Y] of the register file RF1 in each processing element PEK.
[0860]
However, DIR 16 is empty immediately after the start of each field. As can be understood from FIG. 9, the substantial input pixel data capture (input of Y) from DIR 16 to RF1 ([Y]) starts from the second horizontal synchronizing signal.
[0870]
Next, in step S5, it is determined whether the current mode is 1 or 2. In the case of mode 1, only nonlinear processing (LUT) (step S8) described later is executed. In the case of mode 2, first, statistical processing (step S6) for determining the minimum gradation and maximum gradation in the vertical direction and statistical processing (step S7) for determining the frequency for each gradation range RNG0 to RNG3 are sequentially performed, and then nonlinear. Processing (LUT) (step S8) is performed.
[0880]
FIG. 12 conceptually shows a statistical processing technique for obtaining the minimum gradation, maximum gradation, and frequency in the vertical direction. As described above, in this SVP 10, the input image signal is transferred from the DIR 16 to the processing unit 18 in units of one horizontal scanning line, and each pixel data in the input image signal is taken into the corresponding processing element PE. That is, each processing element PE sequentially receives the pixel data of the corresponding column on the screen in the vertical direction in one line cycle.
[0890]
According to this embodiment, as shown in FIG. 12, every time each processing element PE inputs one piece of pixel data in each corresponding column in the vertical direction, the values of minimum gradation, maximum gradation, and frequency are input. MIN calculation, MAX calculation, and frequency calculation are performed in a manner that is sequentially updated. At the end of the vertical scanning period, the minimum gradation degree MINa, the maximum gradation degree MAXa in the vertical direction, and the frequency HSTa0 to RNG3 for each gradation degree range RNG0 to RNG3 The statistical value of HSTa3 is obtained.
[0900]
FIG. 13 is a block diagram showing the processing of each processing element PE (step S6) for obtaining the minimum gradation degree MINa and the maximum gradation degree MAXa in the vertical direction.
[0910]
As described above, “255” and “0” are set as initial values in the register areas [MINa] and [MAXa] of the register file RF0, respectively. As shown in FIG. 13, each processor element PE compares the gradation of this data with the contents of the register area [MINa] for the pixel data (Y) of each corresponding column input for each line. Is left in the register area [MINa], and the gradation of this data is compared with the contents of the register area [MAXa], and the larger value is left in the register area [MAXa]. The MIN operation and the MAX operation are performed using the ALU 24 and the working register WRs in each processor element PE.
[0920]
The above-described successive update MIN and MAX operations in the vertical direction are repeated for each horizontal scanning line. As a result, when the MIN and MAX operations for the last (lower end) horizontal scanning line are completed, the contents of the register areas [MINa] and [MAXa] are the minimum gradation levels obtained by statistics for the corresponding pixel columns in the vertical direction. The values are MINa and the maximum gradation MAXa.
[0930]
In this embodiment, the MIN and MAX calculation processes in the vertical direction are not performed on the horizontal scanning line in mode 1 but only on the horizontal scanning line in mode 2. That is, 120 of the 240 effective scanning lines in one field are performed at a rate of once per two horizontal scanning lines. In a normal image, since the gradation of adjacent bits is approximate, even if the horizontal scanning lines are thinned out at an appropriate interval, the errors in the statistical values MINa and MAXa are small. By thinning out such horizontal scanning lines, the redundancy of statistical processing in the vertical direction can be reduced and the efficiency can be improved.
[0940]
FIG. 14 is a block diagram showing the processing (step S7) of each processing element PE for obtaining the frequencies HSTa0 to HSTa3 for each gradation range RNG0 to RNG3 in the vertical direction. Further, FIG. 15 shows values of respective parts of this block diagram with respect to four-stage values (gradation levels) of the input pixel data (Y).
[0950]
In FIG. 14, after the input pixel data (Y) is transferred from the register area [Y] to the register area [S0], the contents of the register area [MINd] are subtracted from the contents (Y) of the register area [S0] ( H2), and the subtraction result (difference) is used as the new contents of the register area [S0]. Here, the register area [MINd] stores the value (data) of the minimum gradation MINd as the final statistical value in the previous minimum gradation calculation processing.
[0960]
Next, the contents of the register area [RNKwd] are subtracted from the contents of the register area [S0] (H3), and the subtraction result (difference) is used as the new contents of the register area [S0]. When a sign bit of a logical value “1” indicating a minus sign (−) is output from this subtraction operation (H3), this value 1 is set in the register area [F1].
[0970]
Therefore, when the value (gradation degree) of the input pixel data (Y) is smaller than (MINd + RNKwd), the content of the register area [F1] becomes 1. As a result, 1 is added to the register area [HSTa0] in the addition operation (H5), and the content of the register area [HSTa0] is increased by one.
[0980]
At this time, in the subtraction operations (H6) and (H10) in the subsequent stage, a sign bit (sign bit) indicating a minus sign (-) is output, and an exclusive OR operation (H7), (H11) and an inversion operation ( The output of H13) is 0. Thus, in addition operations (H8), (H12), and (H14), 0 is added to the register areas [HSTa1], [HSTa2], and [HSTa3], respectively, and the contents of these register areas are not changed.
[0990]
When the value (gradation degree) of the input pixel data (Y) is not less than (MINd + RNKwd) and smaller than (MINd + RNKwd × 2), the output sign of the subtraction operation (H3) becomes plus (+), but the subtraction operation ( The output signs of H6) and (H10) are maintained at minus (-). In this case, the output of the exclusive OR operation (H7) becomes 1, and in the addition operation (H8), 1 is added to the register area [HSTa1], and the contents of the register area [HSTa1] increase by one. On the other hand, in other addition operations (H5), (H12), and (H14), 0 is added to the register areas [HSTa0], [HSTa2], and [HSTa3], respectively, and the contents of these register areas are not changed.
[1000]
When the value of the input pixel data (Y) is not less than (MINd + RNKwd × 2) and smaller than (MINd + RNKwd × 3), only the contents of the register area [HSTa2] are incremented by one. If the value of Y is (MINd + RNKwd × 3) or more, only the contents of the register area [HSTa3] are increased by one.
[1010]
By the arithmetic processing as described above, at the end of the vertical scanning period, the contents of the register areas [HSTa0], [HSTa1], [HSTa2], [HSTa3] are statistically taken for each corresponding pixel column in the vertical direction. The pixel count value for each gradation range RNG0 to RNG3, that is, a value (data) representing the frequency HSTa0 to HSTa3.
[1020]
However, similar to the MIN and MAX calculation processes in the vertical direction described above, the frequency calculation process in the vertical direction is not performed for the horizontal scan line in mode 1, but is performed only for the horizontal scan line in mode 2.
[1030]
Next, in FIG. 4, the non-linear processing (LUT) (step S8) is performed on the input image signal Yin in each horizontal scanning line period, that is, in both modes 1 and 2, and the calculation result is as follows. An output image signal Yout obtained by gradation conversion with nonlinear characteristics as shown in FIG. 3 is obtained. This non-linear processing (LUT) will be described later in detail with reference to FIG.
[1040]
In FIG. 4, when the mode of the horizontal scanning line period becomes 0 in step S3, that is, when the vertical blanking period starts, the process proceeds to the processing during the vertical blanking period (VBLANK) (FIGS. 5 to 7). To do.
[1050]
As described below, during the vertical blanking period, the horizontal statistical processing is executed by inheriting the calculation result of the vertical statistical processing described above, so that the minimum value as the final statistical value in the immediately preceding field is obtained. A gradient, a maximum gradient, and a frequency are determined. Further, predetermined calculations are performed based on these final statistical values, thereby obtaining the gradation width RNKwd necessary for the linear processing (LUT) and gains A0 to A3 for each gradation range RNG0 to RNG3.
[1060]
In the present embodiment, in view of the SVP characteristics, the statistical processing in the horizontal direction is divided into two stages of primary and secondary, thereby reducing the information compression of statistical data or improving the processing efficiency.
[1070]
FIG. 12 also conceptually shows a method of primary statistical processing in the horizontal direction. As described above, when the vertical scanning period ends, the register areas [MINa], [MAXa], [HSTa0] to [HSTa3] of each processing element PE correspond to the vertical directions in the vertical scanning period. The minimum gradation degree MINa, the maximum gradation degree MAXa, and the values (data) of the respective frequencies HSTa0 to HSTa3 are stored.
[1080]
In this horizontal primary statistical processing, statistical data (MINa, MAXa, HSTa0 to HSTa3) in the vertical direction with an interval (pitch) of 6 pixels in the horizontal direction for each statistical item (MIN, MAX, HST0 to HST3). Is extracted, and the extracted vertical statistical data is divided into data of three adjacent columns separated by six pixels, and MIN calculation, MAX calculation, and frequency calculation are performed for each statistical item. Forty pieces of primary statistical data (MINb, MAXb, HSTb0 to HSTb3) in the horizontal direction are obtained.
[1090]
FIG. 16 shows the operation in the processing unit 18 in the horizontal primary statistical processing. This statistical processing is executed by four instructions (B1) to (B4).
[1100]
The first instruction (B1) is a conditional move instruction (KMOV), and each processing element PE is left two (when K1 is 1) depending on the value set in its register area [K1]. Or data from the processing element PE at the right end (when K1 is 0). This horizontal data movement operation is performed using the L / R communication unit 28.
[1110]
In this embodiment, in order to obtain statistics in units of three columns at intervals of every six pixels, the processing elements PE6, PE24, PE42, PE60,... PE708 are used as the center points of each section, and from this center point within each section. K1 = 1 (the direction of →) is set in the left processing element PE, and K1 = 0 (the direction of ←) is set in the right processing element PE.
[1120]
The second command (B2) is also a conditional move command (KMOV) and performs the data move operation for two pixels (PE) in the horizontal direction as described above. As a result, data from the processing elements (PE 0, PE 12), (PE 18, PE 30),... That are separated by 6 pieces to the left and right arrive at the left and right positions of the processing elements PE 6, PE 24,.
[1130]
Next, by executing the MIN, MAX or addition (ADD) operation twice in succession with the third and fourth instructions (B3), (B4), each processing element PE6, PE24,. Minimum gradation MINb, maximum gradation MAXb or frequency HSTb0 between the data and data from processing elements (PE0, PE12), (PE18, PE30),... .About.HSTb3 is calculated. These calculation results are stored in the register areas [MINb], [MAXb], [HSTb0] to [HSTb3].
[1140]
As described above, in the primary statistical processing in the horizontal direction, three vertical statistical data with a certain interval in the horizontal direction are set as one set, and MIN and MAX calculations are performed by the tournament method in each category. The minimum gradation degree MINb and the maximum gradation degree MAXb for each division are obtained, and the frequencies HSTb0 to HSTb3 for each division are obtained by summation within each division.
[1150]
Other processing elements PE perform MIN operation, MAX operation, or addition operation in accordance with the same instructions (B3) and (B4), but as a result, unnecessary operation results are obtained.
[1160]
The primary statistical processing in the horizontal direction in the processing unit 18 as described above is performed for each statistical item (MIN, MAX, HST0 to HST3). In this embodiment, the horizontal primary statistical processing is performed for each of MIN, MAX, and HST0 in the first horizontal scanning period of the vertical blanking period in two steps (step S10), and the next (second) horizontal scanning is performed. In the period, the horizontal primary statistical processing is performed for each of HST1, HST2, and HST3 (step S13).
[1170]
For each statistical item (MIN, MAX, HST0 to HST3), when the horizontal primary statistical processing result, that is, horizontal primary statistical data MINb, MAXb, HSTb0 to HSTb3 is obtained, each vertical statistical data (MINa, MAXa, HSTa0 to HSTa3) are used up, the contents of the register area [MINa] are reset to the initial value "255", and the contents of the register areas [MAXa], [HSTa0] to [HSTa3] are reset to the initial value "0". (Steps S10 and S13).
[1180]
As described above, as a result of the primary statistical processing in the horizontal direction, in the processing unit 18, the register area [MINb of the processing elements PE6, PE24, PE42,... PE708 located at the center points of the 40 statistical sections. ], [MAXb], and [HSTb0] to [HSTb3] hold statistical data of 40 minimum gradations MINb, maximum gradations MAXb, and frequencies HSTb0 to HSTb3, which are the objects of the primary statistical processing.
[1190]
Although the other processing elements PE operate according to the same instructions as those processing elements PE6, PE24, PE42,..., Unnecessary data is stored in each register area [MINb], [MAXb], [MAX] HSTb0] to [HSTb3].
[1200]
Then, next, processing for extracting only the desired horizontal primary statistical data (MINb, MAXb, HSTb0 to HSTb3) is performed by discarding data of such undesired calculation results.
[1210]
This extraction process is performed by data transfer from the DOR 20 to the DIR 16 in the SVP 10 as described below.
[1220]
That is, at the start of the second horizontal scanning period of the vertical blanking period (strictly, while the horizontal blanking period still continues), the register areas in all the processing elements PE0 to PEN-1 of the processing unit 18 The contents of [MINb], [MAXb], and [HSTb0] are transferred all at once to the DOR 20 (step S12). Among them, the data corresponding to the data transferred from the register areas [MINb], [MAXb], [HSTb0] of the 40 processing elements PE6, PE24, PE42,. Forty horizontal primary statistical data (MINb, MAXb, HSTb0).
[1230]
Then, during the second horizontal scanning period, the processing element PE of the processing unit 18 performs horizontal primary statistical calculation (step S13, FIG. 16) for each of the remaining statistical items (HSTb1, HSTb2, HSTb3). In parallel with this, as indicated by * 1 in FIGS. 9 and 19, the data stored in the DOR 20 is output onto the external data path 21 at the timing (transmission rate) of the read clock SRCK.
[1240]
At this time, the DOR 20 outputs MINb from the output port S0out, MAXb from S1out, and HSTb0 from S2out to the data paths 26, 24, and 22, respectively, as shown in FIG.
[1250]
On the other hand, in DIR16, as indicated by * 1 in FIGS. 9 and 19, the write clock SWCK is synchronized with the read clock SRCK of DOR20, and the calculation of 40 processing elements PE6, PE24, PE42,. The write enable signal (DIRWE) becomes active only when the result (MINb, MAXb, HSTb0) reaches the input ports S0in, S1in, S2in.
[1260]
Thus, the DIR 16 rejects (without inputting) undesired data from the data transferred from the DOR 20, and inputs only the intended 40 horizontal primary statistical data (MINb, MAXb, HSTb0). become.
[1270]
As described above, each of the 40 primary statistical data (MINb, MAXb, HSTb0) in the horizontal direction taken into the DIR 16 during the second horizontal scanning period of the vertical blanking period is the next third horizontal scanning period. Is transferred from the DIR 16 to the processing unit 18 (step S16).
[1280]
In this case, each of the 40 horizontal primary statistical data (MINb, MAXb, HSTb0) is stored in the register areas [MINc], [MAXc], [HSTc0] of the first 40 processing elements PE0, PE1,. ] And stored. The register areas [MINc], [MAXc], [HSTc0] of the other processing elements PE40 to PE719 remain substantially empty.
[1290]
Thus, during the third horizontal scanning period, in these 40 processing elements PE0, PE1,... PE39, secondary statistical processing in the horizontal direction as will be described later for each of the statistical items (MIN, MAX, HST0). Is performed (step S17).
[1300]
For the remaining horizontal primary statistical data (HSTb1, HSTb2, HSTb3), the same operation as described above is performed with the time delayed by one horizontal scanning period.
[1310]
That is, at the start of the third horizontal scanning period of the vertical blanking period, the contents of the register areas [HSTb1], [HSTb2], and [HSTb3] in all the processing elements PE0 to PEN-1 of the processing unit 18 become DOR20. The data are transferred all at once (step S15).
[1320]
During the third horizontal scanning period, data accumulated in the DOR 20 is output onto the external data path 21 at the timing (transmission rate) of the read clock SRCK, as indicated by * 2 in FIGS. The
[1330]
At this time, in the DOR 20, as shown in FIG. 10, HSTb3 is output from the output port S0out, HSTb2 is output from S1out, and HSTb1 is output from S2out to the data paths 26, 24, and 22, respectively.
[1340]
On the other hand, in DIR16, as shown by * 2 in FIGS. 9 and 19, the write clock SWCK is synchronized with the read clock SRCK of DOR20, and the calculation of 40 processing elements PE6, PE24, PE42,. The write enable signal (DIRWE) becomes active only when the results (HSTb3, HSTb2, HSTb1) come to the input ports S0in, S1in, S2in.
[1350]
Thus, the DIR 16 rejects (without inputting) undesired data from the data transferred from the DOR 20, and inputs only the intended 40 horizontal primary statistical data (HSTb1, HSTb2, HSTb3). become.
[1360]
As described above, each of the 40 primary statistical data (HSTb1, HSTb2, HSTb3) in the horizontal direction taken into the DIR 16 during the third horizontal scanning period of the vertical blanking period is the next fourth horizontal scanning period. Is transferred from the DIR 16 to the processing unit 18 and stored in the register areas [HSTc1], [HSTc2], [HSTc3] of the first 40 processing elements PE0, PE1,... PE39 (step S21).
[1370]
Thus, during this fourth horizontal scanning period, in these 40 processing elements PE0, PE1,... PE39, secondary statistical processing in the horizontal direction as will be described later for each of the statistical items (HSTc1, HSTc2, HSTc3). Is performed (step S22).
[1380]
17 and 18 show the operation in the processing unit 18 for the secondary statistical processing in the horizontal direction. FIG. 17 shows processing related to the minimum gradation degree and maximum gradation degree calculation, and FIG. 18 shows processing related to the frequency calculation.
[1390]
As shown in FIG. 17, the minimum gradation degree and maximum gradation degree calculation in the horizontal secondary statistical processing is substantially performed between each of the register areas [MINc between the 40 processing elements PE0, PE1,. ], The primary horizontal statistical data (MINc, MAXc) stored in [MAXc] is performed in the tournament method. This tournament is executed according to 15 instructions (C1) to (C15).
[1400]
For example, the tournament for the minimum gradation calculation is as follows. In each processing element PE, in the first step (C1), the MIN operation is performed between two adjacent data, and the smaller one remains in the register area [MINc].
[1410]
In the second step (C2), every other adjacent data is subjected to a MIN operation, and the smaller one remains in the register area [MINc].
[1420]
In the third step (C3), the data MINc of each processing element PE is shifted rightward by two pixels (PE) and stored in the mid-calculation data storage register area [S0].
[1430]
In the fourth step (C4), each processing element PE performs a MIN operation between the data S0 on the two left side and its own data MINc, leaving the smaller one in its own register area [MINc]. At this stage, 8 blocks (PE0 to PE7), (PE8 to PE15), (PE16 to PE23),... (PE32 to PE39) are registered in the register area [MINc] of the processing elements PE4, PE12, PE20, PE28, and PE36. ) Data of the minimum gradation is obtained.
[1440]
In the fifth to seventh steps (C5) to (C7), data for two pixels (PE) is obtained at a time with the 21st processing element PE20 as the center, rightward on the left side and leftward on the right side. Shift MINc.
[1450]
As a result of these three conditional movement instructions, the data MINc from the 13th processing element PE12 arrives at the position (PE18) two positions away from the left side of the processing element PE20, and from the 29th processing element PE28. The data MINc arrives at the position (PE22) that is two points ahead of the processing element PE20.
[1460]
The data MINc of the fifth processing element PE4 moves to the right six positions (PE10), and the data MINc of the 35th processing element PE36 moves to the six left positions (PE30).
[1470]
In the following, focusing on the 21st processing element PE20, in the eighth step (C8), a small MIN operation is performed between the data MINc of PE12 that has reached the left two (PE18) and its own data MINc. Is left in its own register area [MINc], and in the next ninth step (C9), the MIN operation is performed between the data MINc of PE28 that has reached the right two (PE22) and its own data MINc. The smaller one is left in its own register area [MINc].
[1480]
Next, in the tenth to thirteenth steps (C10) to (C13), the data MINc of the fifth processing element PE4 is moved to the left two positions from the position before movement (PE10) through four conditional movement instructions. At the same time, the data MINc of the 35th processing element PE36 is drawn from the position before movement (PE30) to the position two positions ahead (PE22).
[1490]
Then, in the fourteenth and fifteenth steps (C14) and (C15), a MIN operation is performed between the data MINc of PE4 and PE36 that have reached the two left and right sides (PE18 and PE22) and the own data MINc. The smallest one is left in its own register [MINc].
[1500]
As a result of the above tournament, the last data MINc remaining in the register area [MINc] of the 21st processing element PE20 is the minimum gradation obtained by the horizontal secondary statistical processing, and is obtained for the immediately preceding field. Minimum gradation.
[1510]
The maximum gradation calculation tournament is performed in the same manner as described above, except that the MIN calculation is replaced with the MAX calculation. As a result, data of the maximum gradation obtained in the horizontal secondary statistical processing, that is, data of the maximum gradation MAXc in the immediately preceding field is obtained in the register area [MAXc] of the 21st processing element PE20.
[1520]
In the minimum gradation and maximum gradation calculation tournaments, each of the other processing elements PE operates according to the same instruction as the 21st processing element PE20. As a result, an undesired calculation result is stored in each register area. [MINc] and [MAXc] are obtained.
[1530]
As shown in FIG. 18, the frequency calculation in the horizontal secondary statistical processing is stored in the register areas [HSTc0], [HSTc1], [HSTc2], [HSTc3] of the 40 processing elements PE0, PE1,. The horizontal primary statistical data (HSTc0, HSTc1, HSTc2, HSTc3) are summed.
[1540]
This total operation is executed according to 14 instructions (D1) to (D14). In the first step (D1), the total frequency (20) in the small blocks of each two adjacent (PE0, PE1), (PE2, PE3),... (PE38, PE39) is obtained. In step (D2), the total of the frequencies (10) in the middle block of each of the four adjacent (PE0 to PE3), (PE4 to PE7), ... (PE36 to PE39) is obtained, and the third step (D3 ), The total of the frequencies (5) in the large block of each of the eight adjacent (PE0 to PE7), (PE8 to PE15),... (PE32 to PE39) is obtained.
[1550]
Then, in the seventh, eighth, thirteenth and fourteenth steps (D7), (D8), (D13), (D14), the sum of the frequencies obtained by combining these five large blocks is obtained. The final total value is obtained in the register areas [HSTc0], [HSTc1], [HSTc2], [HSTc3] of the 21st processing element PE20.
[1560]
In the fourth to sixth steps (D4) to (D6) and the ninth to twelfth steps (D9) to (D12), the total value of the four large blocks on both sides centering on the 21st processing element PE20 A conditional move command is executed to pull the to the center side.
[1570]
The frequency calculation in the horizontal secondary statistical processing as described above is performed for each of the statistical items (HSTc0, HSTc1, HSTc2, HSTc3).
[1580]
In this embodiment, in relation to the horizontal primary statistical processing, the statistical items (MIN, MAX, HST0 to HST3) are also divided into two sets for the horizontal secondary statistical processing, and MINc in the third horizontal scanning period of the vertical blanking period. , MAXc, HSTc0, the horizontal secondary statistical processing is calculated (step S17), and the horizontal secondary statistical processing is calculated for each of HSTc1, HSTc2, HSTc3 in the fourth horizontal scanning period (step S22). ).
[1590]
Further, during the third horizontal scanning period, following the above-described horizontal secondary statistical processing (step S17), the minimum gradation MINc and the maximum gradation MAXc for the field are passed through the temporary filter and the previous minimum The minimum gradation MINd and the maximum gradation degree MAXd obtained by the maximum gradation degree calculation are mixed at a certain ratio, respectively, and the minimum gradation degree MINc and the maximum gradation degree MAXc obtained by the current minimum and maximum gradation degree computations are again obtained. (Step S18).
[1600]
This temporary-filtering process is realized by multipliers 30 and 32 and an adder 34 as shown in FIG. As will be described later, the minimum gradation MINd and the maximum gradation MAXd obtained in the previous minimum and maximum gradation calculations are the register areas [MINd of each processing element PE of the SVP 10 via the internal register (AUXFB) of the IG 14. ], [MAXd].
[1610]
The register areas [MINd] and [MAXd] multiplied by a predetermined ratio or coefficient k (0 ≦ k ≦ 1), for example 3/4, by the multiplier 30, and the contents of the register areas [MINc] and [MAXc] The multiplier 32 adds (1−k), for example, 1/4 multiplied by the adder 34, and the addition result is used as the new contents of the register areas [MINc] and [MAXc]. The multipliers 30 and 32 and the adder 34 are realized by the ALU 24 and the working register WRs in each processing element PE.
[1620]
In this way, the previous minimum gradation degree MINc and maximum gradation degree MAXc are added (mixed) to the current minimum gradation degree MINc and maximum gradation degree MAXc at a certain ratio, and this is repeated every time, resulting in some noise. Even if an abnormal minimum gradation MINc or maximum gradation MAXc that does not match the substance is generated, this error is effectively masked by the temporary filtering as described above, and the reliability of nonlinear processing (LUT) is improved. It has come to be guaranteed.
[1630]
Further, in the third horizontal scanning period of the vertical blanking period, the subtractor 36 makes a difference between the minimum gradation MINc and the maximum gradation MAXc after passing through the temporary filter (30, 32, 34) ( MAXc−MINc) is obtained, and the value of this difference is stored in the register area [RNKwc] as the calculated value of the full gradation range width RNKwc (step S18).
[1640]
When the processing in the third horizontal scanning period of the vertical blanking period is completed as described above, the processing unit 18 of the SVP 10 registers the register areas [MINc], [MAXc], [RNKwc] of the 21st processing element PE20. ] Are the target minimum gradation degree MINc, maximum gradation degree MAXc, and gradation degree range width RNKwc, and the contents of the register areas [MINc], [MAXc], and [RNKwc] of the other processing elements PE are Unnecessary data.
[1650]
Therefore, at the start of the fourth horizontal scanning period, the contents of the register areas [MINc], [MAXc], [RNKwc] of all the processing elements PE0 to PEN-1 are temporarily transferred to the DOR 20 (step S20). Transfer from the output terminal to the IG 14 via the internal data path 23.
[1660]
At this time, as for the contents of the register area [RNKwc], the least significant 2 bits are discarded and the value is divided by 1/4 (RNKwc / 4) is transferred to DOR0 (step S20). This value (RNKwc / 4) corresponds to the gradation range width RNKwd.
[1670]
In IG14, as indicated by * 3 in FIGS. 9 and 19, the data from DOR20, that is, the register areas [MINc], [MAXc], [MAXc], [Processing elements PE0 to PEN-1] at the timing of DOR20 read clock SRCK. Although the contents of RNKwc] are given to the input port, the write enable signal AUXFBWE from the external timing control unit becomes active at the timing of the 21st clock SRCK.
[1680]
Thereby, the IG 14 has the minimum gradation MINc, the maximum gradation MAXc, and the gradation range width RNKwc / 4 from the register areas [MINc], [MAXc], [RNKwc] of the target 21st processing element PE20. Data is captured as final statistics (MINd, MAXd, RNKwd).
[1690]
The final statistical data (MINd, MAXd, RNKwd) thus stored in the internal register (AUXFB) of the IG 14 is immediately followed by the register of each processing element PE as part of a microinstruction for use in non-linear processing (LUT). Transferred to areas [MINd], [MAXd], and [RNKwd].
[1700]
In the fourth horizontal scanning period of the vertical blanking period, the remaining frequencies (HSTc1, HSTc2, HSTc3) are calculated by the horizontal secondary statistical processing (step S22), and then the gradation ranges RNG0, RNG1, RNG2, RNG3 are calculated. Each final frequency statistic value (HSTc0, HSTc1, HSTc2, HSTc3) is converted into a corresponding gain (A0, A1, A2, A3) (step S23). In the present embodiment, this frequency-gain conversion is performed by the following arithmetic expression (1).
[1710]
Ai = (4/14400) * (HSTci * 64) * 64
= 1.138 * HSTci
≒ (9/8) * HSTci ......... (1)
[1720]
Here, the constant “4” in the equation (1) is the number of histogram sections, that is, the number of gradation ranges (4), and the constant “14400” is a histogram parameter, that is, a statistical processing target in one field. Number of pixels (240/2) × (720/6). The constant “64” in the parenthesis is a correction value generated by rounding down the lower 6 bits of HSTci so as to reduce the calculation amount, and the constant “64” outside the parenthesis is a value up to 6 bits after the decimal point. This is for expressing integers by multiplying by 64.
[1730]
The calculation results (A0, A1, A2, A3) of the frequency-gain conversion are stored in the register areas [Ax0], [Ax1], [Ax2], [Ax3], respectively.
[1740]
A predetermined lower limit value or upper limit value is set for the frequency HST or the gain A, and when the frequency HST or the gain A in any gradation level range RNG is smaller than the lower limit value or larger than the upper limit value, the frequency Alternatively, it is also possible to distribute the value of the gain below the lower limit value or the value above the lower limit value in an appropriate distribution to the frequency or gain in other gradation levels.
[1750]
That is, if the frequency is excessively concentrated in one gradation range, only the gradient (gain) of the gradation conversion curve in the gradation range is extremely low or large, and the overall nonlinear processing accuracy may be reduced. .
[1760]
Therefore, as described above, distribution is made among other gradation levels with the missing or excessive amount, and the frequency or gain in the gradation range is controlled or corrected within the above lower limit value or upper limit value. Is preferred.
[1770]
Since the frequency-gain conversion is an operation performed subsequent to the horizontal secondary statistical processing (step S22), the register areas [Ax0], [Ax1], [Ax2] of the 21st processing element PE20, The contents of [Ax3] are the data of the target gains A0, A1, A2, and A3. The register areas [Ax0], [Ax1], [Ax2], and [Ax3] of the other processing elements PE The contents are unnecessary data.
[1780]
Therefore, at the start of the fifth horizontal scanning period, the contents of the register areas [Ax0], [Ax1], [Ax2], [Ax3] of all the processing elements PE0 to PEN-1 are temporarily transferred to the DOR 20 and the inside of the DOR 20 Transfer from the output terminal to the IG 14 via the internal data path 23.
[1790]
In the IG 14, as shown by * 4 in FIGS. 9 and 19, data from the DOR 20 at the timing of the read clock SRCK of the DOR 20, that is, the register areas [Ax 0], [Ax 1], [Ax 1], [Ax 1], [Ax 1], [Ax 1], [ The contents of [Ax2] and [Ax3] are given to the input port, but are active only when the write enable signal AUXHBWE from the external timing control unit is the 21st clock.
[1800]
Thereby, the IG 14 takes in the data of the gain (A0, A1, A2, A3) from the register areas [Ax0], [Ax1], [Ax2], [Ax3] of the target 21st processing element PE20. .
[1810]
The gain data (A 0, A 1, A 2, A 3) stored in the internal register (AUXFB) of the IG 14 in this way is transferred from the IG 14 to each processing element as a part of a micro instruction when nonlinear processing (LUT) described later is executed. Sequentially supplied to PE.
[1820]
Next, non-linear processing (LUT) (step S8) for tone conversion in this embodiment will be described with reference to FIG.
[1830]
This non-linear processing calculation is continuously performed on the input image signal Yin as each processing element PE of the processing unit 18 performs a predetermined calculation on each corresponding pixel data in units of horizontal scanning lines.
[1840]
Parameters used in this nonlinear processing calculation are the minimum gradation MINd, maximum gradation MAXd, gradation range width RNKwd, and gradation ranges (RNG0, RNG1, RNG2, RNG3) obtained during the immediately preceding field or vertical blanking period. Each gain (A0, A1, A2, A3). Of these, MINd, MAXd, and RNKwd are stored in register areas [MINd], [MAXd], and [RNKwd] of each processing element PE, respectively, and (A0, A1, A2, A3) are internal registers of IG14 ( AUXFB).
[1850]
In FIG. 20, this non-linear processing operation includes a first coring (L2) for performing a coring operation in which the value of the minimum gradation MINd is a coring level for each corresponding input pixel data Y (yin), A coring operation is performed for the result of one coring operation by the number of times (4 times) corresponding to the number of gradation levels RNG (4 in this example) (4 times), and the value of the width RNKwd of the gradation range is the coring level. Clip or subtraction (L5, L10, L15) to obtain and clip the difference between the second coring (L4, L9, L14) to be performed and the value before and after the calculation of each second coring (L4, L9, L14) ), The first multiplication (L6, L11, L16) for multiplying the calculation result of each clip (L5, L10, L15) and the corresponding gain (A0, A1, A2), and these first multiplications All the calculation results of The first addition (L12, L17) to be matched, the second multiplication (L19) for multiplying the calculation result of the second coring (L14) of the final round and the corresponding gain (A3), The second addition (L20) that adds the operation result of the addition (L12, L17) and the operation result of the second multiplication (L19), the operation result of the second addition (L20), and the minimum gradation MINd And a third addition (L21) for selecting the smaller one by comparing the calculation result of the third addition (L21) and the maximum gradation degree MAXd.
[1860]
Hereinafter, the operation of each processing element PE for this nonlinear processing will be described in detail.
[1870]
First, the input pixel data Y (yin) is moved from the register area [Y] to [S0], and the contents of the register area [MINd] are set to the coring level with respect to the contents (y0, ie, yin) of the register area [S0]. The coring (CORE) L2 is calculated, and the calculation result is left in the register area [S0].
[1880]
Next, the contents (y1) of the register area [S0] are transferred (L3) to the register area [S1] and stored.
[1890]
Next, the coring (CORE) L4 is calculated with the contents (RNKwd) of the register area [RNKwd] as the coring level for the contents (y1) of the register area [S0], and the calculation result (y2) is registered. Leave in area [S0].
[1900]
Next, the contents (y2) of the register area [S0] are subtracted (L5) from the contents (y1) of the register area [S1] and clipped, and the calculation result (y3) is stored in the register area [S1].
[1910]
Next, the content (Y3) of the register area [S1] is multiplied (L6) by the content (A0) of the register area [A0], and the operation result (y4, that is, A0 * y3) is stored in the register area [T0]. .
[1920]
Here, the multiplication of the contents of the register area [S1] and the contents of the register area [A0] is a multiplication of 8-bit data as shown in FIG. can get. Since this data length is too large, the lower 4 bits shown by dotted lines are excluded from the calculation, and the most significant 12 bits are used as the effective output. Even in this case, since the decimal point is calculated up to two digits (bits), the accuracy is ensured.
[1930]
The calculation result (y4) is temporarily stored in the register area [T0] and then immediately transferred (L7) to the register area [T1].
[1940]
Next, the contents [y2] of the register area [S0] are transferred to the register area [S1] (L8) and stored.
[1950]
Then, the coring (CORE) L9 is calculated with the contents (RNKwd) of the register area [RNKwd] as the coring level for the contents (y2) of the register area [S0], and the calculation result (y5) is obtained as the register area. Leave in [S0].
[1960]
Next, the contents (y5) of the register area [S0] are subtracted (L10) from the contents (y2) of the register area [S1] and clipped, and the calculation result (y6) is stored in the register area [S1].
[1970]
Next, the contents (Y1) of the register area [S1] are multiplied (L11) by the contents (A1) of the register area [A1], and the calculation result (A1 * y6) is stored in the register area [T0]. Even in this multiplication (L11), the calculation result is output in 12 bits.
[1980]
Next, the contents (Y4) of the register area [T1] are added to the contents (A1 * y6) of the register area [T0] (L12) and added, and the operation result (y7) is added to the register area [T1]. leave.
[1990]
Next, the contents [y5] of the register area [S0] are transferred to the register area [S1] (L13) and stored.
[2000]
Then, the coring (CORE) L14 having the content (RNKwd) of the register area [RNKwd] as the coring level is calculated for the contents (y5) of the register area [S0], and the calculation result (y8) is calculated as the register area. Leave in [S0].
[2010]
Next, the contents (y8) of the register area [S0] are subtracted (L15) from the contents (y5) of the register area [S1] and clipped, and the calculation result (y9) is stored in the register area [S1].
[2020]
Next, the contents (Y9) of the register area [S1] are multiplied (L16) by the contents (A2) of the register area [A2], and the operation result (A2 * y9) is stored in the register area [T0]. Also in this multiplication (L16), the calculation result is output in 12 bits.
[2030]
Next, the contents (Y7) of the register area [T1] are added (L17) to the contents (A2 * y9) of the register area [T0], and the result (y10) is added to the register area [T1]. leave.
[2040]
Next, the contents (Y8) of the register area [S1] are multiplied (L19) by the contents (A3) of the register area [A3], and the calculation result (A3 * y8) is stored in the register area [T0].
[2050]
Next, the contents (Y10) of the register area [T1] are added (L20) to the contents (A3 * y8) of the register area [T0], and the result (y11) is added to the register area [T0]. leave.
[2060]
Next, the contents (MINd) of the register area [MINd] are added to the contents (y11) of the register area [T0] (L21), and the result of the operation is used as the new contents of the register area [T0].
[2070]
Finally, the MIN operation (L22) is performed between the contents of the register area [T0] and the contents (MAXd) of the register area [MAXd], and the upper limit is clipped by MAXd to obtain the final operation result (y12). . The calculation result (y12) is stored in the register area [T0] as output pixel data yout.
[2080]
Then, the calculation result y12 (you) stored in this register area [T0] is transferred to the corresponding register of the DOR 20 at the start of the next horizontal scanning period (precisely, before the horizontal blanking period is finished yet). (Step S2), during the horizontal scanning period, the output image signal Yout is output from the DOR 20 together with the calculation results from all the other processing elements PE.
[2090]
As shown in the above equation (1), in each gradation range RNG0, RNG1, RNG2, RNG3, each gain A0, A1, A2, A3 and each frequency HSTd0, HSTd1, HSTd2, HSTd3 pass through a constant coefficient. Are proportional to each other. From this relationship, it is possible to use the frequencies HSTd0, HSTd1, HSTd2, and HSTd3 instead of the gains A0, A1, A2, and A3 in the nonlinear processing.
[2100]
That is, in each of the multiplications L6, L11, L16, and L19, the contents of the register area [S1] are replaced with the contents of the register areas [A0], [A1], [A2], and [A3] (A0, A1, A2, A3). Instead of multiplying the contents (HSTd0, HSTd1, HSTd2, HSTd3) of the register areas [HSTd0], [HSTd1], [HSTd2], [HSTd3], and multiplying the multiplication result by the coefficient (9/8) The same result is obtained.
[2110]
Therefore, the non-linear gradation conversion according to the present embodiment using the minimum gradation degree MINd, the minimum gradation degree MAXd, the gradation degree range width RNKwd, and the frequency (HSTd0, HSTd1, HSTd2, HSTd3) obtained by the statistical processing as described above as parameters. It is also possible to perform.
[2120]
In the above embodiment, as shown in FIG. 22, among the statistical values (MINd, MAXd, RNKwd, A0 to A3) obtained in the statistical processing (1, 2) for each field (for example, screen 1), MINd, MAXd and RNKwd are used for non-linear processing in one field (screen 2) immediately after that and are also used in the frequency calculation process (statistic processing 2), and A0 to A3 are non-linear in one field (screen 2) immediately after that. Used for processing.
[2130]
However, the relationship between the field or frame that is the target of each statistical process and the field or frame that is the target of the nonlinear processing or frequency calculation process using the statistical value obtained by the statistical process can be arbitrarily set. For example, the statistical processing (1, 2) may be performed once every two fields, and the statistical value may be used for nonlinear processing for a plurality of subsequent fields.
[2140]
In the above method, an image (field) to be subjected to statistical processing is different from an image (field) to be subjected to gradation conversion. However, since the time difference is 1 to 2 fields, the gradation conversion accuracy is particularly affected in a normal application. Not so much.
[2150]
However, as shown in FIG. 23, the input image signal Yin may be passed through a field memory or a frame memory and delayed by one field or frame (1F) before gradation conversion. In this case, as shown in FIG. 24, the screen to be subjected to statistical processing and the screen to be subjected to gradation conversion can be matched.
[2160]
Further, when two images A and B are displayed simultaneously by dividing one display screen into a plurality of parts, for example, as shown in FIG. 25, statistics are obtained for each input image signal Yin (A) and Yin (B). Processing and gradation conversion are performed separately. In particular, statistical processing is performed alternately for each screen. The gradation conversion is performed in parallel or in a time division manner for each input image signal Yin (A), Yin (B).
[2170]
In the above embodiment, the minimum gradation MINd and the maximum gradation MAXd that define the limit point of the gradation range and the gradation range width RNKwd are dynamically controlled (updated) according to the gradation of the image. Therefore, the number of gradation ranges RNG is set to a relatively small number of four, thereby reducing the arithmetic processing.
[2180]
However, as shown in FIG. 26, it is of course possible to set the number of gradation ranges RNG to a larger number (for example, 8), and each gradation degree can be set without using the dynamic minimum gradation degree MINd and the maximum gradation degree MAXd. The position of the range RNG and the range width RNKwd can be set to constant (fixed) values.
[2190]
As described above, when the minimum gradation MINd and the maximum gradation MAXd are not used, the nonlinear processing calculation (FIG. 20) includes the first coring (L2), the third addition (L21), and the final MIN calculation (L22). ) Becomes unnecessary. However, the number of operations of the second coring, clipping, and first multiplication increases.
[2200]
In this case, the non-linear processing calculation includes coring for performing coring calculation for each corresponding input pixel data for the coring level with the value RNKwd of the width of the gradation range continuing as many times as the number of gradation ranges RNG. A clip or subtraction for clipping the difference between values before and after each coring operation, a first multiplication for multiplying the operation result of each clip and each corresponding gain (or frequency), and the first A first addition that adds all the operation results of the multiplications, a second multiplication that multiplies the operation result of the last coring and the corresponding gain (or frequency), and an operation result of the first addition And a second addition for adding the operation result of the second multiplication.
[2210]
In the above-described embodiment, the horizontal scanning lines and pixel columns to be subjected to statistical processing are effectively thinned out in the vertical direction and horizontal direction of the field or frame to improve the processing efficiency. However, the thinning pattern can be variously modified, and the thinning method in the above embodiment is merely an example. In an actual application, a statistical process may be performed only on a part of the screen, typically only in the area near the center.
[2220]
27 to 33 show program lists for executing the gradation conversion procedure in the present embodiment.
[2230]
In this embodiment, the program is stored in a program memory in the IG 14 in a coded state. Program data is loaded into the program memory of the IG 14 from an external ROM, an external controller, or the like via a predetermined interface (not shown).
[2240]
Since all the processing elements PE0 to PEN-1 of the SVP 10 perform the same arithmetic processing simultaneously for each instruction of this program, even if the transmission rate of the image signal is high, highly accurate statistical processing and Tone conversion can be performed efficiently in units of scanning lines.
[2250]
Then, by utilizing the functions of the SVP 10, individual processing in statistical processing and gradation conversion can be advanced and diversified. In other words, by changing or modifying the contents of the program as appropriate, it is possible to deal with a wide variety of applications without any modification to the SVP 10. In addition, the system design only requires rewriting of the program, and the simulation is very easy.
[2260]
【The invention's effect】
As described above, according to the image gradation conversion method of the present invention, it is possible to efficiently cope with a wide variety of image formats with one hardware system, and various and advanced gradations for moving images. Conversion can be done easily.
[Brief description of the drawings]
FIG. 1 is a block diagram showing a configuration example of a SIMD type parallel processor (SVP) used in an image gradation conversion method of the present invention.
FIG. 2 is a diagram schematically illustrating a configuration of a main part (core) of an SVP in an embodiment.
FIG. 3 is a diagram illustrating an example of a gradation conversion characteristic curve and a histogram for explaining the principle of a gradation conversion method in an embodiment.
FIG. 4 is a flowchart illustrating an SVP processing procedure (processing during a vertical scanning period) in the embodiment.
FIG. 5 is a flowchart illustrating an SVP processing procedure (processing during a vertical blanking period) in the embodiment.
FIG. 6 is a flowchart illustrating an SVP processing procedure (processing during a vertical blanking period) in the embodiment.
FIG. 7 is a flowchart illustrating an SVP processing procedure (processing during a vertical blanking period) in the embodiment.
FIG. 8 is a block diagram showing overall processing and data flow in the SVP in the embodiment.
FIG. 9 is a timing chart showing overall processing and data flow in the SVP in the embodiment.
FIG. 10 is a block diagram illustrating a connection relationship between an output port and an input port of the SVP in the embodiment.
FIG. 11 is a diagram illustrating a register area provided in a register file of each processing element in the SVP in the embodiment.
FIG. 12 is a diagram conceptually showing a method of statistical processing in the vertical direction in the embodiment.
FIG. 13 is a block diagram illustrating processing of a processing element for obtaining a vertical minimum gradation and a maximum gradation in an embodiment.
FIG. 14 is a block diagram illustrating processing of a processing element for obtaining a frequency in the vertical direction in the embodiment.
15 is a diagram illustrating data values in respective units in FIG. 14 with respect to gradation levels at respective stages of input pixel data.
FIG. 16 is a diagram for explaining the effect of horizontal primary statistical processing in the embodiment.
FIG. 17 is a diagram for explaining the action of horizontal secondary statistical processing (calculation of minimum gradation and maximum gradation) in the embodiment.
FIG. 18 is a diagram for explaining the effect of horizontal secondary statistical processing (frequency calculation) in the embodiment.
FIG. 19 is a timing chart showing a part of the operation of FIG. 9 in the time axis direction.
FIG. 20 is a diagram illustrating the effect of nonlinear processing for tone conversion in the embodiment.
FIG. 21 is a diagram illustrating rounding with respect to a multiplication output in the nonlinear processing according to the embodiment.
FIG. 22 is a diagram illustrating a relationship between a screen flow and each process in the embodiment.
FIG. 23 is a diagram illustrating a method of performing gradation conversion after delaying an input image signal by one field or frame by a frame memory in the embodiment.
24 is a diagram showing the relationship between the screen flow and each process in the method of FIG.
FIG. 25 is a diagram for explaining a processing method in an embodiment in which one screen is divided into two and two screens are displayed on the left and right.
FIG. 26 is a diagram illustrating a modified example of the gradation conversion curve format and the histogram in the embodiment.
FIG. 27 is a list of programs for carrying out the gradation conversion method in the embodiment.
FIG. 28 is a list of programs for executing the gradation conversion method in the embodiment.
FIG. 29 is a list of programs for executing the gradation conversion method in the embodiment.
FIG. 30 is a list of programs for executing the gradation conversion method in the embodiment.
FIG. 31 is a list of programs for carrying out the gradation conversion method in the embodiment.
FIG. 32 is a list of programs for executing the gradation conversion method in the embodiment.
FIG. 33 is a list of programs for carrying out the gradation conversion method in the embodiment.
FIG. 34 is a diagram for explaining the principle of gradation conversion of an image.
[Explanation of symbols]
10 SVP
12 SVP core
14 IG (command generation unit)
16 DIR (data input register)
18 Processing unit
20 DOR (data output register)
PE processing element
RF0, RF1 register file

Claims (28)

走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサによって、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算工程と、
前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記度数に応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換工程と
を有し、
前記階調変換工程が、各々のプロセッシング・エレメントによって、
各対応する入力画素データについて前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行うコアリング工程と、
各々の前記コアリング演算の演算前後の値の差分を求めてクリップするクリップ工程と、
各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算工程と、
前記第1の乗算工程の演算結果を全て加え合わせる第1の加算工程と、
最終回の前記コアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算工程と、
前記第1の加算工程の演算結果と前記第2の乗算工程の演算結果とを加え合わせる第2の加算工程と
を含む、
画像階調変換方法。
It has a plurality of processing elements that are assigned to the pixels on the scanning line in a one-to-one correspondence and perform the same operation according to a common command, and has a function of processing the input image signal in units of scanning lines The gradation level of the input image signal is classified into one of a plurality of gradation levels each having a predetermined width for each pixel by a SIMD type parallel processor, and the number of pixels that fall into each of the gradation levels is counted to determine the frequency. A frequency calculation process to be obtained;
By the SIMD type parallel processor, the gradient range and the non-linear processing in accordance with the frequency subjected in operation possess a tone conversion step of converting the gradient of the input image signal to the input image signal ,
The gradation conversion step is performed by each processing element.
A coring step of performing a coring operation in which the value of the width of the gradation level range is set to the coring level continuously for each corresponding input pixel data according to the number of the gradation level ranges;
A clipping step for obtaining and clipping a difference between values before and after each coring operation;
A first multiplication step of multiplying a calculation result of each of the clip calculations and a slope of each corresponding frequency or gradation conversion curve;
A first addition step of adding all the calculation results of the first multiplication step;
A second multiplication step of multiplying the calculation result of the last coring operation by the frequency or the gradient of the gradation conversion curve corresponding thereto;
A second addition step of adding the calculation result of the first addition step and the calculation result of the second multiplication step;
including,
Image gradation conversion method.
走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサによって、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算工程と、
前記SIMD型並列プロセッサにより、各々の前記階調度範囲毎に前記度数に応じた階調変換曲線の傾きを求める傾き演算工程と、
前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記傾きに応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換工程と
を有し、
前記階調変換工程が、各々のプロセッシング・エレメントによって、
各対応する入力画素データについて前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行うコアリング工程と、
各々の前記コアリング演算の演算前後の値の差分を求めてクリップするクリップ工程と、
各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算工程と、
前記第1の乗算工程の演算結果を全て加え合わせる第1の加算工程と、
最終回の前記コアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算工程と、
前記第1の加算工程の演算結果と前記第2の乗算工程の演算結果とを加え合わせる第2の加算工程と
を含む、
画像階調変換方法。
A plurality of processing elements that are assigned to the pixels on the scanning line in a one-to-one correspondence relationship and perform the same operation in accordance with a common command, and have a function of processing input image signals in units of scanning lines The gradation level of the input image signal is classified into one of a plurality of gradation levels each having a predetermined width for each pixel by a SIMD type parallel processor, and the number of pixels falling in each of the gradation levels is counted to determine the frequency. A frequency calculation process to be obtained;
An inclination calculating step for obtaining an inclination of a gradation conversion curve corresponding to the frequency for each gradation range by the SIMD type parallel processor;
By the SIMD type parallel processor, the gradient range and the non-linear processing in accordance with the inclination by performing the arithmetic, have a gradation conversion step of converting the gradient of the input image signal to the input image signal ,
The gradation conversion step is performed by each processing element.
A coring step of performing a coring operation in which the value of the width of the gradation range is set as a coring level continuously for each corresponding input pixel data according to the number of the gradation range.
A clipping step for obtaining and clipping a difference between values before and after each coring operation;
A first multiplication step of multiplying a calculation result of each of the clip calculations and a slope of each corresponding frequency or gradation conversion curve;
A first addition step of adding all the calculation results of the first multiplication step;
A second multiplication step of multiplying the calculation result of the last coring operation by the corresponding frequency or the slope of the gradation conversion curve;
A second addition step of adding the calculation result of the first addition step and the calculation result of the second multiplication step;
including,
Image gradation conversion method.
走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサによって、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算工程と、
前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記度数に応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換工程と、
前記入力画像信号の最小階調度および最大階調度を求める最小及び最大階調度演算工程と、
前記最小階調度と前記最大階調度との間の階調度範囲を等間隔で予め設定した数に分割することによって前記複数の階調度範囲を決定する階調度範囲演算工程と
を有し、
前記階調変換工程が、各々のプロセッシング・エレメントによって、
各対応する入力画素データについて前記最小階調度の値をコアリングレベルとするコアリング演算を行う第1のコアリング工程と、
前記第1のコアリング工程の演算結果について前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行う第2のコアリング工程と、
各々の前記第2のコアリング演算の演算前後の値の差分を求めてクリップするクリップ工程と、
各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算工程と、
前記第1の乗算工程の演算結果を全て加え合わせる第1の加算工程と、
最終回の前記第2のコアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算工程と、
前記第1の加算工程の演算結果と前記第2の乗算工程の演算結果とを加え合わせる第2の加算工程と、
前記第2の加算工程の演算結果と前記最小階調度とを加え合わせる第3の加算工程と、
前記第3の加算工程の演算結果と前記最大階調度とを比較し、小さい方を選択する最小値演算工程と
を含む、
画像階調変換方法。
It has a plurality of processing elements that are assigned to the pixels on the scanning line in a one-to-one correspondence and perform the same operation according to a common command, and has a function of processing the input image signal in units of scanning lines The gradation level of the input image signal is classified into one of a plurality of gradation levels each having a predetermined width for each pixel by a SIMD type parallel processor, and the number of pixels that fall into each of the gradation levels is counted to determine the frequency. A frequency calculation process to be obtained;
A gradation conversion step of converting a gradation degree of the input image signal by performing non-linear processing according to the gradation degree range and the frequency on the input image signal by the SIMD type parallel processor;
Minimum and maximum gradation calculation steps for obtaining a minimum gradation and a maximum gradation of the input image signal;
A gradation range calculation step for determining the plurality of gradation ranges by dividing a gradation range between the minimum gradation and the maximum gradation by a predetermined number at equal intervals;
Have
The gradation conversion step is performed by each processing element.
A first coring step for performing a coring operation using the minimum gradation value as a coring level for each corresponding input pixel data;
A second coring step of performing a coring operation in which the value of the width of the gradation range is used as a coring level continuously for the calculation result of the first coring step by the number of times corresponding to the number of the gradation ranges; ,
A clip step of clipping by calculating a difference between values before and after each second coring operation;
A first multiplication step of multiplying a calculation result of each of the clip calculations and a slope of each corresponding frequency or gradation conversion curve;
A first addition step of adding all the calculation results of the first multiplication step;
A second multiplication step of multiplying the calculation result of the second coring operation of the last round and the corresponding frequency or the slope of the gradation conversion curve;
A second addition step of adding the operation result of the first addition step and the operation result of the second multiplication step;
A third addition step of adding the calculation result of the second addition step and the minimum gradation degree;
Comparing the calculation result of the third addition step with the maximum gradation and selecting a smaller one ,
Image gradation conversion method.
走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサによって、前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算工程と、
前記SIMD型並列プロセッサにより、各々の前記階調度範囲毎に前記度数に応じた階調変換曲線の傾きを求める傾き演算工程と、
前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記傾きに応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換工程と、
前記入力画像信号の最小階調度および最大階調度を求める最小及び最大階調度演算工程と、
前記最小階調度と前記最大階調度との間の階調度範囲を等間隔で予め設定した数に分割することによって前記複数の階調度範囲を決定する階調度範囲演算工程と
を有し、
前記階調変換工程が、各々のプロセッシング・エレメントによって、
各対応する入力画素データについて前記最小階調度の値をコアリングレベルとするコアリング演算を行う第1のコアリング工程と、
前記第1のコアリング工程の演算結果について前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行う第2のコアリング工程と、
各々の前記第2のコアリング演算の演算前後の値の差分を求めてクリップするクリップ工程と、
各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算工程と、
前記第1の乗算工程の演算結果を全て加え合わせる第1の加算工程と、
最終回の前記第2のコアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算工程と、
前記第1の加算工程の演算結果と前記第2の乗算工程の演算結果とを加え合わせる第2の加算工程と、
前記第2の加算工程の演算結果と前記最小階調度とを加え合わせる第3の加算工程と、
前記第3の加算工程の演算結果と前記最大階調度とを比較し、小さい方を選択する最小値演算工程と
を含む、
画像階調変換方法。
It has a plurality of processing elements that are assigned to the pixels on the scanning line in a one-to-one correspondence and perform the same operation according to a common command, and has a function of processing the input image signal in units of scanning lines The gradation level of the input image signal is classified into one of a plurality of gradation levels each having a predetermined width for each pixel by a SIMD type parallel processor, and the number of pixels that fall into each of the gradation levels is counted to determine the frequency. A frequency calculation process to be obtained;
An inclination calculating step for obtaining an inclination of a gradation conversion curve according to the frequency for each gradation range by the SIMD type parallel processor;
A gradation conversion step of converting a gradation degree of the input image signal by performing non-linear processing according to the gradation degree range and the inclination on the input image signal by an operation by the SIMD type parallel processor;
Minimum and maximum gradation calculation steps for obtaining a minimum gradation and a maximum gradation of the input image signal;
A gradation range calculation step for determining the plurality of gradation ranges by dividing a gradation range between the minimum gradation and the maximum gradation by a predetermined number at equal intervals;
Have
The gradation conversion step is performed by each processing element.
A first coring step for performing a coring operation using the minimum gradation value as a coring level for each corresponding input pixel data;
A second coring step of performing a coring operation in which the value of the width of the gradation range is used as a coring level continuously for the calculation result of the first coring step by the number of times corresponding to the number of the gradation ranges; ,
A clip step of clipping by calculating a difference between values before and after each second coring operation;
A first multiplication step of multiplying a calculation result of each of the clip calculations and a slope of each corresponding frequency or gradation conversion curve;
A first addition step of adding all the calculation results of the first multiplication step;
A second multiplication step of multiplying the calculation result of the second coring operation of the last round and the corresponding frequency or the slope of the gradation conversion curve;
A second addition step of adding the operation result of the first addition step and the operation result of the second multiplication step;
A third addition step of adding the calculation result of the second addition step and the minimum gradation degree;
Comparing the calculation result of the third addition step with the maximum gradation and selecting a smaller one ,
Image gradation conversion method.
1フィールドまたは1フレーム分の前記入力画像信号を単位として前記度数演算工程を行う請求項1〜4のいずれか一項に記載の画像階調変換方法。The image gradation conversion method according to any one of claims 1 to 4, wherein the frequency calculation step is performed in units of the input image signal for one field or one frame. 所定数のフィールドまたはフレーム置きに前記度数演算工程を行う請求項1〜5のいずれか一項に記載の画像階調変換方法。6. The image gradation conversion method according to claim 1, wherein the frequency calculation step is performed every predetermined number of fields or frames. 1フィールドまたは1フレーム内の一部の入力画像領域についてのみ前記度数演算工程を行う請求項5または請求項6に記載の画像階調変換方法。The image gradation conversion method according to claim 5 or 6 , wherein the frequency calculation step is performed only for a part of input image areas in one field or one frame. 所定の間隔を置いた画素および所定の間隔を置いた走査線についてのみ前記度数演算工程を行う請求項5〜7のいずれか一項に記載の画像階調変換方法。The image gradation conversion method according to any one of claims 5 to 7, wherein the frequency calculation step is performed only for pixels having a predetermined interval and scanning lines having a predetermined interval. 前記度数演算工程は、
各々のプロセッシング・エレメントが、垂直走査期間中に各対応する垂直方向の画素列について各々の前記階調度範囲毎に前記度数を演算する垂直方向の度数演算工程と、
その後に続く垂直ブランキング期間中に、全部または一部の前記プロセッシング・エレメントが協働して、垂直方向の全部または一部の画素列分の前記度数を各々の前記階調度範囲毎に水平方向で合計して、当該フィールドまたはフレームにおける各々の前記階調度範囲分の度数を演算する水平方向の度数演算工程と
を含む請求項5〜8のいずれか一項に記載の画像階調変換方法。
The frequency calculation step includes
A vertical frequency calculation step in which each processing element calculates the frequency for each of the gradation range for each corresponding vertical pixel column during a vertical scan period;
During the subsequent vertical blanking period, all or a part of the processing elements cooperate, and the frequency for all or a part of the pixel columns in the vertical direction is set in the horizontal direction for each gradation range. The image gradation conversion method according to claim 5, further comprising: a horizontal frequency calculation step of calculating a frequency corresponding to each gradation level range in the field or frame.
各々のプロセッシング・エレメントが、複数の前記階調度範囲にそれぞれ対応した複数の度数演算値記憶部を有し、前記垂直方向の度数演算工程では、垂直方向の各対応する画素列において各入力画素がいずれの前記階調度範囲に入るのかを判定して、その該当する前記階調度範囲に対応する前記度数演算記憶部の内容に「1」を加算するとともに、他の全ての前記度数演算値保持部の内容に「0」に加える請求項記載の画像階調変換方法。Each processing element has a plurality of frequency calculation value storage units respectively corresponding to the plurality of gradation level ranges, and in the vertical frequency calculation step, each input pixel in each corresponding pixel column in the vertical direction It is determined which gradation level range is entered, and “1” is added to the content of the frequency calculation storage unit corresponding to the corresponding gradation level range, and all the other frequency calculation value holding units The image gradation conversion method according to claim 9 , wherein the content is added to “0”. 前記水平方向における度数合計演算を複数回に分割し、相前後する2つの水平方向の度数合計演算では、前の度数合計演算で得られた全てのプロセッシング・エレメントの演算結果をいったん前記並列プロセッサより出力して、その出力した全演算結果の中で所定のプロセッシング・エレメントに対応する演算結果だけを前記並列プロセッサに入力して後の度数合計演算の演算対象とする請求項に記載の画像階調変換方法。The total frequency calculation in the horizontal direction is divided into a plurality of times, and in two successive horizontal frequency total calculations, the calculation results of all the processing elements obtained in the previous total frequency calculation are temporarily obtained from the parallel processor. 10. The image scale according to claim 9 , wherein an output result is input, and only the operation result corresponding to a predetermined processing element is input to the parallel processor among all of the output operation results to be subjected to a frequency total operation later. Key conversion method. 各回の前記度数演算工程で求めた前記度数を所定数の後続フィールドまたはフレームの入力画像信号に対する前記階調変換工程に用いる請求項5〜7のいずれか一項に記載の画像階調変換方法。The image gradation conversion method according to any one of claims 5 to 7 , wherein the frequency obtained in each frequency calculation step is used in the gradation conversion step with respect to an input image signal of a predetermined number of subsequent fields or frames. 前記度数に所定の下限値または上限値を設定し、いずれかの前記階調度範囲における度数が前記下限値より少ないかまたは前記上限値より多いときは、その度数のうちの前記下限値を下回る分または前記上限値を超える分について他の前記階調度範囲における度数との間で分配を行って、前記下限値または前記上限値以内に補正する請求項1〜4のいずれか一項に記載の画像階調変換方法。A predetermined lower limit value or upper limit value is set for the frequency, and when the frequency in any of the gradation degree ranges is less than the lower limit value or greater than the upper limit value, an amount below the lower limit value of the frequency The image according to any one of claims 1 to 4, wherein a part exceeding the upper limit value is distributed with the frequency in the other gradation range and corrected within the lower limit value or the upper limit value. Tone conversion method. 前記入力画像信号の最小階調度および最大階調度を求める最小及び最大階調度演算工程と、前記最小階調度と前記最大階調度との間の階調度範囲を等間隔で予め設定した数に分割することによって前記複数の階調度範囲を決定する階調度範囲演算工程とを含む請求項1または請求項2に記載の画像階調変換方法。A minimum and maximum gradation calculation step for obtaining a minimum gradation and a maximum gradation of the input image signal, and a gradation range between the minimum gradation and the maximum gradation are divided into predetermined numbers at equal intervals. 3. The image gradation conversion method according to claim 1 , further comprising: a gradation degree range calculating step of determining the plurality of gradation degree ranges. 1フィールドまたは1フレーム分の前記入力画像信号を単位として前記最小及び最大階調度演算工程を行う請求項14に記載の画像階調変換方法。The image gradation conversion method according to claim 14 , wherein the minimum and maximum gradation calculation steps are performed in units of the input image signal for one field or one frame. 所定数のフィールドまたはフレーム置きに前記最小及び最大階調度演算工程を行う請求項14または請求項15に記載の画像階調変換方法。 16. The image gradation conversion method according to claim 14 , wherein the minimum and maximum gradation degree calculation step is performed every predetermined number of fields or frames. 1フィールドまたは1フレーム内の一部の入力画像領域についてのみ前記最小及び最大階調度演算工程を行う請求項14〜16のいずれか一項に記載の画像階調変換方法。The image gradation conversion method according to any one of claims 14 to 16, wherein the minimum and maximum gradation calculation steps are performed only for a part of input image areas in one field or one frame. 所定の間隔を置いた画素および所定の間隔を置いた走査線についてのみ前記最小及び最大階調度演算工程を行う請求項14〜17のいずれか一項に記載の画像階調変換方法。The image gradation conversion method according to any one of claims 14 to 17, wherein the minimum and maximum gradation calculation steps are performed only for pixels having a predetermined interval and scanning lines having a predetermined interval. 各回の前記最小及び最大階調度演算工程で求められる前記最小階調度および前記最大階調度は、前回の前記最小及び最大階調度演算工程で求められた前記最小階調度および前記最大階調度に第1の係数k(0≦k≦1)を掛けたものと、今回のフィールドまたはフレームにおける入力画像信号の最小階調値および最大階調度に第2の係数(1−k)を掛けたものとの和である請求項14〜18のいずれか一項に記載の画像階調変換方法。The minimum gradation and the maximum gradation obtained in each of the minimum and maximum gradation computation steps are the first to the minimum gradation and the maximum gradation obtained in the previous minimum and maximum gradation computation steps. Multiplied by the coefficient k (0 ≦ k ≦ 1) and the minimum gradation value and maximum gradation of the input image signal in the current field or frame multiplied by the second coefficient (1-k). The image gradation conversion method according to any one of claims 14 to 18, which is a sum. 前記最小及び最大階調度演算工程は、
各々のプロセッシング・エレメントが、垂直走査期間中に各対応する垂直方向の画素列について最小階調度および最大階調度を演算する垂直方向の最小及び最大階調度演算工程と、
その後に続く垂直ブランキング期間中に、全部または一部の前記プロセッシング・エレメントが協働して、垂直方向の全部または一部の画素列分の前記最小階調度および最大階調度を水平方向で比較して、当該フィールドまたはフレーム分の前記最小階調度および前記最大階調度を演算する水平方向の最小及び最大階調度演算工程と
を含む請求項14〜18のいずれか一項に記載の画像階調変換方法。
The minimum and maximum gradation calculation steps include
A vertical minimum and maximum gradient calculation step in which each processing element calculates a minimum gradient and a maximum gradient for each corresponding vertical pixel column during a vertical scan period;
During the subsequent vertical blanking period, all or part of the processing elements cooperate to compare the minimum and maximum gradations of all or part of the vertical pixel columns in the horizontal direction. The image gradation according to claim 14, further comprising: a horizontal minimum and maximum gradation calculation step for calculating the minimum gradation and the maximum gradation for the field or frame. Conversion method.
各々のプロセッシング・エレメントが、最小階調度に対応した最小階調度記憶部を有し、前記垂直方向の最小階調度演算工程では、垂直ブランキング期間中に予め前記最小階調度記憶部に入力画像信号のとりうる最大階調度をセットし、その後の垂直走査期間中に垂直方向の各対応する画素列について各画素毎に順次前記最小階調度記憶部の内容と比較し、小さい方を前記最小階調度記憶部の新たな内容として保存する請求項20に記載の画像階調変換方法。Each processing element has a minimum gradation storage unit corresponding to the minimum gradation. In the minimum gradation calculation step in the vertical direction, an input image signal is input to the minimum gradation storage unit in advance during a vertical blanking period. The maximum gradient that can be taken is set, and during the subsequent vertical scanning period, each corresponding pixel column in the vertical direction is sequentially compared with the content of the minimum gradient storage unit for each pixel, and the smaller one is the minimum gradient The image gradation conversion method according to claim 20 , wherein the image gradation conversion method is stored as new contents in the storage unit. 各々のプロセッシング・エレメントが、最大階調度に対応した最大階調度記憶部を有し、前記垂直方向の最大階調度演算工程では、垂直ブランキング期間中に予め前記最大階調度記憶部に入力画像信号のとりうる最小階調度をセットし、その後の垂直走査期間中に垂直方向の各対応する画素列について各画素毎に順次前記最大階調度記憶部の内容と比較し、大きい方を前記最大階調度記憶部の新たな内容として保存する請求項20に記載の画像階調変換方法。Each processing element has a maximum gradation storage unit corresponding to the maximum gradation, and in the vertical maximum gradation calculation step, the input image signal is input to the maximum gradation storage unit in advance during the vertical blanking period. The minimum gradation that can be taken is set, and each corresponding pixel column in the vertical direction is sequentially compared with the content of the maximum gradation storage unit for each pixel during the subsequent vertical scanning period, and the larger one is compared with the maximum gradation. The image gradation conversion method according to claim 20 , wherein the image gradation conversion method is stored as new contents in the storage unit. 前記水平方向における最小階調度および最大階調度の演算をトーナメント方式で行う請求項20に記載の画像階調変換方法。21. The image gradation conversion method according to claim 20 , wherein the calculation of the minimum gradation and the maximum gradation in the horizontal direction is performed by a tournament method. 前記トーナメント方式による最小階調度および最大階調度の演算を複数回のトーナメントに分割し、相前後する2つのトーナメントの間では前のトーナメントで得られた全てのプロセッシング・エレメントの演算結果をいったん前記並列プロセッサより出力し、その出力した全演算結果の中で所定のプロセッシング・エレメントに対応する演算結果だけを前記並列プロセッサに入力して後のトーナメントの演算対象とする請求項23に記載の画像階調変換方法。The calculation of the minimum gradation and the maximum gradation according to the tournament method is divided into a plurality of tournaments, and the calculation results of all processing elements obtained in the previous tournament are once in parallel between the two consecutive tournaments. 24. The image gradation according to claim 23 , which is outputted from a processor, and among all the outputted computation results, only computation results corresponding to a predetermined processing element are inputted to the parallel processor to be subject to computation of a subsequent tournament. Conversion method. 前記階調変換工程は、各々の前記階調度範囲毎に前記階調変換曲線の傾きを前記度数に比例させ、相隣接する2つの前記階調度範囲の境界で出力画像の階調度を連続させる工程を含む請求項または請求項4に記載の画像階調変換方法。In the gradation conversion step, the gradient of the gradation conversion curve is proportional to the frequency for each gradation range, and the gradation of the output image is continued at the boundary between two adjacent gradation ranges. The image gradation conversion method according to claim 2 or 4 , comprising: 1つの画面上に表示されるべき複数の画像に対応する複数の入力画像信号について、前記度数演算工程を各入力画像信号毎に、かつ交互に行う請求項1〜25のいずれかに記載の画像階調変換方法。  The image according to any one of claims 1 to 25, wherein the frequency calculation step is alternately performed for each input image signal for a plurality of input image signals corresponding to a plurality of images to be displayed on one screen. Tone conversion method. 走査線上の画素に1対1の対応関係で割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサに、
前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算手順と、
前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記度数に応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する諧調変換手順と
を実行させ、
前記階調変換手順において、各々のプロセッシング・エレメントによって、
各対応する入力画素データについて前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行うコアリング手順と、
各々の前記コアリング演算の演算前後の値の差分を求めてクリップするクリップ手順と、
各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算手順と、
前記第1の乗算手順の実行による演算結果を全て加え合わせる第1の加算手順と、
最終回の前記コアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算手順と、
前記第1の加算手順の実行による演算結果と前記第2の乗算手順の実行による演算結果とを加え合わせる第2の加算手順と
を実行させるためのプログラムを記録した記憶媒体。
A plurality of processing elements that are assigned to the pixels on the scanning line in a one-to-one correspondence relationship and perform the same operation in accordance with a common command, and have a function of processing input image signals in units of scanning lines SIMD type parallel processor
A frequency calculation procedure for classifying the gradation of the input image signal into any of a plurality of gradation levels each having a predetermined width for each pixel, and counting the pixels entering each of the gradation levels to obtain the frequency ;
A gradation conversion procedure for converting the gradation degree of the input image signal by performing non-linear processing according to the gradation range and the degree of frequency on the input image signal by the SIMD parallel processor ;
In the gradation conversion procedure, each processing element
A coring procedure for performing a coring operation for each corresponding input pixel data by a number of times corresponding to the number of the gradation range, and using a value of the width of the gradation range as a coring level;
A clip procedure for obtaining and clipping a difference between values before and after each coring operation,
A first multiplication procedure for multiplying the calculation result of each clip calculation by the corresponding frequency or slope of the gradation transformation curve;
A first addition procedure for adding all the calculation results from the execution of the first multiplication procedure;
A second multiplication procedure for multiplying the calculation result of the last coring operation by the corresponding frequency or the slope of the gradation transformation curve;
A second addition procedure for adding the operation result obtained by executing the first addition procedure and the operation result obtained by executing the second multiplication procedure;
A storage medium storing a program for executing the program.
走査線上の画素に割り当てられ、かつ共通の命令にしたがって同一の動作を行う複数個のプロセッシング・エレメントを有し、入力した画像信号を走査線単位で処理する機能を有するSIMD型並列プロセッサに、
前記入力画像信号の階調度を画素毎にそれぞれ所定の幅を有する複数の階調度範囲のいずれかに分類し、各々の前記階調度範囲に入る画素を計数して度数を求める度数演算手順と、
前記SIMD型並列プロセッサにより、各々の前記階調度範囲毎に前記度数に応じた階調変換曲線の傾きを求める傾き演算手順と、
前記SIMD型並列プロセッサにより、前記入力画像信号に対して前記階調度範囲および前記傾きに応じた非線形処理を演算で施して、前記入力画像信号の階調度を変換する階調変換手順と、
を実行させ、
前記階調変換手順において、各々のプロセッシング・エレメントによって、
各対応する入力画素データについて前記階調度範囲の個数に応じた回数だけ続けて前記階調度範囲の幅の値をコアリングレベルとするコアリング演算を行うコアリング手順と、
各々の前記コアリング演算の演算前後の値の差分を求めてクリップするクリップ手順と、
各々の前記クリップ演算の演算結果と各対応する前記度数または前記階調変換曲線の傾きとを乗算する第1の乗算手順と、
前記第1の乗算手順の実行による演算結果を全て加え合わせる第1の加算手順と、
最終回の前記コアリング演算の演算結果とそれに対応する前記度数または前記階調変換曲線の傾きとを乗算する第2の乗算手順と、
前記第1の加算手順の実行による演算結果と前記第2の乗算手順の実行による演算結果とを加え合わせる第2の加算手順と
を実行させるためのプログラムを記録した記憶媒体。
A SIMD type parallel processor having a plurality of processing elements assigned to pixels on a scanning line and performing the same operation according to a common command, and having a function of processing an input image signal in units of scanning lines,
A frequency calculation procedure for classifying the gradation of the input image signal into any of a plurality of gradation levels each having a predetermined width for each pixel, and counting the pixels entering each of the gradation levels to obtain the frequency ;
An inclination calculation procedure for obtaining an inclination of a gradation conversion curve according to the frequency for each gradation degree range by the SIMD type parallel processor;
A gradation conversion procedure for converting the gradation degree of the input image signal by performing non-linear processing according to the gradation degree range and the inclination on the input image signal by an operation by the SIMD type parallel processor;
Was executed,
In the gradation conversion procedure, each processing element
A coring procedure for performing a coring operation for each corresponding input pixel data by a number of times corresponding to the number of the gradation range, and using a value of the width of the gradation range as a coring level;
A clip procedure for obtaining and clipping a difference between values before and after each coring operation,
A first multiplication procedure for multiplying the calculation result of each clip calculation by the corresponding frequency or slope of the gradation transformation curve;
A first addition procedure for adding all the calculation results from the execution of the first multiplication procedure;
A second multiplication procedure for multiplying the calculation result of the last coring operation by the corresponding frequency or the slope of the gradation transformation curve;
A second addition procedure for adding the operation result obtained by executing the first addition procedure and the operation result obtained by executing the second multiplication procedure;
A storage medium storing a program for executing the program.
JP30663297A 1997-10-21 1997-10-21 Image gradation conversion method Expired - Fee Related JP4162101B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP30663297A JP4162101B2 (en) 1997-10-21 1997-10-21 Image gradation conversion method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP30663297A JP4162101B2 (en) 1997-10-21 1997-10-21 Image gradation conversion method

Publications (2)

Publication Number Publication Date
JPH11126255A JPH11126255A (en) 1999-05-11
JP4162101B2 true JP4162101B2 (en) 2008-10-08

Family

ID=17959437

Family Applications (1)

Application Number Title Priority Date Filing Date
JP30663297A Expired - Fee Related JP4162101B2 (en) 1997-10-21 1997-10-21 Image gradation conversion method

Country Status (1)

Country Link
JP (1) JP4162101B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2006033595A (en) * 2004-07-20 2006-02-02 Synthesis Corp Illuminance compensation device, and program for functioning computer as illuminance compensation device
JP4835525B2 (en) * 2007-07-04 2011-12-14 ソニー株式会社 Image processing apparatus, image processing method, and program

Also Published As

Publication number Publication date
JPH11126255A (en) 1999-05-11

Similar Documents

Publication Publication Date Title
US5210705A (en) Digital filtering with single-instruction, multiple-data processor
US5798753A (en) Color format conversion in a parallel processor
US5128760A (en) Television scan rate converter
US5600582A (en) Programmable horizontal line filter implemented with synchronous vector processor
JPH02213291A (en) Method and circuit for processing data signal which expressed continuous image of two-dimensional annimate image
JP2002542741A (en) De-interlacing of video signal
CN108765282B (en) Real-time super-resolution method and system based on FPGA
KR20100029223A (en) Image processing device and method for pixel data conversion
EP0069542B1 (en) Data processing arrangement
JPS628072B2 (en)
JPH09231380A (en) Method and device for operating accumulation buffer for graphical image processing
JP4162101B2 (en) Image gradation conversion method
JP4205307B2 (en) Flicker filtering and overscan compensation
CN101425177A (en) Segmented image processing apparatus and method and control factor computation apparatus
CN108875733A (en) A kind of infrared small target quick extraction system
JP2565580B2 (en) Digital image conversion method and conversion system
Iakovidou et al. FPGA implementation of a real-time biologically inspired image enhancement algorithm
JP3914633B2 (en) Color signal processing apparatus and color signal processing method
JP2865168B1 (en) Motion data creation system
US6741294B2 (en) Digital signal processor and digital signal processing method
JPH1098743A (en) Device and method for calculating luminance signal
CN113766205B (en) Tone mapping circuit and image processing apparatus
JPH01280880A (en) Picture processing method
JPH10161633A (en) Picture element interpolating device
US5276778A (en) Image processing system

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20041001

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20080321

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20080415

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080612

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: 20080715

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20080717

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110801

Year of fee payment: 3

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110801

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20120801

Year of fee payment: 4

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20130801

Year of fee payment: 5

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

LAPS Cancellation because of no payment of annual fees