JPH064680A - Device and method for displaying graphic - Google Patents
Device and method for displaying graphicInfo
- Publication number
- JPH064680A JPH064680A JP4156868A JP15686892A JPH064680A JP H064680 A JPH064680 A JP H064680A JP 4156868 A JP4156868 A JP 4156868A JP 15686892 A JP15686892 A JP 15686892A JP H064680 A JPH064680 A JP H064680A
- Authority
- JP
- Japan
- Prior art keywords
- information
- display
- figures
- graphic
- dimensional
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 42
- 238000010586 diagram Methods 0.000 description 14
- 230000008030 elimination Effects 0.000 description 4
- 238000003379 elimination reaction Methods 0.000 description 4
- 230000010365 information processing Effects 0.000 description 4
- 230000005484 gravity Effects 0.000 description 3
- 230000006870 function Effects 0.000 description 2
- 238000003672 processing method Methods 0.000 description 2
- 238000004040 coloring Methods 0.000 description 1
- 239000000463 material Substances 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
Landscapes
- Image Generation (AREA)
Abstract
Description
【0001】[0001]
【産業上の利用分野】本発明は、2次元情報で作成した
複数個の立体形状の図形を表示する図形表示装置及び方
法に関する。BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a graphic display device and method for displaying a plurality of three-dimensional graphics created by two-dimensional information.
【0002】[0002]
【従来の技術】カタログやパンフレットなどのプレゼン
テーションを目的とする資料には、見やすさや理解度の
向上をはかるために立体形状の図柄が多用されている。
そのような図柄をオフィスにおける一般ユーザが作成す
る場合にはできるだけ手軽に作成できることが望まし
い。2. Description of the Related Art In a material for presentation such as a catalog or a pamphlet, three-dimensional patterns are often used in order to improve visibility and comprehension.
When such a design is created by a general user in the office, it is desirable that it can be created as easily as possible.
【0003】立体図形を作成する一般的な方法には、3
次元グラフィックスの利用や2次元グラフィックスの利
用があるが、前者は操作性や計算コストの面でオフィス
ユースには向かず、また後者は機能の点で実用的ではな
い。A common method for creating a solid figure is 3
Although there are two-dimensional graphics and two-dimensional graphics, the former is not suitable for office use in terms of operability and calculation cost, and the latter is not practical in terms of functions.
【0004】その他の方法として図形の座標情報は2次
元でありながら、立体的な図形と見えるように生成表示
する手法の試みもある。この手法を支援するものの1つ
に、本出願人により出願された特願平3−181166
号明細書に記載されているような、隠面消去表示を角柱
図形に対して行う図形処理方法がある。As another method, there is an attempt to generate and display the coordinate information of a figure so that it looks like a three-dimensional figure even though it is two-dimensional. One of the supports for this method is Japanese Patent Application No. 3-181166 filed by the present applicant.
There is a graphic processing method for performing hidden surface elimination display on a prismatic graphic as described in Japanese Patent No.
【0005】[0005]
【発明が解決しようとする課題】上記の図形処理方法
は、単体の角柱図形自身に対して隠面消去表示処理する
ものである。そのため、その方法は複数個の図形を生成
表示しようとする場合において、図形同志の間で隠面消
去表示する用途には対応できない。SUMMARY OF THE INVENTION The above graphic processing method is a hidden surface erasing display process for a single prismatic graphic itself. Therefore, that method cannot be applied to the hidden surface erasing display between the figures when generating and displaying a plurality of figures.
【0006】仮に図形を作成した順番に重ね表示する
と、立体的な前後関係を配慮した表示とならず、不自然
になることがある。前後関係は2次元グラフィックスに
あるような上下変更機能を用いれば変更修正できるが、
図形の数が多くなるにつれてその操作の手間も増え、面
倒となる。そこでこの変更処理を手軽に行う方法が求め
られていた。If the graphics are displayed in an overlapping order in the order in which they were created, they may not be displayed in consideration of the three-dimensional context and may be unnatural. The context can be changed and corrected using the up / down change function as in 2D graphics,
As the number of figures increases, the labor of the operation increases, which is troublesome. Therefore, there has been a demand for a method of performing this change process easily.
【0007】本発明は、2次元情報で表現した複数個の
角柱図形同志の隠面消去表示を簡単な処理で行う図形表
示装置及び方法を提供することを目的とする。SUMMARY OF THE INVENTION It is an object of the present invention to provide a graphic display device and method for performing a hidden surface erasing display of a plurality of prismatic figures expressed by two-dimensional information by a simple process.
【0008】[0008]
【課題を解決するための手段】本発明の図形表示装置
は、前記目的を達成するため、2次元情報で表現した複
数個の角柱形状の図形を表示する図形表示装置におい
て、各図形上の基準点となる位置情報を算出する手段
と、複数図形の表示方向を表すベクトルの向きを角度情
報として算出する手段と、各基準点の位置情報をベクト
ル角度情報に基づいて回転させる手段と、回転後の座標
情報同志を比較する手段と、回転座標情報の比較結果よ
り各図形間の表示順序を決定する手段を備えることによ
り、複数個の角柱形状の図形を前記表示順序に基づいて
表示することを特徴とする。In order to achieve the above-mentioned object, a graphic display device of the present invention is a graphic display device for displaying a plurality of prism-shaped graphics expressed by two-dimensional information, and a reference on each graphic. Means for calculating position information of points, means for calculating the orientation of a vector representing the display direction of a plurality of graphics as angle information, means for rotating the position information of each reference point based on vector angle information, and after rotation It is possible to display a plurality of prism-shaped figures based on the display order by providing a means for comparing the coordinate information of the two and a means for determining the display order between the figures from the comparison result of the rotation coordinate information. Characterize.
【0009】また、本発明の図形表示方法は、前記目的
を達成するため、2次元情報で表現した複数個の角柱形
状の図形を表示する図形表示方法において、各図形上の
基準点となる位置情報を算出し、複数図形の表示方向を
表すベクトルの向きを角度情報として算出し、各基準点
の位置情報をベクトル角度情報に基づいて回転させ、回
転後の座標情報同志を比較し、回転座標情報の比較結果
より各図形間の表示順序を決定し、複数個の角柱形状の
図形を前記表示順序に基づいて表示することを特徴とす
る。Further, in order to achieve the above-mentioned object, the graphic display method of the present invention is a graphic display method for displaying a plurality of prismatic figures expressed by two-dimensional information, and a position serving as a reference point on each graphic. Information is calculated, the direction of the vector representing the display direction of multiple figures is calculated as angle information, the position information of each reference point is rotated based on the vector angle information, the coordinate information after rotation is compared, and the rotation coordinates It is characterized in that the display order between the figures is determined based on the result of the information comparison, and a plurality of prismatic figures are displayed based on the display order.
【0010】[0010]
【作用】本発明の作用を具体的に例を挙げて説明する。The operation of the present invention will be described with reference to specific examples.
【0011】本発明の図形の表示を行う上で隠面消去表
示するための処理部は、図1に示すように図形の頂点座
標値や隠面消去表示処理に必要な情報などを記憶する図
形情報記憶手段1と、各図形上の基準点となる位置を算
出する基準点位置算出手段2と、複数個の図形の表示方
向を表すベクトルの向きを算出するベクトル角度算出手
段3と、各基準点の位置を回転させる座標情報回転手段
4と、座標値同志を比較する座標情報比較手段5と、座
標値の比較結果より各図形間の表示順序を決定する表示
順序決定手段6と、上記各手段を制御する制御手段7と
から構成される。The processing unit for displaying the hidden surface in displaying the graphic of the present invention stores the vertex coordinate values of the graphic and the information necessary for the hidden surface display processing as shown in FIG. Information storage means 1, reference point position calculation means 2 for calculating a position serving as a reference point on each figure, vector angle calculation means 3 for calculating the direction of a vector representing the display direction of a plurality of figures, and each reference. The coordinate information rotating means 4 for rotating the position of the point, the coordinate information comparing means 5 for comparing the coordinate values, the display order determining means 6 for determining the display order between the figures based on the comparison result of the coordinate values, and each of the above. And a control means 7 for controlling the means.
【0012】本発明は上記構成により、図形情報記憶手
段1において角柱形状図形の頂点座標値に関する情報
や、表示方法の種類の情報や、複数個の図形の表示方向
を表すベクトルによる情報などを記憶し、基準点位置算
出手段2において各図形上の基準点となる位置情報を算
出し、ベクトル角度算出手段3において入力したベクト
ルの向きを角度情報として算出し、座標情報回転手段4
において各図形上の基準点に対しベクトル角度情報に基
づいた回転処理を施し、座標情報比較手段5において回
転後の座標値の大きさの比較を行い、表示順序決定手段
6において座標値の比較結果により各図形間の表示順序
を決定する。According to the present invention having the above-mentioned configuration, the graphic information storage means 1 stores information on the vertex coordinate values of the prismatic figure, information on the type of display method, information by a vector representing the display direction of a plurality of figures, and the like. Then, the reference point position calculation means 2 calculates the position information serving as the reference point on each figure, the vector angle calculation means 3 calculates the direction of the vector input as the angle information, and the coordinate information rotation means 4 is calculated.
At the reference point on each figure, the rotation processing based on the vector angle information is performed, the coordinate information comparing means 5 compares the magnitudes of the coordinate values after the rotation, and the display order determining means 6 compares the coordinate values. The display order between the figures is determined by.
【0013】[0013]
【実施例】本発明の一実施例を図面を参照しながら説明
する。DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS An embodiment of the present invention will be described with reference to the drawings.
【0014】まず2次元情報で扱う角柱図形の例と、そ
れを表現する情報の内容について述べる。図2は2次元
座標情報で表現した角柱図形を2次元平面上に配置した
例であり、同図(a)はワイヤフレームにより表示した
もので、同図(b)は隠面消去表示したものである。同
図においてP1 ,P2 ,P3 ,P4 ,Q1 ,Q2 ,
Q3 ,Q4 は頂点の名前である。頂点P1 ,P2 ,
P3 ,P4 と頂点Q1 ,Q2 ,Q3 ,Q4 はそれぞれ対
応しており、説明の都合上、隠面消去表示したときに見
える頂点P1 〜P4 で構成される図形を上面、そしても
う一方の頂点Q1 〜Q4で構成される見えない側の図形
を下面と便宜的に呼ぶことにする。図形のこれら2面以
外の面を側面と呼ぶことにする。形状は4角柱としたが
これは本実施例における一例である。First, an example of a prismatic figure handled by two-dimensional information and the contents of information expressing it will be described. FIG. 2 shows an example in which prismatic figures expressed by two-dimensional coordinate information are arranged on a two-dimensional plane. The figure (a) is displayed by wire frame, and the figure (b) is hidden surface erased display. Is. In the figure, P 1 , P 2 , P 3 , P 4 , Q 1 , Q 2 ,
Q 3 and Q 4 are the names of vertices. Vertices P 1 , P 2 ,
P 3, P 4 and the vertex Q 1, Q 2, Q 3 , Q 4 corresponds respectively, for convenience of explanation, the figure composed of vertices P 1 to P 4 visible when viewing the hidden surface removal For convenience, the upper surface and the figure on the invisible side composed of the other vertices Q 1 to Q 4 will be referred to as the lower surface. The faces other than these two faces of the figure will be called side faces. The shape is a quadrangular prism, but this is an example in this embodiment.
【0015】上述の図形の情報の内容を表したものを図
3に示す。同図(a)は上面図形の各頂点の2次元座標
値を、同図(b)は下面図形の各頂点の2次元座標値
を、同図(c)は上面図形側を利用しての各辺の両端の
頂点番号を、それぞれ示している。角柱図形は平面図形
を入力し、それを各頂点を関連づけて複写することで得
られる。FIG. 3 shows the contents of the above-mentioned graphic information. The figure (a) shows the two-dimensional coordinate values of each vertex of the top figure, the figure (b) shows the two-dimensional coordinate values of each vertex of the bottom figure, and the figure (c) uses the top figure side. The vertex numbers at both ends of each side are shown. A prismatic figure can be obtained by inputting a plane figure and copying it by associating each vertex.
【0016】いま、図形の数が複数個になった場合を考
えることにする。図4は2つの角柱図形をワイヤフレー
ムにて表示した一例である。これを隠面消去表示したも
のが図5の例である。これらの2つの図形は2次元的に
は重なってはいないため、図形間での前後関係は気にせ
ずそれぞれ隠面消去表示すればよい。Now, consider the case where the number of figures becomes plural. FIG. 4 is an example in which two prismatic figures are displayed in a wire frame. An example of FIG. 5 shows the hidden surface erase display. Since these two figures do not overlap two-dimensionally, the hidden surface erase display may be performed without worrying about the context between the figures.
【0017】図4の図形を2次元的に重なるように配置
し、ワイヤフレームにて表示したものを図6に示す。同
図の2つの図形は3次元的な前後関係の情報は与えてな
く、また図からはそれらの前後関係は判断できない。図
7は図6の2つの図形を3次元的な前後関係の状態を変
えて隠面消去表示したものである。同図(a)では左側
の図形の方が3次元的に手前側にあり、同図(b)では
右側の図形の方が3次元的に手前側にある、と解釈でき
る。2次元的には上下関係が反対である。FIG. 6 shows the figure of FIG. 4 arranged in a two-dimensional manner and displayed in a wire frame. The two figures in the figure do not give three-dimensional context information, and the context cannot be determined from the figure. FIG. 7 shows the two figures shown in FIG. 6 in a hidden surface erased display by changing the state of the three-dimensional context. In the figure (a), it can be interpreted that the left figure is three-dimensionally on the front side, and the right figure is three-dimensionally on the front side. Two-dimensionally, the vertical relationship is opposite.
【0018】このような2次元平面上で重なりあう複数
個の角柱図形について隠面消去表示を行う処理の概略に
ついて説明する。図形同志の表示順番は図形の座標情報
からだけでは自動的には決定できないため、操作者がそ
の決定を支援する情報を与える。図8がその操作の様子
を示したものであり、図形同志の立体的な位置関係を表
す情報を2次元ベクトルで設定する。例えば図6の図形
を図7(a)の図形のように左側の図形が手前側となる
ようにするためには、図8(a)のように右斜め上から
左斜め下方向に2次元的ベクトルを描き、その方向に沿
って図形を表示させる。この2次元的ベクトルを指示ベ
クトルと呼ぶことにする。図8(b)の場合には、左斜
め上から右斜め下方向に2次元的ベクトルを描き、その
方向に沿って図形を表示させる。An outline of a process for performing hidden surface elimination display for a plurality of prismatic figures overlapping each other on such a two-dimensional plane will be described. Since the display order of the figures cannot be automatically determined only by the coordinate information of the figures, the operator gives information for supporting the decision. FIG. 8 shows a state of the operation, and information representing the three-dimensional positional relationship between the figures is set by a two-dimensional vector. For example, in order to make the figure on the left side to the front side like the figure in FIG. 7A from the figure in FIG. 6, two-dimensionally from the diagonally upper right to the diagonally lower left as shown in FIG. 8A. The target vector is drawn and the figure is displayed along the direction. This two-dimensional vector will be called an instruction vector. In the case of FIG. 8B, a two-dimensional vector is drawn from diagonally upper left to diagonally lower right, and a graphic is displayed along that direction.
【0019】ベクトルに沿う方向に対する図形の位置関
係は、図形上のどの位置を取るかにより変わる。その位
置を基準点と呼ぶことにするが、この各図形の基準点の
位置は本発明では上面図形の中心点、下面図形の中心
点、または図形全体の中心点のいづれかを選択して選ぶ
こととする。中心点は選択した図形の重心点または図形
を囲む最小矩形の中心のいづれかを選択する。The positional relationship of the graphic with respect to the direction along the vector changes depending on which position on the graphic is taken. Although the position is referred to as a reference point, the position of the reference point of each figure is selected by selecting either the center point of the top figure, the center point of the bottom figure, or the center point of the whole figure in the present invention. And For the center point, select either the center of gravity of the selected figure or the center of the smallest rectangle surrounding the figure.
【0020】図形の表示までに施す操作の処理フローを
図9に示す。ステップ1(図中、S1で示す。以下同
様)では図形の座標値情報を入力する。ステップ2では
表示方法の種類としてワイヤフレーム表示か隠面消去表
示かを選択する。ここでワイヤフレーム表示を選択した
場合にはステップ3以降の操作は行わない。ステップ3
では図形間の隠面消去表示の順序を自動的に決めるか、
操作者が手動的に決めるのかを選択する。手動で決める
場合には、ステップ4以降の操作は行なわず、必要に応
じて図形の表示順序を指定する操作を行う。ステップ4
では図形単位に表示したい順序を決めるように2次元方
向の指示ベクトルを設定する。ステップ5では各図形の
基準点の種類を選択する。ここでは、用いる図形を上
面、下面、全体の中から選択する操作と、中心点の種類
を選択する操作を行う。図形の数が1つの場合には、ス
テップ3以降の処理は行わなくてよい。FIG. 9 shows a processing flow of the operations performed up to the display of the figure. In step 1 (indicated by S1 in the figure; the same applies hereinafter), coordinate value information of the graphic is input. In step 2, a wireframe display or hidden surface removal display is selected as the type of display method. If the wire frame display is selected here, the operations after step 3 are not performed. Step 3
Then, automatically decide the order of hidden surface removal display between figures,
Select whether the operator decides manually. In the case of manual determination, the operations after step 4 are not performed, but the operation of designating the display order of the graphics is performed as necessary. Step 4
Then, the instruction vector in the two-dimensional direction is set so as to determine the order of display in units of figures. In step 5, the type of reference point of each figure is selected. Here, an operation of selecting the figure to be used from the upper surface, the lower surface, and the whole and an operation of selecting the type of the center point are performed. When the number of figures is one, the processing from step 3 onward may not be performed.
【0021】図形を表示する全体的な処理フローを図1
0に示す。ステップ11では表示方法の種類の判定を行
い、ステップ12においてその種類が隠面消去表示か否
かを調べ、YESの場合にはステップ13に進み、NO
の場合にはステップ21以降のワイヤフレーム表示処理
の方に進む。ステップ13では図形同志の表示順序を決
めるモードの種類を判定し、ステップ14においてその
種類が自動的か否かを調べ、YESの場合にはステップ
15に進み、NOの場合にはステップ17に進む。ステ
ップ15では全ての図形同志の表示順序を決定する。こ
のステップ15の処理については後ほど詳しく説明す
る。ステップ16ではステップ15で決定した表示順序
に従った図形の選択を開始する。順序決定モードが自動
でない場合には、ステップ17で図形を記憶している順
序に従った図形の選択を開始する。この図形を記憶して
いる順序とは、ユーザにより図形を表すための座標が入
力された順序を意味する。ステップ18では図形を1つ
選択し情報を読み出す。ここで1つの図形とは、1つの
角柱図形として認識される図形を意味する。ステップ1
9では選択した図形に対し隠面消去処理を行い表示す
る。ステップ20では全ての図形を選択したか否かを判
定し、YESの場合には全処理を終了し、NOの場合に
はステップ18に戻る。FIG. 1 shows an overall processing flow for displaying a figure.
It shows in 0. In step 11, the type of display method is determined, and in step 12, it is checked whether or not the type is hidden surface elimination display. If YES, the process proceeds to step 13 and NO.
In the case of, the process proceeds to the wire frame display process after step 21. In step 13, the type of mode that determines the display order of the figures is determined, and in step 14, it is checked whether or not the type is automatic. If YES, the process proceeds to step 15, and if NO, the process proceeds to step 17. . In step 15, the display order of all the figures is determined. The process of step 15 will be described in detail later. In step 16, selection of the graphic according to the display order determined in step 15 is started. If the order determination mode is not automatic, in step 17, the selection of the graphic according to the order in which the graphic is stored is started. The order in which the figures are stored means the order in which the coordinates for representing the figures are input by the user. In step 18, one figure is selected and the information is read. Here, one figure means a figure recognized as one prismatic figure. Step 1
At 9, the hidden figure is erased and displayed on the selected figure. In step 20, it is determined whether or not all the figures have been selected. If YES, the whole process is terminated, and if NO, the process returns to step 18.
【0022】隠面消去表示でない場合、すなわち、ワイ
ヤフレーム表示である場合、ステップ21で、図形を記
憶している順序に従って図形の選択を開始する。ステッ
プ22では図形を1つ選択し情報を読み出す。ステップ
23では選択した図形をワイヤフレームにて表示する。
ステップ24では全ての図形を選択したか否かを判定
し、YESの場合には全処理を終了し、NOの場合には
ステップ22に戻る。図形を表示する場合に伴う色付け
は本処理フローでは特にふれないが、隠面消去表示の際
に行えばよい。If it is not the hidden surface elimination display, that is, if it is the wire frame display, in step 21, the selection of the graphic is started in the order in which the graphic is stored. In step 22, one figure is selected and the information is read. In step 23, the selected figure is displayed in wireframe.
In step 24, it is determined whether or not all the figures have been selected. If YES, the whole process is terminated, and if NO, the process returns to step 22. The coloring associated with displaying a graphic is not particularly mentioned in this processing flow, but may be performed during the hidden surface erasing display.
【0023】図10の表示処理フローの中のステップ1
5の図形同志の表示順序を決定する処理を少し詳しくし
たものを図11の処理フローに示す。ステップ31では
指示ベクトルデータを読み出す。ステップ32では指示
ベクトルデータの2次元平面上における方向を角度情報
として求める。その様子を図12に示す。指示ベクトル
Vの終点が2次元平面上の原点位置となるように配置
し、原点から見た指示ベクトルVの始点の位置までの線
分のY軸の+方向の線分に対する変化角度θを求める。
ステップ33では図形の選択を記憶順序に従い選択を開
始する。ステップ34では1つの図形を選択し情報を読
み出す。ステップ35では選択図形の基準点の位置を求
める。ステップ36では基準点の座標値を原点を中心に
してステップ32で求めた角度θのマイナス分だけ回転
し、その位置情報を記憶しておく。その回転処理の様子
を図13に示す。同図において点QcおよびQc’は2
つの図形の基準点であり、図12の角度より図13のよ
うに反時計回りに回転させる。YcおよびYc’は−θ
回転後のY方向の座標値(位置情報)である。ステップ
37では全ての図形を選択したか否かを判定し、YES
の場合にはステップ38に進み、NOの場合にはステッ
プ34に戻る。ステップ38では基準点の回転後の位置
のY方向の座標値の大きさを比較しあい、大きい値ほど
先に表示するように順序を決定する。Step 1 in the display processing flow of FIG.
The processing flow of FIG. 11 shows the processing for determining the display order of the figures 5 in a slightly more detailed manner. At step 31, the instruction vector data is read. In step 32, the direction of the instruction vector data on the two-dimensional plane is obtained as angle information. This is shown in FIG. Arranged so that the end point of the instruction vector V is the origin position on the two-dimensional plane, and the change angle θ with respect to the + direction line segment of the Y axis from the origin to the position of the start point of the instruction vector V is obtained. .
In step 33, the selection of figures is started in accordance with the storage order. In step 34, one figure is selected and the information is read. In step 35, the position of the reference point of the selected figure is obtained. In step 36, the coordinate value of the reference point is rotated about the origin by the minus amount of the angle θ obtained in step 32, and the position information is stored. The state of the rotation processing is shown in FIG. In the figure, points Qc and Qc 'are 2
It is a reference point of two figures, and is rotated counterclockwise from the angle of FIG. 12 as shown in FIG. Yc and Yc ′ are −θ
It is the coordinate value (position information) in the Y direction after rotation. In step 37, it is determined whether or not all the figures have been selected, and YES
If NO, the process proceeds to step 38, and if NO, the process returns to step 34. In step 38, the magnitudes of the coordinate values in the Y direction of the rotated positions of the reference points are compared with each other, and the order is determined such that the larger value is displayed first.
【0024】図11の処理フローの中のステップ35の
基準点の位置を求める処理を少し詳しくしたものを図1
4の処理フローに示す。ステップ41では基準点の利用
図形の種類を判定し、ステップ42においてその種類が
図形全体から算出するか否かを判定し、YESの場合に
はステップ43に進み、NOの場合にはステップ44に
進む。ステップ44では基準点を図形の上面から算出す
るか否かを判定し、YESの場合にはステップ45に進
み、NOの場合にはステップ46に進む。ステップ43
では図形の全体の座標値を読み込む。ステップ45では
図形の上面側の図形の座標値を読み込む。ステップ46
では図形の下面側の図形の座標値を読み込む。ステップ
47では基準点の利用位置の種類を判定し、ステップ4
8においてその種類が読み込んだ図形の重心の位置を用
いるか否かを判定し、YESの場合にはステップ49に
進み、NOの場合にはステップ50に進む。ステップ4
9では読み出した座標値から重心位置の座標値を求め
る。ステップ50では読み出した図形を取り囲む最小矩
形を求める。ステップ51では最小矩形の重心の位置を
求める。このような基準点の求め方には、例えば図形上
のある特定の頂点位置を利用するなど、上記処理に限定
する必要はない。FIG. 1 is a detailed block diagram of the process of obtaining the position of the reference point in step 35 in the process flow of FIG.
4 shows the processing flow. In step 41, the type of the figure to be used as the reference point is determined. In step 42, it is determined whether or not the type is calculated from the entire figure. move on. In step 44, it is determined whether or not the reference point is calculated from the upper surface of the figure. If YES, the process proceeds to step 45, and if NO, the process proceeds to step 46. Step 43
Now read the coordinates of the whole figure. In step 45, the coordinate value of the figure on the upper surface side is read. Step 46
Then, the coordinate value of the figure on the lower side of the figure is read. In step 47, the type of use position of the reference point is determined, and in step 4
In 8, it is determined whether or not the position of the center of gravity of the read graphic is used as the type. If YES, the process proceeds to step 49. Step 4
At 9, the coordinate value of the barycentric position is obtained from the read coordinate value. In step 50, the minimum rectangle surrounding the read figure is obtained. In step 51, the position of the center of gravity of the smallest rectangle is obtained. The method of obtaining such a reference point does not need to be limited to the above processing, for example, using a specific vertex position on the figure.
【0025】図形情報の入力から図形の表示処理までを
行うための構成の概略のブロック図を図15に示す。座
標情報入力手段11は、図形の座標値情報を入力する。
一般的には、図形入力作業は表示装置の画面を見ながら
マウス等を用いて対話的に行うことが多く、ポインティ
ング装置から入る座標情報を受け取る部分に相当する。
属性情報入力手段12は、図形の表示方法の種類を初め
として、隠面消去表示処理に必要な情報までを入力す
る。図形情報記憶手段13は、入力した各種情報を記憶
する。隠面消去処理手段14は、隠面消去表示のための
処理を行う。描画処理手段15は、図形情報からラスタ
情報に展開する処理を行う。表示メモリ16は、描画さ
れた図形画像等が展開される部分である。制御手段17
は上記各手段を制御する。図1の隠面消去処理を行う処
理部は、図15の図形情報記憶手段13と隠面消去処理
手段14に相当する。FIG. 15 shows a schematic block diagram of a configuration for performing the process of inputting graphic information to the process of displaying a graphic. The coordinate information input means 11 inputs coordinate value information of a graphic.
Generally, the figure inputting operation is often performed interactively by using a mouse or the like while looking at the screen of the display device, and corresponds to a portion for receiving coordinate information input from the pointing device.
The attribute information input means 12 inputs the information necessary for the hidden surface erasing display process, including the type of graphic display method. The graphic information storage unit 13 stores various input information. The hidden surface removal processing means 14 performs processing for hidden surface removal display. The drawing processing means 15 performs processing for expanding graphic information into raster information. The display memory 16 is a portion where the drawn graphic image and the like are developed. Control means 17
Controls the above means. The processing unit that performs the hidden surface removal processing in FIG. 1 corresponds to the graphic information storage unit 13 and the hidden surface removal processing unit 14 in FIG.
【0026】図16は、本発明を実施するためのハード
ウェア構成の一例を示したものである。同図において、
21は計算機、22は中央演算処理装置、23は図形情
報処理装置、24は情報記憶メモリ、25は画像メモ
リ、26は入力装置、27は表示メモリ、28はディス
プレイ、29はスキャナ、30はプリンタ、31はバス
である。FIG. 16 shows an example of a hardware configuration for implementing the present invention. In the figure,
21 is a computer, 22 is a central processing unit, 23 is a graphic information processing device, 24 is an information storage memory, 25 is an image memory, 26 is an input device, 27 is a display memory, 28 is a display, 29 is a scanner, 30 is a printer. , 31 are buses.
【0027】中央演算処理装置22は、処理装置全体の
制御や一般的な演算を行うものである。図形情報処理装
置23は、図形の生成/表示のための処理を行う。情報
記憶メモリ24は、図形座標情報や隠面消去処理に必要
な情報を初めとした各種情報を記憶する。画像メモリ2
5は、画像データを記憶するものである。入力装置26
は、図形情報を入力したり計算機に命令等を与えたりす
るものである。表示メモリ27は、表示すべきデータを
展開するものであり、ディスプレイ28は、図形を含む
画像を出力表示するものである。スキャナ29は、画像
を入力するもので、プリンタ30は、画像を出力するも
のである。バス31は、画像データや図形データや制御
情報を受渡しする役割を果たす。図形情報処理装置23
と情報記憶メモリ24に、図1で示した隠面消去処理を
行うための処理部が含まれる。The central processing unit 22 controls the entire processing unit and performs general calculations. The graphic information processing device 23 performs processing for generating / displaying a graphic. The information storage memory 24 stores various kinds of information including graphic coordinate information and information necessary for hidden surface removal processing. Image memory 2
Reference numeral 5 stores image data. Input device 26
Is for inputting graphic information and giving instructions to a computer. The display memory 27 expands data to be displayed, and the display 28 outputs and displays an image including a figure. The scanner 29 is for inputting an image, and the printer 30 is for outputting an image. The bus 31 plays a role of passing image data, graphic data, and control information. Graphic information processing device 23
The information storage memory 24 includes a processing unit for performing the hidden surface removal processing shown in FIG.
【0028】[0028]
【発明の効果】以上のように本発明によれば、2次元情
報で表現した複数個の角柱図形同志を手軽な操作により
隠面消去表示できるようにしたため、複数個の角柱図形
を2次元グラフィックス環境で作成することが可能とな
り、その結果として立体図形の作成が、簡単な操作およ
び安い計算コストで行えるという効果を奏する。As described above, according to the present invention, since a plurality of prismatic figures represented by two-dimensional information can be hidden and displayed by a simple operation, a plurality of prismatic figures can be displayed in a two-dimensional graphic. It is possible to create a three-dimensional figure as a result, and as a result, it is possible to create a three-dimensional figure with a simple operation and a low calculation cost.
【図1】 図形の隠面消去処理を行う処理部のブロック
図である。FIG. 1 is a block diagram of a processing unit that performs hidden surface removal processing of a figure.
【図2】 角柱図形の一例を説明する説明図である。FIG. 2 is an explanatory diagram illustrating an example of a prismatic figure.
【図3】 角柱図形情報の内容を説明する説明図であ
る。FIG. 3 is an explanatory diagram illustrating the contents of prismatic figure information.
【図4】 2つの角柱図形をワイヤフレームにて表示し
た一例を説明する説明図である。FIG. 4 is an explanatory diagram illustrating an example in which two prismatic figures are displayed in a wire frame.
【図5】 2つの角柱図形を隠面消去表示した一例を説
明する説明図である。FIG. 5 is an explanatory diagram illustrating an example in which two prismatic figures are hidden and displayed.
【図6】 2つの重なる角柱図形をワイヤフレーム表示
した一例を説明する説明図である。FIG. 6 is an explanatory diagram illustrating an example in which two overlapping prismatic figures are displayed in a wire frame.
【図7】 2つの重なる角柱図形を隠面消去表示した一
例を説明する説明図である。FIG. 7 is an explanatory diagram illustrating an example in which two overlapping prismatic figures are hidden and erased and displayed.
【図8】 図形同志の表示順番の決定を支援する操作の
様子を説明する説明図である。FIG. 8 is an explanatory diagram illustrating a state of an operation that assists in determining the display order of the figures.
【図9】 図形の表示までに施す操作の処理フローであ
る。FIG. 9 is a processing flow of an operation performed until a figure is displayed.
【図10】 図形を表示する処理フローである。FIG. 10 is a processing flow for displaying a figure.
【図11】 図形同志の表示順序を決定する処理フロー
である。FIG. 11 is a processing flow for determining the display order of figures.
【図12】 指示ベクトルの角度を求める様子を説明す
る説明図である。FIG. 12 is an explanatory diagram for explaining how to determine the angle of the instruction vector.
【図13】 基準点の位置を回転する様子を説明する説
明図である。FIG. 13 is an explanatory diagram illustrating a manner of rotating the position of the reference point.
【図14】 基準点の位置を求める処理フローである。FIG. 14 is a processing flow for obtaining the position of a reference point.
【図15】 図形情報の入力から表示までを行う処理部
のブロック図である。FIG. 15 is a block diagram of a processing unit that performs input to display of graphic information.
【図16】 本発明を実施するためのハードウェア構成
の一例を説明する説明図である。FIG. 16 is an explanatory diagram illustrating an example of a hardware configuration for implementing the present invention.
1…図形情報記憶手段、2…基準点位置算出手段、3…
ベクトル角度算出手段、4…座標情報回転手段、5…座
標情報比較手段、6…表示順序決定手段、7…制御手
段、11…座標入力手段、12…属性情報入力手段、1
3…図形情報記憶手段、14…隠面消去処理手段、15
…描画処理手段、16…表示メモリ、17…制御手段、
21…計算機、22…中央演算処理装置、23…図形情
報処理装置、24…情報記憶メモリ、25…画像メモ
リ、26…入力装置、27…表示メモリ、28…ディス
プレイ、29…スキャナ、30…プリンタ、31…バス1 ... Graphic information storage means, 2 ... Reference point position calculation means, 3 ...
Vector angle calculating means, 4 ... Coordinate information rotating means, 5 ... Coordinate information comparing means, 6 ... Display order determining means, 7 ... Control means, 11 ... Coordinate input means, 12 ... Attribute information input means, 1
3 ... Graphic information storage means, 14 ... Hidden surface removal processing means, 15
... drawing processing means, 16 ... display memory, 17 ... control means,
21 ... Calculator, 22 ... Central processing unit, 23 ... Graphic information processing unit, 24 ... Information storage memory, 25 ... Image memory, 26 ... Input device, 27 ... Display memory, 28 ... Display, 29 ... Scanner, 30 ... Printer , 31 ... Bus
Claims (2)
の図形を表示する図形表示装置において、 各図形上の基準点となる位置情報を算出する手段と、 複数図形の表示方向を表すベクトルの向きを角度情報と
して算出する手段と、 各基準点の位置情報をベクトル角度情報に基づいて回転
させる手段と、 回転後の座標情報同志を比較する手段と、 回転座標情報の比較結果より各図形間の表示順序を決定
する手段を備えることにより、 複数個の角柱形状の図形を前記表示順序に基づいて表示
することを特徴とする図形表示装置。1. A graphic display device for displaying a plurality of prismatic figures expressed by two-dimensional information, a means for calculating position information serving as a reference point on each figure, and a vector representing a display direction of the plurality of figures. To calculate the orientation of each as the angle information, to rotate the position information of each reference point based on the vector angle information, to compare the coordinate information after rotation, and to compare each figure from the comparison result of the rotation coordinate information. A graphic display device, characterized in that a plurality of prismatic figures are displayed based on the display order by providing a means for determining a display order between them.
の図形を表示する図形表示方法において、 各図形上の基準点となる位置情報を算出し、 複数図形の表示方向を表すベクトルの向きを角度情報と
して算出し、 各基準点の位置情報をベクトル角度情報に基づいて回転
させ、 回転後の座標情報同志を比較し、 回転座標情報の比較結果より各図形間の表示順序を決定
し、 複数個の角柱形状の図形を前記表示順序に基づいて表示
することを特徴とする図形表示方法。2. A graphic display method for displaying a plurality of prismatic figures expressed by two-dimensional information, in which position information serving as a reference point on each figure is calculated, and the direction of a vector indicating the display direction of the plurality of figures. Is calculated as angle information, the position information of each reference point is rotated based on the vector angle information, the coordinate information after rotation is compared, and the display order between each figure is determined from the comparison result of the rotated coordinate information. A method for displaying a figure, comprising displaying a plurality of figures in the shape of prisms based on the display order.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP4156868A JPH064680A (en) | 1992-06-16 | 1992-06-16 | Device and method for displaying graphic |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP4156868A JPH064680A (en) | 1992-06-16 | 1992-06-16 | Device and method for displaying graphic |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH064680A true JPH064680A (en) | 1994-01-14 |
Family
ID=15637149
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP4156868A Pending JPH064680A (en) | 1992-06-16 | 1992-06-16 | Device and method for displaying graphic |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH064680A (en) |
-
1992
- 1992-06-16 JP JP4156868A patent/JPH064680A/en active Pending
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US5379371A (en) | Displaying method and apparatus for three-dimensional computer graphics | |
| EP0311081B1 (en) | Displaying method and apparatus for three-dimensional computer graphics | |
| JP2559910B2 (en) | Method and apparatus for designating 3D points in 2D graphic display | |
| US5734383A (en) | Apparatus and method for generating a three-dimensional model on a graphic display from a two-dimensional image | |
| KR950024108A (en) | Texture mapping method and device | |
| JP3602360B2 (en) | Three-dimensional landscape display device and display method | |
| JP3181877B2 (en) | 3D image creation device | |
| JPH064680A (en) | Device and method for displaying graphic | |
| JPH05298413A (en) | Graphic processor | |
| US6633291B1 (en) | Method and apparatus for displaying an image | |
| JPH1031757A (en) | Graphic processing apparatus and method for calculating minimum distance between elements | |
| JP2907356B2 (en) | Graphic processing method and apparatus | |
| JP2713582B2 (en) | Plot editor | |
| JP3312560B2 (en) | Texture mapping device | |
| JPH07114655A (en) | Graphic processing device | |
| JPH07225859A (en) | Object display | |
| JP3268667B2 (en) | Interactive polygon selection device | |
| JPH05274445A (en) | Method and device for processing image | |
| JPH06236446A (en) | Graphic display method/device | |
| JP4310909B2 (en) | Image processing device | |
| JP3681240B2 (en) | Three-dimensional shape display method and three-dimensional CAD system using the method | |
| JPH09231412A (en) | 3D curve input method | |
| JPH06187460A (en) | Graphic processing method | |
| JPH03144869A (en) | Method and device for displaying polygon | |
| JPS6340979A (en) | Hidden-line processing system |