JPH0830797A - Antialiasing method - Google Patents

Antialiasing method

Info

Publication number
JPH0830797A
JPH0830797A JP16647994A JP16647994A JPH0830797A JP H0830797 A JPH0830797 A JP H0830797A JP 16647994 A JP16647994 A JP 16647994A JP 16647994 A JP16647994 A JP 16647994A JP H0830797 A JPH0830797 A JP H0830797A
Authority
JP
Japan
Prior art keywords
pixel
model
intersection
ray
interest
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.)
Pending
Application number
JP16647994A
Other languages
Japanese (ja)
Inventor
Naoki Chiba
直樹 千葉
Fumio Yasutomi
文夫 安富
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.)
Sanyo Electric Co Ltd
Original Assignee
Sanyo Electric 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 Sanyo Electric Co Ltd filed Critical Sanyo Electric Co Ltd
Priority to JP16647994A priority Critical patent/JPH0830797A/en
Publication of JPH0830797A publication Critical patent/JPH0830797A/en
Pending legal-status Critical Current

Links

Landscapes

  • Image Generation (AREA)

Abstract

PURPOSE:To prevent the stoppage of the plotting of the line part of a grid stripe due to an aliasing by providing a step deciding whether light beam steps over the line part of a grid stripe model or not on the assumption that light beam is shifted from one intersected point to the other intersected point. CONSTITUTION:Based on the intersected point Qn-1 of light beam passing an arbitrary first picture element from a viewpoint location and a grid stripe model and the intersected point Qn of light beam passing a second picture element adjacent to the first picture element from the viewpoint location and the grid stripe model, whether light beam steps over the line part of the grid stripe model or not is decided on the assumption that light beam is shifted from one intersected point Qn-1 and the other intersected point Qn. When it is decided that light beam steps over the part, the information on the distance between the both intersected points Qn-1 and Qn on the grid stripe model is calculated and the information on the average of the density value between the both intersected points Qn-1 and Qn on the grid stripe model is calculated. Based on the information on the distance between the both intersected points Qn-1 and Qn and the information on the average of the density value between the both intersected points Qn-1 and Qn, the luminance value of the second picture element is calculated.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】この発明は、格子縞モデルの曲面
形状モデルに対する反射映像を、投影面の各画素の輝度
を光線追跡法で決定することにより生成する際に用いら
れるアンチエイリアシング方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an anti-aliasing method used when a reflection image for a curved surface shape model of a lattice fringe model is generated by determining the brightness of each pixel on the projection surface by a ray tracing method.

【0002】[0002]

【従来の技術】自動車用フロントガラス等の3次元自由
曲面物体の反射映像を調べるために、、3次元自由曲面
物体に対する格子縞の反射映像をシミュレーションで生
成することが考えられる。
2. Description of the Related Art In order to examine a reflection image of a three-dimensional free-form surface object such as an automobile windshield, it is conceivable to generate a reflection image of lattice stripes for the three-dimensional free-form surface object by simulation.

【0003】3次元自由曲面物体に対する格子縞の反射
映像をシミュレーションで生成する手法としては、光線
追跡法を用いることが考えられる。つまり、視点位置か
ら格子縞までの光線を追跡し、格子縞と光線との交点位
置が格子縞の白か黒かによって投影面における輝度を決
定する。
A ray tracing method may be used as a method of generating a lattice fringe reflection image for a three-dimensional free-form surface object by simulation. That is, the ray from the viewpoint position to the lattice fringe is traced, and the brightness on the projection plane is determined depending on whether the intersection point of the lattice fringe and the ray is white or black.

【0004】[0004]

【発明が解決しようとする課題】3次元自由曲面物体に
対する格子縞の反射映像を光線追跡法を用いて生成する
場合には、標本化不足によりエイリアシングが生じる可
能性がある。つまり、格子縞の線部分が描画されなくな
る可能性がある。
When a lattice fringe reflection image for a three-dimensional free-form surface object is generated using the ray tracing method, aliasing may occur due to insufficient sampling. That is, the line portion of the checkered pattern may not be drawn.

【0005】この発明は、エイリアシングにより格子縞
の線部分が描画されなくなるといったことを防止できる
アンチエイリアシング方法を提供することを目的とす
る。
It is an object of the present invention to provide an anti-aliasing method which can prevent the line portion of the lattice fringes from being drawn due to aliasing.

【0006】[0006]

【課題を解決するための手段】この発明によるアンチエ
イリアシング方法は、格子縞モデルの曲面形状モデルに
対する反射映像を、投影面の各画素の輝度を光線追跡法
で決定することにより生成する際に用いられるアンチエ
イリアシング方法であって、視点位置から任意の第1画
素を通る光線と格子縞モデルとの交点と、視点位置から
上記第1画素の隣にある第2画素を通る光線と格子縞モ
デルとの交点とに基づいて、一方の交点から他方の交点
に光線が移行したと仮定した場合に、格子縞モデルの線
部分を光線が跨いだか否かを判定するステップ、格子縞
モデルの線部分を光線が跨いだと判定したときには、格
子縞モデル上の両交点間の距離に関する情報を算出する
とともに格子縞モデル上の両交点間の濃度値の平均に関
する情報を算出するステップ、および上記両交点間の距
離に関する情報と、両交点間の濃度値の平均に関する情
報とに基づいて、上記第2画素の輝度値を算出するステ
ップを備えていることを特徴とする。
The anti-aliasing method according to the present invention is used when a reflection image for a curved surface shape model of a lattice fringe model is generated by determining the brightness of each pixel on the projection surface by the ray tracing method. An anti-aliasing method, wherein an intersection of a ray passing through an arbitrary first pixel from the viewpoint position and a lattice fringe model, and an intersection of a ray passing through a second pixel adjacent to the first pixel from the viewpoint position and the lattice fringe model Based on the above, if it is assumed that the ray has moved from one intersection to the other, the step of determining whether the ray has straddled the line portion of the checkered model, and the ray has straddled the line portion of the checkered model. When the judgment is made, the information on the distance between the intersections on the checkerboard model is calculated and the information on the average of the density values between the intersections on the checkerboard model is calculated. Steps and information about the distance between the both intersections, on the basis of the information about the average of the density values between the two intersection points, characterized in that it comprises the step of calculating the luminance value of the second pixel.

【0007】[0007]

【作用】視点位置から任意の第1画素を通る光線と格子
縞モデルとの交点と、視点位置から上記第1画素の隣に
ある第2画素を通る光線と格子縞モデルとの交点とに基
づいて、一方の交点から他方の交点に光線が移行したと
仮定した場合に、格子縞モデルの線部分を光線が跨いだ
か否かが判定される。
Based on the intersection of the ray passing through the arbitrary first pixel from the viewpoint position and the lattice fringe model, and the intersection of the ray passing through the second pixel next to the first pixel from the viewpoint position and the lattice fringe model, If it is assumed that the ray has moved from one intersection to the other, it is determined whether or not the ray crosses the line portion of the checkered model.

【0008】格子縞モデルの線部分を光線が跨いだと判
定したときには、格子縞モデル上の両交点間の距離に関
する情報が算出されるとともに格子縞モデル上の両交点
間の濃度値の平均に関する情報が算出される。
When it is determined that the light ray straddles the line portion of the checkered model, the information on the distance between the two intersections on the checkered model is calculated and the information on the average of the density values between the two points on the checkered model is calculated. To be done.

【0009】そして、上記両交点間の距離に関する情報
と、両交点間の濃度値の平均に関する情報とに基づい
て、上記第2画素の輝度値が算出される。
Then, the brightness value of the second pixel is calculated based on the information on the distance between the two intersections and the information on the average of the density values between the two intersections.

【0010】[0010]

【実施例】図1は、格子縞モデルの曲面形状モデルに対
する反射映像をシミュレーションで作成する際の反射映
像の光学系モデルを示している。
FIG. 1 shows an optical system model of a reflected image when a reflected image for a curved surface shape model of a lattice fringe model is created by simulation.

【0011】この光学系モデルにおいては、手前から視
点1、反射映像を作成するための投影面2、自動車用ガ
ラス等の3次元自由曲面ガラス3および白黒の格子縞ス
クリーン4が配置されている。
In this optical system model, a viewpoint 1, a projection plane 2 for creating a reflected image, a three-dimensional free-form curved glass 3 such as a glass for automobiles, and a black and white lattice striped screen 4 are arranged from the near side.

【0012】投影面2は、画素単位で複数領域に分割さ
れている。3次元自由曲面ガラス3は、この例では、Y
−Z面に沿う断面が曲線となるかまぼこ状である。格子
縞スクリーン4は、図2に示すように複数本の縦横の黒
線部分と、黒線部分に囲まれた複数の白矩形部分とから
構成されている。黒線部分の幅はHbであり、白矩形部
分の高さはHwである。
The projection plane 2 is divided into a plurality of areas on a pixel-by-pixel basis. In this example, the three-dimensional free-form glass 3 is Y
The cross section along the -Z plane has a curved semi-cylindrical shape. As shown in FIG. 2, the checkered screen 4 is composed of a plurality of vertical and horizontal black line portions and a plurality of white rectangular portions surrounded by the black line portions. The width of the black line portion is Hb, and the height of the white rectangular portion is Hw.

【0013】投影面2の各画素の輝度値は、原則的に
は、光線追跡法によって決定される。つまり、視点位置
から各画素を通ってスクリーン面に至る光線が追跡さ
れ、その光線とスクリーン面との交点位置が格子縞の白
部分であるか黒部分であるかによって当該画素の輝度値
が決定される。
The brightness value of each pixel on the projection plane 2 is basically determined by the ray tracing method. That is, a ray from the viewpoint position through each pixel to the screen surface is traced, and the brightness value of the pixel is determined depending on whether the intersection position of the ray and the screen surface is the white part or the black part of the checkered pattern. It

【0014】投影面2の各画素の輝度値を光線追跡法の
みによって決定する場合には、標本化不足により、エイ
リアシングが発生し、格子縞の黒部分が描画されなくな
る可能性がある。特に、3次元自由曲面ガラス3が図1
に示す形状および配置である場合には、格子縞の縦横の
黒線部分のうち、横方向の黒線部分が描画されなくなる
可能性がある。
When the brightness value of each pixel on the projection plane 2 is determined only by the ray tracing method, aliasing may occur due to insufficient sampling, and the black portion of the grid pattern may not be drawn. In particular, the three-dimensional free-form glass 3 is shown in FIG.
In the case of the shape and arrangement shown in (1), of the vertical and horizontal black line portions of the checkered pattern, the horizontal black line portion may not be drawn.

【0015】このようなエイリアシングは、投影面2内
の上下に隣合う画素のうち、一方の画素に対して追跡さ
れた光線とスクリーン面4との交点位置Qn-1 と、他方
の画素に対して追跡された光線とスクリーン面4との交
点位置Qn とが、図2に示すような関係になる場合に生
じる。
Such aliasing is performed in the position Q n-1 of the intersection of the ray traced for one pixel and the screen surface 4 among the vertically adjacent pixels in the projection plane 2 and the other pixel. This occurs when the traced position of the ray and the intersection position Q n of the screen surface 4 have the relationship shown in FIG.

【0016】つまり、投影面2内の上下に隣合う画素の
うち、一方の画素に対する交点位置Qn-1 から他方の画
素に対する交点位置Qn に光線が移行したと仮定した場
合に、格子縞の黒線部分を光線が跨ぐようなときに、エ
イリアシングが発生する。このような場合には、両交点
n-1 、Qn の間にある横方向の黒線部分は、描画され
なくなる。
That is, among the vertically adjacent pixels in the projection plane 2, assuming that the light ray has moved from the intersection point position Q n-1 for one pixel to the intersection point position Q n for the other pixel, the lattice stripes Aliasing occurs when a light ray crosses a black line portion. In such a case, the horizontal black line portion between the intersections Q n-1 and Q n is not drawn.

【0017】そこで、この実施例では、以下のようにし
て、横方向の黒線部分が描画されなくなるのを防止して
いる。この実施例では、投影面2内の各画素の輝度値
は、投影面2内の画素を各列ごとに上から下の方向に走
査することによって順次決定される。したがって、上記
のようなエイリアシングが発生する場合とは、前回の注
目画素に対する交点位置Qn-1 から今回の注目画素に対
する交点位置Qn に光線が移行したと仮定した場合に、
格子縞モデルの水平方向の黒部分を光線が跨いだ場合と
なる。
Therefore, in this embodiment, the black line portion in the horizontal direction is prevented from being undrawn in the following manner. In this embodiment, the brightness value of each pixel in the projection plane 2 is sequentially determined by scanning the pixels in the projection plane 2 for each column from the top to the bottom. Therefore, in the case where aliasing as described above is generated, if it is assumed that light is shifted to the intersection Q n for the current pixel of interest from the intersection Q n-1 for the previous pixel of interest,
This is the case when the light beam straddles the black portion in the horizontal direction of the plaid model.

【0018】このような場合には、次式1に基づいて、
今回の注目画素の輝度値Pn が決定される。
In such a case, based on the following equation 1,
The luminance value P n of the pixel of interest this time is determined.

【0019】[0019]

【数1】Pn =PA/L## EQU1 ## P n = PA / L

【0020】ただし、PAは、交点位置Qn-1 と交点位
置Qn との間の濃度和である。また、Lは、交点位置Q
n-1 と交点位置Qn との間の距離である。したがって、
注目画素の輝度値Pn は、前回の注目画素に対する交点
位置Qn-1 と前回の注目画素に対する交点位置Qn との
間のスクリーン面4上の濃度平均値となる。この結果、
今回の注目画素に対する輝度値が白部分に対する輝度値
より濃くなるため、両交点間Qn-1 、Qn にある横方向
の黒線部分が描画されることになる。
However, PA is the sum of densities between the intersection point position Q n-1 and the intersection point position Q n . L is the intersection point Q
the distance between the n-1 and the point of intersection Q n. Therefore,
The luminance value P n of the target pixel is the average value of the densities on the screen surface 4 between the intersection point position Q n-1 for the previous target pixel and the intersection point position Q n for the previous target pixel. As a result,
Since the luminance value for the pixel of interest this time becomes darker than the luminance value for the white portion, the horizontal black line portion between the intersections Q n−1 and Q n is drawn.

【0021】交点位置Qn-1 と交点位置Qn との間の距
離Lは、交点位置Qn-1 のY座標値をyn-1 、交点位置
n のY座標値をyn とすると、次式2により概略的に
求められる。
As for the distance L between the intersection point position Q n-1 and the intersection point position Q n , the Y coordinate value of the intersection point position Q n-1 is y n-1 , and the Y coordinate value of the intersection point position Q n is y n . Then, it is roughly obtained by the following equation 2.

【0022】[0022]

【数2】L=yn-1 −yn ## EQU2 ## L = y n-1 -y n

【0023】また、交点位置Qn-1 と交点位置Qn との
間の濃度和PAは、次の数式3で表されるように、交点
位置Qn-1 と交点位置Qn との間にある黒部分の濃度和
Pと、交点位置Qn-1 と交点位置Qn との間にある白部
分の濃度和Pwとの和として求められる。
Further, the density sum PA between the intersection point position Q n-1 and the intersection point position Q n is expressed by the following equation 3 between the intersection point position Q n-1 and the intersection point position Q n. It is calculated as the sum of the density sum P of the black portion in the area and the density sum Pw of the white portion between the intersection position Q n-1 and the intersection position Q n .

【0024】[0024]

【数3】PA=Pb+Pw[Formula 3] PA = Pb + Pw

【0025】黒部分の濃度和Pbは、次のようにして求
められる。格子縞の各列ごとに、白矩形部分に上から下
の順に通しの識別番号M(=1、2、3…)が予めつけ
られている。前回の注目画素に対する交点Qn-1 が存在
する白矩形部分の識別番号をMn-1 とし、今回の注目画
素に対する交点Qn が存在する白矩形部分の識別番号を
n とすると、交点位置Qn-1 から交点位置Qn まで
に、光線が跨ぐ黒線部分の数Nbは、次の数式4で表さ
れる。
The density sum Pb of the black portion is obtained as follows. A serial identification number M (= 1, 2, 3, ...) Is preliminarily assigned to the white rectangular portion in order from top to bottom for each row of the checkered pattern. Assuming that the identification number of the white rectangular portion where the intersection Q n-1 with respect to the previous pixel of interest exists is M n-1 and the identification number of the white rectangular portion where the intersection Q n with respect to the current pixel of interest is M n , the intersection point From the position Q n-1 to the intersection position Q n , the number Nb of black line portions that the light ray straddles is represented by the following mathematical formula 4.

【0026】[0026]

【数4】Nb=Mn −Mn-1 ## EQU00004 ## Nb = Mn - Mn-1

【0027】黒線部分の幅をHb、黒線部分に対する画
像強度をIbとすると、黒部分による濃度和Pbは、次
の数式5で表される。
Assuming that the width of the black line portion is Hb and the image intensity for the black line portion is Ib, the density sum Pb due to the black portion is expressed by the following equation 5.

【0028】[0028]

【数5】Pb=Nb×Hb×Ib(5) Pb = Nb × Hb × Ib

【0029】交点位置Qn-1 と交点位置Qn との間にあ
る白部分の濃度和PWは、次のようにして求められる。
濃度和Pwは、交点位置Qn-1 から交点位置Qn までに
含まれる白矩形部分による濃度和Pw1と、交点位置Q
n-1 から下側にある最も近い黒線部分までの白部分によ
る濃度和Pw2と、交点位置Qn から上側にある最も近
い黒線部分までの白部分による濃度和Pw3との総和で
ある。
The density sum PW of the white portion between the intersection point position Q n-1 and the intersection point position Q n is obtained as follows.
The density sum Pw is the density sum Pw1 by the white rectangular portion included from the intersection position Q n-1 to the intersection position Q n , and the intersection position Q.
the concentration sum Pw2 by the white portion of the n-1 to the nearest black line portion at the bottom, is the sum of the concentration sum Pw3 using the white portion of the intersection Q n to the nearest black line portion of the upper side.

【0030】交点位置Qn-1 と交点位置Qn との間にあ
る白矩形部分の濃度和Pwは、次のようにして求められ
る。
The density sum Pw of the white rectangular portion between the intersection point position Q n-1 and the intersection point position Q n is obtained as follows.

【0031】前回と今回との間で、光線が白四辺形を跨
いだ数Nwは、次の数式6で表される。
The number Nw of light rays straddling the white quadrangle between the previous time and this time is expressed by the following mathematical expression 6.

【0032】[0032]

【数6】Nw=Nb−1(6) Nw = Nb-1

【0033】白矩形部分の高さをHw、白矩形部分に対
する画像強度をIwとすると、交点位置Qn-1 から交点
位置Qn までに含まれる白矩形部分による濃度和Pw1
は、次の数式7で表される。
The white rectangular portion height Hw, the image intensity for the white rectangular portion and Iw, density sum by white-block portion contained in the intersection Q n-1 to the intersection point position Q n Pw1
Is expressed by the following Equation 7.

【0034】[0034]

【数7】Pw1=Nw×Hw×Iw[Equation 7] Pw1 = Nw × Hw × Iw

【0035】また、交点位置Qn-1 から下側の黒線部分
までの白部分による濃度和Pw2は、交点位置Qn-1
Y座標値をyn-1 、Mod(a/b)をa/bの余りと
定義すると、次の数式8で表される。
In addition, the density sum Pw2 by the white part from the intersection point position Q n-1 to the lower black line portion is the Y coordinate value of the intersection point position Q n-1 , y n-1 , Mod (a / b) When is defined as the remainder of a / b, it is expressed by the following formula 8.

【0036】[0036]

【数8】Pw2={Hw−Mod(yn-1 /(Hw+H
b)}×Ib
## EQU8 ## Pw2 = {Hw-Mod (y n-1 / (Hw + H
b)} × Ib

【0037】上記数式8の右辺の{Hw−Mod(y
n-1 /(Hw+Hb)}は、図2のL1に相当する。
[Hw-Mod (y
n-1 / (Hw + Hb)} corresponds to L1 in FIG.

【0038】また、交点位置Qn から上側の黒交点位置
n-1 から下側の黒線分までの白部分による濃度和Pw
3は、交点位置Qn のY座標値をyn 、Mod(a/
b)をa/bの余りと定義すると、次の数式9で表され
る。
Also, the density sum Pw of the white portion from the intersection point position Q n to the upper black intersection point position Q n-1 to the lower black line segment
3 is the Y coordinate value of the intersection point position Q n , y n , Mod (a /
If b) is defined as the remainder of a / b, it is expressed by the following Equation 9.

【0039】[0039]

【数9】 Pw3={Mod(yn /(Hw+Hb)}×Ib## EQU9 ## Pw3 = {Mod (y n / (Hw + Hb)} × Ib

【0040】上記数式9の右辺の{Mod(yn /(H
w+Hb)}は、図2のL2に相当する。
[Mod (y n / (H
w + Hb)} corresponds to L2 in FIG.

【0041】図3は、輝度値決定処理の全体的な手順を
示している。
FIG. 3 shows the overall procedure of the brightness value determination process.

【0042】上述したように、投影面2内の各画素の輝
度は、投影面2内の画素群の各列ごとに上から下方に走
査することによって決定される。図4は、1列分の画素
に対する輝度値決定処理を示している。
As described above, the brightness of each pixel on the projection surface 2 is determined by scanning from the top to the bottom for each column of the pixel group on the projection surface 2. FIG. 4 shows a brightness value determination process for pixels in one column.

【0043】まず、走査しようとする列の最上段の画素
を注目画素とする(ステップ1)。そして、視点から注
目画素を通る光線と、格子縞のスクリーン面との交点位
置の座標が求められる(ステップ2)。
First, the uppermost pixel in the column to be scanned is set as the pixel of interest (step 1). Then, the coordinates of the position of the intersection of the ray passing through the pixel of interest from the viewpoint and the screen surface of the grid pattern are obtained (step 2).

【0044】次に、前回の注目画素に対する交点位置か
ら今回の注目画素に対する交点位置まで光線を移動させ
たと仮定した場合に、黒線部分を跨いだか否かが判定さ
れる(ステップ3)。
Next, if it is assumed that the light beam is moved from the intersection point position for the previous pixel of interest to the intersection point position for the current pixel of interest, it is determined whether or not the line crosses the black line portion (step 3).

【0045】注目画素が最上段の画素である場合には、
前回の注目画素が存在しないので、ステップ4に移り、
光線追跡法によって今回の注目画素の輝度が決定され
る。つまり、ステップ2で求められた今回の注目画素に
対する交点位置が白矩形部分内か黒線部分内かによって
今回の注目画素の輝度が決定される。
If the pixel of interest is the uppermost pixel,
Since the last pixel of interest does not exist, move to step 4,
The ray tracing method determines the luminance of the pixel of interest this time. That is, the brightness of the current pixel of interest is determined depending on whether the intersection point position of the current pixel of interest obtained in step 2 is within the white rectangular portion or the black line portion.

【0046】この後、ステップ6に移り、今回の注目画
素が最下段の画素か否かが判別される。今回の注目画素
が最下段の画素でなければ、今回の注目画素より1つ下
側の画素が注目画素とされた後(ステップ7)、ステッ
プ2に戻る。そして、視点から注目画素を通る光線と、
格子縞のスクリーン面との交点位置の座標が求められ
る。
After this, the routine proceeds to step 6, where it is judged if the pixel of interest this time is the pixel at the bottom. If the pixel of interest this time is not the lowermost pixel, the pixel one lower than the pixel of interest this time is regarded as the pixel of interest (step 7), and then the process returns to step 2. And a ray passing through the pixel of interest from the viewpoint,
The coordinates of the position of the intersection of the checkered pattern with the screen surface are obtained.

【0047】次に、前回の注目画素に対する交点位置か
ら今回の注目画素に対する交点位置まで光線を移動させ
たと仮定した場合に、黒線部分を跨いだか否かが判定さ
れる(ステップ3)。
Next, if it is assumed that the light beam is moved from the intersection point position for the previous pixel of interest to the intersection point position for the current pixel of interest, it is determined whether or not the light beam crosses the black line portion (step 3).

【0048】黒線部分を跨いでいないと判定されたとき
には、上述したように、光線追跡法によって今回の注目
画素の輝度が決定される(ステップ4)。この後、今回
の注目画素が最下段の画素か否かが判別される(ステッ
プ6)。今回の注目画素が最下段の画素でなければ、今
回の注目画素より1つ下側の画素が注目画素とされた後
(ステップ7)、ステップ2に戻る。
When it is determined that the pixel does not cross the black line portion, the brightness of the pixel of interest this time is determined by the ray tracing method as described above (step 4). After this, it is judged whether or not the pixel of interest this time is the lowermost pixel (step 6). If the pixel of interest this time is not the lowermost pixel, the pixel one lower than the pixel of interest this time is regarded as the pixel of interest (step 7), and then the process returns to step 2.

【0049】ステップ3において、黒線部分を跨いだと
判定されたときには、前回の注目画素に対する交点位置
と今回の注目画素に対する交点位置との間の濃度平均値
が上記数式1〜9に基づいて算出される(ステップ
5)。そして、その算出結果が、今回の注目画素の輝度
値として決定される。
When it is determined in step 3 that the black line portion is crossed, the density average value between the intersection point position with respect to the previous pixel of interest and the intersection point position with respect to the current pixel of interest is calculated based on the above equations 1 to 9. It is calculated (step 5). Then, the calculation result is determined as the luminance value of the pixel of interest this time.

【0050】この後、ステップ6に移り、今回の注目画
素が最下段の画素か否かが判別される。今回の注目画素
が最下段の画素でなければ、今回の注目画素より1つ下
側の画素が注目画素とされた後(ステップ7)、ステッ
プ2に戻る。
After this, the routine proceeds to step 6, where it is judged whether or not the pixel of interest this time is the lowermost pixel. If the pixel of interest this time is not the lowermost pixel, the pixel one lower than the pixel of interest this time is regarded as the pixel of interest (step 7), and then the process returns to step 2.

【0051】以上のような処理が、順次繰り返され、最
下段の画素についての処理が終了すると、ステップ6で
YESとなり、1列分の輝度値決定処理は終了する。
The above-described processing is sequentially repeated, and when the processing for the lowermost pixel is completed, YES is determined in step 6, and the brightness value determination processing for one column is completed.

【0052】上記実施例によれば、格子縞の横方向の黒
線部分が描画されなくなるといったことが防止され、よ
り写実的な画像が得られる。
According to the above-described embodiment, it is possible to prevent the black line portion in the horizontal direction of the checkered pattern from becoming undrawn, and a more realistic image can be obtained.

【0053】上記実施例では、格子縞の横方向の黒線部
分がエイリアシングによって描画されなくなるのを防止
するために、投影面の画素群を垂直方向に走査している
が、格子縞の縦方向の黒線部分がエイリアシングによっ
て描画されなくなるのを防止したい場合には、投影面の
画素群を水平方向に走査すればよい。
In the above embodiment, the pixel groups on the projection surface are scanned in the vertical direction in order to prevent the black line portions in the horizontal direction of the lattice stripes from being drawn by aliasing, but the black lines in the vertical direction of the lattice stripes are scanned. When it is desired to prevent the line portion from being drawn due to aliasing, the pixel group on the projection surface may be scanned in the horizontal direction.

【0054】また、格子縞の横方向の黒線部分と格子縞
の縦方向の黒線部分との両方が、エイリアシングによっ
て描画されなくなるのを防止したい場合には、次のよう
にすればよい。投影面の画素群を水平方向および垂直方
向のうち、一方の方向に走査して、上記実施例と同様な
方法で、各画素の輝度値を決定する。この後、さらに、
他方の方向に走査して、エイリアシングが発生する箇所
についてのみ、この発明のアンチエイリアシング方法
(図5のステップ5の処理)によって注目画素の輝度値
を補正すればよい。
If it is desired to prevent the black line portion in the horizontal direction of the checkered pattern and the black line part in the vertical direction of the checkered pattern from being prevented from being drawn due to aliasing, the following may be done. The pixel group on the projection surface is scanned in one of the horizontal direction and the vertical direction, and the brightness value of each pixel is determined by the same method as in the above-described embodiment. After this,
By scanning in the other direction, the brightness value of the pixel of interest may be corrected by the anti-aliasing method of the present invention (processing of step 5 in FIG. 5) only in the area where aliasing occurs.

【0055】また、格子縞が反射される物体モデルとし
て、3次元自由曲面ガラスが用いられているが、3次元
自由曲面形状の物体であれば、ガラス以外の物体のモデ
ルを用いてもよい。
Although a three-dimensional free-form curved surface glass is used as the object model in which the lattice fringes are reflected, an object model other than glass may be used as long as the object has a three-dimensional free-form curved surface shape.

【0056】[0056]

【発明の効果】この発明によれば、エイリアシングによ
って格子縞の線部分が描画されなくなるといったことを
防止することができる。
As described above, according to the present invention, it is possible to prevent the line portions of the lattice fringes from becoming undrawn due to aliasing.

【図面の簡単な説明】[Brief description of drawings]

【図1】反射映像の光学系モデルの構成を示す模式図で
ある。
FIG. 1 is a schematic diagram showing a configuration of an optical system model of a reflected image.

【図2】アンチエイリアシングが生じた場合の上下に隣
合う画素に対する交点位置と格子縞との位置関係の一例
を示す模式図である。
FIG. 2 is a schematic diagram showing an example of the positional relationship between the intersection points and the lattice stripes for vertically adjacent pixels when antialiasing occurs.

【図3】輝度値決定処理の手順を示すフローチャートで
ある。
FIG. 3 is a flowchart showing a procedure of a brightness value determination process.

【符号の説明】[Explanation of symbols]

1 視点 2 投影面 3 3次元自由曲面ガラス 4 格子縞のスクリーン 1 viewpoint 2 projection plane 3 three-dimensional free-form glass 4 lattice screen

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】 格子縞モデルの曲面形状モデルに対する
反射映像を、投影面の各画素の輝度を光線追跡法で決定
することにより生成する際に用いられるアンチエイリア
シング方法であって、 視点位置から任意の第1画素を通る光線と格子縞モデル
との交点と、視点位置から上記第1画素の隣にある第2
画素を通る光線と格子縞モデルとの交点とに基づいて、
一方の交点から他方の交点に光線が移行したと仮定した
場合に、格子縞モデルの線部分を光線が跨いだか否かを
判定するステップ、 格子縞モデルの線部分を光線が跨いだと判定したときに
は、格子縞モデル上の両交点間の距離に関する情報を算
出するとともに格子縞モデル上の両交点間の濃度値の平
均に関する情報を算出するステップ、および上記両交点
間の距離に関する情報と、両交点間の濃度値の平均に関
する情報とに基づいて、上記第2画素の輝度値を算出す
るステップ、 を備えているアンチエイリアシング方法。
1. An anti-aliasing method used when a reflected image of a curved surface shape model of a lattice fringe model is determined by determining the brightness of each pixel on the projection surface by a ray tracing method, the method being an arbitrary method from a viewpoint position. The intersection of the ray passing through the first pixel and the lattice fringe model, and the second pixel next to the first pixel from the viewpoint position.
Based on the intersection of the ray passing through the pixel and the plaid model,
If it is assumed that the ray has moved from one intersection to the other, the step of determining whether the ray has straddled the line portion of the checkered model, when it is determined that the ray has straddled the line portion of the checkered model, Calculating information about the distance between the intersections on the checkered model and calculating information about the average density value between the intersections on the checkered model, and information about the distance between the intersections and the density between the intersections Calculating the luminance value of the second pixel based on the information about the average of the values.
JP16647994A 1994-07-19 1994-07-19 Antialiasing method Pending JPH0830797A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP16647994A JPH0830797A (en) 1994-07-19 1994-07-19 Antialiasing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP16647994A JPH0830797A (en) 1994-07-19 1994-07-19 Antialiasing method

Publications (1)

Publication Number Publication Date
JPH0830797A true JPH0830797A (en) 1996-02-02

Family

ID=15832169

Family Applications (1)

Application Number Title Priority Date Filing Date
JP16647994A Pending JPH0830797A (en) 1994-07-19 1994-07-19 Antialiasing method

Country Status (1)

Country Link
JP (1) JPH0830797A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20160045561A (en) * 2014-10-17 2016-04-27 후아웨이 테크놀러지 컴퍼니 리미티드 Image anti-aliasing method and apparatus

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20160045561A (en) * 2014-10-17 2016-04-27 후아웨이 테크놀러지 컴퍼니 리미티드 Image anti-aliasing method and apparatus

Similar Documents

Publication Publication Date Title
US9237320B2 (en) Method and device for generating a calibrated projection
CA2063756C (en) Data projection system
JP4680796B2 (en) Image base protrusion displacement mapping method and double displacement mapping method using the method
CN111399507B (en) Method for determining boundary line in grid map and method for dividing grid map
US20060120593A1 (en) 3D image generation program, 3D image generation system, and 3D image generation apparatus
JP4071290B2 (en) Method and apparatus for generating computer graphics images
JPH05506730A (en) image generator
JP3402610B2 (en) Method and apparatus for mapping textures
US5864639A (en) Method and apparatus of rendering a video image
JPH09330423A (en) Three-dimensional shape data transforming device
JPH0997344A (en) Method and system for texture generation
JPH0830797A (en) Antialiasing method
JP2837584B2 (en) How to create terrain data
CN115127481A (en) Stripe projection 3D measuring method, terminal device and computer readable storage medium
CN114463344A (en) Method and device for generating gradient image and image signal generator
RU2364940C1 (en) Way of hachures arrangement on contour sheet, computer way of recognition of parts of horizontals which are passing through areas with small biases on contour sheet, and computer way of recognition of minimum outlines made by horizontals and frame of contour sheet
CN111223142A (en) Vertex coordinate mapping method for GPU point rasterization point size odd-even configuration
JPH0636039A (en) Texture mapping device
JPH07271847A (en) Method and device for modeling formation ground
JP3376884B2 (en) 3D terrain display device
JP2716570B2 (en) Image generation device
JP2773127B2 (en) Image editing method
JPH0765199A (en) Image shading method
JPH0554151B2 (en)
JPH1125281A (en) Texture mapping method