JPS62145369A - Graphic data retrieving method - Google Patents

Graphic data retrieving method

Info

Publication number
JPS62145369A
JPS62145369A JP60285512A JP28551285A JPS62145369A JP S62145369 A JPS62145369 A JP S62145369A JP 60285512 A JP60285512 A JP 60285512A JP 28551285 A JP28551285 A JP 28551285A JP S62145369 A JPS62145369 A JP S62145369A
Authority
JP
Japan
Prior art keywords
cell
data
segment
search
graphic
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
JP60285512A
Other languages
Japanese (ja)
Inventor
Takafumi Miyatake
孝文 宮武
Hitoshi Matsushima
整 松島
Shigeko Otani
大谷 成子
Junichi Tono
東野 純一
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.)
Hitachi Ltd
Original Assignee
Hitachi 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 Hitachi Ltd filed Critical Hitachi Ltd
Priority to JP60285512A priority Critical patent/JPS62145369A/en
Priority to US06/942,633 priority patent/US4803477A/en
Priority to DE19863643585 priority patent/DE3643585A1/en
Publication of JPS62145369A publication Critical patent/JPS62145369A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T9/00Image coding
    • G06T9/20Contour coding, e.g. using detection of edges
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/20Drawing from basic elements, e.g. lines or circles
    • G06T11/203Drawing of straight lines or curves

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Multimedia (AREA)
  • Processing Or Creating Images (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

PURPOSE:To execute the retrieval of a graphic data at a high speed by checking an inclusion relation between the position data and the retrieval range of a graphic after an overlapped number is eliminated from a graphic number read out from an index table. CONSTITUTION:At an index table 50, the graphic number to identify the graphic is registered at every cell. And retrieval ranges (Xs, Ys) and (Xe, Ye) are inputted from a keyboard 10, and at a processing device 20, the cell overlapped with a given retrieval range is found, and all of corresponding segment numbers within the table 50 are extracted. And out of the extracted segment numbers, overlapped segment numbers except one are erased. Next, the coordinate data for the segment numbers in which overlapped numbers are eliminated is read out, and the inclusion relation between the data and the retrieval range is checked, and the segment number for an included one is taken out, and it is outputted to a display device 30 as the graphic.

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明はCADや地図データのアプリケーション分野等
において、ディスプレイ画面に図形を表示しておき、あ
る範囲を指定しその中に含まれる図形データを検索する
方法に係り、特に高速化が要求される場合に好適な検索
方法に関する。
[Detailed Description of the Invention] [Industrial Application Field] The present invention is used in the application field of CAD and map data, etc. to display a figure on a display screen, specify a certain range, and extract the figure data contained therein. The present invention relates to a search method, and particularly to a search method suitable when high speed is required.

〔従来の技術〕[Conventional technology]

CADや地図データのアプリケーションで必要とする様
な空間的なデータを効率良く扱うためには、空間的な位
置に基づいて高速にデータを検索できるようなインデッ
クスメカニズムが必要になる。この際位置は一般に2次
元以上のいbゆる多次元になるため、−次元データの高
速検索のために一般に用いられる方法、たとえばデータ
を予めソートしておき、バイすリサーチ検索する様な方
法は適用できない。
In order to efficiently handle spatial data such as that required by CAD and map data applications, an indexing mechanism that can quickly search data based on spatial location is required. In this case, the location is generally multi-dimensional (two or more dimensions), so methods commonly used for high-speed searches of -dimensional data, such as sorting the data in advance and performing a bi-research search, are not recommended. Not applicable.

こうした多次元データの検索方法として、従来各種の方
法が研究されてきた。例えば、コンピュータサーベイズ
(Computer 5urveys)第11巻第4号
第400〜第401頁、(以下、文献(1)と呼ぶ)参
照。文献(1)では「セル法」と呼ばれる手法が述へら
れており、これは点データ(位置だけで大きさや幅がな
いデータ)を対象としてデータを空間的な位置に基づい
て、格子状に区分しておき、(この区分された単位をセ
ルと呼ぶ)。
Various methods have been studied to search for such multidimensional data. For example, see Computer Surveys, Vol. 11, No. 4, pp. 400-401 (hereinafter referred to as document (1)). Reference (1) describes a method called the "cell method," which targets point data (data that has only position but no size or width) and divides the data into a grid based on spatial position. (This divided unit is called a cell).

データの検索においては、まず検M範囲がどのセルと重
なりを持つか調べ、重なりを持つセルに対してのみデー
タを読み出し、そのデータの位置と検索範囲との包含関
係をチェックし、最終的な検索結果を得るというもので
ある。このようにすると、全数についてデータの位置を
チェックする方法に比べ、データ数が限定されるので高
速検索が可能となる。
When searching for data, first check which cells the search M range overlaps with, read data only for the cells that overlap, check the inclusion relationship between the data position and the search range, and finally The purpose is to obtain search results. In this way, compared to the method of checking the position of data for all data, the number of data is limited, so high-speed searching becomes possible.

〔発明が解決しようとする問題点〕[Problem that the invention seeks to solve]

ところがCADや地図データのアプリケーションで取り
扱う図形は単純な点データではなく、細長い線データで
あったり、さらに幅を持つ面データであったりするので
、こうしたデータが取り扱えなければならない。
However, the figures handled by CAD and map data applications are not simple point data, but rather elongated line data or surface data with width, so it is necessary to be able to handle such data.

上記従来技術は線データや面データに関して配慮がされ
ておらず、文献(1)のようにセル毎に図形データを区
分すると複数のセルにまたがる図形の取り扱いが問題と
なる。もの文献(1)の方法を単純に応用しようとすれ
ば1図形を代表する点の位置(たとえば重心位置)がど
のセルに含まれているかで区分する方法が考えられるが
、この方法をとると検索時に、検索範囲と重なりを持つ
セル内に必ずしも図形が含まれているという保証がなく
なるため、検索漏れのケースが生じる。
The above-mentioned conventional technology does not consider line data or surface data, and if graphic data is divided into cells as in Document (1), handling of graphics that span multiple cells becomes a problem. If we try to simply apply the method in Reference (1), we can consider a method of classifying the position of a point representing one figure (for example, the position of the center of gravity) according to which cell it is included in, but if we use this method, During a search, there is no guarantee that a figure is necessarily included in a cell that overlaps with the search range, resulting in cases where the search is missed.

又文献(1)のセル法ではデータの追加や削除に関する
技術は全く述べられていないが、CADや地図データの
アプリケーションではこの操作が高速に出来るインデッ
クスメカニズムも必要である。セル法は一般に追加や削
除を高速に実行しようとすると大きなメモリスペースが
必要であり、メモリスペースを大きくしないで高速に実
行する技術が課題であった。
Further, although the cell method in document (1) does not mention any technology for adding or deleting data, CAD and map data applications require an indexing mechanism that can perform this operation at high speed. The cell method generally requires a large memory space to perform additions and deletions at high speed, and the challenge was to find a technology to perform it at high speed without increasing the memory space.

本発明は、従来のセル法の問題を解決し1図形データを
検索する場合の検索漏れを防止し、追加や削除の操作を
メモリスペースを大きくしないで高速に処理するインデ
ックスメカニズムを提供することにある。
The present invention solves the problems of the conventional cell method, prevents omissions in searches when searching for one figure data, and provides an index mechanism that processes addition and deletion operations at high speed without increasing the memory space. be.

〔問題点を解決するための手段〕[Means for solving problems]

上記目的の内、セル法の検索漏れを防止する目的では、
線データや面データについては図形が一部分でも含まれ
るセルに対して、すべての図形を登録するようにし、実
際の図形を区分するとメモリ量が増大するので、インデ
ックステーブルを設け、その中にセル毎に図形を識別す
る図形番号を登録し、検索時には、このインデックステ
ーブルの図形番号だけをまず読み出し、さらにこの読み
出した図形番号は同一の番号が重複して読み出されてい
る可能性があるので重複番号を除去し、しかる後に実際
の図形の位置データと検索範囲の包含関係をチェックし
て検索結果を得るようにすることにより、達成される。
Among the above purposes, for the purpose of preventing omissions in cell method searches,
For line data and area data, all shapes should be registered in cells that contain even a part of the shape. Since dividing the actual shapes will increase the amount of memory, an index table is set up and each cell is stored in the index table. A figure number that identifies a figure is registered in , and when searching, only the figure number in this index table is read first, and the read figure number is also duplicated because the same number may have been read out twice. This is achieved by removing the number and then checking the inclusion relationship between the actual figure position data and the search range to obtain the search results.

又、別の目的である、セル法の追加や削除に関する高速
化の目的では、インデックステーブルの構造として、図
形番号を格納したアドレスを示すポインタをセル毎に集
合化したセルポインタデープルと図形番号と次の図形番
号の格納アドレスを示す、連結ポインタとを組みとして
リスト化したセルテーブルと、セルテーブルの空き領域
のアドレスを示す空き管理ポインタを設けることにより
達成される。
In addition, for another purpose of speeding up the addition and deletion of the cell method, the structure of the index table is a cell pointer data table in which pointers indicating the address where the figure number is stored are collected for each cell, and the figure number. This is achieved by providing a cell table in which a cell table is listed as a pair with a link pointer indicating the storage address of the next graphic number, and a free space management pointer indicating the address of a free area in the cell table.

図形番号の追加操作は、空きV理ポインタの示すセルテ
ーブルに書き込むようにし、その時のセルテーブルの連
結ポインタ、空き管理ポインタの内容はその都度更新し
ておく。このようにするとインデックステーブル内のデ
ータ数に依存せず追加登録できる。
The operation of adding a graphic number is written in the cell table indicated by the free V management pointer, and the contents of the cell table connection pointer and free management pointer are updated each time. In this way, additional registration can be performed without depending on the number of data in the index table.

又図形番号の削除操作は、削除する図形番号の概当する
セルについて、セルポインタテーブルからサーチを開始
し、セルテーブルの図形番号を読み出しながら、削除す
る図形番号のアドレスを発見し、その領域については削
除したしるしとして、空き管理ポインタにアドレスを書
き込む。この時連結ポインタの更新やセルポインタの更
新を行う。
In addition, to delete a figure number, start searching from the cell pointer table for the cell to which the figure number to be deleted roughly corresponds, and while reading the figure number from the cell table, find the address of the figure number to be deleted, and search for that area. writes the address to the free management pointer as a sign of deletion. At this time, the link pointer and cell pointer are updated.

このようにすると、削除すべき図形番号の発見は概当す
るセルに限定されているので高速に処理できる。さらに
また削除したセルテーブルの領域が次の追加操作の時に
再利用できるためメモリが有効活用される。
In this way, the discovery of figure numbers to be deleted is limited to approximately corresponding cells, so that the process can be performed at high speed. Furthermore, since the deleted cell table area can be reused for the next addition operation, memory is effectively utilized.

〔実施例〕〔Example〕

以下、本発明の一実施例について詳細に説明する。 Hereinafter, one embodiment of the present invention will be described in detail.

第1図は本発明を実施した検索装置である。この検索装
置は検索範囲をキーボード10から入力する。処理装置
20は、図形データが格納されているセグメントテーブ
ル40をインデックステーブル50を参J!((して、
検索範囲内の図形データを検索し、表示装置:30へ出
力する。検索範囲の指定はキーボード入力以外にもマウ
スなどのボインティング装置からの入力であっても良い
し、計算機プログラム等から自動的に発生したものであ
っても良い。処理装置20は汎用計算機であることが好
ましいが、目的によっては検索しようとするデータを処
理するためにだけ使われる特殊装置であっても良い。イ
ンデックステーブル50.セグメントテーブル40は処
理装置20からアクセスできるメモリであることが好ま
しい。表示装置は検索結果を図形として表示したいので
、セグメントテーブル上に格納されているデータがベク
トルが基本あるので、ベクトルが表示できる表示装置で
あることが好ましい。
FIG. 1 shows a search device implementing the present invention. In this search device, a search range is input from a keyboard 10. The processing device 20 uses the index table 50 to refer to the segment table 40 in which graphic data is stored. ((do,
Graphic data within the search range is searched and output to the display device 30. In addition to keyboard input, the search range may be specified by input from a pointing device such as a mouse, or may be automatically generated from a computer program or the like. The processing device 20 is preferably a general-purpose computer, but depending on the purpose, it may be a special device used only to process data to be searched. Index table 50. Preferably, segment table 40 is memory that is accessible by processing device 20. Since it is desired that the display device display the search results as graphics, and since the data stored on the segment table is basically a vector, it is preferable that the display device be capable of displaying vectors.

第2図は本発明の図形データの区分方法を示したもので
ある。図においてハツチング部分対応するセルを示す。
FIG. 2 shows a method of dividing graphic data according to the present invention. In the figure, the hatched portion indicates the corresponding cell.

中の数字はセル番号である。第2図(a)は点データが
属するセルを示したものであり、セル番号10に区分す
る。(b)は線データであり、通過するすべてのセルに
区分する。すなわちセル番号3,6,7.10に区分す
る。
The numbers inside are cell numbers. FIG. 2(a) shows the cells to which the point data belongs, which are divided into cell numbers 10. (b) is line data, which is divided into all the cells it passes through. That is, it is divided into cell numbers 3, 6, 7, and 10.

(c)は面データであり、而を構成する線の通過するセ
ル以外にも面が包含しているセルにも区分する。すなわ
ちセル番号1.2,3,5,6,7゜8.9,10,1
1.12に区分する。このようにすると検索時に検索漏
れが防止できる。
(c) is surface data, which is divided into cells included in the surface in addition to the cells through which the line constituting the surface passes. That is, cell number 1.2, 3, 5, 6, 7° 8.9, 10, 1
Classified into 1.12. By doing this, it is possible to prevent omissions during the search.

第33図は本発明のインデックステーブル50とセグメ
ントテーブルの構造を具体的に示すための図形データと
セルの区分状況を例として示したものである。以降のイ
ンデックステーブルの説明やセグメントテーブルの説明
では例としてこの図形データを具体的に用いる。第3図
(a)の1,2゜:3は図形番号(以降セグメント番号
と呼ぶ)である。セグメント1は5個の座標点から構成
されている。又セグメント2は2個の座標点、セグメン
ト3は3個の座標点から構成されている。10’は検索
範囲を示しており、その形状として長方形の例を示した
ものであり、(b)のごとく長方形の左下の座標を(x
s、 Y3) 、右上の座標(xe。
FIG. 33 shows an example of graphic data and cell division to specifically illustrate the structure of the index table 50 and segment table of the present invention. In the following explanation of the index table and segment table, this graphic data will be specifically used as an example. 1, 2°:3 in FIG. 3(a) are figure numbers (hereinafter referred to as segment numbers). Segment 1 is composed of five coordinate points. Segment 2 is composed of two coordinate points, and segment 3 is composed of three coordinate points. 10' indicates the search range, and its shape is a rectangle as an example. As shown in (b), the coordinates of the lower left of the rectangle are (x
s, Y3), upper right coordinates (xe.

ye)で記述する。又りはセルサイズであり、ここでは
正方形の例を示しである。NXMAXは横方向のセルの
区分した数であり、この例では4である。
ye). Another example is the cell size; here, a square example is shown. NXMAX is the number of cell divisions in the horizontal direction, which is 4 in this example.

第4図はセグメントテーブル40の具体的な構造の一例
を示したものであり、セグメントの座標点列が格納され
たSEGテーブル40−1と、セグメント番号別にその
先頭格納先アドレスを格納した5EGPテーブル40−
2から構成される。
FIG. 4 shows an example of a specific structure of the segment table 40, which includes a SEG table 40-1 in which coordinate point sequences of segments are stored, and a 5EGP table in which the start storage address is stored for each segment number. 40-
Consists of 2.

SEGテーブル40−1内には第3図(a)の図形デー
タを格納した例を示している。このセグメントの座標デ
ータにアクセスするためには、セグメント番号から5E
GPテーブルのポインタを読み出し、このポインタが示
すSEGテーブル40−1を読み出す。具体的にはセグ
メント番号をSEG Nαとすると S E G (SEGP(SEfJα))でセグメント
番号S[:GNαの座標点の構成点数が読み出せる。さ
らに次のアドレスから座標データが読み出せることにな
る。このセグメントテーブル40は図形データの一つの
記述例であり、必要に応じて各セグメントについて線種
その他の附属情報を持つ構造であっても良い。
An example is shown in which the graphic data of FIG. 3(a) is stored in the SEG table 40-1. To access the coordinate data of this segment, enter 5E from the segment number.
The GP table pointer is read, and the SEG table 40-1 pointed to by this pointer is read. Specifically, when the segment number is SEG Nα, the number of constituent points of the coordinate points of the segment number S[:GNα can be read out using SEG (SEGP(SEfJα)). Furthermore, coordinate data can be read from the next address. This segment table 40 is an example of description of graphic data, and may have a structure that includes line type and other attached information for each segment as necessary.

第5図はインデックステーブル50のデータ構造の一例
である。これはセグメント番号とセル番号を組みとした
関係形式の表で構成したものである。たとえばセル番号
1にはセグメント番号1だけが登録されている。これは
第3図(a)より明らかであ芯。又セグメント番号1は
セル番号1゜2.3,9.10に部分的に含まれている
ので、各セルにそれぞれ登録している。又このインデッ
クステーブル50はセル番号をキーとしてソートしであ
る。したがっであるセル番号に属するセグメント番号を
捜し出すのに、インデックスの数をN(図では16)と
するとバイナリサーチの手法を用いてQogxN回のオ
ーダーで処理できる。検索高速化という観点からさらに
工夫したのが第6図のインデックステーブルである。こ
れはCELLテーブル50−1とCELLPテーブル5
0−2から構成されている。CELLテーブル50−1
はセグメント番号だけが格納されており、第5図のデー
プルのaセグメント番号の項目と同じデータである。一
方CELLPテーブル50−2はセル番号毎にCPLL
50のスタートとエンドのアドレスをポインタとして記
憶したものである。たとえばセル番号3は第5図から明
らかなようにセグメント番号1,2゜3が格納されてい
るが、この格納アドレスはアドレス3,4.5である。
FIG. 5 shows an example of the data structure of the index table 50. This is a table in a relational format that combines segment numbers and cell numbers. For example, only segment number 1 is registered in cell number 1. This is clear from Figure 3(a). Also, since segment number 1 is partially included in cell numbers 1°2.3, 9.10, it is registered in each cell. This index table 50 is sorted using cell numbers as keys. Therefore, in order to find the segment number belonging to a certain cell number, if the number of indexes is N (16 in the figure), the process can be performed on the order of QogxN times using the binary search method. The index table shown in FIG. 6 has been further improved from the viewpoint of speeding up the search. This is CELL table 50-1 and CELLP table 5
It consists of 0-2. CELL table 50-1
only the segment number is stored, and is the same data as the item a segment number of the daple in FIG. On the other hand, the CELLP table 50-2 contains CPLL for each cell number.
50 start and end addresses are stored as pointers. For example, in cell number 3, segment numbers 1, 2.3 are stored, as is clear from FIG. 5, and the storage addresses are addresses 3, 4.5.

そこでスタートポインタには3.エンドポインタには5
を格納する。尚第6図においてポインタは黒丸印で表現
している。
Therefore, the start point is 3. 5 for end pointer
Store. In FIG. 6, the pointer is represented by a black circle.

セル番号が4の場合はセグメント番号が登録されていな
いので「空」であることを示すのに斜線印で表現しであ
る。実際の数値としては、例えばスタートポインタ0.
エンドポインタが−1のデータを入れておく。この特殊
な数値は次に述べる具体的な検索処理の過程で利用する
。このインデックステーブル50の構造により、セル番
号が与えられると直接セグメント番号を参照できるよう
になる。
If the cell number is 4, no segment number has been registered, so a diagonal line is used to indicate that it is "empty." As an actual value, for example, the start point is 0.
Insert data whose end pointer is -1. This special numerical value is used in the specific search process described below. The structure of this index table 50 makes it possible to directly refer to a segment number when a cell number is given.

以上データ構造の具体的な例を示したが、次にこのデー
タ構造を用いた、本発明の検索方法を述べる。検索方法
は第7図のフローチャートに沿って説明する。尚利用す
るテーブルは、第4図のセグメントテーブル40.第6
図のインデックステーブル50とする。まず処理の実行
は処理装置20上で行う。検索処理は大きく5つのステ
ップからなり、第7図の処理100.処理200.処理
300.処理400.処理500の順で実行される。処
理100はキーボードから検索範囲(Xs、 Ys)=
 (Xe、 Ye)を入力する処理である。
A specific example of the data structure has been shown above. Next, a search method of the present invention using this data structure will be described. The search method will be explained along the flowchart of FIG. The table to be used is segment table 40. in FIG. 6th
It is assumed that the index table 50 is shown in the figure. First, processing is performed on the processing device 20. The search process mainly consists of five steps, including process 100 in FIG. Processing 200. Processing 300. Processing 400. Processes 500 are executed in order. Process 100 is to search range (Xs, Ys) from the keyboard.
This is a process of inputting (Xe, Ye).

処理200は与えられた検索範囲(Xs+YsL(X 
e 、 Y e )と重なりのあるセルを割り出し、概
当するインデックステーブル50内のセグメント番号を
すべて抽出する処理である。処理300を抽出したセグ
メント番号の中で重複した番号について1つを残して残
りを削除する処理である。
Processing 200 is performed based on a given search range (Xs+YsL(X
This is a process of determining the cells that overlap with (e, Ye) and extracting all the corresponding segment numbers in the index table 50. Process 300 is a process of deleting all but one of the duplicate numbers extracted from the extracted segment numbers.

本発明では検索漏れを防止するため1つのセグメントが
多数のセルに登録されることもあり、そのため重複して
セグメント番号を抽出するケースも発生するため、処理
300が必要である。処理400は重複を除去したセグ
メント番号について、セグメントテーブル40をアクセ
スして、座標データを読み出し、検索範囲(Xs、Ys
)t(Xa+ ye)と詳細な包含関係をチェックし、
包含されているものについてセグメント番号を検索結果
として出力する。このようにすると実際にセグメントテ
ーブル40の座標データを読み出すのは限定されている
ので、高速化効果が大きい。一般にセル内のデータ数を
Fとすると、オーダFの処理量で検索が実行できる。処
理500は検索結果を表示装置30へ図形として出力す
る。
In the present invention, in order to prevent search omissions, one segment may be registered in a large number of cells, and therefore there may be cases where segment numbers are extracted twice, so the process 300 is necessary. The process 400 accesses the segment table 40 for the segment number from which duplicates have been removed, reads coordinate data, and sets the search range (Xs, Ys
)t(Xa+ye) and check the detailed inclusion relationship,
Outputs segment numbers for included items as search results. In this way, since the number of times the coordinate data of the segment table 40 is actually read is limited, the speed-up effect is large. Generally, if the number of data in a cell is F, a search can be executed with the processing amount of order F. Processing 500 outputs the search results to display device 30 as a graphic.

以下各処理についてさらに詳細に述べる。Each process will be described in more detail below.

処理100はここでは長方形形状の範囲を指定している
Process 100 here specifies a rectangular shaped range.

処理200ではまず、処理205によりセル番号を検索
範囲(Xs、 Ys)、(Xs、 Ye)から割り出す
In process 200, first, in process 205, cell numbers are determined from the search ranges (Xs, Ys) and (Xs, Ye).

この割り出す方法について次に述べる。The method for determining this will be described next.

セル番号はある座標空間をセルサイズDで区分したとき
のセルの番号であり、座標空間を第1象限にとると、あ
る点(X、Y)に対応するセル番号には次の(1)式で
求まる。
A cell number is a cell number when a certain coordinate space is divided by cell size D. If the coordinate space is taken as the first quadrant, the cell number corresponding to a certain point (X, Y) has the following (1). It can be found by the formula.

に=  (j −1)  本NXMAX+ i    
    −(1)ここで1+ jはそれぞれX方向、Y
方向の区分番号であり、次の(2)式で示される値を持
つ。
= (j −1) Book NXMAX+ i
-(1) Here, 1+ j are the X direction and Y direction, respectively.
This is a direction division number, and has a value shown by the following equation (2).

又、NXMAXは座標空間を無限に区分するのではなく
、X方向に有限個区分したときの数を示したものである
。通常はセグメントテーブル40内の座標空間をカバー
しておれば良い。尚、セル番号には2次元的な表現のセ
ル番号(i、j)と等価である。処理205は(2)式
に基づいて検索範囲が占有しているセルのX方向区分番
号の始まりの番号11と終わりの番号i2とY方向の正
分番号の始まりの番号jxと終わりの番号j2を求めて
いる。
Furthermore, NXMAX indicates the number of divisions into a finite number of coordinate spaces in the X direction, rather than an infinite number of divisions. Normally, it is sufficient that the coordinate space within the segment table 40 is covered. Note that the cell number is equivalent to the cell number (i, j) in two-dimensional representation. Process 205 calculates the starting number 11 and ending number i2 of the X-direction division number and the starting number jx and ending number j2 of the Y-direction fraction number of the cell occupied by the search range based on formula (2). I'm looking for.

次に処理210により、インデックステーブル5oから
抽出するセグメント番号の総個数を記憶するカウンタN
をOに初期化する。処理215゜220.225,23
0,235,290は区分番号のirから12及びjx
からjz迄の間のすべてのセル番号(i、j)を走査す
る機構であり、プロダラムは2重のDoループになって
いる。処理250はセル番号N、j)が与えられてイン
デックステーブル50をアクセスして概当するセグメン
ト番号を抽出する処理である。この処理をさらに詳細に
述べると、まず処理255によりセル番号(i、j)を
セル番号Kに(1)式により変換する。
Next, in process 210, a counter N is set to store the total number of segment numbers extracted from the index table 5o.
Initialize to O. Processing 215°220.225,23
0,235,290 is the division number ir to 12 and jx
This mechanism scans all cell numbers (i, j) from to jz, and the programmer has a double Do loop. Process 250 is a process in which the cell number N, j) is given, the index table 50 is accessed, and the approximate segment number is extracted. To describe this process in more detail, first, in process 255, cell number (i, j) is converted into cell number K using equation (1).

その後、処理260,265,275により、CE L
 L )’テーブル50−2のセル番号にのアドレスの
スタートポインタとエンドポインタが示す範囲でCI化
I4テーブル50−1を走査する。処理270はバッフ
ァBuffにCI’:Ll、テーブル50−1から抽出
したセグメント番号を一時的に記憶するものであり、同
時にカウンタNで抽出したセグメントの個数を計数する
。以上処理250について説明したが、処理200が終
了した時点ではバッファBuff内には検索範囲内と重
なるセル内のN個のセグメント番号群が格納されている
ことになる。
Thereafter, through processes 260, 265, and 275, CE L
L)' Scan the CI I4 table 50-1 within the range indicated by the start pointer and end pointer of the address in the cell number of the table 50-2. The process 270 is to temporarily store CI':Ll and the segment number extracted from the table 50-1 in the buffer Buff, and at the same time, the counter N counts the number of extracted segments. The process 250 has been described above, and at the end of the process 200, the buffer Buff will have stored a group of N segment numbers in cells that overlap with the search range.

処理300ではバッファBuff内にN個のセグメント
番号につにて重複番号を除くために次の処理を行う。ま
ず処理305でNが0かどうか調べ、0の場合は以降の
処理は行わず、検索処理全体が停止する。Nが1以上で
あれば、処理310でバッファRuffの内容をセグメ
ント番号順にソートする。次に処理315で重複を除去
した後のセグメント番号の総個数を記憶するカウンタN
Nを1の初期化する。又処理325により変数BFにバ
ッファBoffの第1番目のデータBuff(1)を初
期設定しておく。この後、バッファBuffをサーチし
て重複データを発見し除去する。処理325,330゜
340はサーチのための機構であり、−重のBOループ
で構成されている。尚この場合ループ変数iは2からN
迄の範囲である。まず重複データを発見するために、R
FとBuff(i)の内容を処理335により比較し一
致していればBuff(i)のセグメント番号は重複し
ていると解釈して読み捨て、次の内容を調べるために処
理340へ行く。
In process 300, the following process is performed to remove duplicate numbers among the N segment numbers in the buffer Buff. First, in step 305, it is checked whether N is 0, and if it is 0, the subsequent processing is not performed and the entire search processing is stopped. If N is 1 or more, in step 310 the contents of the buffer Ruff are sorted in the order of segment numbers. Next, in process 315, a counter N is used to store the total number of segment numbers after removing duplicates.
Initialize N to 1. Further, in process 325, the first data Buff(1) of the buffer Boff is initialized in the variable BF. Thereafter, the buffer Buff is searched to find and remove duplicate data. Processes 325, 330, and 340 are search mechanisms, and are composed of multiple BO loops. In this case, the loop variable i is 2 to N.
The range is up to. First, in order to discover duplicate data, R
The contents of F and Buff(i) are compared in process 335, and if they match, the segment number of Buff(i) is interpreted as being duplicated and is discarded, and the process goes to process 340 to check the next content.

一方不一致であれば処理340によりBuff内のデー
タを詰め直し、カウンタNNの内容を更新する。
On the other hand, if they do not match, the data in Buff is repacked in step 340 and the contents of counter NN are updated.

この後処理340へ行く。以上述べた処理300が終了
した時点でバッファBuffには重複のないセグメント
番号がNNN油抽出れている。
After this, the process goes to post-processing 340. At the time when the process 300 described above is completed, NNN oil with no duplicate segment numbers has been extracted into the buffer Buff.

処理400ではバッファBuff内のNN個のセグメン
ト番号について、セグメントテーブル4oがら座標デー
タを読み出して、検索範囲(xs、 YS)(Xe、Y
θ)と詳細な包含関係のチェックを行い、最終的な検索
結果であるセグメント番号を抽出する。まず処理405
では検索セグメント数を記憶するカウンタMを0に初期
化する。次にバッファBuff内にすべてのセグメント
番号について順次検索を行うが、処理410,415,
435がそのためのループの機構であり、ループ変数i
の範囲は1からNN迄である。まず処理420によりB
uff(1)のセグメント番号に対応するSEGテーブ
ル40−1の座標点の構成点数を読み出し、変数NKO
に設定する。このセグメントはNK○−1個のベクトル
で構成されているので、次に順次ベクトルを読み出して
、座標の包含チェックを行う。処理425,430,4
55がこのループ機構であり、ループ変数はjである。
In process 400, coordinate data is read from the segment table 4o for NN segment numbers in the buffer Buff, and the search range (xs, YS) (Xe, Y
θ) and check the detailed inclusion relationship, and extract the segment number which is the final search result. First, process 405
Now, a counter M that stores the number of search segments is initialized to 0. Next, all segment numbers in the buffer Buff are sequentially searched, but processes 410, 415,
435 is the loop mechanism for this purpose, and the loop variable i
ranges from 1 to NN. First, by processing 420, B
The number of coordinate points in the SEG table 40-1 corresponding to the segment number of uff(1) is read out, and the variable NKO is read out.
Set to . Since this segment is composed of NK○-1 vectors, next, the vectors are sequentially read out and a coordinate inclusion check is performed. Processing 425, 430, 4
55 is this loop mechanism, and the loop variable is j.

処理440はSEGテーブル40−1からベクトルを読
み出す礎処理であり、ベクトルの始点座標(X I+ 
Y x) +終点Pj!、標(Xz、 Y2)とすると
具体的には以下の方法で読み出す。
The process 440 is the basic process of reading a vector from the SEG table 40-1, and the starting point coordinates of the vector (X I+
Y x) + end point Pj! , mark (Xz, Y2), specifically, it is read out using the following method.

X 1 = S E G (SEGP(Buff(i)
) + j )Y s =S E G (SEGP(R
uff(i))+ 、j + 1 )Xx= S E 
G (SEGP(Buff(i)) + j + 2 
)Y z= S E G (SEGP()loff(i
)) 十j + 3 )次に処理445でベクトルと検
索範囲との間で包含関係を調べて、処理450でもし包
含されていない場合に次のベクトルを読み出するために
処理455へ行き、包含されている場合は処理460で
概当するセグメント番号をBoffへ登録する。この際
、検索個数を記憶する変数Mを1更新しておく。一つで
もベクトルが包含されているのがわかった時点で、次の
セグメント番号を読み出すために処理435へ行く。以
上述べた処理400が終了した時で、バッファBuff
内にはM個の検索結果であるセグメント番号が格納され
ている。
X 1 = S E G (SEGP(Buff(i)
) + j ) Y s = S E G (SEGP(R
uff(i))+ ,j+1)Xx=S E
G (SEGP(Buff(i)) + j + 2
)Y z= S E G (SEGP()loff(i
)) 1 j + 3) Next, in process 445, the inclusion relationship is checked between the vector and the search range, and if it is not included in process 450, the process goes to process 455 to read the next vector, and If so, the approximate segment number is registered in Boff in process 460. At this time, the variable M that stores the number of search items is updated by 1. When it is found that at least one vector is included, the process goes to step 435 to read the next segment number. When the process 400 described above is completed, the buffer Buff
There are stored segment numbers that are M search results.

処理500はバッファ内の検索結果を表示装置30に表
示する処理である。処理505ではMが○であれば表示
する必要がないのでそれをチェックし、もしOでなけれ
ば、処理510で表示装置30上にB u f f内の
M個のセグメントを図形として表示する。
A process 500 is a process of displaying the search results in the buffer on the display device 30. In process 505, if M is O, there is no need to display it, so this is checked. If it is not O, in process 510, the M segments in B u f are displayed as figures on the display device 30.

以上第7図のフローチャートに沿った検索方法によれば
、線データや面データであっても、検索漏れが防止でき
、しかも検索の高速性は保証される。ここでは図形の例
としてベクトルの例で表現されたセグメントを検索する
方法について述べたが、その他にたとえばベクトルを検
索の単位としてベクトル番号をインデックステーブルに
登録したり、逆に複数のセグメントから構成された閉図
形の閉図形番号をインデックステーブルに登録したり、
あるいはより一般化して位置的な属性を持ったオブジェ
クトに対してオブジェクト番号をインデックステーブル
に登録したりすることによりやはり高速検索が可能とな
ることは言うまでもない。
According to the retrieval method according to the flowchart shown in FIG. 7, omissions in retrieval can be prevented even for line data or surface data, and high-speed retrieval is guaranteed. Here, we have described how to search for a segment expressed as a vector as an example of a figure, but there are other ways to search, such as registering a vector number in an index table using a vector as a search unit, or conversely, searching for a segment expressed as a vector that is made up of multiple segments. Register the closed shape number of the closed shape in the index table,
Alternatively, it goes without saying that high-speed searches can be made more general by registering object numbers in the index table for objects with positional attributes.

本発明の第2の目的はインデックステーブルの追加、削
除を高速にしかもメモリスペースをあます大きくとらな
いで実現する技術を提供することにある。検索の特性だ
けであれば、インデックステーブルの構造は第6図に示
したもので十分であるが、インデックステーブルの追加
や削除の時はインデックステーブルをセル番号別にソー
トする必要があるので、データ数をNとすると処理量は
NQogxNのオーダのコストとなり、検索コストとの
バランスが悪い、そこで本発明ではさらに改良したイン
デックステーブルとして、第8図に示すデータ構造を提
供する。このデータ構造はC[: L Lテーブル50
−3とCELLPテーブル50−4と、空き管理ポイン
タ5PACP 50−5とから構成される。CEI几テ
ーブル50−3はセグメント番号と連結ポインタの組み
から構成されるリストであり、同一セル番号のセグメン
ト番号はこの連結ポインタにより結びつけである。図中
黒丸印はポインタでありアドレス情報が入っている6又
斜線印は各セル番号の最後のセグメント番号であること
を意味し、その先に連結されたデータはない。具体的な
数値としてはたとえば0を入れておく。一方CELLP
テーブル5o−4は各セル番号に対応するCELLテー
ブル50−3のセグメント番号の格納アドレスを示すセ
ルポインタ群をテーブル化したものである0図中黒丸印
はポインタでありアドレス情報を入っている。すなわち
対応するセル内にはセグメント番号が全くない状態であ
り、具体的な数値としてはたとえば0を入れておく、又
、空き管理ポインタ5PACEP 50−5はCE I
−Lテーブル50−3の空き領域のリストの先頭を示す
アドレス情報を記憶しておく 、 CELLテーブル5
0−3の空き領域は連結ポインタで第8図のように結ん
でおく。
A second object of the present invention is to provide a technique for quickly adding and deleting index tables without taking up too much memory space. The structure of the index table shown in Figure 6 is sufficient for search characteristics only, but when adding or deleting an index table, it is necessary to sort the index table by cell number, so the number of data If N is the amount of processing, the cost is on the order of NQogxN, which is not well balanced with the search cost.Therefore, in the present invention, a data structure shown in FIG. 8 is provided as a further improved index table. This data structure is C[: LL table 50
-3, a CELLP table 50-4, and a free management pointer 5PACP 50-5. The CEI table 50-3 is a list consisting of combinations of segment numbers and connection pointers, and segment numbers of the same cell number are connected by this connection pointer. In the figure, the black circle mark is a pointer, and the six-point diagonal line mark containing address information means that it is the last segment number of each cell number, and there is no data connected beyond it. For example, enter 0 as a specific value. On the other hand, CELLP
Table 5o-4 is a table containing a group of cell pointers indicating the storage address of the segment number of CELL table 50-3 corresponding to each cell number.0 The black circles in the figure are pointers and contain address information. In other words, there is no segment number in the corresponding cell, and the specific value is, for example, 0. Also, the empty management pointer 5PACEP 50-5 is set to CE I
- Store address information indicating the beginning of the list of free areas in L table 50-3, CELL table 5
The empty areas 0-3 are connected using connection pointers as shown in FIG.

第8図の例では、17行目以降が空き領域として、空き
管理ポインタ5PACEP 50−5が管理している。
In the example of FIG. 8, the 17th line and subsequent lines are managed as free areas by the free space management pointer 5PACEP 50-5.

以上の第8図のインデックステーブルを用いた場合の検
索、追加、削除の処理の方法を次に述べる。
The search, addition, and deletion processing methods when using the above index table shown in FIG. 8 will be described below.

まず検索処理は既に述べた第7図のフローチャートとほ
ぼ同じであるが、インデックステーブルをアクセスする
処理の部分だけが異なる。そこで第7図の処理250を
第9図の処理で置き換える。
First, the search process is almost the same as the flowchart shown in FIG. 7 already described, but the only difference is the process of accessing the index table. Therefore, the process 250 in FIG. 7 is replaced with the process in FIG. 9.

第9図のフローチャートはまず、処理600によリセル
番号(le j)が与えられて、(1)式に基づいてセ
ル番号Kに変換する。次に処理605CELLPテーブ
ル50−4のセル番号Kに対応するセルポインタを読み
出し、ポインタPに設定する。
In the flowchart of FIG. 9, first, a recell number (le j) is given in process 600 and converted into a cell number K based on equation (1). Next, in step 605, the cell pointer corresponding to cell number K of the CELLP table 50-4 is read and set to pointer P.

次に処理610でポインタPであるかどうかをチェック
する。もしポインタPが0であればセグメント番号がな
いことを意味するので処理は終了する。Oでなければ処
理615によりまず抽出したセグメント番号の個数を記
憶するカウンタNを1更新した後、ポインタPが示すC
VXLLテーブル50−3からセグメント番号を読み出
し、バッファ3uffに登録する。この後処理620に
より連結ポインタCBLL(2,P)を読み出し、これ
を再びポインタPに設定し、処理610へ戻る。第9図
の処理は第7図の処理250と同程度の規模であり、検
索コストは増えないのでオーダF(Fはセル内のセグメ
ント数)のコストのままである。
Next, in step 610, it is checked whether the pointer is P or not. If pointer P is 0, it means that there is no segment number, and the process ends. If not, in step 615, the counter N that stores the number of extracted segment numbers is updated by 1, and then the C indicated by the pointer P is
The segment number is read from the VXLL table 50-3 and registered in the buffer 3uff. This post-processing 620 reads the concatenated pointer CBLL (2, P), sets it to the pointer P again, and returns to the process 610. The process in FIG. 9 is on the same scale as the process 250 in FIG. 7, and the search cost does not increase, so the cost remains the same as that of order F (F is the number of segments in a cell).

次にインデックステーブルにセグメント番号を追加する
処理を第1.0図のフローチャートを用いて説明する。
Next, the process of adding segment numbers to the index table will be explained using the flowchart of FIG. 1.0.

追加するセグメント番号S[E(Jαとそのセグメント
がMくするセル番号CELI−Nαを入力としてインデ
ックステーブルの追加方法は次のように行う。まず処理
700によりセグメント番号5EGNn  を空き管理
ポインタ5PACEPが示すCELLテーブル50−3
のセグメント番号の項に書き込む。
The index table addition method is performed as follows by inputting the segment number S[E(Jα) to be added and the cell number CELI-Nα that the segment represents M. First, in process 700, the free management pointer 5PACEP indicates the segment number 5EGNn. CELL table 50-3
Write in the segment number field.

すなわち CFLL= (1、5PACEP)=SEGNαを実行
する。次に処理705により、令書き込んだCF L 
Lテーブル50−3の連結ポインタを読み出しポインタ
Pに退避しておく。すなわちP =CELL (2、5
PACEP)を実行する。次に処理710によりCEL
LPテーブル50−4のセルポインタが現在示している
CELLテーブル50−3のアドレスを読み出し令書き
込んだCELLテーブル50−3の連結ポインタの項へ
書き込む。すなわち CBLL=  (2、CELLNQ)=CEl、!、P
 (CELLNn)を実行する。次に処理715により
CELLPテーブル50−4のセル番号CELL&に対
応するセルポインタを、現在の空き管理ポインタが示し
ている内容に変更する。すなわち CELLP (CELLNQ) =SPACEPを実行
する。最後に処理720により、空き管理ポインタ5P
ACEPにポインタPの内空を書き込んで終了する。す
なわち 5PACEP= P を実行する。この方法では新しく追加されたセグメント
番号は常にCELLPテーブルのセルポインタによって
示されることになる。すなわち常にリストの先頭の部分
として登録される。以上述べたように本発明によればイ
ンデックステーブルに登録されたデータ量にかかわらず
、たった5ステツプで追加の処理が行える。この追加リ
ストはオーダ1と言える。
That is, CFLL=(1,5PACEP)=SEGNα is executed. Next, in process 705, the instruction written CF L
The concatenation pointer of the L table 50-3 is saved to the read pointer P. That is, P = CELL (2, 5
PACEP). Next, in process 710, CEL
The address of the CELL table 50-3 currently indicated by the cell pointer of the LP table 50-4 is written to the link pointer section of the CELL table 50-3 to which the read command was written. That is, CBLL= (2, CELLNQ)=CEl,! , P
Execute (CELLNn). Next, in process 715, the cell pointer corresponding to the cell number CELL& in the CELLP table 50-4 is changed to the content indicated by the current free management pointer. That is, CELLP (CELLNQ) =SPACEP is executed. Finally, by processing 720, the free management pointer 5P
Write the empty space in pointer P to ACEP and end. That is, execute 5PACEP=P. In this method, the newly added segment number will always be indicated by the cell pointer in the CELLP table. That is, it is always registered as the first part of the list. As described above, according to the present invention, additional processing can be performed in just five steps regardless of the amount of data registered in the index table. This additional list can be called order 1.

次にインデックステーブルからセグメント番号を削除す
る処理を第11図のフローチャートを用いて説明する。
Next, the process of deleting a segment number from the index table will be explained using the flowchart of FIG.

尚フローチャート中で変数Paは一回前にサーチしたポ
インタの内容が、変数P1は現在サーチしているポイン
タの内容がそれぞれ格納されるものである。この削除の
処理では対象となるセグメント番号5EGNαとそのセ
グメント番号が属するセル番号CBLL Nαを入力と
する。まず、処理800で変数PoにO2変数P1にC
ELLPテーブル50−4のセル番号CELL Nαに
対応するセルポインタの内容を初期設立する6すなわち
In the flowchart, the variable Pa stores the contents of the pointer searched once before, and the variable P1 stores the contents of the pointer currently searched. In this deletion process, the target segment number 5EGNα and the cell number CBLL Nα to which the segment number belongs are input. First, in process 800, the variable Po is set to O2, the variable P1 is set to C
6, that is, the contents of the cell pointer corresponding to the cell number CELL Nα of the ELLP table 50-4 are initially established.

Po=O P1=CBLL (CELLNQ) を実行する。次に変数Pzが示すCELLテーブル50
−3からセグメント番号を読み出し、セグメント番号5
EGNn を一致するもの(すなねち削除の対象)をサ
ーチする。このサーチの機構が処理805.810,8
15である。処理805t’!!変数P1が0でないこ
とをまず確認する。0であれば削除しようとしたセグメ
ントがもともとインデックステーブルに登録されていな
かったことを意味し、処理は終了する。もし0でなけれ
ば、(1:ELLテーブル50−3セグメント番号と削
除すべきセグメント番号SEG Nαとの一致を処理8
10で調べ、不一致であれば処理815へ行き、さらに
サーチを続ける。処理815では現在示している変数P
1を変数Paに書き込んだ後、変数PiもCELLテー
ブル5o−3の連結ポインタの内容を読み出して、P+
 を更新する。すなわちPo=PI Pr=CELL (2,Pz) を実行し、処理805へ戻る。一方、削除すべきセグメ
ント番号を見つけた場合は削除のためのリスト操作を処
理820,825,830,840゜845で実行する
。処理820は削除対象のCEI几テーブル50−3の
領域がリストの先頭であるかどうかを調べる。もし変数
PaがOであれば、CELLテーブル5o−4を更新し
、そうでなければ一つ前のポインタが示すCELLテー
ブル50−3の連結ポインタを更新する。処理825は
削除すべきセグメント番号5EGNαが属するセル番号
CELLNaのCELLテーブル50−3に削除するC
ELLテーブル50−3の連結ポインタの内容を書き込
む、すなわち、 CELLP (CELLNα) =CELL (2,P
I)を実行する6一方、処理830では一つ前のポイン
タが示すCE L Lテーブル50−3の連結ポインタ
に削除すべきCELLテーブル50−3の連結ポインタ
の内容を書き込む。すなわち CELL  (2、Po)  =CF、LL  (2、
Pt)を実行する。次に処理840,845により削除
したC[l!LLテーブル50−3を空き領域として次
の追加操作の時に再利用できるように空き管理ポインタ
5PACEPを通じて返却する。まず処理840では、
空き管理ポインタ5PADEPの内容を読み出し、これ
を削除したCELLテーブル5o−3の連結ポインタに
書き込む、すなわち CELL  (2、P 1)  =SPACEPを実行
する。これによって空き領域リストの先頭に削除した領
域が返却されたことになる。次に変数P1の内容を空き
管理ポインタ5PACEPに書き込む。
Execute Po=O P1=CBLL (CELLNQ). Next, the CELL table 50 indicated by the variable Pz
- Read the segment number from 3, segment number 5
Search for a match for EGNn (target for deletion). This search mechanism processes 805.810,8
It is 15. Processing 805t'! ! First, confirm that variable P1 is not 0. If it is 0, it means that the segment to be deleted was not originally registered in the index table, and the process ends. If it is not 0, (1: Process 8 to match the segment number of ELL table 50-3 and the segment number SEG Nα to be deleted.
10, and if there is no match, the process goes to step 815 to continue the search. In process 815, the currently indicated variable P
After writing 1 to variable Pa, variable Pi also reads the contents of the link pointer of CELL table 5o-3 and writes P+
Update. That is, Po=PI Pr=CELL (2, Pz) is executed, and the process returns to process 805. On the other hand, if a segment number to be deleted is found, list operations for deletion are executed in processes 820, 825, 830, 840 and 845. Process 820 checks whether the area of the CEI table 50-3 to be deleted is at the top of the list. If the variable Pa is O, the CELL table 5o-4 is updated, and if not, the linked pointer of the CELL table 50-3 indicated by the previous pointer is updated. Process 825 deletes C in the CELL table 50-3 of the cell number CELLNa to which the segment number 5EGNα to be deleted belongs.
Write the contents of the concatenation pointer of the ELL table 50-3, that is, CELLP (CELLNα) = CELL (2, P
On the other hand, in process 830, the content of the concatenation pointer of the CELL table 50-3 to be deleted is written into the concatenation pointer of the CELL table 50-3 indicated by the previous pointer. That is, CELL (2, Po) = CF, LL (2,
Pt) is executed. Next, C[l! The LL table 50-3 is returned as a free space through the free space management pointer 5PACEP so that it can be reused for the next addition operation. First, in process 840,
The contents of the empty management pointer 5PADEP are read and written to the concatenation pointer of the deleted CELL table 5o-3, that is, CELL (2, P 1) =SPACEP is executed. This means that the deleted area is returned to the top of the free area list. Next, the contents of the variable P1 are written to the free space management pointer 5PACEP.

すなわち 5PACEP =P 1 を実行する。以上の処理により削除処理は完了し削除さ
れた領域は常に空き管理ポインタ5PACEPにより、
リストの先頭に位置づけられ、次回の追加処理の時はま
ずこの領域から利用される。又ここで述べた削除の処理
はCELLテーブル5o−3を指定したセル番号に限定
して、削除すべきセグメント番号をサーチするため、削
除コストとしてはオーダF (Fはセル内のデータ数)
となり、検索処理と同等以上の高速化が実現できる。し
かもメモリスペースとしても削除した領域を動的に再利
用するため少なくてすむ。
That is, 5PACEP = P 1 is executed. The above process completes the deletion process, and the deleted area is always stored using the free management pointer 5PACEP.
It is positioned at the beginning of the list, and the next time additional processing is performed, this area will be used first. Also, in the deletion process described here, the cell table 5o-3 is limited to the specified cell number and the segment number to be deleted is searched, so the deletion cost is order F (F is the number of data in the cell).
This makes it possible to achieve speeds that are equal to or higher than search processing. Moreover, since the deleted area is dynamically reused, the memory space can be reduced.

〔発明の効果〕〔Effect of the invention〕

本発明によれば、検索処理は点データ、線データ面デー
タいずれについても、一部分でも含まれるセルにすべて
割り当てる方法をとっているため、図形データに適用し
ても検索漏れが防止でき、しかも、検索コストはセル内
のデータに限定するのでオーダF(Fはセル内のデータ
数)と高速化できる効果がある。追加処理ではインデッ
クステーブルに連結ポインタ、空き管理ポインタ等を導
入しリスト操作を行うことが可能となり、追加コストは
オーダ1と高速化できる効果がある。又削除処理では検
索と同様にセル内のデータに限定して。
According to the present invention, since the search process uses a method of allocating all points data, line data, and surface data to cells that include even a part of it, omissions in the search can be prevented even when applied to graphic data. Since the search cost is limited to the data within the cell, it has the effect of speeding up the order of F (F is the number of data within the cell). In the additional processing, a link pointer, a free management pointer, etc. are introduced into the index table, and list operations can be performed, and the additional cost is 1 order, which has the effect of speeding up the process. Also, the deletion process is limited to the data within the cell, similar to the search.

削除対象をサーチできる−ので、削除コストとしてオー
ダFと高速化できる効果があり、しかも空き管理ポイン
タによって削除した領域が動的に再利用できるためメモ
リスペースが少なくてすむ効果もある。
Since the deletion target can be searched, there is an effect that the deletion cost can be increased to order F, and there is also an effect that the memory space can be reduced because the deleted area can be dynamically reused using the free management pointer.

又本発明は図形データについて説明したが、位置情報の
属性を持った一般のオブジェクトに対しても、たとえば
インデックステーブルにオブジェクト番号をセル別に登
録すれば良いだけであり、汎用的に適用可能である。
Furthermore, although the present invention has been described with respect to graphic data, it is also applicable to general objects that have the attribute of positional information, as it is only necessary to register the object number for each cell in the index table, for example. .

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

第1図は本発明の一実施例の検索装置、第2図はデータ
のセルへの区分方法の原理図、第3図は図形データの一
例、第4図はセグメントテーブルの構造図、第5図はイ
ンデックステーブルの構造の一例、第6図は第5図のイ
ンデックステーブルを改良した一例、第7図は検索処理
のフローチャート、第8図は追加削除を効率良く行うた
めのインデックステーブルの構造図、第9図は第8図の
インデックステーブルを利用した時のテーブルアクセス
のフローチャート、第10図は第8図ンデツクステーブ
ルの追加処理のフローチャ第11図は第8図のインデッ
クステーブルC処理のフローチャートである。 10・・・検索範囲を入力するキーボード、20理装置
、30・・・表示装置、40・・・セグメントプル、5
0・・・インデックステーブル、100索範囲入力処理
、200・・・インデックスチーのセグメント番号抽出
処理、300・・・重複しグメント番号を除去する処理
、400・・・柚、′上セグメント番号から座標データ
を読み出し槓囲との包含関係を調べ、検索結果を求める
望500・・・検索結果の表示処理。
Fig. 1 is a search device according to an embodiment of the present invention, Fig. 2 is a principle diagram of a method of dividing data into cells, Fig. 3 is an example of graphic data, Fig. 4 is a structural diagram of a segment table, and Fig. 5 is a diagram of the structure of a segment table. The figure shows an example of the structure of an index table, Figure 6 is an example of an improved index table of Figure 5, Figure 7 is a flowchart of search processing, and Figure 8 is a diagram of the structure of an index table for efficient addition and deletion. , Fig. 9 is a flowchart of table access when using the index table of Fig. 8, Fig. 10 is a flowchart of the index table addition process of Fig. 8, and Fig. 11 is a flowchart of the index table C processing of Fig. 8. It is a flowchart. DESCRIPTION OF SYMBOLS 10...Keyboard for inputting search range, 20...Display device, 40...Segment pull, 5
0...Index table, 100 search range input processing, 200...Index Q segment number extraction processing, 300...Processing to remove duplicate segment numbers, 400...Yuzu, 'coordinates from upper segment number 500. Search result display processing by reading out data and checking the inclusion relationship with the surrounding area to obtain search results.

Claims (1)

【特許請求の範囲】 1、指定された検索範囲から検索キーを計算し、前記検
索キーに基づいてインデックステーブルの図形番号を読
み出し、 前記読み出した図形番号の中で同一のものがあるかどう
かを調べ、同一であれば1つを残して残りを削除し、 前記残りの図形番号をキーとしてセグメントテーブルに
格納されている図形の位置データを読み出し、 前記位置データと検索範囲との重なりを調べ、重なりの
ある図形番号を検索結果として出力するようにしたこと
を特徴とする図形データの検索方法。 2、特許請求の範囲第1項のインデックステーブルは、
座標空間をセル状に区分したときのセル毎に、図形デー
タの位置が一部分でも含まれている図形番号をすべて記
憶しておくようにしたことを特徴とする図形データの検
索方法。 3、特許請求の範囲第1項のインデックステーブルの構
造は、セル毎に図形番号の格納先アドレスを示すセルポ
インタテーブルと、図形番号と次の図形番号格納先アド
レスを示す連結ポインタとを組みとしたセルテーブルと
、セルテーブルの空き領域を示す空き管理ポインタとか
ら構成されていることを特徴とする図形データの検索方
法。
[Claims] 1. Calculate a search key from a specified search range, read out figure numbers in an index table based on the search key, and check whether there is an identical figure number among the read figure numbers. If they are the same, leave one and delete the rest, read the position data of the figures stored in the segment table using the remaining figure number as a key, check the overlap between the position data and the search range, A method for searching figure data characterized by outputting overlapping figure numbers as search results. 2. The index table in claim 1 is:
A method for searching graphic data, characterized in that when a coordinate space is divided into cells, all graphic numbers containing even a part of the position of graphic data are stored for each cell. 3. The structure of the index table in claim 1 includes a cell pointer table that indicates the storage address of a graphic number for each cell, and a link pointer that indicates the graphic number and the next graphic number storage address. A method for searching graphic data, characterized in that the method is comprised of a cell table that has been updated, and a free space management pointer that indicates a free space in the cell table.
JP60285512A 1985-12-20 1985-12-20 Graphic data retrieving method Pending JPS62145369A (en)

Priority Applications (3)

Application Number Priority Date Filing Date Title
JP60285512A JPS62145369A (en) 1985-12-20 1985-12-20 Graphic data retrieving method
US06/942,633 US4803477A (en) 1985-12-20 1986-12-17 Management system of graphic data
DE19863643585 DE3643585A1 (en) 1985-12-20 1986-12-19 PROCESSING SYSTEM FOR GRAPHIC DATA

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP60285512A JPS62145369A (en) 1985-12-20 1985-12-20 Graphic data retrieving method

Publications (1)

Publication Number Publication Date
JPS62145369A true JPS62145369A (en) 1987-06-29

Family

ID=17692484

Family Applications (1)

Application Number Title Priority Date Filing Date
JP60285512A Pending JPS62145369A (en) 1985-12-20 1985-12-20 Graphic data retrieving method

Country Status (3)

Country Link
US (1) US4803477A (en)
JP (1) JPS62145369A (en)
DE (1) DE3643585A1 (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02188883A (en) * 1989-01-17 1990-07-24 Mitsubishi Electric Corp Graphic display method
JPH03260880A (en) * 1990-03-12 1991-11-20 Mitsubishi Electric Corp Graphic display method
JPH03263272A (en) * 1990-03-14 1991-11-22 Fujitsu Ltd Graphic retrieving system
JPH075308U (en) * 1993-06-24 1995-01-27 新興和産業株式会社 Self-propelled work trolley

Families Citing this family (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5285193A (en) * 1987-01-16 1994-02-08 Sharp Kabushiki Kaisha Data base system
US4949388A (en) * 1987-02-19 1990-08-14 Gtx Corporation Method and apparatus for recognition of graphic symbols
US5144679A (en) * 1987-06-29 1992-09-01 Hitachi, Ltd Graphic data searching and storage method
JP2786294B2 (en) * 1990-02-19 1998-08-13 株式会社日立製作所 Graphic data inspection and storage method
US5097411A (en) * 1987-08-13 1992-03-17 Digital Equipment Corporation Graphics workstation for creating graphics data structure which are stored retrieved and displayed by a graphics subsystem for competing programs
JP2811445B2 (en) * 1988-03-22 1998-10-15 パイオニア株式会社 Recording method and reproduction method of image information
JP3607107B2 (en) * 1998-03-13 2005-01-05 株式会社東芝 Data management device
US7015917B2 (en) * 2003-07-18 2006-03-21 Matsushita Electric Industrial Co., Ltd. Curved surface subdivision apparatus
US9081681B1 (en) * 2003-12-19 2015-07-14 Nvidia Corporation Method and system for implementing compressed normal maps
US8078656B1 (en) 2004-11-16 2011-12-13 Nvidia Corporation Data decompression with extra precision
US7961195B1 (en) 2004-11-16 2011-06-14 Nvidia Corporation Two component texture map compression
US7928988B1 (en) 2004-11-19 2011-04-19 Nvidia Corporation Method and system for texture block swapping memory management
US7916149B1 (en) * 2005-01-04 2011-03-29 Nvidia Corporation Block linear memory ordering of texture data
US8594441B1 (en) 2006-09-12 2013-11-26 Nvidia Corporation Compressing image-based data using luminance
US8724895B2 (en) * 2007-07-23 2014-05-13 Nvidia Corporation Techniques for reducing color artifacts in digital images
US8373718B2 (en) * 2008-12-10 2013-02-12 Nvidia Corporation Method and system for color enhancement with color volume adjustment and variable shift along luminance axis
US8610732B2 (en) * 2008-12-11 2013-12-17 Nvidia Corporation System and method for video memory usage for general system application

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS58117077A (en) * 1981-12-31 1983-07-12 Fujitsu Ltd Diagram data retrieval system in diagram processing
JPS6280766A (en) * 1985-10-04 1987-04-14 Oki Electric Ind Co Ltd Graphic data retrieving device

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
NL8300872A (en) * 1983-03-10 1984-10-01 Philips Nv MULTIPROCESSOR CALCULATOR SYSTEM FOR PROCESSING A COLORED IMAGE OF OBJECT ELEMENTS DEFINED IN A HIERARCHICAL DATA STRUCTURE.
GB2130855B (en) * 1982-11-03 1986-06-04 Ferranti Plc Information display system
JPS59218493A (en) * 1983-05-25 1984-12-08 シャープ株式会社 Graphic display information memory system
US4742558A (en) * 1984-02-14 1988-05-03 Nippon Telegraph & Telephone Public Corporation Image information retrieval/display apparatus
US4660029A (en) * 1984-07-06 1987-04-21 Tektronix, Inc. Method of providing raster information for a graphics display employing linked lists
US4760390A (en) * 1985-02-25 1988-07-26 Computer Graphics Laboratories, Inc. Graphics display system and method with enhanced instruction data and processing
US4731606A (en) * 1985-08-02 1988-03-15 International Business Machines Corporation Method for rapid windowing of display information in computer graphics
US4692880A (en) * 1985-11-15 1987-09-08 General Electric Company Memory efficient cell texturing for advanced video object generator

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS58117077A (en) * 1981-12-31 1983-07-12 Fujitsu Ltd Diagram data retrieval system in diagram processing
JPS6280766A (en) * 1985-10-04 1987-04-14 Oki Electric Ind Co Ltd Graphic data retrieving device

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH02188883A (en) * 1989-01-17 1990-07-24 Mitsubishi Electric Corp Graphic display method
JPH03260880A (en) * 1990-03-12 1991-11-20 Mitsubishi Electric Corp Graphic display method
JP2543425B2 (en) * 1990-03-12 1996-10-16 三菱電機株式会社 Figure display method
JPH03263272A (en) * 1990-03-14 1991-11-22 Fujitsu Ltd Graphic retrieving system
JPH075308U (en) * 1993-06-24 1995-01-27 新興和産業株式会社 Self-propelled work trolley

Also Published As

Publication number Publication date
DE3643585A1 (en) 1987-07-16
US4803477A (en) 1989-02-07

Similar Documents

Publication Publication Date Title
JPS62145369A (en) Graphic data retrieving method
US6195664B1 (en) Method and system for controlling the conversion of a file from an input format to an output format
US5249265A (en) Structure storage management in a graphics display device
ES2214535T3 (en) PROCEDURE AND PORTABLE SYSTEM FOR INDEXING DOCUMENTS USING THE DECOMPOSITION OF WORDS IN N-GRAMS.
CN108090150B (en) GIS space object storage method and system
AU2018204393B2 (en) Graphically representing content relationships on a surface of graphical object
JPS6354659A (en) Editorial method in display of tree
US5345544A (en) Data base system
JP2686758B2 (en) Graphic editing device
Lin et al. Database-oriented storage based on LMDB and linear octree for massive block model
CN115796111A (en) File processing method suitable for agf, computer equipment and readable storage medium
JP2001014338A (en) Method and system for graphic data management, and storage medium
JPS58117077A (en) Diagram data retrieval system in diagram processing
JP2786294B2 (en) Graphic data inspection and storage method
CN113220945B (en) Method and system for field retrieval and path display of data blood edges
JP2940567B2 (en) Image database system
JPH04112253A (en) Data accessing method using multilayer buffer
JPS62121532A (en) Data retrieving method
JPS5853641Y2 (en) Product handling system
JPH0128979B2 (en)
JPH03194656A (en) Cad device
JPH05159001A (en) Retrieval device for graphic information
JPS6217850A (en) Information processor
Zhang Purchase from www. A-PDF. com to remove the watermark
JPH06231152A (en) Method for processing business slip