JP4125080B2 - Image processing apparatus, image processing method, and recording medium - Google Patents

Image processing apparatus, image processing method, and recording medium Download PDF

Info

Publication number
JP4125080B2
JP4125080B2 JP2002268490A JP2002268490A JP4125080B2 JP 4125080 B2 JP4125080 B2 JP 4125080B2 JP 2002268490 A JP2002268490 A JP 2002268490A JP 2002268490 A JP2002268490 A JP 2002268490A JP 4125080 B2 JP4125080 B2 JP 4125080B2
Authority
JP
Japan
Prior art keywords
image data
resizing
data
image
image processing
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
JP2002268490A
Other languages
Japanese (ja)
Other versions
JP2004112068A (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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2002268490A priority Critical patent/JP4125080B2/en
Publication of JP2004112068A publication Critical patent/JP2004112068A/en
Application granted granted Critical
Publication of JP4125080B2 publication Critical patent/JP4125080B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Record Information Processing For Printing (AREA)
  • Color, Gradation (AREA)
  • Storing Facsimile Image Data (AREA)
  • Editing Of Facsimile Originals (AREA)
  • Facsimile Image Signal Circuits (AREA)
  • Color Image Communication Systems (AREA)
  • Image Processing (AREA)
  • Compression Of Band Width Or Redundancy In Fax (AREA)

Description

【0001】
【発明の属する技術分野】
本発明はデジタルスチルカメラやビデオカメラなどによって撮像された電子情報を、記録媒体を介して、プリンタ等の出力装置に画像データを出力する画像処理装置、画像処理方法に関する。
【0002】
【従来の技術】
従来から印画用紙に感熱型の用紙を用い、主走査方向に配列された複数個の発熱体を選択的に駆動して、用紙を副走査方向に搬送することで、用紙にドットライン状に印画を行うライン熱転写方式のプリンターがある。
【0003】
近年、入力側としてのデジタルカメラやデジタルビデオカメラ、またはスキャナなどの画像を扱う入力機器の進歩に伴い、プリント手段として、熱転写方式のプリンター装置も注目されている。
【0004】
それはインクジェットプリンターが、液滴を飛ばすか飛ばさないか、という2値の選択しかないために、小さな液滴を用紙へ着弾させて、誤差拡散等の手法でみかけの解像度と階調性を得ようとするのに対して、熱転写方式のプリンターの場合には、一つの画素において、制御可能な熱の値を容易に変更できるため、一つの画素に対する階調性を多く取る事が可能になるので、インクジェットプリンターに比べて滑らかで高画質な画像を得ることができるという点が上げられる。またサーマルヘッドの性能や用紙材料の性能も向上したために、仕上がり品位で銀塩写真にも見劣りしない画像プリントを得る事が可能になっており、近年のデジタルカメラの進歩に歩調を合わせるように特に自然画像用のプリンターとして注目されている。
【0005】
そこでこうしたプリンター装置とデジタルカメラやデジタルビデオカメラなどの撮影機器を直接的に接続したり、または一体的に構成して、撮影された画像情報をコンピューターなどの画像情報を処理する機器を介すことなくプリントするシステムも登場している。
【0006】
デジタルカメラとプリンター装置を直接的に接続したプリントシステムを具体的に説明する。デジタルカメラで撮影された画像は一旦、デジタルカメラが有する記録媒体に保存される。この画像をプリンター装置からプリントアウトする為には、ユーザはデジタルカメラとプリンター装置を専用のケーブルで直接的に接続する。次に、記録媒体に保存されている画像をデジタルカメラの表示装置に表示しプリントしたい画像を選択する。この時画像を選択するためにデジタルカメラの有する操作部材を用いたことは言うまでもない。プリントしたい画像が選択できたらデジタルカメラの操作部材に割り付けられたプリント指示キーを押す。そうすることでデジタルカメラ内でプリント用の画像処理が実行される。デジタルカメラ内での画像処理が終了するとプリント用データをプリンター装置に転送しプリンター装置は受け取ったデータをプリントアウトする。
【0007】
上記の説明ではユーザはプリントアウトをする為にデジタルカメラの操作部材を数回操作するだけで簡単に写真的なプリントアウトを行うことが可能になり、大変便利である。
【0008】
また、デジタルカメラはその装置の性格上、撮影した画像のデータをJPGファイルに圧縮したり、逆にJPGファイルを伸長して画像データを復元する為のJPGチップを有していたり、撮影した画像データを所望のサイズにする為のリサイズ機能を持ったICチップを有している場合が一般的である。このデジタルカメラの有するハードリソースを印刷データ作成の為に有効に利用することはJPG伸長、リサイズ機能をソフト処理で実現する場合に較べて処理時間が格段に速くなるばかりでなく、プリントシステムトータルとして要求されるリソースを最低限で構成することができコストダウンにも繋がる。
【0009】
その反面、上記プリントシステムの構成のように印刷データの画像処理をデジタルカメラ内で実現することは、印刷データ作成の為の画像処理に適したハードブロックを有効に活用できると言う長所もあるもののデジタルカメラ内の有する別のハードブロックの制限を受けると言う短所もある。具体的にはデジタルカメラの有する限られたワークメモリの中で印刷データを作成する為の画像処理を行わなければならなく、印刷データサイズが大きくなるとデジタルカメラのワークメモリが不足すると言うことがある。従来この問題を解決する為に、印刷データの画像処理の各ブロック毎(1次リサイズ、2次リサイズ)にワークメモリに書き出す際に、その装置が対応する全ての印刷データのサイズ(クレジットカードサイズ、Lサイズ、A6サイズ等)を処理可能とする為に、あらかじめリサイズ率及び画像形式(YUV形式)を設定して、印刷データの画像処理中のワークメモリの不足を解消していた。
【0010】
【発明が解決しようとする課題】
しかし、上記プリントシステムの構成のように印刷データサイズ(クレジットカードサイズ、Lサイズ、A6サイズ等)によって画像変換後の画像形式(YUV形式)を一義的に決定すると言うことは、入力画像サイズによっては、例え画像処理用のワークメモリが充分にあるとしても画像データを間引く処理をしていたので、過度のプリント画像の劣化を招くと言う問題点があった。
【0011】
【課題を解決するための手段】
かかる課題を解決する為、本発明は、画像データの記録されている記憶媒体から、圧縮画像データを取り込む取り込み手段と、取り込み手段により取り込まれた圧縮画像データを展開する展開手段と、展開手段で展開された画像データを格納する内部メモリと、内部メモリに格納される画像データを、印刷画像データに変換して出力する出力手段とを有し、展開手段は、圧縮画像データを展開する前に、圧縮画像データを展開後の画像データの大きさと内部メモリの空き容量とに基づいて、輝度色差信号の形式を選択することを特徴とする。
【0012】
【発明の実施の形態】
〔第1の実施形態〕
図1に本発明の第1の実施例の構成図を示す。第1の実施例では1のデジタルカメラで撮影した画像及び撮影後メモリー媒体に保存し再度読み出した画像をデジタルカメラ内で昇華型プリンターのプリントデータに画像処理した後、2の専用ケーブル経由でイエロー、マゼンタ、シアンの順で3の昇華型プリンターに送り出しそのデータをカラープリントする例である。
【0013】
ユーザは、図1に示すデジタルカメラの操作部材4でプリントパターン、プリントしたい画像、プリント指定枠等を選択しデジタルカメラの液晶画面5でそれらの内容を確認することが可能である。
【0014】
図2に本発明で用いた画像記録方式の昇華型熱転写方式の基本原理を説明するための概略図を示す。昇華型熱転写方式は、染料(色素)の拡散現象を用いた方式である。
図中11は、3色(イエロー、マゼンタ、シアン)の染料をプラスチックシートに塗布したインクシートである。このインクシート11は専用印画紙12と重ね合わされた形で、サーマルヘッド13とプラテンローラー14によって挟支されこのインクシートをサーマルヘッド13の熱により、専用印画紙12に昇華/熱拡散させることにより、カラープリントを得る。
【0015】
また、専用印画紙12には、昇華性染料15の発色を確保するために、ポリエステル系樹脂を主成分とした受容層16が塗布されている。この時サーマルヘッド13に与える熱量を制御することにより階調を与えることができる。3色(イエロー、マゼンタ、シアン)それぞれに階調を与え、印画紙の同じ個所に重ねてプリントすることにより1画素単位の高精細フルカラープリントを実現できる。
【0016】
次に、本実施例でプリント用データを作成する為の画像処理部分を行うデジタルカメラのブロック図を図3に示す。図中20はレンズを通して結像された画像を電気信号に変換するためのCCD、21は本デジタルカメラシステムを制御、演算処理を司るCPU、22はCCDから送られてきた電気信号を処理する画像処理エンジン、23は本デジタルカメラシステムを制御するためのプログラムを格納しておくためのFlash ROM、24は、画像データを一時的に保存したり、データ処理作業に使うためのSDRAM、25は画像データファイルを保存しておくためのCF(コンパクトフラッシュ(R)メモリー)、26はCFを本デジタルカメラに装着するためのCFコネクター、27は本デジタルカメラで撮影した画像を表示したり、本デジタルカメラを操作するメニューを表示するためのLCD、28は、そのLCDをドライブするLCDドライバーである。
【0017】
本実施例では図4に示すように3つのプリントパターンを選択することが可能である。
【0018】
1つめは、縁無し(図4−1)このパターンは記録用紙全面に画像をプリントする。2つめは縁有り(図4−2)このパターンは記録用紙に画像全体が収まるようにプリントされる。3つめはマルチ(図4−3)このパターンは同一の画像が8つ印刷(カードサイズの場合)される。
【0019】
更に本実施例では図5に示すように3種類の印刷用紙を選択することが可能である。図中▲1▼がカードサイズで縦横のサイズは、1040x662ピクセルである。昇華型プリンターは1ピクセルで256段階の階調表現が可能であるのでイエロー、マゼンタ、シアンのそれぞれで、1040x662x256(bit)=1040x662(Byte)=688.480(Kbyte)のデータ量が印刷時に必要になる。▲2▼はL判サイズで縦横のサイズは、1456x1100ピクセルである。データ量としては、イエロー、マゼンタ、シアンでそれぞれ
1456x1100x256(bit)=1456x1100(Byte)=1601.600(Kbyte)である。
▲3▼はA6サイズで縦横のサイズは、1808x1232ピクセルである。データ量としては、イエロー、マゼンタ、シアンでそれぞれ
1808x1232x256(bit)=1808x1232(Byte)=2227.456(Kbyte)である。
【0020】
各印刷用紙のデータ量は、▲1▼のカードサイズを1.000とすると▲2▼のL判サイズは、その2.326倍、▲3▼のA6サイズは3.235倍になり印刷用紙サイズが大きくなるにつれ画像処理時に必要となるワークメモリが大きくなることが分かる。
【0021】
図6に本実施例の印刷画像データ作成手順を示す。まず、▲2▼CF(コンパクトフラッシュ(R)メモリ)に保存されているJPGファイルをデジタルカメラのワークメモリ上に読み込む。
【0022】
次に▲3▼ワークメモリ上のJPGファイルをJPGチップに送り伸長後、1次リサイズを行う。この時画像形式としてはYUV形式で1次リサイズ後の画像データはワークメモリ上に書き込まれる。更に、▲4▼入力画像サイズと印刷画像サイズの関係から必要があればローパスフィルターをかける。▲5▼1次リサイズ後、或いは、ローパスフィルター後の画像データを読み込み2次リサイズを行い所望のYUV形式のデータを得その結果をワークメモリに書き込む、その画像データにシャープネスを施す。最後に、▲6▼YUV形式の画像データからイエロー(Y)、マゼンダ(M)、シアン(C)の印刷画像データをそれぞれ作成する。
【0023】
上記に説明した印刷画像データ作成手順の途中でのワークメモリの使い方を図7を用いて具体的に説明する。
【0024】
図中各メモリマップの上下の濃い網掛け部分はシステムが使用する領域である。まず、CF(コンパクトフラッシュ(R)メモリ)から読み込まれたJPGファイルは、圧縮状態のまま図7−▲1▼のJPEG読み込み領域71に展開される。次に、JPEG読み込み領域71上に展開されているJPGファイルを画像変換ブロック1に読み込み伸長を行い、次に1次リサイズを実行する。その結果のデータを展開する領域は図7−▲2▼に示す領域72が利用可能である。この時、展開処理の確実性を考慮して、JPGファイルが展開されている領域71を上書きしてはならない事としている。次に、入力画像が非常に大きく、出力すべきデータ量と比較して明らかにデータの削減が大きいことが予想されるような場合などには、ローパスフィルターをかける。例えば、比較的印刷サイズが小さい場合には、出力するべき印刷データも小さくすむが、この印刷データが、展開されて一次リサイズ後の画像データよりも例えば1/2以下であることが予想される場合には、ローパスフィルターをかけるようにする。
【0025】
ローパスフィルターをかける必要がある場合には図7−▲3▼に示すようにワークメモリを目いっぱい使ってローパスフィルターをかけることになる。また、ローパスフィルター適用後のデータは、1次リサイズ後のデータと同じ位置(アドレス)の領域74に展開される。従って、画像変換ブロック2(2次リサイズ)にデータを渡す際のデータの位置(アドレス)は、ローパスフィルターをかける、かけないにかかわらず同一である。2次リサイズ後の展開領域は図7−▲5▼の領域75に示す。この2次リサイズ後のYUVデータからプリント用データであるイエロー(Y)、マゼンダ(M)、シアン(C)をそれぞれ作成し図7−▲6▼に示すY/M/Cのデータ領域76に展開する。最後にY/M/Cのデータの周辺部分を、印刷用紙に合わせて切り落とす等のよりを行って、図7−▲7▼のY’/M’/C’のデータ領域77にコピーすると印刷データが完成する。
【0026】
上記の印刷データ処理において注意しなければならないのは、中間段階でのデータがそれぞれの時点においてワークメモリ内で処理できるデータサイズでなければならないと言うことである。
【0027】
それと同時に、印刷画質をなるべくよいものとする為に、印刷データとして処理すべきデータ量をなるべく多く確保したい。
【0028】
そこで、本実施例では1次リサイズ後の画像データのYUV形式とリサイズ率を1次リサイズ後に画像を展開するワークメモリ72の大きさを超えないように決定することで、ワークメモリに書き出す際のデータ容量を調節することを可能とし印刷画像データ処理途中で必要となるワークメモリ領域の重複を避け且つ印刷画像の劣化を無くすことが可能とする。
【0029】
ここで言うYUV形式とは画像データを表す際の輝度データ(Y)と色差データ(U、V)の含まれる割合である。YUV4:4:4、YUV4:2:2、YUV4:1:1等が一般的な形式である。YUV4:4:4は輝度データとU、Vの色差データの割合が等しい場合である。YUV4:2:2は輝度データ4に対して、U、Vの色差データが2のデータ形式であり、YUV4:1:1は輝度データ4に対して、U、Vの色差データが1のデータ形式である。図8にYUV4:2:2とYUV4:1:1のデータ量の違いを示す。
【0030】
YUV4:2:2の場合は4ピクセルのデータを表現するのに4ワードのデータが必要であり、YUV4:1:1の場合は4ピクセルのデータを表現するのに3ワードのデータが必要である。従って、YUV4:1:1の方がYUV4:2:2に対して3/4のデータ量で済むことが分かる。ワークメモリのデータ量が不足する場合にはYUV4:1:1を使った方が有利であることが分かる。
【0031】
また、図8のYUV4:2:2とYUV4:1:1のデータパッキングの形から、YUV4:2:2の場合は2ピクセル単位のデータの扱いが可能であるが、YUV4:1:1の場合は4ピクセル単位でしかデータを扱うことができないことが分かる。このことは、リサイズ処理等を行う際にYUV4:2:2の場合は2の倍数のデータサイズを扱うことができるが、YUV4:1:1の場合は4の倍数のデータサイズしか扱うことができず、サイズの自由度という観点からはYUV4:2:2の方が有利である。さらに、画像データの情報量の観点からは同じ画像を表現する時にはYUV4:2:2の方が多く画像を忠実に表現でき画像劣化もYUV4:1:1よりは少ないと考えられる。
【0032】
上述のことを考慮して本実施例での1次リサイズ時のリサイズ率、YUV形式の決定のしかたを図9、図10を用いて具体的に説明する。
【0033】
ローパスフィルターをかけるかかけないかによって考え方が違う。
【0034】
ローパスフィルターをかけない場合。図9にそのフローチャートを示す。まず、1次リサイズ率の分母、分子、リサイズ後の書き出しデータのYUV形式を初期値として設定する(S1)。1次リサイズ率の分母、分子は共に8を設定する。この値だとJPG伸長後データはリサイズを行わずそのままワークメモリ上に展開される。書き出しデータのYUV形式は、4:2:2を設定する。次に、JPG伸長・1次リサイズ後のデータ量が予め確保されているワークメモリ容量の中に収まるかを判定する(S2)。Yesなら左側の分岐、Noなら右側の分岐に進む。Yesで左側の分岐に進んだら、2次リサイズ後の画像サイズとしてのリサイズ目標サイズと、入力画像サイズを(B−2)/A倍した値とを比較する(S3)。リサイズ目標サイズの方が小さければ、1次リサイズ率の値をB−2(=6)とする(S4)。ここでこのような操作をするのは、1次リサイズ率を8/8としてリサイズを行わないで、2次リサイズ一回で目標のサイズにリサイズするよりも、1次リサイズと2次リサイズの二回で目標のサイズにリサイズした方が、一般的にリサイズ後の画像品質が良いためである。
【0035】
但し、1次リサイズで縮小した結果がリサイズ目標サイズよりも小さくなってしまうと、必要以上に画像データを捨てていることになるので、1次リサイズ率の分子は初期値のままにしている(S5)。S2で一度もNOの判別がなされていなければ、S4、5どちらのケースに進んだ場合も、YUV形式は、初期値のままである。この実施例の場合は、4:2:2である。
【0036】
S2の条件判断がNoの場合には、S6に進み、始めはYUV形式が4:2:2なので、、S7に進んでYUV形式を4:1:1に設定する。その後、再度S2の条件判断を行う。この段階でS2の結果がYesの場合はS3に進み上述の操作を行う。まだ、Noの場合には、S6に進み、今度はYUV形式が4:1:1なのでS8で4:2:2に設定し直し、S9で分子の初期値から2を引く。この時点での1次リサイズ率は、分母=8、分子=6、YUV形式4:2:2である。以上のような操作を繰り返し1次リサイズ率と1次リサイズ後の書き出し時のYUV形式を決定する。
【0037】
即ち、1次リサイズ率と1次リサイズ後のYUV形式は次のようになる。
1.YUV形式は4:2:2で1次リサイズが等倍でワークメモリにリサイズ後のデータが収まるが、入力画像を6/8倍してもリサイズ目標サイズよりも大きい場合には、1次リサイズ率6/8、YUV形式4:2:2となる。
2.YUV形式は4:2:2で1次リサイズが等倍でワークメモリにリサイズ後のデータが収まるが、入力画像を6/8倍するとリサイズ目標サイズよりも小さい場合には、1次リサイズ率8/8、YUV形式4:2:2となる。
3.YUV形式は4:2:2で1次リサイズが等倍だとワークメモリにリサイズ後のデータが収まらない場合には、YUV形式を4:1:1にすることでワークメモリ内に1次リサイズ後のデータが収まり入力画像を6/8倍してもリサイズ目標サイズよりも大きい場合には、1次リサイズ率6/8、YUV形式4:1:1となる。
4.YUV形式は4:2:2で1次リサイズが等倍だとワークメモリにリサイズ後のデータが収まらない場合には、YUV形式を4:1:1にすることでワークメモリ内に1次リサイズ後のデータが収まり入力画像を6/8倍するとリサイズ目標サイズよりも小さい場合には、1次リサイズ率8/8、YUV形式4:1:1となる。
5.YUV形式を4:1:1として1次リサイズを等倍でもワークメモリ内に1次リサイズ後のデータが収まらない場合には、YUV形式を4:2:2として分子を6としてワークメモリ内に1次リサイズ後のデータが収まるかを判定して収まるようだと、
1次リサイズ率6/8、YUV形式4:2:2となる。
【0038】
なお、ここで5つの場合しか列挙していないのは、後述するように、1次リサイズ率が4/8となることが予想されるような場合には、ローパスフィルタを適用することとしているので、このフローでは4/8になることが無いものとしているからである。
【0039】
次に、ローパスフィルターをかける場合は、図10にそのフローチャートを示す。
この場合は、展開後の画像データ明らかに大きい場合で、1次リサイズでのリサイズ率が4/8(つまり1/2)よりも小さくなる場合を想定している。
【0040】
なお、所定の印刷サイズよりも小さな印刷サイズが選択されている場合に、自動的に本フローが適用されても良い。
【0041】
まず、S11で、1次リサイズ率の分母、分子、リサイズ後の書き出しデータのYUV形式を初期値として設定する。1次リサイズ率の分母、分子は共に8を設定する。この値だとJPG伸長後データはリサイズを行わずそのままワークメモリ上に展開される。書き出しデータのYUV形式は、4:2:2を設定する。次に、S12で、JPG伸長・1次リサイズ後のデータ量が予め確保されているワークメモリ容量の中に収まるかを判定する。Yesなら左側の分岐(S13)へ行き、Noなら右側の分岐(S15)に進む。Yesで左側の分岐(S13)に進んだら、ローパスフィルターをかける時に充分なワークメモリがあるかを判定する。判定がYesなら左側の分岐に進み、S14で1次リサイズ率の分子を初期値のまま8としこの時点で1次リサイズ率、リサイズ後の書き出しデータのYUV形式は初期値のままで決定されたことになる。ローパスフィルターは、画像をリサイズする前にかけなければ効果が少ないので1次リサイズ率は可能限り等倍となるようにする。
【0042】
S12、S13の条件判断の何れかがNoの場合には、S15に進みYUV形式を4:1:1に設定する(S16)。その後、再度S12、S13の条件判断を行う。S12、S13の結果が両方ともYesの場合はS14に進み1次リサイズ率の分子は初期値のまま8とする。S12、S13の判定の結果いずれかがNoの場合には、再びS15に進み現在のYUV形式が4:1:1なので、今度はS17でYUV形式を4:2:2に設定し直し、S18で分子の初期値から2を引く。この時点での1次リサイズ率は、分母=8、分子=6、YUV形式4:2:2である。以上のような操作を繰り返し1次リサイズ率と1次リサイズ後の書き出し時のYUV形式を決定する。
【0043】
即ち、1次リサイズ率と1次リサイズ後のYUV形式は次のようになる。
1.YUV形式は4:2:2で1次リサイズが等倍でワークメモリにリサイズ後のデータが収まり且つローパスフィルターを実行するに充分なワークメモリがある場合には、1次リサイズ率8/8、YUV形式4:2:2となる。
2.YUV形式は4:2:2で1次リサイズが等倍だとワークメモリにリサイズ後のデータが収まらないか、ローパスフィルターを実行するには充分なワークメモリが無い場合には、YUV形式を4:1:1にすることでワークメモリ内に1次リサイズ後のデータが収まり、ローパスフィルターの実行に充分なワークメモリがあるようだと、1次リサイズ率8/8、YUV形式4:1:1となる。
3.YUV形式を4:1:1として1次リサイズを等倍でもワークメモリ内に1次リサイズ後のデータが収まらないかローパスフィルターを実行するに充分なワークメモリが無い場合には、YUV形式を4:2:2として分子を6としてワークメモリ内に1次リサイズ後のデータが収まり、ローパスフィルターの実行に充分なワークメモリがあるようだと、1次リサイズ率6/8、YUV形式4:2:2となる。
【0044】
ここでも、1次リサイズ率6/8迄としているが、1次リサイズ率として、もっとデータ量を削減したい場合には、更にデータ削減率が大きなローパスフィルタを適用し、例えば展開直後の画像データ量の1/4程度にするようなものを用意しておけばよい。
もちろん、1次リサイズ率を4/8、2/8となるまで処理を続けても対応可能である。
【0045】
これまで、説明してきたことを考慮しながら印刷画像のデータ処理を行っている訳だが、本実施例の一連のデータ処理フローは、図11のようになる。
【0046】
本実施例では、カードサイズのみ印刷可能なプリンターとカードサイズ、L判サイズ、A6サイズの印刷が可能なプリンターをサポートしており、用紙サイズに応じて初期値としてのYUV形式を設定する。ただし、この初期値設定は、図9、図10のような処理を行うことで、適宜可変である。
【0047】
以下、処理フローを説明する。設定されているPrint Modeを取得する(S21)。図4でも説明したが、Print Modeとして縁無し、縁有り、マルチが選択可能であるがそのPrint Modeのいずれが指定されているかを取得する。S22でPrinter Typeを取得する。前にも説明したが本実施例では、カードサイズのみ印刷可能なタイプのプリンターとカード、L判、A6サイズの印刷が可能なタイプのプリンターをサポートするのでそのPrinter Typeを取得する。S23で、S22で取得したプリンタータイプを判定する。カードサイズのみ印刷可能なプリンターであればPaper Typeをカードに固定する(S24a)。カード、L判、A6サイズの印刷が可能なプリンターであればPaper Typeを取得する(S24b)。S25でPaper Typeを判定しカード、L判、A6で振り分ける。カードサイズの場合(S26a)は、1次リサイズ後、2次リサイズ後共YUV4:2:2のデータ形式を指定し、1次リサイズ後、2次リサイズ後にデータを書き出すワークメモリのアドレスを指定する。L判サイズの場合(S26b)、1次リサイズ後YUV4:2:2、2次リサイズ後YUV4:1:1のデータ形式を指定し、1次リサイズ後、2次リサイズ後にデータを書き出すワークメモリのアドレスを指定する。A6サイズの場合(S26c)、1次リサイズ後YUV4:2:2、2次リサイズ後YUV4:1:1のデータ形式を指定し、1次リサイズ後、2次リサイズ後にデータを書き出すワークメモリのアドレスを指定する。
【0048】
ここで、各印刷用紙毎に1次リサイズ後、2次リサイズ後の画像データ形式を設定したがこの値は使用できるワークメモリの容量によって変わってくる。
【0049】
つまりその後のS27において、図9、図10で説明した手順で1次リサイズ率、1次リサイズ後の画像形式を決定する。S28において、S27でそれぞれ決定したYUV形式でJPG伸長、1次リサイズを行い、ワークメモリにデータを書き出す。S29で、1次リサイズ後ワークメモリに書き込まれたデータを読み込み2次リサイズを実行しS26a、b、cで指定されたYUV形式でワークメモリに書き込む。
【0050】
S30、Print Modeがマルチかどうかを判定する。S31は、マルチなら2次リサイズ後に更に3次リサイズを行う。このように分割的にリサイズ処理をすることで、画質の劣化が多少なりとも抑えられる。S32で、所望のサイズにリサイズされた画像データにシャープネスをかける。S33で、YUVデータ形式の画像データから、まず、イエロー(Y)データを作成する。以降の処理はマゼンタ(M)、シアン(C)作成毎に行う。結果として3回同じルーチンを通ることになる。S34で、印刷データの微調整、位置調整の為にPrint Modeを判定する。縁無しの場合S36cでYUVデータからの色変換後のデータの周辺部分の数ピクセル分のデータを捨てプリントデータ格納領域にコピーする。縁有りの場合S35bで印刷データ格納領域を印刷用紙に応じたデータ量分だけ白データ(FFh)で塗りつぶす。S36bで上記印刷データ格納領域にYUVデータからの色変換後のデータの周辺部分の数ピクセル分のデータを捨て重心に位置調整してコピーする。マルチの場合S35aで印刷データ格納領域を印刷用紙に応じたデータ量分だけ白データ(FFh)で塗りつぶす。S36bで上記印刷データ格納領域にYUVデータからの色変換後のデータの周辺部分の数ピクセル分のデータを捨て所定の枚数分同一の画像を並べる。S37で、プリンターへ印刷データを転送する。
【0051】
マゼンタ(M)、シアン(C)作成毎にS33からS37の処理を繰り返す。
【0052】
以上のように本プリントシステムは実現可能である。
【0053】
〔第2の実施形態〕
図12に本発明の第2の実施例の構成図を示す。第2の実施例では1001のデジタルカメラで撮影した画像及び撮影後メモリー媒体に保存し再度読み出した画像をデジタルカメラ内で昇華型プリンターのプリントデータに画像処理した後、デジタルカメラに内蔵されている昇華型プリンターでカラープリントする例である。
【0054】
ユーザは、図12に示すデジタルカメラの操作部材1002でプリントモード、プリントしたい画像、プリント枚数等を選択しデジタルカメラの液晶画面1003でそれらの内容を確認することが可能である。
【0055】
プリントデータを作成するための画像処理に関しては実施例1と同様なのでここでは省略するが、デジタルカメラとプリンタとを常に一体としているので、撮影後に自動的にプリントを開始するモードを備えている。あらかじめプリント用紙が内蔵されているので、このモードが設定されているときには、設定されている用紙サイズに合わせて、図11のS26a、b、cの処理が自動的に選択される。
【0056】
さらに、デジタルカメラでは通常、撮影して得られる画像サイズが選択設定可能である。
【0057】
しかし、撮影後に自動的にプリント処理するモードの場合には、使用する用紙によってあらかじめ撮影して得られる画像サイズを決めておく。
【0058】
つまり使用者は、撮影後に自動的にプリント処理するモードを選択しただけで、内蔵している用紙にあわせたカメラ制御がなされるので、わずらわしい操作を軽減することが出来る。そしてその場合に得られるプリントは、内部メモリを最大限に利用して、用紙に合わせてなるべく高画質なものとすることが出来る。
【0059】
【発明の効果】
以上説明したように、本発明によれば、プリンター装置とデジタルカメラやデジタルビデオカメラ等の撮影機器を直接接続したプリントシステムやそれらの装置が一体になった形でプリントシステムを構成する際に、画像変換方式1(1次リサイズ)のリサイズ率と画像変換後の画像フォーマット(YUV形式)を、画像サイズ変換後にデータを展開するデータ領域の大きさ、画像変換方式1によってサイズ変換された画像サイズと最終的な目標画像サイズの関係、画像サイズ変換前にローパスフィルター(LPF)を施すかどうか、ローパスフィルターを実行する際に充分なワークメモリがあるか、によって決定することで印刷データの画像処理中にワークメモリを不足させること無く、またメモリ領域をなるべく有効に利用することが出来る。そして、得られるプリント画像の劣化をなるべく低減することを可能にした。
【図面の簡単な説明】
【図1】第1の実施形態を説明する図
【図2】昇華型熱転写方式の概要を説明する図
【図3】本実施例のデジタルカメラブロック図
【図4】プリントパターンの説明図
【図5】印刷用紙の違いによる印刷データサイズを説明する図
【図6】プリントデータ画像処理手順を説明する図
【図7】印刷画像データ作成時のワークメモリの使い方を説明する図
【図8】YUV422とYUV411のデータ量の違いを説明する図
【図9】1次リサイズ率、YUV形式の決定フロー(ローパスフィルター無し)
【図10】1次リサイズ率、YUV形式の決定フロー(ローパスフィルター有り)
【図11】本実施例の処理フローを説明する図
【図12】第二実施例を説明する図
[0001]
BACKGROUND OF THE INVENTION
The present invention relates to an image processing apparatus and an image processing method for outputting image data of electronic information captured by a digital still camera or a video camera to an output device such as a printer via a recording medium.
[0002]
[Prior art]
Conventionally, heat-sensitive paper has been used as printing paper, and a plurality of heating elements arranged in the main scanning direction are selectively driven to convey the paper in the sub-scanning direction, thereby printing dots on the paper. There is a line thermal transfer printer.
[0003]
In recent years, with the progress of input devices that handle images such as digital cameras, digital video cameras, and scanners on the input side, thermal transfer type printer devices have attracted attention as printing means.
[0004]
Because the inkjet printer has only two choices of whether or not to drop the droplets, let the small droplets land on the paper and get an apparent resolution and gradation by methods such as error diffusion On the other hand, in the case of a thermal transfer printer, the controllable heat value can be easily changed in one pixel, so that a large gradation can be obtained for one pixel. As a result, it is possible to obtain a smoother and higher quality image as compared with the ink jet printer. In addition, the performance of the thermal head and the performance of paper materials have also improved, making it possible to obtain image prints that are as good as silver halide photographs with a finished quality, especially in order to keep pace with the recent progress of digital cameras. It is attracting attention as a printer for natural images.
[0005]
Therefore, such a printer device and a photographing device such as a digital camera or a digital video camera are directly connected to each other or are integrally configured, and the photographed image information is passed through a device such as a computer for processing the image information. There is also a system for printing.
[0006]
A printing system in which a digital camera and a printer device are directly connected will be specifically described. An image taken with a digital camera is temporarily stored in a recording medium included in the digital camera. In order to print out the image from the printer device, the user directly connects the digital camera and the printer device with a dedicated cable. Next, the image stored in the recording medium is displayed on the display device of the digital camera, and the image to be printed is selected. Needless to say, the operation member of the digital camera is used to select an image at this time. When the image to be printed can be selected, the print instruction key assigned to the operation member of the digital camera is pressed. By doing so, image processing for printing is executed in the digital camera. When the image processing in the digital camera is completed, the print data is transferred to the printer device, and the printer device prints out the received data.
[0007]
In the above description, the user can easily perform a photographic printout by simply operating the operation member of the digital camera several times for printing out, which is very convenient.
[0008]
In addition, the digital camera has a JPG chip for compressing captured image data into a JPG file or decompressing the JPG file to restore the image data due to the nature of the device. In general, it has an IC chip having a resizing function for making data a desired size. Effective use of the hardware resources of this digital camera for creating print data not only greatly increases the processing time compared to the case where JPG decompression and resizing functions are realized by software processing, but also as a total printing system. The required resources can be configured at the minimum, leading to cost reduction.
[0009]
On the other hand, the realization of print data image processing within the digital camera as in the configuration of the print system described above has the advantage that the hardware blocks suitable for image processing for print data creation can be used effectively. There is also a disadvantage of being limited by another hard block in the digital camera. Specifically, image processing for creating print data must be performed in the limited work memory of the digital camera, and when the print data size increases, the work memory of the digital camera may be insufficient. . Conventionally, in order to solve this problem, when writing to the work memory for each block (primary resizing, secondary resizing) of image processing of print data, the size of all the print data (credit card size) supported by the device , L size, A6 size, etc.), the resizing rate and the image format (YUV format) are set in advance to solve the shortage of work memory during image processing of print data.
[0010]
[Problems to be solved by the invention]
However, the fact that the image format after image conversion (YUV format) is uniquely determined by the print data size (credit card size, L size, A6 size, etc.) as in the configuration of the printing system described above depends on the input image size. However, even if there is a sufficient work memory for image processing, the image data is thinned out, so that there is a problem that the print image is excessively deteriorated.
[0011]
[Means for Solving the Problems]
In order to solve such a problem, the present invention includes a capturing unit that captures compressed image data from a storage medium in which image data is recorded, a decompressing unit that decompresses compressed image data captured by the capturing unit, and a decompressing unit. An internal memory for storing the decompressed image data; and output means for converting the image data stored in the internal memory into print image data and outputting the print image data. The decompression means before decompressing the compressed image data The format of the luminance color difference signal is selected based on the size of the image data after decompressing the compressed image data and the free space in the internal memory.
[0012]
DETAILED DESCRIPTION OF THE INVENTION
[First Embodiment]
FIG. 1 shows a configuration diagram of a first embodiment of the present invention. In the first embodiment, an image photographed by the digital camera 1 and an image stored in the memory medium after photographing and read out again are processed into print data of the sublimation printer in the digital camera, and then yellow via two dedicated cables. In this example, the data is sent to a sublimation printer 3 in the order of magenta and cyan, and the data is color-printed.
[0013]
The user can select a print pattern, an image to be printed, a print designation frame, and the like with the operation member 4 of the digital camera shown in FIG. 1 and confirm the contents on the liquid crystal screen 5 of the digital camera.
[0014]
FIG. 2 is a schematic diagram for explaining the basic principle of the sublimation thermal transfer system of the image recording system used in the present invention. The sublimation type thermal transfer method is a method using a diffusion phenomenon of a dye (pigment).
In the figure, reference numeral 11 denotes an ink sheet in which dyes of three colors (yellow, magenta, and cyan) are applied to a plastic sheet. The ink sheet 11 is superimposed on the dedicated photographic paper 12 and sandwiched between the thermal head 13 and the platen roller 14, and the ink sheet is sublimated / thermally diffused onto the dedicated photographic paper 12 by the heat of the thermal head 13. Get a color print.
[0015]
In addition, in order to ensure the color development of the sublimation dye 15, a receiving layer 16 mainly composed of a polyester resin is applied to the dedicated photographic paper 12. At this time, gradation can be given by controlling the amount of heat given to the thermal head 13. By giving gradation to each of the three colors (yellow, magenta, and cyan) and printing them on the same part of the photographic paper, high-definition full-color printing in units of one pixel can be realized.
[0016]
Next, FIG. 3 shows a block diagram of a digital camera that performs an image processing portion for creating print data in this embodiment. In the figure, 20 is a CCD for converting an image formed through a lens into an electric signal, 21 is a CPU that controls the digital camera system, and is responsible for arithmetic processing, and 22 is an image that processes an electric signal sent from the CCD. A processing engine, 23 is a flash ROM for storing a program for controlling the digital camera system, 24 is an SDRAM for temporarily storing image data or used for data processing work, and 25 is an image. A CF (Compact Flash (R) memory) for storing data files, 26 a CF connector for mounting the CF on the digital camera, 27 an image taken with the digital camera, An LCD 28 for displaying a menu for operating the camera is an LCD driver for driving the LCD. Iber.
[0017]
In this embodiment, three print patterns can be selected as shown in FIG.
[0018]
First, there is no border (FIG. 4-1). This pattern prints an image on the entire surface of the recording paper. The second has a border (FIG. 4-2). This pattern is printed so that the entire image fits on the recording paper. The third is multi (FIG. 4-3). In this pattern, eight identical images are printed (in the case of card size).
[0019]
Furthermore, in this embodiment, it is possible to select three types of printing paper as shown in FIG. In the figure, (1) is the card size and the vertical and horizontal size is 1040x662 pixels. Since sublimation printers can express 256 levels of gradation with one pixel, a data amount of 1040x662x256 (bit) = 1040x662 (Byte) = 688.480 (Kbyte) is required for printing in each of yellow, magenta, and cyan. . (2) is an L size and the vertical and horizontal sizes are 1456 x 1100 pixels. The amount of data is yellow, magenta and cyan.
1456x1100x256 (bit) = 1456x1100 (Byte) = 1601.600 (Kbyte).
(3) is A6 size and the vertical and horizontal size is 1808x1232 pixels. The amount of data is yellow, magenta and cyan.
1808x1232x256 (bit) = 1808x1232 (Byte) = 2227.456 (Kbyte).
[0020]
The amount of data on each printing paper is as follows. If the card size in (1) is 1.000, the L size in (2) is 2.326 times that of A, and the A6 size in (3) is 3.235 times. It can be seen that the work memory required for processing increases.
[0021]
FIG. 6 shows a print image data creation procedure of this embodiment. First, (2) the JPG file stored in the CF (compact flash (R) memory) is read into the work memory of the digital camera.
[0022]
Next, (3) the JPG file on the work memory is sent to the JPG chip and decompressed, and then the primary resizing is performed. At this time, the image data after the primary resizing in the YUV format is written on the work memory. Furthermore, (4) a low pass filter is applied if necessary from the relationship between the input image size and the print image size. (5) The image data after the primary resizing or after the low pass filter is read and subjected to the secondary resizing to obtain the desired YUV format data, and the result is written in the work memory, and the image data is sharpened. Finally, {circle over (6)} yellow (Y), magenta (M), and cyan (C) print image data are created from the YUV format image data.
[0023]
The use of the work memory during the print image data creation procedure described above will be specifically described with reference to FIG.
[0024]
In the figure, dark shaded portions above and below each memory map are areas used by the system. First, the JPG file read from the CF (compact flash (R) memory) is expanded in the JPEG reading area 71 of FIG. Next, the JPG file developed on the JPEG reading area 71 is read into the image conversion block 1 and decompressed, and then primary resizing is executed. As an area for developing the resultant data, an area 72 shown in FIG. At this time, in consideration of the certainty of the expansion process, the area 71 where the JPG file is expanded should not be overwritten. Next, when the input image is very large and it is expected that the data reduction is obviously large compared to the amount of data to be output, a low pass filter is applied. For example, if the print size is relatively small, the print data to be output may be small, but this print data is expected to be, for example, ½ or less than the image data after being expanded and subjected to the primary resizing. In some cases, a low-pass filter is applied.
[0025]
When it is necessary to apply a low-pass filter, the work memory is used as much as shown in FIG. Further, the data after applying the low-pass filter is developed in a region 74 at the same position (address) as the data after the primary resizing. Therefore, the position (address) of data when the data is transferred to the image conversion block 2 (secondary resizing) is the same regardless of whether or not the low-pass filter is applied. The developed area after the secondary resizing is shown in an area 75 in FIG. Yellow (Y), magenta (M), and cyan (C), which are print data, are created from the YUV data after the secondary resizing, and are created in the Y / M / C data area 76 shown in FIG. expand. Finally, the peripheral portion of the Y / M / C data is copied to the Y '/ M' / C 'data area 77 in FIG. The data is complete.
[0026]
It should be noted that in the above-described print data processing, the data in the intermediate stage must have a data size that can be processed in the work memory at each time point.
[0027]
At the same time, in order to improve the print image quality as much as possible, it is desirable to secure as much data as possible to be processed as print data.
[0028]
Therefore, in this embodiment, the YUV format and the resizing rate of the image data after the primary resizing are determined so as not to exceed the size of the work memory 72 for expanding the image after the primary resizing, so that the data is written to the work memory. It is possible to adjust the data capacity, avoid duplication of work memory areas required during print image data processing, and eliminate print image deterioration.
[0029]
The YUV format referred to here is a ratio in which luminance data (Y) and color difference data (U, V) are included when representing image data. YUV4: 4: 4, YUV4: 2: 2, YUV4: 1: 1, etc. are common formats. YUV4: 4: 4 is the case where the ratio of the luminance data and the U and V color difference data is equal. YUV4: 2: 2 is a data format in which U and V color difference data is 2 with respect to luminance data 4, and YUV4: 1: 1 is data in which U and V color difference data is 1 with respect to luminance data 4. Format. FIG. 8 shows the difference in data amount between YUV4: 2: 2 and YUV4: 1: 1.
[0030]
In the case of YUV4: 2: 2, 4 words of data are required to express 4 pixels of data, and in the case of YUV4: 1: 1, 3 words of data are required to express 4 pixels of data. is there. Therefore, it can be seen that YUV4: 1: 1 requires 3/4 of the data amount compared to YUV4: 2: 2. It can be seen that it is advantageous to use YUV 4: 1: 1 when the amount of data in the work memory is insufficient.
[0031]
Further, from the data packing form of YUV4: 2: 2 and YUV4: 1: 1 in FIG. 8, in the case of YUV4: 2: 2, data can be handled in units of 2 pixels, but YUV4: 1: 1. In this case, it can be seen that data can be handled only in units of 4 pixels. This means that when resizing, etc., YUV4: 2: 2 can handle a data size that is a multiple of 2, but YUV4: 1: 1 can only handle a data size that is a multiple of 4. However, YUV 4: 2: 2 is more advantageous from the viewpoint of degree of freedom in size. Further, from the viewpoint of the amount of information of the image data, when expressing the same image, YUV 4: 2: 2 can be expressed more faithfully and image degradation can be considered to be less than YUV 4: 1: 1.
[0032]
In consideration of the above, how to determine the resizing ratio and YUV format at the time of primary resizing in the present embodiment will be specifically described with reference to FIGS.
[0033]
The way of thinking is different depending on whether a low pass filter is applied or not.
[0034]
When the low pass filter is not applied. The flowchart is shown in FIG. First, the denominator of the primary resizing rate, the numerator, and the YUV format of the rewritten writing data are set as initial values (S1). The denominator and numerator of the primary resizing ratio are set to 8. With this value, the data after JPG decompression is expanded on the work memory without being resized. The YUV format of the write data is set to 4: 2: 2. Next, it is determined whether or not the data amount after JPG decompression and primary resizing fits in the work memory capacity secured in advance (S2). If yes, go to the left branch, if no, go to the right branch. When the process proceeds to the left branch at Yes, the resize target size as the image size after the secondary resizing is compared with the value obtained by multiplying the input image size by (B-2) / A (S3). If the resize target size is smaller, the value of the primary resize rate is set to B-2 (= 6) (S4). In this case, the primary resizing rate is set to 8/8 and the resizing is not performed, and the resizing to the target size is performed once. This is because the image size after resizing is generally better when the image is resized to the target size.
[0035]
However, if the result of reduction by primary resizing becomes smaller than the resize target size, the image data is discarded more than necessary, so the numerator of the primary resizing rate is left at the initial value ( S5). If NO has never been determined in S2, the YUV format remains the initial value regardless of whether the process proceeds to S4 or S5. In this example, it is 4: 2: 2.
[0036]
If the condition determination in S2 is No, the process proceeds to S6. Since the YUV format is 4: 2: 2 at the beginning, the process proceeds to S7, where the YUV format is set to 4: 1: 1. Thereafter, the condition determination of S2 is performed again. If the result of S2 is Yes at this stage, the process proceeds to S3 and the above operation is performed. If the answer is No, the process proceeds to S6. Since the YUV format is 4: 1: 1 this time, it is reset to 4: 2: 2 in S8, and 2 is subtracted from the initial value of the molecule in S9. The primary resizing ratio at this time is denominator = 8, numerator = 6, YUV format 4: 2: 2. The above operations are repeated to determine the primary resizing rate and the YUV format at the time of writing after the primary resizing.
[0037]
That is, the primary resizing rate and the YUV format after the primary resizing are as follows.
1. The YUV format is 4: 2: 2 and the primary resizing is the same size and the resized data fits in the work memory. If the input image is 6/8 times larger than the resizing target size, the primary resizing is performed. The ratio is 6/8 and the YUV format is 4: 2: 2.
2. The YUV format is 4: 2: 2 and the primary resizing is the same size and the resized data is stored in the work memory. If the input image is 6/8 times smaller than the resize target size, the primary resizing ratio is 8 / 8, YUV format 4: 2: 2.
3. If the YUV format is 4: 2: 2 and the primary resizing is the same size, and the data after resizing does not fit in the work memory, the YUV format is set to 4: 1: 1 to perform the primary resizing in the work memory. If the later data is stored and the input image is 6/8 times larger than the resize target size, the primary resize ratio is 6/8 and the YUV format is 4: 1: 1.
4). If the YUV format is 4: 2: 2 and the primary resizing is the same size, and the data after resizing does not fit in the work memory, the YUV format is set to 4: 1: 1 to perform the primary resizing in the work memory. When the subsequent data is stored and the input image is 6/8 times smaller than the resize target size, the primary resize ratio is 8/8 and the YUV format is 4: 1: 1.
5. If the data after the primary resizing does not fit in the work memory even if the primary resizing is 4: 1: 1 with the YUV format set to 4: 1, the work memory is set to the YUV format 4: 2: 2 and the molecule 6 If it seems that the data after the primary resizing fits within it,
The primary resizing ratio is 6/8 and the YUV format is 4: 2: 2.
[0038]
Note that only five cases are listed here because, as will be described later, a low-pass filter is applied when the primary resizing ratio is expected to be 4/8. This is because it is assumed that this flow does not become 4/8.
[0039]
Next, when applying a low-pass filter, the flowchart is shown in FIG.
In this case, it is assumed that the image data after development is obviously large, and the resizing rate in the primary resizing is smaller than 4/8 (that is, 1/2).
[0040]
Note that this flow may be automatically applied when a print size smaller than a predetermined print size is selected.
[0041]
First, in S11, the denominator of the primary resizing rate, the numerator, and the YUV format of the rewritten writing data are set as initial values. The denominator and numerator of the primary resizing ratio are set to 8. With this value, the data after JPG decompression is expanded on the work memory without being resized. The YUV format of the write data is set to 4: 2: 2. Next, in S12, it is determined whether the data amount after JPG decompression / primary resizing fits in the work memory capacity reserved in advance. If yes, go to the left branch (S13), if no, go to the right branch (S15). If the process proceeds to the left branch (S13) with Yes, it is determined whether there is sufficient work memory when the low-pass filter is applied. If the determination is Yes, the process proceeds to the left branch. In S14, the numerator of the primary resizing rate is set to 8 with the initial value, and at this time, the YUV format of the write data after the primary resizing rate and the resizing is determined with the initial value. It will be. Since the low-pass filter is less effective unless it is applied before resizing the image, the primary resizing rate is set to be as large as possible.
[0042]
If any of the condition determinations in S12 and S13 is No, the process proceeds to S15 and the YUV format is set to 4: 1: 1 (S16). After that, the condition judgment of S12 and S13 is performed again. When both the results of S12 and S13 are Yes, the process proceeds to S14, and the numerator of the primary resizing rate is set to 8 with the initial value. If either of the determination results in S12 and S13 is No, the process proceeds to S15 again, and the current YUV format is 4: 1: 1, so that the YUV format is reset to 4: 2: 2 in S17, and S18 Then subtract 2 from the initial value of the numerator. The primary resizing ratio at this time is denominator = 8, numerator = 6, YUV format 4: 2: 2. The above operations are repeated to determine the primary resizing rate and the YUV format at the time of writing after the primary resizing.
[0043]
That is, the primary resizing rate and the YUV format after the primary resizing are as follows.
1. If the YUV format is 4: 2: 2, the primary resizing is the same size, the resized data can be stored in the work memory, and there is enough work memory to execute the low-pass filter, the primary resizing ratio is 8/8. YUV format is 4: 2: 2.
2. If the YUV format is 4: 2: 2 and the primary resizing is the same size, the data after resizing will not fit in the work memory, or if there is not enough work memory to execute the low-pass filter, the YUV format will be 4 When 1: 1 is selected, the data after the primary resizing is stored in the work memory, and if there is sufficient work memory for the execution of the low-pass filter, the primary resizing ratio is 8/8, the YUV format is 4: 1: 1
3. If the YUV format is 4: 1: 1 and the primary resizing does not fit in the work memory even if the primary resizing is the same size, or if there is not enough work memory to execute the low-pass filter, the YUV format is set to 4. : 2: 2 If the numerator is 6 and the data after the primary resizing is stored in the work memory and there is enough work memory to execute the low-pass filter, the primary resizing ratio is 6/8, YUV format 4: 2 : 2
[0044]
Here, the primary resizing rate is up to 6/8. However, when it is desired to reduce the data amount as the primary resizing rate, a low pass filter having a larger data reducing rate is applied, for example, the amount of image data immediately after development. It is sufficient to prepare something that is about 1/4 of that.
Of course, it is possible to respond even if the processing is continued until the primary resizing rate becomes 4/8, 2/8.
[0045]
Although the print image data processing is performed in consideration of what has been described so far, a series of data processing flow of this embodiment is as shown in FIG.
[0046]
In this embodiment, a printer capable of printing only the card size and a printer capable of printing the card size, L size, and A6 size are supported, and the YUV format as an initial value is set according to the paper size. However, this initial value setting can be appropriately changed by performing the processes shown in FIGS.
[0047]
Hereinafter, the processing flow will be described. The set Print Mode is acquired (S21). As described with reference to FIG. 4, the print mode can be selected from borderless, bordered, and multi, but which print mode is designated is acquired. In S22, Printer Type is acquired. As described above, in this embodiment, the printer type that can print only the card size and the printer that can print the card, L size, and A6 size are supported, and the Printer Type is acquired. In S23, the printer type acquired in S22 is determined. If the printer can print only the card size, the Paper Type is fixed to the card (S24a). If the printer is capable of card, L size, and A6 size printing, the Paper Type is acquired (S24b). In S25, Paper Type is determined, and the card, L size, and A6 are allocated. In the case of the card size (S26a), the data format of YUV 4: 2: 2 is designated after the primary resizing and after the secondary resizing, and the address of the work memory to which data is written after the primary resizing and after the secondary resizing is designated. . For L size (S26b), specify the data format of YUV4: 2: 2 after primary resizing, YUV4: 1: 1 after secondary resizing, and write the data after primary resizing and after secondary resizing. Specify an address. For A6 size (S26c), YUV4: 2: 2 after primary resizing, YUV4: 1: 1 data format after secondary resizing, and address of work memory where data is written after primary resizing and after secondary resizing Is specified.
[0048]
Here, the image data format after the primary resizing and the secondary resizing is set for each printing paper, but this value varies depending on the usable work memory capacity.
[0049]
That is, in the subsequent S27, the primary resizing rate and the image format after the primary resizing are determined by the procedure described with reference to FIGS. In S28, JPG decompression and primary resizing are performed in the YUV format determined in S27, and the data is written to the work memory. In S29, the data written in the work memory after the primary resizing is read, the secondary resizing is executed, and the data is written in the work memory in the YUV format designated in S26a, b, and c.
[0050]
S30, whether the Print Mode is multi or not is determined. In S31, if it is multi, the secondary resize is further performed after the secondary resize. By performing the resizing process in a divided manner in this way, image quality deterioration can be suppressed somewhat. In S32, sharpness is applied to the image data resized to a desired size. In S33, first, yellow (Y) data is created from image data in the YUV data format. The subsequent processing is performed every time magenta (M) and cyan (C) are created. As a result, you will go through the same routine three times. In S34, Print Mode is determined for fine adjustment and position adjustment of print data. If there is no border, in S36c, the data for several pixels in the peripheral portion of the data after color conversion from the YUV data is discarded and copied to the print data storage area. When there is a border, the print data storage area is filled with white data (FFh) by the amount corresponding to the printing paper in S35b. In S36b, the data for several pixels in the peripheral portion of the data after color conversion from the YUV data is discarded in the print data storage area and copied to the center of gravity. In the case of multi, the print data storage area is filled with white data (FFh) by the amount corresponding to the print paper in S35a. In S36b, a few pixels of data in the peripheral portion of the data after color conversion from the YUV data are discarded in the print data storage area and the same number of images are arranged. In S37, the print data is transferred to the printer.
[0051]
The processing from S33 to S37 is repeated every time magenta (M) and cyan (C) are created.
[0052]
As described above, this print system can be realized.
[0053]
[Second Embodiment]
FIG. 12 shows a configuration diagram of the second embodiment of the present invention. In the second embodiment, an image photographed by a digital camera 1001 and an image stored in a memory medium after photographing and read again are processed into print data of a sublimation printer in the digital camera, and then incorporated in the digital camera. This is an example of color printing with a sublimation printer.
[0054]
The user can select a print mode, an image to be printed, the number of prints, and the like with the operation member 1002 of the digital camera shown in FIG. 12, and can confirm the contents on the liquid crystal screen 1003 of the digital camera.
[0055]
Since the image processing for creating print data is the same as that of the first embodiment and is omitted here, the digital camera and the printer are always integrated, and therefore a mode for automatically starting printing after photographing is provided. Since the print paper is built in beforehand, when this mode is set, the processes of S26a, b, and c in FIG. 11 are automatically selected according to the set paper size.
[0056]
Further, in an ordinary digital camera, the image size obtained by photographing can be selected and set.
[0057]
However, in the case of a mode in which print processing is automatically performed after shooting, the image size obtained by shooting is determined in advance depending on the paper to be used.
[0058]
That is, the user can control troublesome operations only by selecting a mode for automatically performing print processing after shooting, since camera control is performed in accordance with the built-in paper. In such a case, the print obtained can be made as high in image quality as possible according to the sheet by making maximum use of the internal memory.
[0059]
【The invention's effect】
As described above, according to the present invention, when configuring a print system in which a printer device and a photographing apparatus such as a digital camera or a digital video camera are directly connected, or those devices are integrated, The resizing ratio of image conversion method 1 (primary resizing), the image format after image conversion (YUV format), the size of the data area in which the data is expanded after the image size conversion, the image size converted by image conversion method 1 And final target image size, whether to apply a low-pass filter (LPF) before image size conversion, and whether there is enough work memory when executing the low-pass filter. It is possible to use the memory area as effectively as possible without running out of work memory. That. And it became possible to reduce deterioration of the obtained print image as much as possible.
[Brief description of the drawings]
FIG. 1 is a diagram for explaining a first embodiment;
FIG. 2 is a diagram for explaining the outline of the sublimation thermal transfer system.
FIG. 3 is a block diagram of a digital camera according to the present embodiment.
FIG. 4 is an explanatory diagram of a print pattern
FIG. 5 is a diagram for explaining the print data size depending on the print paper.
FIG. 6 is a diagram for explaining a print data image processing procedure;
FIG. 7 is a diagram for explaining how to use the work memory when creating print image data.
FIG. 8 is a diagram for explaining a difference in data amount between YUV422 and YUV411.
FIG. 9: Primary resizing ratio, determination flow of YUV format (without low-pass filter)
FIG. 10: Primary resizing ratio, determination flow of YUV format (with low-pass filter)
FIG. 11 is a diagram for explaining the processing flow of the embodiment;
FIG. 12 is a diagram for explaining a second embodiment.

Claims (11)

画像データの記録されている記憶媒体から、圧縮画像データを取り込む取り込み手段と、
前記取り込み手段により取り込まれた圧縮画像データを展開する展開手段と、
前記展開手段で展開された画像データを格納する内部メモリと、
前記内部メモリに格納される画像データを、印刷画像データに変換して出力する出力手段と、
前記展開手段により前記圧縮画像データを展開する前に、前記圧縮画像データを展開後の画像データの大きさと前記内部メモリの空き容量とに基づいて、輝度色差信号の形式を選択する選択手段を有することを特徴とする画像処理装置。
Capture means for capturing compressed image data from a storage medium in which image data is recorded;
Expansion means for expanding the compressed image data captured by the capture means;
An internal memory for storing image data expanded by the expansion means;
Output means for converting the image data stored in the internal memory into print image data and outputting it;
Before developing the compressed image data by the developing means, there is a selection means for selecting the format of the luminance color difference signal based on the size of the image data after the compressed image data is developed and the free space of the internal memory. An image processing apparatus.
前記展開手段は、更に、展開して前記内部メモリに格納される画像のサイズを前記出力装置へ出力する印刷画像データのサイズに合わせてリサイズするリサイズ手段を有し、前記選択手段は、前記内部メモリの空き容量に応じて、前記輝度色差信号の形式と前記リサイズ手段でのリサイズ率とを制御することを特徴とする請求項1に記載の画像処理装置。  The expansion unit further includes a resizing unit that resizes the image stored in the internal memory according to the size of print image data to be output to the output device, and the selection unit includes the internal unit. The image processing apparatus according to claim 1, wherein a format of the luminance color difference signal and a resizing ratio in the resizing unit are controlled according to a free space of a memory. 更に、前記展開手段により展開された画像データに対してローパスフィルタ処理を適応するフィルタリング手段を有し、
前記選択手段は、前記ローパスフィルタ処理の為の作業領域が前記内部メモリに確保されるか否かを判別し、確保できない場合には、前記展開手段により前記輝度色差信号の形式と前記リサイズ手段でのリサイズ率とを制御することを特徴とする請求項1または2に記載の画像処理装置。
Furthermore, it has filtering means for applying low-pass filter processing to the image data developed by the developing means,
The selection means determines whether or not a work area for the low-pass filter processing is secured in the internal memory. If the work area cannot be secured, the expansion means uses the format of the luminance color difference signal and the resizing means. The image processing apparatus according to claim 1, wherein the resizing rate is controlled.
前記ローパスフィルタ処理の要否は、前記圧縮画像データを前記ローパスフィルタを適用せずに展開した場合のデータ量と、前記出力手段により出力する印刷画像データのデータ量との関係に基づいて決定されることを特徴とする請求項3に記載の画像処理装置。  The necessity of the low-pass filter processing is determined based on the relationship between the amount of data when the compressed image data is expanded without applying the low-pass filter and the amount of print image data output by the output means. The image processing apparatus according to claim 3. 前記選択手段は、前記ローパスフィルタ処理が適応される場合は、前記リサイズ手段によるリサイズ率が等倍となるように制御することを特徴とする請求項3または4に記載の画像処理装置。  5. The image processing apparatus according to claim 3, wherein, when the low-pass filter process is applied, the selection unit performs control so that a resizing rate by the resizing unit becomes equal to the same size. 前記画像処理装置は、画像表示手段と撮像手段とを有するデジタルカメラであり、前記画像表示手段により表示される画像に対して出力指示を行う指示手段とを有することを特徴とする請求項1ないし5のいずれか1項に記載の画像処理装置。  2. The image processing apparatus according to claim 1, wherein the image processing apparatus is a digital camera having an image display means and an imaging means, and has an instruction means for giving an output instruction to an image displayed by the image display means. The image processing apparatus according to claim 5. 前記選択手段は、輝度信号と色差信号とのデータ量の割合が異なる複数の輝度色差信号の形式から輝度色差信号の形式を選択することを特徴とする請求項1ないし6のいずれか1項に記載の画像処理装置。  The said selection means selects the format of a brightness | luminance color difference signal from the format of the some brightness | luminance color difference signal from which the ratio of the data amount of a brightness | luminance signal and a color difference signal differs, The any one of Claim 1 thru | or 6 characterized by the above-mentioned. The image processing apparatus described. 画像データの記録されている記憶媒体から、圧縮画像データを取り込む取り込み工程と、
前記取り込み工程で取り込まれた圧縮画像データを展開する展開工程と、
前記展開工程で展開された画像データを格納する内部メモリと、
前記内部メモリに格納される画像データを、印刷画像データに変換して出力する出力工程と、
前記展開工程において前記圧縮画像データを展開する前に、前記圧縮画像データを展開後の画像データの大きさと、前記内部メモリの空き容量とに基づいて、輝度色差信号の形式を選択する選択工程を有することを特徴とする画像処理方法。
A capturing step of capturing compressed image data from a storage medium on which image data is recorded;
A decompression step of decompressing the compressed image data captured in the capture step;
An internal memory for storing the image data expanded in the expansion step;
An output step of converting the image data stored in the internal memory into print image data and outputting the print image data;
Before expanding the compressed image data in the expanding step, a selection step of selecting the format of the luminance color difference signal based on the size of the image data after expanding the compressed image data and the free space of the internal memory An image processing method comprising:
前記展開工程は、更に、前記出力装置へ出力する印刷画像データのサイズに合わせてリサイズするリサイズ工程を有し、前記内部メモリの空き容量に応じて、前記輝度色差信号の形式と前記リサイズ工程でのリサイズ率とを制御することを特徴とする請求項8に記載の画像処理方法。  The expanding step further includes a resizing step for resizing in accordance with the size of print image data to be output to the output device, and according to the free space of the internal memory, the luminance color difference signal format and the resizing step The image processing method according to claim 8, wherein a resizing rate of the image is controlled. 更に、前記展開手段により展開された画像データに対してローパスフィルタ処理を適応するフィルタリング工程を有し、
前記選択工程では、前記ローパスフィルタ処理の為の作業領域が前記内部メモリに確保されるか否かを判別して、確保できない場合に、前記展開工程での前記輝度色差信号の形式と前記リサイズ工程でのリサイズ率とを制御することを特徴とする請求項8に記載の画像処理方法。
And a filtering step for applying low-pass filter processing to the image data developed by the developing means.
In the selection step, it is determined whether or not a work area for the low-pass filter process is secured in the internal memory. If the work area cannot be secured, the format of the luminance color difference signal and the resizing step in the development step are determined. The image processing method according to claim 8, wherein the resizing rate is controlled.
請求項8乃至10いずれか1項に記載の画像処理方法を実行させるためのプログラムを記録したコンピュータ読み取り可能な記録媒体。  11. A computer-readable recording medium on which a program for executing the image processing method according to claim 8 is recorded.
JP2002268490A 2002-09-13 2002-09-13 Image processing apparatus, image processing method, and recording medium Expired - Fee Related JP4125080B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2002268490A JP4125080B2 (en) 2002-09-13 2002-09-13 Image processing apparatus, image processing method, and recording medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2002268490A JP4125080B2 (en) 2002-09-13 2002-09-13 Image processing apparatus, image processing method, and recording medium

Publications (2)

Publication Number Publication Date
JP2004112068A JP2004112068A (en) 2004-04-08
JP4125080B2 true JP4125080B2 (en) 2008-07-23

Family

ID=32266690

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2002268490A Expired - Fee Related JP4125080B2 (en) 2002-09-13 2002-09-13 Image processing apparatus, image processing method, and recording medium

Country Status (1)

Country Link
JP (1) JP4125080B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050062755A1 (en) * 2003-09-18 2005-03-24 Phil Van Dyke YUV display buffer
JP5120366B2 (en) * 2009-11-30 2013-01-16 ブラザー工業株式会社 Image processing apparatus and image processing program

Also Published As

Publication number Publication date
JP2004112068A (en) 2004-04-08

Similar Documents

Publication Publication Date Title
JP4678188B2 (en) Image processing device
JP3832089B2 (en) Digital camera and printing system
JP4323748B2 (en) Digital camera and control method thereof, image processing apparatus, image processing method, and image processing system
US6650366B2 (en) Digital photography system using direct input to output pixel mapping and resizing
JP3731718B2 (en) Digital photo processing equipment
JP2003244584A (en) Image processing equipment, printing system, image data form selecting method, program and recording medium
JP4125080B2 (en) Image processing apparatus, image processing method, and recording medium
JP2003046763A (en) Image processor and image processing method
US20030161608A1 (en) Image reproducing apparatus and image reproducing method
JP2003061034A (en) Image data processing method and printing system
JP2000270294A (en) Digital camera and method for processing image data
JP4085786B2 (en) Digital camera, printing system, and computer-readable recording medium
JP4243956B2 (en) Image printing system, image processing apparatus and method, recording medium, and program
JP3786270B2 (en) Digital camera
JP4415359B2 (en) Image processing apparatus and printer
JP4266497B2 (en) Image forming apparatus
JP2003136800A (en) Cartridge, printer, print system, imaging apparatus, print control method, storage medium, and program
JP2004253909A (en) Image processing method
JP2006060612A (en) Image input device, image formation system, image forming method, and computer program
JP2003244583A (en) Printing system, imaging equipment, printer equipment, image processing equipment and image processing method
JP3456169B2 (en) Digital camera
JP2002314907A (en) Print system, printer and electronic storage medium used for print system
JP3427837B2 (en) Digital camera
JP3427838B2 (en) Digital camera
JP2008028839A (en) Printing system, printing device, image processing method, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20050905

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20070628

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20070731

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20071001

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

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

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

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20120516

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20120516

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20130516

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20140516

Year of fee payment: 6

LAPS Cancellation because of no payment of annual fees