KR102447747B1 - Image processing apparatus and method - Google Patents
Image processing apparatus and method Download PDFInfo
- Publication number
- KR102447747B1 KR102447747B1 KR1020220030253A KR20220030253A KR102447747B1 KR 102447747 B1 KR102447747 B1 KR 102447747B1 KR 1020220030253 A KR1020220030253 A KR 1020220030253A KR 20220030253 A KR20220030253 A KR 20220030253A KR 102447747 B1 KR102447747 B1 KR 102447747B1
- Authority
- KR
- South Korea
- Prior art keywords
- polygon
- area
- pixel
- map
- adjacent
- Prior art date
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T11/00—2D [Two Dimensional] image generation
- G06T11/60—Editing figures and text; Combining figures or text
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/11—Region-based segmentation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/136—Segmentation; Edge detection involving thresholding
Abstract
Description
본 발명은 이미지 처리 장치 및 방법에 관한 것으로, 보다 상세하게는 이미지내에서 폴리곤들을 검출하고 검출된 폴리곤들을 병합할 수 있는 장치 및 방법에 관한 것이다.The present invention relates to an image processing apparatus and method, and more particularly, to an apparatus and method capable of detecting polygons in an image and merging the detected polygons.
이미지를 채색한다는 것은 이미지 내의 각 픽셀들에 색상 값을 부여하는 것을 의미한다. 한편, 이미지 내에 형상들이 있는 경우 해당 형상을 동일한 색으로 채색할 수 있다. 이를 위해, 각 형상에 대응하는 폴리곤들을 검출하고, 검출된 폴리곤들 각각을 채색한다.Coloring an image means assigning a color value to each pixel in the image. On the other hand, if there are shapes in the image, the corresponding shapes may be colored with the same color. To this end, polygons corresponding to each shape are detected, and each of the detected polygons is colored.
한편, 이러한 폴리곤을 검출하는 종래의 방법으로서, 도 1에서와 같이 트랩 볼(trapped ball)이라고 하는 소정 사이즈의 볼(5)을 이용하는 방식이 있다. 구체적으로, 볼(5)을 이미지 상에서 굴려가며 볼(5)이 굴려지는 영역 단위 별로 하나의 폴리곤으로서 검출한다. 예를 들어, 영역 1의 경우 볼(5)을 굴려보면 도 1의 우측 그림과 같이 볼(5)이 굴러갈 수 있는 영역 2와 볼(5)이 굴러갈 수 없는 영역 3으로 나뉘어지게 된다. 그에 따라, 영역 2와 영역 3은 동일한 영역으로 하나의 폴리곤으로서 검출되는 것이 바람직하나 볼(5)의 크기 한계상 별도의 폴리곤으로 검출된다.On the other hand, as a conventional method for detecting such a polygon, there is a method using a
폴리곤 각각에 대해 채색 처리가 이루어지므로, 효율적인 채색을 위해서는 위와 같이 동일한 영역에 대응하는 다수의 폴리곤들을 병합하는 과정이 필요하다. 즉, 도 1의 경우 폴리곤(2) 및 폴리곤(3)을 하나의 폴리곤으로 병합하여 채색을 진행하는 것이 효율적이다.Since color processing is performed for each polygon, a process of merging a plurality of polygons corresponding to the same area as above is required for efficient coloring. That is, in the case of FIG. 1 , it is efficient to merge the
종래의 경우, 병합 대상 폴리곤(예컨대, 영역 2의 제 2 폴리곤(2))을 선택하고 선택된 병합 대상 폴리곤의 경계점을 추출한 후에, 병합 대상 폴리곤의 경계점(즉, 경계 픽셀)을 포함하는 다른 폴리곤을 검출한다. 도 2의 경우, 영역 3의 제 3 폴리곤(3)이 병합 대상 폴리곤(2)의 경계점을 포함하는 다른 폴리곤으로 검출될 것이다. 검출된 인접한 다른 폴리곤을 병합 대상 폴리곤에 병합한다. In the conventional case, after selecting a polygon to be merged (eg, the
그러나, 종래의 폴리곤 병합 알고리즘은 모든 폴리곤 각각에 대해 인접한 폴리곤을 검출하여 병합하는 방식이므로, 이미지가 복잡할수록 폴리곤 개수가 많아져 폴리곤 병합 알고리즘 작동에 소요되는 시간이 증가하는 문제가 있다. However, since the conventional polygon merging algorithm detects and merges adjacent polygons for each polygon, as the image becomes more complex, the number of polygons increases, which increases the time required to operate the polygon merging algorithm.
이상의 배경기술에 기재된 사항은 발명의 배경에 대한 이해를 돕기 위한 것으로서, 공개된 종래 기술이 아닌 사항을 포함할 수 있다.The matters described in the background art above are intended to help the understanding of the background of the invention, and may include matters that are not disclosed prior art.
본 발명은 상기한 종래의 사정을 감안하여 제안된 것으로, 이미지내에 존재하는 폴리곤들을 빠르게 병합할 수 있는 이미지 처리 장치 및 방법을 제공함에 그 목적이 있다.The present invention has been proposed in view of the above-described conventional circumstances, and an object of the present invention is to provide an image processing apparatus and method capable of quickly merging polygons existing in an image.
상기와 같은 목적을 달성하기 위하여 본 발명의 바람직한 실시양태에 따른 이미지 처리 장치는, 이미지의 각 픽셀이 속하는 폴리곤 영역에 대한 정보를 포함하는 영역 맵을 미리 저장하고 있는 저장부; 및 연산 처리 기능을 갖는 프로세서;를 포함하고, 상기 프로세서는 상기 저장부에 저장된 명령들을 로드함으로써, 상기 이미지에 포함된 복수의 폴리곤 영역들 사이의 인접 관계를 나타내는 인접 계수를 포함하는 인접관계 매트릭스를 생성하되, 상기 이미지의 픽셀들 중 제 1 픽셀이 속한 제 1 폴리곤 영역과 상기 제 1 픽셀에 인접한 제 2 픽셀이 속한 제 2 폴리곤 영역을 서로 비교하고, 비교 결과에 따라 상기 제 1 폴리곤 영역과 상기 제 2 폴리곤 영역 사이의 인접 계수를 계산하고, 상기 계산된 인접 계수를 이용하여 상기 인접관계 매트릭스를 생성하고, 상기 인접관계 매트릭스의 생성이 완료됨에 따라 상기 생성완료된 인접관계 매트릭스를 근거로 폴리곤 영역들을 병합하여 폴리곤 영역이 병합된 영역 맵을 출력한다.In order to achieve the above object, an image processing apparatus according to a preferred embodiment of the present invention includes: a storage unit which stores in advance a region map including information on a polygon region to which each pixel of an image belongs; and a processor having an arithmetic processing function, wherein the processor loads the instructions stored in the storage unit, thereby generating an adjacency matrix including an adjacency coefficient representing the adjacency relationship between a plurality of polygon regions included in the image. and comparing the first polygon area to which a first pixel of the pixels of the image belongs and a second polygon area to which a second pixel adjacent to the first pixel belongs, and according to a result of the comparison, the first polygon area and the The adjacency coefficient between the second polygon regions is calculated, the adjacency matrix is generated using the calculated adjacency coefficient, and as the generation of the adjacency matrix is completed, polygon regions are divided based on the generated adjacency matrix. Outputs an area map in which the polygon area is merged by merging.
상기 프로세서는, 상기 제 1 폴리곤 영역과 상기 제 2 폴리곤 영역을 서로 비교하고, 비교 결과에 따라 상기 제 1 폴리곤 영역과 상기 제 2 폴리곤 영역이 서로 다른 영역인지를 판단하고, 상기 제 1 폴리곤 영역과 상기 제 2 폴리곤 영역이 서로 다르면 이에 응답하여 카운트 값을 생성하고, 생성된 카운트 값에 기초하여 상기 인접 계수를 계산할 수 있다.The processor compares the first polygon area and the second polygon area with each other, and determines whether the first polygon area and the second polygon area are different from each other according to a result of the comparison, and the first polygon area and the second polygon area If the second polygon regions are different from each other, a count value may be generated in response thereto, and the adjacency coefficient may be calculated based on the generated count value.
상기 프로세서는, 상기 제 1 픽셀이 속한 제 1 폴리곤 영역과 상기 제 1 픽셀에 인접한 제 2 픽셀이 속한 제 2 폴리곤 영역의 비교가 종료되면, 상기 제 1 픽셀의 오른쪽에 인접한 픽셀을 상기 제 1 픽셀로 갱신하고, 갱신된 제 1 픽셀의 오른쪽에 인접한 픽셀 및 아래에 인접한 픽셀을 상기 제 2 픽셀로서 설정하여 비교를 반복할 수 있다.When the comparison of the first polygon area to which the first pixel belongs and the second polygon area to which the second pixel adjacent to the first pixel belongs is finished, the processor is configured to select a pixel adjacent to the right of the first pixel as the first pixel , and a pixel adjacent to the right of the updated first pixel and a pixel adjacent to the bottom of the updated first pixel are set as the second pixel to repeat the comparison.
상기 프로세서는, 상기 제 1 폴리곤 영역과 다른 것으로 판단된 상기 제 2 폴리곤 영역에 속한 상기 제 2 픽셀들의 개수에 기초하여 상기 카운트 값을 계산할 수 있다.The processor may calculate the count value based on the number of the second pixels belonging to the second polygon area determined to be different from the first polygon area.
본 발명의 바람직한 실시양태는, 상기 저장부는 인접한 서로 다른 두 개의 폴리곤 영역간의 병합을 위한 병합조건을 더 저장할 수 있고, 상기 프로세서는 상기 병합조건을 이용하여 폴리곤 영역들을 병합할 수 있다.In a preferred embodiment of the present invention, the storage unit may further store a merging condition for merging between two adjacent polygonal regions, and the processor may merge the polygonal regions using the merging condition.
상기 병합조건은, 상기 인접한 서로 다른 두 개의 폴리곤 영역간의 병합이 이루어질 기준값이 되는 임계치에 대한 정보를 포함할 수 있다.The merging condition may include information on a threshold value serving as a reference value for merging between the two adjacent polygon regions.
상기 프로세서는, 상기 인접한 서로 다른 두 개의 폴리곤 영역에 대응하는 인접 계수와 상기 임계치를 비교하고, 비교 결과에 따라 인접 계수가 임계치를 초과하면 상기 인접한 서로 다른 두 개의 폴리곤 영역을 병합할 수 있다.The processor may compare the adjacent coefficients corresponding to the two different adjacent polygonal areas with the threshold, and if the adjacent coefficients exceed the threshold according to the comparison result, the two adjacent different polygonal areas may be merged.
상기 병합조건은 폴리곤 영역의 크기를 추가로 포함하고, 상기 프로세서는, 상기 인접한 서로 다른 두 개의 폴리곤 영역을 병합할 때 상기 폴리곤 영역의 크기에 근거하여 보다 큰 폴리곤 영역으로 병합시킬 수 있다.The merging condition may further include a size of the polygon area, and the processor may merge the two adjacent polygon areas into a larger polygon area based on the size of the polygon area when merging the two adjacent polygon areas.
상기 프로세서는, 상기 인접관계 매트릭스의 생성이 완료됨에 따라 상기 생성완료된 인접관계 매트릭스를 근거로 병합할 폴리곤 영역을 나타내는 병합 맵을 생성하고, 상기 병합 맵의 생성이 완료됨에 따라 상기 생성완료된 병합 맵을 상기 영역 맵에 적용하여 인접한 서로 다른 두 개의 폴리곤 영역이 병합된 영역 맵을 생성할 수 있다.The processor generates a merge map indicating a polygon area to be merged based on the generated adjacency matrix as the generation of the adjacency matrix is completed, and generates the generated merge map as the generation of the merge map is completed. By applying to the area map, an area map in which two adjacent polygon areas are merged may be generated.
본 발명의 바람직한 실시양태는, 상기 영역 맵을 수신하는 통신부;를 추가로 포함하되, 상기 통신부는 수신한 영역 맵을 상기 프로세서에게로 보낸 후에 영역 맵 전송완료신호를 상기 프로세서에게로 보내고, 상기 프로세서는 상기 영역 맵을 수신완료함에 따른 영역 맵 수신완료신호를 액크(ACK)신호로서 상기 통신부에 보낸 후에 상기 영역 맵을 상기 저장부에 저장시킬 수 있다.A preferred embodiment of the present invention further comprises a communication unit for receiving the area map, wherein the communication unit sends an area map transmission completion signal to the processor after sending the received area map to the processor, and the processor may store the area map in the storage unit after sending the area map reception completion signal according to the reception completion of the area map as an ACK signal to the communication unit.
한편, 본 발명의 바람직한 실시양태에 따른 이미지 처리 방법은, 저장부 및 프로세서를 포함하는 이미지 처리 장치에서 수행되는 방법으로서, 상기 저장부가, 이미지의 각 픽셀이 속하는 폴리곤 영역에 대한 정보를 포함하는 영역 맵을 미리 저장하는 단계; 상기 프로세서가, 상기 이미지에 포함된 복수의 폴리곤 영역들 사이의 인접 관계를 나타내는 인접 계수를 포함하는 인접관계 매트릭스를 생성하되, 상기 이미지의 픽셀들 중 제 1 픽셀이 속한 제 1 폴리곤 영역과 상기 제 1 픽셀에 인접한 제 2 픽셀이 속한 제 2 폴리곤 영역을 서로 비교하고, 비교 결과에 따라 상기 제 1 폴리곤 영역과 상기 제 2 폴리곤 영역 사이의 인접 계수를 계산하고, 상기 계산된 인접 계수를 이용하여 상기 인접관계 매트릭스를 생성하는 단계; 및 상기 프로세서가, 상기 인접관계 매트릭스의 생성이 완료됨에 따라 상기 생성완료된 인접관계 매트릭스를 근거로 폴리곤 영역들을 병합하여 폴리곤 영역이 병합된 영역 맵을 출력하는 단계;를 포함한다.Meanwhile, the image processing method according to a preferred embodiment of the present invention is a method performed in an image processing apparatus including a storage unit and a processor, wherein the storage unit includes an area including information on a polygon area to which each pixel of an image belongs. pre-saving the map; wherein the processor generates an adjacency matrix including an adjacency coefficient representing an adjacency relationship between a plurality of polygon regions included in the image, wherein a first polygon region to which a first pixel of the pixels of the image belongs and the first polygon region A second polygon area to which a second pixel adjacent to one pixel belongs is compared with each other, and an adjacency coefficient between the first polygon area and the second polygon area is calculated according to a result of the comparison, and using the calculated adjacency coefficient, the generating an adjacency matrix; and outputting, by the processor, a polygonal area merged area map by merging polygon areas based on the generated adjacency matrix as the generation of the adjacency matrix is completed.
이러한 구성의 본 발명에 따르면, 래스터 스캔 한번으로 영역 맵에 대하여 인접한 서로 다른 두 개의 폴리곤 영역에 대한 인접관계 매트릭스를 생성하고 갱신할 수 있고, 인접관계 매트릭스의 비제로(nonzero) 성분을 근거로 병합 맵을 생성한 후에 영역 맵에 병합 맵을 적용시켜서 인접한 서로 다른 두 개의 폴리곤 영역을 병합시킬 수 있다.According to the present invention having such a configuration, it is possible to create and update an adjacency matrix for two different polygon regions adjacent to a region map with one raster scan, and merge based on the nonzero component of the adjacency matrix. After creating the map, you can merge two different polygonal areas adjacent to each other by applying the merge map to the area map.
이로 인해, 기존의 폴리곤 병합 방식에 비해 훨씬 빠르게 폴리곤 병합을 행할 수 있다. For this reason, polygon merging can be performed much faster than the existing polygon merging method.
도 1은 일반적인 이미지 에디팅 소프트웨어 설명을 위한 도면이다.
도 2는 종래의 폴리곤 병합 설명에 채용되는 도면이다.
도 3은 본 발명의 실시예에 따른 이미지 처리 장치의 구성도이다.
도 4는 도 3에 도시된 제어부의 내부 구성도이다.
도 5 및 도 6은 영역 맵의 예들이다.
도 7은 도 4에 도시된 인접관계 매트릭스 생성부에서 생성되는 인접관계 매트릭스의 일 예를 나타낸 도면이다.
도 8은 본 발명의 실시예에 따른 이미지 처리 방법을 설명하기 위한 플로우차트이다.1 is a diagram for explaining general image editing software.
2 is a diagram employed in the conventional polygon merging description.
3 is a block diagram of an image processing apparatus according to an embodiment of the present invention.
FIG. 4 is an internal configuration diagram of the control unit shown in FIG. 3 .
5 and 6 are examples of area maps.
FIG. 7 is a diagram illustrating an example of an adjacency matrix generated by the adjacency matrix generator shown in FIG. 4 .
8 is a flowchart illustrating an image processing method according to an embodiment of the present invention.
본 발명은 다양한 변경을 가할 수 있고 여러 가지 실시예를 가질 수 있는 바, 특정 실시 예들을 도면에 예시하고 상세하게 설명하고자 한다.Since the present invention can have various changes and can have various embodiments, specific embodiments are illustrated in the drawings and described in detail.
그러나, 이는 본 발명을 특정한 실시 형태에 대해 한정하려는 것이 아니며, 본 발명의 사상 및 기술 범위에 포함되는 모든 변경, 균등물 내지 대체물을 포함하는 것으로 이해되어야 한다.However, this is not intended to limit the present invention to specific embodiments, and should be understood to include all modifications, equivalents and substitutes included in the spirit and scope of the present invention.
본 출원에서 사용한 용어는 단지 특정한 실시예를 설명하기 위해 사용된 것으로, 본 발명을 한정하려는 의도가 아니다. 단수의 표현은 문맥상 명백하게 다르게 뜻하지 않는 한, 복수의 표현을 포함한다. 본 출원에서, "포함하다" 또는 "가지다" 등의 용어는 명세서상에 기재된 특징, 숫자, 단계, 동작, 구성요소, 부품 또는 이들을 조합한 것이 존재함을 지정하려는 것이지, 하나 또는 그 이상의 다른 특징들이나 숫자, 단계, 동작, 구성요소, 부품 또는 이들을 조합한 것들의 존재 또는 부가 가능성을 미리 배제하지 않는 것으로 이해되어야 한다.The terms used in the present application are only used to describe specific embodiments, and are not intended to limit the present invention. The singular expression includes the plural expression unless the context clearly dictates otherwise. In the present application, terms such as “comprise” or “have” are intended to designate that a feature, number, step, operation, component, part, or combination thereof described in the specification exists, but one or more other features It is to be understood that this does not preclude the possibility of the presence or addition of numbers, steps, operations, components, parts, or combinations thereof.
다르게 정의되지 않는 한, 기술적이거나 과학적인 용어를 포함해서 여기서 사용되는 모든 용어들은 본 발명이 속하는 기술 분야에서 통상의 지식을 가진 자에 의해 일반적으로 이해되는 것과 동일한 의미를 가지고 있다. 일반적으로 사용되는 사전에 정의되어 있는 것과 같은 용어들은 관련 기술의 문맥상 가지는 의미와 일치하는 의미를 가진 것으로 해석되어야 하며, 본 출원에서 명백하게 정의하지 않는 한, 이상적이거나 과도하게 형식적인 의미로 해석되지 않는다.Unless defined otherwise, all terms used herein, including technical or scientific terms, have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. Terms such as those defined in commonly used dictionaries should be interpreted as having a meaning consistent with the meaning in the context of the related art, and should not be interpreted in an ideal or excessively formal meaning unless explicitly defined in the present application. does not
이하, 첨부한 도면들을 참조하여, 본 발명의 바람직한 실시예를 보다 상세하게 설명하고자 한다. 본 발명을 설명함에 있어 전체적인 이해를 용이하게 하기 위하여 도면상의 동일한 구성요소에 대해서는 동일한 참조부호를 사용하고 동일한 구성요소에 대해서 중복된 설명은 생략한다. Hereinafter, preferred embodiments of the present invention will be described in more detail with reference to the accompanying drawings. In describing the present invention, in order to facilitate the overall understanding, the same reference numerals are used for the same components in the drawings, and duplicate descriptions of the same components are omitted.
도 3은 본 발명의 실시예에 따른 이미지 처리 장치의 구성도이다.3 is a block diagram of an image processing apparatus according to an embodiment of the present invention.
본 발명의 실시예에 따른 이미지 처리 장치(100)는 통신부(10), 저장부(20), 및 제어부(30)를 포함할 수 있다. 필요에 따라, 통신부(10)와 저장부(20) 및 제어부(30)는 통신모듈과 저장모듈 및 제어모듈이라고도 칭할 수 있다.The
통신부(10)는 사용자 단말(도시 생략)과 같은 외부 장치로부터 영역 맵(region map)을 수신할 수 있다. 여기서, 통신부(10)가 수신하는 영역 맵은 이미지의 각 픽셀의 값을 포함한다. 이미지의 각 픽셀의 값은 해당 픽셀을 포함하는 영역 아이디(region id)를 의미할 수 있다. 이때, 영역 아이디는 폴리곤 영역 아이디라고 할 수 있다. 통신부(10)에 수신되는 영역 맵은 폴리곤 병합 이전의 영역 맵이라고 할 수 있다.The
즉, 통신부(10)는 외부 장치로부터의 영역 맵 전송 신호에 응답하여 외부 장치로부터의 영역 맵을 수신하고, 영역 맵의 수신이 완료됨에 따른 영역 맵 수신 완료신호를 출력할 수 있다. 보다 구체적으로는, 통신부(10)는 외부 장치로부터의 영역 맵 전송 신호를 수신하게 되면 그에 응답하여 영역 맵 수신 가능 신호를 액크(ACK)신호로서 외부 장치에게로 보낸다. 그에 따라, 액크신호에 반응하여 외부 장치가 소정의 영역 맵을 통신부(10)에게로 전송하고 나서 영역 맵 전송완료신호를 보낸다. 이로 인해, 통신부(10)는 소정의 영역 맵을 수신완료함에 따른 영역 맵 수신완료신호를 액크(ACK)신호로서 외부 장치에게로 보낼 수 있다.That is, the
그리고, 통신부(10)는 수신된 영역 맵을 제어부(30)에게로 보내어 제어부(30)가 영역 맵을 저장부(20)에 저장시킬 수 있도록 한다. 이 경우, 통신부(10)는 수신한 영역 맵을 제어부(30)에게로 보낸 후에 영역 맵 전송완료신호를 제어부(30)에게로 보낼 것이다. 그리하면 제어부(30)는 영역 맵을 수신완료함에 따른 영역 맵 수신완료신호를 액크(ACK)신호로서 통신부(10)에 보낸 후에 영역 맵을 저장부(20)에 저장시킬 수 있다.Then, the
필요에 따라, 통신부(10)는 영역 맵 대신에 소정의 스케치 이미지를 수신할 수도 있다. If necessary, the
상술한 사용자 단말은 연산 처리 기능을 갖는 컴퓨팅 장치로서, 이동형 장치이거나 또는 고정형 장치일 수 있다. 예컨대, 외부 장치는 컴퓨터, PC(personal computer), 스마트폰, 네비게이션, 랩톱 컴퓨터, 태블릿 컴퓨터, 웨어러블 장치 또는 태블릿 등을 의미할 수 있으나, 본 발명의 실시 예들이 이에 한정되는 것은 아니다.The user terminal described above is a computing device having an arithmetic processing function, and may be a mobile device or a fixed device. For example, the external device may mean a computer, a personal computer (PC), a smart phone, a navigation system, a laptop computer, a tablet computer, a wearable device, or a tablet, but embodiments of the present invention are not limited thereto.
통신부(10)는 무선 통신 방식의 네트워크 또는 유선 통신 방식의 네트워크에 따라 외부 장치와 통신을 수행하되, 폴리곤 병합된 영역 맵을 외부 장치에게로 보낼 수 있다.The
예를 들어, 무선 통신 방식의 네트워크는 무선랜(Wireless LAN (WLAN)), 와이브로(Wireless Broadband (Wibro)), WCDMA(Wideband CDMA), IEEE 802.16, 롱 텀 에볼루션(Long Term Evolution (LTE)), LTE-A(Long Term Evolution-Advanced), 블루투스(Bluetooth), RFID(Radio Frequency Identification), 적외선 통신(Infrared Data Association: IrDA), UWB(Ultra-Wideband), 지그비(ZigBee), 인접 자장 통신(Near Field Communication (NFC)), 초음파 통신(Ultra Sound Communication (USC)), 가시광 통신(Visible Light Communication (VLC)), 와이 파이(Wi-Fi) 등을 포함할 수 있으나, 이에 한정되는 것은 아니다.For example, a wireless communication type network includes a wireless LAN (WLAN), a wireless broadband (Wibro), a wideband CDMA (WCDMA), an IEEE 802.16, a long term evolution (LTE), LTE-A (Long Term Evolution-Advanced), Bluetooth (Bluetooth), RFID (Radio Frequency Identification), Infrared Data Association (IrDA), UWB (Ultra-Wideband), ZigBee, Near Field Communication (Near) Field Communication (NFC)), ultrasonic communication (Ultra Sound Communication (USC)), visible light communication (VLC), Wi-Fi (Wi-Fi), and the like may be included, but are not limited thereto.
한편, 유선 통신 방식의 네트워크는 유선 LAN(Local Area Network), 유선 WAN(Wide Area Network), 전력선 통신(Power Line Communication (PLC)), USB 통신, 이더넷(Ethernet), 시리얼 통신(serial communication), 광/동축 케이블 통신 등을 포함할 수 있으나, 이에 한정되는 것은 아니다.On the other hand, wired communication type networks include wired LAN (Local Area Network), wired WAN (Wide Area Network), Power Line Communication (PLC), USB communication, Ethernet, serial communication, It may include, but is not limited to, optical/coaxial cable communication.
저장부(20)는 장치(100)의 동작에 필요한 데이터를 저장할 수 있다. 실시 예들에 따라, 저장부(20)는 통신부(10)에서 수신한 영역 맵(즉, 폴리곤 병합 이전의 영역 맵)을 저장할 수 있고, 장치(100)에서의 처리동작에 의해 생성된 폴리곤 병합된 영역 맵을 저장할 수 있다.The
또한, 저장부(20)는 인접한 서로 다른 두 개의 폴리곤 영역간의 병합을 위한 병합조건을 미리 저장할 수 있다. 여기서, 병합조건은 인접한 서로 다른 두 개의 폴리곤 영역간의 병합이 이루어질 기준값이 되는 임계치에 대한 정보를 포함할 수 있다. 또한, 병합조건은 인접한 서로 다른 두 개의 폴리곤 영역을 병합할 때 보다 큰 폴리곤 영역으로 병합시킬 수 있도록 하는 폴리곤 영역의 크기를 더 포함할 수 있다.Also, the
또한, 저장부(20)는 장치(100)에 의해 수행되는 일련의 동작들을 수행하기 위한 명령어(instruction)들로 구성되는 프로그램을 저장할 수 있다.Also, the
저장부(20)는 비휘발성 메모리 장치 또는 휘발성 메모리 장치를 포함할 수 있다. 실시 예들에 따라, 저장부(20)는 제어부(30)에 포함되어 구성될 수 있으나, 이에 한정되는 것은 아니다.The
제어부(30)는 장치(100)의 전반적인 동작들을 제어할 수 있다.The
예를 들어, 제어부(30)는 통신부(10)를 통해 수신한 영역 맵을 저장부(20)에 저장할 수 있다. 즉, 제어부(30)는 통신부(10)로부터의 영역 맵 수신 완료신호에 응답하여 해당 영역 맵을 저장부(20)에 저장할 수 있다.For example, the
만약, 통신부(10)에서 영역 맵이 아니라 소정의 이미지(예컨대, 스케치 이미지)를 수신한 경우, 제어부(30)는 해당 이미지를 기반으로 폴리곤을 생성(추출)하고 폴리곤을 근거로 영역 맵(예컨대, 폴리곤 병합 이전의 영역 맵)을 생성할 수도 있다. If the
또한, 제어부(30)는 저장된 영역 맵을 리드하여 폴리곤 병합을 위한 신호처리를 행함으로써 폴리곤 병합된 영역 맵을 생성하여 출력할 수 있다.Also, the
제어부(30)는 장치(100)의 동작을 위한 일련의 연산들 또는 판단들을 수행할 수 있는 장치를 의미할 수 있다. 예를 들어, 제어부(30)는 CPU(central processing unit), MCU(micro controller unit), GPU(graphical processing unit), ASIC(application specific integrated circuit), 또는 FPGA(field programmable gate array)일 수 있으나, 이에 한정되는 것은 아니다.The
다시 말해서, 제어부(30)는 연산 처리 기능을 갖는 적어도 하나의 프로세서를 포함한다. 제어부(30)는 장치(100)에서 수행되는 동작들을 제어할 수 있으며, 소정 동작(예컨대, 본 발명에서의 이미지 처리 동작; 폴리곤 병합 동작이라고 할 수 있음)이 수행되도록 장치(100)내에 포함되는 다른 구성들을 제어할 수 있다. 구체적으로, 제어부(30)에 포함되는 프로세서는 내부적으로 포함될 수 있는 저장부(20)에 저장되어 있는 적어도 하나의 인스트럭션을 실행시켜서, 소정 동작(예컨대, 본 발명에서의 이미지 처리 동작)이 수행되도록 제어할 수 있다.In other words, the
또한, 본 발명의 실시예에서는 제어부(30)에 포함되는 적어도 하나의 프로세서가 장치(100)에서 수행되는 동작들을 제어할 수 있으며 소정 동작이 수행되도록 장치(100) 내에 포함되는 다른 구성들을 제어할 수 있다. 따라서, 제어부(30)가 소정 동작(예컨대, 본 발명에서의 이미지 처리 동작)이 수행되도록 제어하는 경우를 예로 들어 설명하더라도, 제어부(30)에 포함되는 적어도 하나의 프로세서가 소정 동작(예컨대, 본 발명에서의 이미지 처리 동작)이 수행되도록 제어할 수 있음은 자명하다 할 것이다.In addition, in an embodiment of the present invention, at least one processor included in the
도 4는 도 3에 도시된 제어부의 내부 구성도이고, 도 5 및 도 6은 영역 맵의 예들이고, 도 7은 도 4에 도시된 인접관계 매트릭스 생성부에서 생성되는 인접관계 매트릭스의 일 예를 나타낸 도면이다.4 is an internal configuration diagram of the control unit shown in FIG. 3 , FIGS. 5 and 6 are examples of area maps, and FIG. 7 is an example of an adjacency matrix generated by the adjacency matrix generator shown in FIG. 4 . the drawing shown.
제어부(30)는 폴리곤 생성부(31), 영역 맵 생성부(32), 인접관계 매트릭스 생성부(33), 병합조건 설정부(34), 병합 맵 생성부(35), 및 병합부(36)를 포함할 수 있다. 필요에 따라, 폴리곤 생성부(31)와 영역 맵 생성부(32)와 인접관계 매트릭스 생성부(33)와 병합조건 설정부(34)와 병합 맵 생성부(35) 및 병합부(36)는 폴리곤 생성모듈과 영역 맵 생성모듈과 인접관계 매트릭스 생성모듈과 병합조건 설정모듈과 병합 맵 생성모듈 및 병합모듈이라고도 칭할 수 있다.The
폴리곤 생성부(31)는 통신부(100)에서 소정의 이미지(예컨대, 스케치 이미지)를 수신한 경우, 해당 이미지를 기반으로 폴리곤을 생성(추출)할 수 있다. 여기서, 폴리곤은 이미지내의 영역들 각각을 분류(classification)함에 따라 생성될 수 있다. 생성된 폴리곤 각각에는 하나 이상의 픽셀이 포함될 수 있는데, 이때 하나 이상의 픽셀은 해당하는 영역 아이디값을 가질 수 있다. When a predetermined image (eg, a sketch image) is received from the
폴리곤 생성부(31)는 폴리곤 생성이 종료됨에 따라 폴리곤 전송신호와 함께 폴리곤을 영역 맵 생성부(32)에게로 전송한다.The
영역 맵 생성부(32)는 폴리곤을 수신함에 따라 그에 상응하는 폴리곤 수신완료신호를 생성하여 폴리곤 생성부(31)에게로 보낸다.As the
영역 맵 생성부(32)는 수신한 폴리곤을 근거로 영역 맵(예컨대, 폴리곤 병합 이전의 영역 맵)을 생성할 수 있다. The
예를 들면, 통신부(10)에 수신되거나 영역 맵 생성부(32)에 의해 생성되는 영역 맵은 도 5에서와 같은 형태일 수 있다. 영역 맵은 각 픽셀별로 해당하는 영역 아이디(폴리곤 영역 아이디라고도 할 수 있음)를 포함할 수 있다. 도 5에는 픽셀별 영역 아이디 이외로 각각의 영역의 폴리곤을 표시하였는데, 이는 이해를 돕기 위한 것으로서 실제로는 각각의 영역의 폴리곤은 표시되지 않을 것이다.For example, the area map received by the
만약, 통신부(10)에서 영역 맵을 수신한다면 폴리곤 생성부(31) 및 영역 맵 생성부(32)는 필요없을 것이다.If the
인접관계 매트릭스 생성부(33)는 영역 맵을 전체적으로 래스터 스캔을 하면서 인접한 서로 다른 두 개의 영역(즉, 폴리곤 영역)에 대한 인접관계 매트릭스를 생성하고, 생성된 인접관계 매트릭스를 갱신할 수 있다. 여기서, 인접한 서로 다른 두 개의 영역은 각각 해당 영역의 픽셀에 부여된 값이 서로 다른 두 개의 영역으로서 인접한 두 개의 영역을 의미한다. The
인접관계 매트릭스는 인접한 두 개의 서로 다른 영역(즉, 폴리곤 영역)에 대해 몇 개의 경계 픽셀을 통해 서로 연결되어 있는지를 나타낼 수 있다. The adjacency matrix may indicate how many boundary pixels are connected to each other for two different adjacent regions (ie, polygon regions).
예를 들면, 래스터 스캔을 하는 중에는 인접한 두 개의 서로 다른 폴리곤 영역들이 예컨대, (r_1, r_2), (r_2, r_3), (r_1, r_4), (r_2, r_4)와 같이 여러 개 검출될 수 있다. 이때, 인접한 두 개의 서로 다른 폴리곤 영역(r_1, r_2)에 대한 인접관계 매트릭스(M)는 M[r_1, r_2]로 나타낼 수 있고, 폴리곤 영역(r_1, r_2) 이외의 다른 두 개의 폴리곤 영역들도 이와 같은 방식으로 나타낼 수 있다. 그리고, 인접한 서로 다른 두 개의 영역(예컨대, r_1, r_2; 폴리곤 영역)에 대한 인접관계 매트릭스를 처음 생성할 때에는 M[r_1, r_2]의 초기화(즉, "0(zero)"으로 세팅)하는 것이 필요하다. 물론, 인접한 서로 다른 두 개의 영역(예컨대, r_2, r_3; 폴리곤 영역)이 더 있다면 이들 두 개의 폴리곤 영역(r_2, r_3)에 대한 인접관계 매트릭스를 처음 생성할 때에도 M[r_2, r_3]의 초기화(즉, "0(zero)"으로 세팅)하는 것이 필요하다.For example, during raster scan, two different polygon regions adjacent to each other may be detected in multiple numbers, for example, (r_1, r_2), (r_2, r_3), (r_1, r_4), (r_2, r_4). . At this time, the adjacency matrix M for two different adjacent polygon regions r_1 and r_2 may be expressed as M[r_1, r_2], and the other two polygon regions other than the polygon regions r_1 and r_2 are also It can be expressed in this way. In addition, when initially generating the adjacency matrix for two different adjacent regions (eg, r_1, r_2; polygon region), it is recommended to initialize M[r_1, r_2] (that is, set to “0 (zero)”). need. Of course, if there are two different adjacent regions (e.g., r_2, r_3; polygon region), the initialization of M[r_2, r_3] ( That is, it is necessary to set it to "0 (zero)".
이와 같이 인접관계 매트릭스 생성과 함께, 인접관계 매트릭스 생성부(33)는 상술한 래스터 스캔중에 영역 맵 내의 픽셀들 각각에 대해 해당 픽셀이 속한 영역의 다른 영역(즉, 폴리곤 영역)과의 인접여부를 검출하고, 검출된 결과를 해당 인접관계 매트릭스에 반영할 수 있다. 여기서, 반영이라 함은 검출된 결과로 해당 인접관계 매트릭스의 값을 갱신한다는 의미이다.In this way, together with the generation of the adjacency matrix, the adjacency
다시 말해서, 도 6에서와 같은 영역 맵을 수신하였다고 가정하였을 경우, 인접관계 매트릭스 생성부(33)는 래스터 스캔을 통해 최종적으로 4*4 행렬 형태의 인접관계 매트릭스(M)를 생성할 수 있다. 도 6의 픽셀들의 값은 1,2,3,4 까지 표기되었으므로, 이는 총 4개의 영역(즉, 폴리곤)이 포함되었다고 볼 수 있다. 그에 따라, 인접관계 매트릭스 생성부(33)는 4*4 행렬 형태의 인접관계 매트릭스(M)를 생성할 수 있다.In other words, if it is assumed that the region map as shown in FIG. 6 is received, the
그리고, 인접관계 매트릭스 생성부(33)는 영역 맵 전체에 대해 래스터 스캔 순(raster scan order)으로 스캔해 가면서 영역 맵 내의 픽셀들 각각에 대해 해당 픽셀이 속한 영역의 다른 영역과의 인접여부를 검출하고, 검출결과에 상응하는 인접 계수를 계산하고, 계산된 인접 계수를 이용하여 인접관계 매트릭스(M)를 갱신할 수 있다(도 7 참조). Then, the
다시 말해서, 인접관계 매트릭스 생성부(33)는 이미지에 포함된 복수의 폴리곤 영역들 사이의 인접 관계를 나타내는 인접 계수를 포함하는 인접관계 매트릭스를 생성하되, 이미지의 픽셀들 중 제 1 픽셀이 속한 제 1 폴리곤 영역과 제 1 픽셀에 인접한 제 2 픽셀이 속한 제 2 폴리곤 영역을 서로 비교하고, 비교 결과에 따라 제 1 폴리곤 영역과 제 2 폴리곤 영역 사이의 인접 계수를 계산하고, 계산된 인접 계수를 이용하여 인접관계 매트릭스를 생성할 수 있다. 이때의 제 1 픽셀(즉, 래스터 스캔을 통해 현재 선택된 픽셀)은 제 2 픽셀(즉, 선택되지 않은 픽셀로서 제 1 픽셀의 주변에 존재할 수 있음)은 동일 폴리곤 영역에 속해 있을 수도 있고 서로 다른 영역에 속해 있으면서 상호 인접해 있을 수도 있다. 그에 따라, 제 1 폴리곤 영역과 제 2 폴리곤 영역은 동일할 수도 있고 다를 수도 있다. 그래서, 인접관계 매트릭스 생성부(33)는 제 1 픽셀이 속한 제 1 폴리곤 영역과 제 1 픽셀에 인접한 제 2 픽셀이 속한 제 2 폴리곤 영역이 서로 다른지를 비교해야 하는 것이다.In other words, the adjacency
그리고, 인접관계 매트릭스 생성부(33)는 제 1 폴리곤 영역과 제 2 폴리곤 영역을 서로 비교하고, 비교 결과에 따라 제 1 폴리곤 영역과 제 2 폴리곤 영역이 서로 다른 영역인지를 판단하고, 제 1 폴리곤 영역과 제 2 폴리곤 영역이 서로 다르면 이에 응답하여 소정의 카운트 값을 생성하고, 생성된 카운트 값에 기초하여 인접 계수를 계산할 수 있다. Then, the adjacency
그리고, 인접관계 매트릭스 생성부(33)는 제 1 픽셀(즉, 래스터 스캔을 통해 현재 선택된 픽셀)이 속한 제 1 폴리곤 영역과 제 1 픽셀에 인접한 제 2 픽셀(즉, 선택되지 않은 픽셀로서 제 1 픽셀의 주변에 존재할 수 있음)이 속한 제 2 폴리곤 영역의 비교가 종료되면, 제 1 픽셀의 오른쪽에 인접한 픽셀을 제 1 픽셀로 갱신하고, 갱신된 제 1 픽셀의 오른쪽에 인접한 픽셀 및 아래에 인접한 픽셀을 제 2 픽셀로서 설정하여 비교를 반복할 수 있다. In addition, the adjacency
인접관계 매트릭스 생성부(33)는 제 1 폴리곤 영역과 다른 것으로 판단된 제 2 폴리곤 영역에 속한 제 2 픽셀들의 개수에 기초하여 카운트 값을 계산할 수 있다.The
예를 들어, 인접관계 매트릭스 생성부(33)는 래스터 스캔 순으로 스캔중에 현재 픽셀의 오른쪽, 아래쪽 픽셀의 레이블(label)을 읽어 현재의 픽셀의 레이블과 다른 픽셀이 있는지를 판단한다. 인접관계 매트릭스 생성부(33)는 현재의 픽셀의 레이블과 다른 픽셀이 있을 때마다 소정의 카운트 값(예컨대, +1)을 생성하고, 생성된 카운트 값을 이용하여 인접 계수를 계산할 수 있다. 예컨대, 현재의 픽셀의 오른쪽 픽셀 및 아래쪽 픽셀중 1개가 다르다면 인접관계 매트릭스 생성부(33)는 카운트 값을 "+1"로 생성하고, 생성된 카운트 값을 인접 계수에 가산시킴으로써 인접 계수를 계산할 수 있다. 만약, 현재의 픽셀의 오른쪽 픽셀 및 아래쪽 픽셀이 모두 다르다면 인접관계 매트릭스 생성부(33)는 카운트 값을 "+2"로 생성하고, 생성된 카운트 값을 인접 계수에 가산시킴으로써 인접 계수를 계산할 수 있다. 물론, 필요에 따라서는, 현재의 픽셀의 오른쪽 및 아래쪽 픽셀중 어느 하나의 픽셀의 레이블이 현재의 픽셀의 레이블과 다를 때마다 +2 또는 +3 등으로 증분시켜도 무방하다.For example, the adjacency
도 6의 영역 맵을 보면, 제 1 영역(r_1)과 제 2 영역(r_2)이 서로 인접하고, 제 2 영역(r_2)과 제 3 영역(r_3)이 서로 인접하고, 제 3 영역(r_3)과 제 4 영역(r_4)이 서로 인접하고, 제 2 영역(r_2)과 제 4 영역(r_4)이 서로 인접한다. 이 경우, 인접관계 매트릭스 생성부(33)에서 생성되는 서로 다른 두 영역에 대한 인접관계 매트릭스는 M[r_1, r_2] = 6이 되고, M[r_2, r_3] = 2가 되고, M[r_3, r_4] = 3이 되고, M[r_2, r_4] = 5가 되고, M[r_4, r_2] = 1이 된다. 즉, 래스터 스캔 순으로 스캔하면서 제 1 영역(r_1)과 제 2 영역(r_2)의 인접여부를 검출하여 보면 픽셀(41, 42, 43)의 레이블과 픽셀(41, 42, 43)의 오른쪽 픽셀 및 아래쪽 픽셀의 레이블이 다르므로 M[r_1, r_2] = 6이 된다. 래스터 스캔 순으로 스캔하면서 제 2 영역(r_2)과 제 3 영역(r_3)의 인접여부를 검출하여 보면 픽셀(51, 52)의 레이블과 픽셀(51, 52)의 오른쪽 픽셀의 레이블이 다르므로 M[r_2, r_3] = 2가 된다. 래스터 스캔 순으로 스캔하면서 제 3 영역(r_3)과 제 4 영역(r_4)의 인접여부를 검출하여 보면 픽셀(61, 62, 63)의 레이블과 픽셀(61, 62, 63)의 아래쪽 픽셀의 레이블이 다르므로 M[r_3, r_4] = 3이 된다. 래스터 스캔 순으로 스캔하면서 제 2 영역(r_2)과 제 4 영역(r_4)의 인접여부를 검출하여 보면 픽셀(52, 53)의 레이블과 픽셀(52, 53)의 아래쪽 픽셀의 레이블이 다르고, 픽셀(54, 55, 56)의 레이블과 픽셀(54, 55, 56)의 오른쪽 픽셀의 레이블이 다르므로 M[r_2, r_4] = 5가 된다. 또한, 래스터 스캔 순으로 스캔하면서 제 2 영역(r_2)과 제 4 영역(r_4)의 인접여부를 검출하여 보면 픽셀(71)의 레이블과 픽셀(71)의 아래쪽 픽셀의 레이블이 다르므로 M[r_4, r_2] = 1이 된다. 그에 따라, 인접관계 매트릭스 생성부(33)는 도 7의 좌측과 같은 최종적인 인접관계 매트릭스(M)(즉, 영역 맵에서 인접하는 영역들이 몇 개의 경계점(경계 픽셀)을 통해 서로 연결되어 있는지의 정보를 포함하는 인접관계 매트릭스)를 생성할 수 있다.Referring to the region map of FIG. 6 , the first region r_1 and the second region r_2 are adjacent to each other, the second region r_2 and the third region r_3 are adjacent to each other, and the third region r_3 is adjacent to each other. and the fourth region r_4 are adjacent to each other, and the second region r_2 and the fourth region r_4 are adjacent to each other. In this case, the adjacency matrix for two different regions generated by the adjacency
인접관계 매트릭스 생성부(33)는 래스터 스캔을 종료한 후에 인접관계 매트릭스에 대칭(symmetry) 적용을 행할 수 있다. 그에 따라, 도 7의 우측과 같은 인접관계 매트릭스를 생성할 수 있다.The adjacency
한편으로, 상술한 설명에서는 계산되는 카운트 값이 +1인 것으로 예로 들었으나, 필요에 따라서는 계산되는 카운트 값은 영역 크기에 따라 다르게 설정될 수 있다. 예를 들어, 큰 영역(즉, 폴리곤)과 작은 영역(즉, 폴리곤)이 인접해 있다면 작은 영역이 큰 영역에 병합되는 것이 바람직할 것이며, 이를 위해서는 가급적 큰 영역에 속해 있는 픽셀을 기반으로 카운트되는 카운트 값을 더 크게 하는 것이 좋다. 그에 따라, 기준 개수 이상의 픽셀을 포함하는 큰 영역의 픽셀을 기준으로 인접한 다른 영역(즉, 작은 영역)과 비교하여 현재의 픽셀의 레이블과 다른 레이블을 갖는 오른쪽, 아래쪽 픽셀이 발견될 때마다 소정의 가중값(예컨대, +3)으로 증가시킬 수도 있다. 이와 같이 영역별로 동일한 임계치를 부여한다면 큰 영역일수록 가중값으로 카운팅하는 것이 바람직할 수 있다. Meanwhile, in the above description, it is assumed that the calculated count value is +1, but if necessary, the calculated count value may be set differently depending on the size of the region. For example, if a large area (i.e. polygon) and a small area (i.e. polygon) are adjacent to each other, it would be desirable to merge the smaller area into the larger area. It is better to make the count value larger. Accordingly, a predetermined number of pixels are found each time the right and bottom pixels having a label different from the label of the current pixel are found, compared with other adjacent regions (ie, small regions) based on the pixels of the large area containing more than the reference number of pixels. It can also be increased by a weight value (eg, +3). In this way, if the same threshold value is given to each region, it may be preferable to count the larger region by a weight value.
이와 같이 인접관계 매트릭스 생성부(33)는 한번의 래스터 스캔으로 인접관계 매트릭스의 생성 및 갱신을 할 수 있다. 물론, 필요에 따라서는, 래스터 스캔을 통해 영역 맵 내의 인접한 서로 다른 두 개의 폴리곤 영역들의 개수를 근거로 하는 초기화된 인접관계 매트릭스(M)를 먼저 생성한 후에, 재차 래스터 스캔을 하여 영역 맵 내의 픽셀들 각각에 대해 해당 픽셀이 속한 폴리곤 영역의 다른 폴리곤 영역과의 인접여부를 검출하고 검출된 결과를 초기화된 인접관계 매트릭스에 반영하는 것으로 할 수도 있다.As such, the adjacency
래스터 스캔이 최종적으로 종료되면 인접관계 매트릭스의 갱신이 최종적으로 완료되었다고 볼 수 있으므로, 인접관계 매트릭스 생성부(33)는 인접관계 매트릭스 갱신이 최종적으로 완료됨에 따라 그에 상응하는 완료신호 및 인접관계 매트릭스를 병합조건 생성부(34)에게로 전송할 수 있다.When the raster scan is finally completed, it can be considered that the update of the adjacency matrix is finally completed. It can be transmitted to the merging
그에 따라, 병합조건 생성부(34)는 인접관계 매트릭스를 수신하고 나서 그에 상응하는 수신완료신호를 액크(ACK)신호로서 인접관계 매트릭스 생성부(33)에게로 전송한다.Accordingly, the merging
그리고, 병합조건 생성부(34)는 인접한 서로 다른 두 개의 영역(즉, 폴리곤 영역)간의 병합을 위한 병합조건을 생성(또는 설정)할 수 있다. 이때, 병합조건 생성부(34)는 인접관계 매트릭스 생성부(33)에서 생성한 인접관계 매트릭스를 근거로 인접한 서로 다른 두 개의 영역(즉, 폴리곤 영역)간의 병합을 위한 병합조건을 생성(또는 설정)할 수 있다.Further, the merging
여기서, 병합조건은 소정의 임계치(threshold)일 수 있다.Here, the merging condition may be a predetermined threshold.
본 발명의 실시예에서는 래스터 스캔(raster scan)을 하면 최종적으로 각 영역(즉, 폴리곤 영역)에 대해서 다른 영역의 픽셀이 몇 개가 맞닿아 있는지를 파악할 수 있다. 즉, 래스터 스캔을 종료하게 되면 인접한 두 개의 서로 다른 폴리곤 영역들에 대한 인접관계 매트릭스 값이 산출된다. 그에 따라, 본 발명의 실시예에서는 이미지내 픽셀들 각각에 대해 해당 픽셀이 속한 영역의 다른 영역과의 인접을 카운팅하여 계산된 인접 계수(즉, 인접관계 매트릭스 값이 됨)가 임계치보다 클 경우(즉, 임계치를 초과하는 경우) 해당 픽셀이 속한 영역과 인접한 다른 영역을 서로 병합시킬 수 있다. 여기서, 임계치는 인접한 두 개의 서로 다른 폴리곤 영역들에 대한 인접관계 매트릭스 값들을 기반으로 적절하게 설정될 수 있다.In the embodiment of the present invention, when a raster scan is performed, it is possible to determine how many pixels in other areas are in contact with each area (ie, polygon area). That is, when the raster scan is finished, an adjacency matrix value for two different polygonal regions adjacent to each other is calculated. Accordingly, in the embodiment of the present invention, when the adjacency coefficient (that is, the adjacency matrix value) calculated by counting the adjacency of each pixel in the image with another area of the area to which the pixel belongs is greater than the threshold ( That is, when the threshold value is exceeded), the region to which the corresponding pixel belongs and other adjacent regions may be merged with each other. Here, the threshold value may be appropriately set based on adjacency matrix values for two different polygon regions adjacent to each other.
이와 같이, 병합조건 생성부(34)는 인접한 서로 다른 두 개의 영역(즉, 폴리곤 영역)간의 병합이 이루어질 기준값이 될 수 있는 임계치를 생성할 수 있다. 여기서, 임계치는 갱신가능하다.In this way, the merging
추가적으로, 병합조건 생성부(34)는 병합이 이루어지는 경우의 병합방향을 생성할 수 있다.Additionally, the merging
예를 들어, 서로 인접한 두 개의 다른 영역(즉, 제 1 영역, 제 2 영역)이 하나의 영역으로 병합되어야 한다고 가정할 경우, 병합방향은 제 1 영역이 제 2 영역으로 병합되는 것을 의미하거나, 제 2 영역이 제 1 영역으로 병합되는 것을 의미할 수 있다. 만약, 제 1 영역이 제 2 영역으로 병합되어야 한다면 제 1 영역내의 모든 픽셀들의 값은 제 2 영역의 영역 아이디로 바뀔 것이다. 반대로, 제 2 영역이 제 1 영역으로 병합되어야 한다면 제 2 영역내의 모든 픽셀들의 값은 제 1 영역의 영역 아이디로 바뀔 것이다. 이러한 병합방향은 처리의 편의를 위한 것으로서, 두 개의 서로 다른 영역이 하나의 영역으로 병합되어야 한다면 어떠한 방향으로 병합되어도 무방하리라 본다.For example, if it is assumed that two different regions adjacent to each other (ie, the first region and the second region) should be merged into one region, the merging direction means that the first region is merged into the second region, It may mean that the second area is merged into the first area. If the first area is to be merged into the second area, the values of all pixels in the first area will be changed to the area ID of the second area. Conversely, if the second region is to be merged into the first region, the values of all pixels in the second region will be changed to the region ID of the first region. This merging direction is for the convenience of processing, and if two different regions are to be merged into one region, it is considered that they may be merged in any direction.
이와 같이, 병합조건 생성부(34)는 임계치를 충족하였을 경우의 병합방향을 생성할 수 있다. In this way, the merging
한편으로, 병합조건 생성부(34)는 영역(즉, 폴리곤 영역)의 크기도 병합조건의 일 예로 사용할 수 있다.On the other hand, the merging
앞서의 병합방향 설명에서는 병합방향이 매우 자유로운 것으로 설명하였으나, 영역의 크기가 병합조건의 일예로 사용될 경우에는 병합되어야 할 두 개의 영역(즉, 폴리곤 영역)이 있다면 두 개의 영역중에서 가급적 보다 큰 영역으로 병합되게 할 수 있다. 여기서, 보다 큰 영역은 해당 영역에 포함된 픽셀의 수가 다른 영역에 비해 보다 많은 영역을 의미할 수 있다. In the previous description of the merging direction, the merging direction was described as being very free, but when the size of the region is used as an example of the merging condition, if there are two regions to be merged (that is, a polygon region), use the larger region as possible among the two regions. can be merged. Here, the larger area may mean an area in which the number of pixels included in the corresponding area is greater than that of other areas.
상기의 폴리곤 영역의 크기를 병합조건의 일 예로 사용할 경우에 있어서, 소정 크기 이상(예컨대, 픽셀의 수가 100개 이상)의 제 1 폴리곤 영역과 이와 다른 크기(예컨대, 픽셀의 수가 5개 정도)의 제 2 폴리곤 영역간의 인접관계 매트릭스 값이 임계치보다 큰 경우에는 제 1 폴리곤 영역과 제 2 폴리곤 영역은 서로 병합될 것이다. 그러나, 이와 같이 제 1 폴리곤 영역이 상당히 큰 경우에는 설정된 임계치가 너무 작음으로 인한 불필요한 병합을 방지하기 위해 임계치를 재조정하여 제 2 폴리곤 영역을 제 1 폴리곤 영역에 병합시키지 않는 것으로 할 수도 있다. In the case of using the size of the polygon region as an example of a merging condition, the first polygon region having a predetermined size or more (eg, the number of pixels is 100 or more) and a size different from the first polygon region (eg, the number of pixels is about 5) When the adjacency matrix value between the second polygon regions is greater than the threshold, the first polygon region and the second polygon region will be merged with each other. However, when the first polygon area is quite large as described above, in order to prevent unnecessary merging due to the set threshold being too small, the threshold value may be readjusted so that the second polygon area is not merged with the first polygon area.
병합조건 생성부(34)는 병합조건이 생성완료됨에 따라 그에 상응하는 완료신호 및 병합조건을 병합 맵 생성부(35)에게로 전송한다.The merging
물론, 상기의 설명에서는 인접관계 매트릭스 생성부(33)가 인접관계 매트릭스를 병합조건 생성부(34)에게로 전송하는 것으로 설명하였으나, 본 발명의 실시예에서는 병합조건이 미리 설정되어 저장부(20)에 미리 저장되어 있는 것으로 할 수 있다. 그리하면, 병합조건 생성부(34)가 필요없을 수도 있고, 인접관계 매트릭스 생성부(33)는 인접관계 매트릭스를 병합조건 생성부(34)에게로 보내지 않고 병합 맵 생성부(35)에게로 보낼 것이다.Of course, in the above description, the adjacency
그에 따라, 병합 맵 생성부(35)는 병합조건을 수신하고 나서 그에 상응하는 수신완료신호를 액크(ACK)신호로서 병합조건 생성부(34)에게로 전송한다. 여기서, 병합조건이 만약 미리 저장되어 있는 경우라면 병합 맵 생성부(35)는 인접관계 매트릭스를 수신함에 따라 저장부(20)에 기저장되어 있는 병합조건을 리드(read)할 것이다.Accordingly, the merging
그리고, 병합 맵 생성부(35)는 인접관계 매트릭스 생성부(34)에서 생성된 인접관계 매트릭스(즉, 영역 맵내의 영역별로의 인접영역과의 인접정도를 나타내는 매트릭스)를 근거로 병합할 영역(즉, 폴리곤 영역)을 나타내는 병합 맵을 생성할 수 있다. 예를 들어, 병합 맵은 룩업테이블(look up table; LUT) 형태일 수 있다.Then, the merge
다시 말해서, 병합 맵 생성부(35)는 인접관계 매트릭스 생성부(34)에서 생성된 인접관계 매트릭스 및 병합조건을 근거로 병합할 영역 아이디를 나타내는 병합 맵을 생성할 수 있다. In other words, the
예를 들어, 임계치를 2라고 가정하고, 도 6의 영역 맵을 기반으로 하여 생성된 서로 다른 두 개의 영역에 대한 인접관계 매트릭스를 예로 들면, 상기의 임계치보다 큰 값을 갖는 인접관계 매트릭스는 M[r_1, r_2] = 6이고, M[r_2, r_4] = 5이고, M[r_3, r_4] = 3이다. 그에 따라, 병합 맵 생성부(35)는 제 1 영역(r_1)과 제 2 영역(r_2) 및 제 4 영역(r_4)을 병합하고, 제 3 영역(r_3) 및 제 4 영역(r_4)을 병합하는 병합 맵을 생성할 수 있다. 이 경우, 병합 맵 생성부(35)는 LUT(r_1) = r_4, LUT(r_2) = r_4, LUT(r_3) = r_4 와 같은 병합 맵을 생성할 수 있다. 여기서, LUT(r_1) = r_4는 제 1 영역을 제 4 영역에 병합시키라는 의미이고, LUT(r_2) = r_4는 제 2 영역을 제 4 영역에 병합시키라는 의미이고, LUT(r_3) = r_4는 제 3 영역을 제 4 영역에 병합시키라는 의미이다. 물론, 필요에 따라서는 병합 맵 생성부(35)는 영역(즉, 폴리곤 영역) 크기를 고려하여 제 1 영역 및 제 4 영역은 각각 제 2 영역에 병합시키라는 병합 맵(즉, LUT(r_1) = r_2, LUT(r_4) = r_2)을 생성할 수도 있다. 한편, 제 2 영역(r_2)의 제 3 영역(r_3)과의 인접관계 매트릭스(즉, M[r_2, r_3])의 값은 "2"이므로 임계치 보다 크지 않으므로 제 2 영역(r_2)과 제 3 영역(r_3)을 서로 병합시킬 필요가 없다. 그래서, 병합시킬 필요가 없을 경우에는 그에 상응하는 병합 맵을 생성하거나 병합 맵에 포함시키지 않아도 무방하다.For example, assuming that the threshold is 2, and taking an adjacency matrix for two different regions generated based on the region map of FIG. 6 as an example, the adjacency matrix having a value greater than the threshold is M[ r_1, r_2] = 6, M[r_2, r_4] = 5, and M[r_3, r_4] = 3. Accordingly, the
결국, 병합 맵 생성부(35)는 도 7에 예시된 인접관계 매트릭스(M)의 비제로(nonzero) 성분을 기반으로 병합조건을 통해 룩업테이블(look up table; LUT) 형태의 병합 맵을 생성한다고 볼 수 있다. 이때의 병합 맵의 수는 서로 인접(또는 연결)되어 있는 폴리곤 페어(pair) 수에 비례할 것이다.As a result, the
병합 맵 생성부(35)는 병합 맵이 생성완료됨에 따라 그에 상응하는 완료신호 및 병합 맵을 병합부(36)에게로 전송한다.The
그에 따라, 병합부(36)는 병합 맵을 수신하고 나서 그에 상응하는 수신완료신호를 액크(ACK)신호로서 병합 맵 생성부(35)에게로 전송한다.Accordingly, the merging
그리고, 병합부(36)는 통신부(10)에서 수신한 영역 맵에 병합 맵을 적용함으로써 인접한 서로 다른 두 영역(즉, 폴리곤 영역)간의 병합을 수행할 수 있다. 예를 들어, 제 1 영역을 제 2 영역에 병합시키는 경우에는 제 1 영역내의 픽셀의 영역 아이디가 제 2 영역의 픽셀의 영역 아이디로 변환될 수 있다. 제 1 영역, 제 2 영역 이외의 영역들간에도 상술한 바와 같은 병합이 이루어질 수 있다.In addition, the merging
이에, 병합부(36)는 인접한 서로 다른 두 개의 폴리곤 영역이 병합된 영역 맵을 생성하여 출력할 수 있다. 여기서, 출력되는 영역 맵은 외부 장치에게로 전송될 수 있다.Accordingly, the merging
도 8은 본 발명의 실시예에 따른 이미지 처리 방법을 설명하기 위한 플로우차트이다.8 is a flowchart illustrating an image processing method according to an embodiment of the present invention.
본 발명의 실시예에 따른 이미지 처리 방법은 통신부(10), 저장부(20), 및 제어부(30)를 포함하는 장치(100)에서 행해지는 것이다.The image processing method according to an embodiment of the present invention is performed in the
장치(100)의 통신부(10)는 외부 장치로부터의 영역 맵 전송 신호에 응답하여 외부 장치로부터의 영역 맵을 수신하고, 영역 맵의 수신이 완료됨에 따라 영역 맵 수신 완료신호를 출력한다. 그에 따라, 제어부(30)는 통신부(10)로부터의 영역 맵 수신 완료신호에 응답하여 해당 영역 맵을 저장부(20)에 저장한다. 또한, 저장부(20)에는 소정의 병합조건이 기저장되어 있을 수 있다.The
그리고 나서, 제어부(30)는 저장된 영역 맵을 리드한다(S10).Then, the
이어, 제어부(30)는 영역 맵을 전체적으로 래스터 스캔하면서 인접한 서로 다른 두 개의 영역(즉, 폴리곤 영역)들에 대한 인접관계 매트릭스를 생성한다(S12). 이때에는, 인접한 서로 다른 두 개의 영역(예컨대, r_1, r_2)에 대한 인접관계 매트릭스(M)를 처음 생성할 때이므로 생성된 해당 인접관계 매트릭스(M)의 값을 "0(zero)"으로 초기화한다.Next, the
그리고, 제어부(30)는 영역 맵을 래스터 스캔 순으로 스캔하는 과정에서 영역 맵 내의 픽셀들 각각에 대해, 현재 픽셀(제 1 픽셀이라고 함)이 속한 폴리곤 영역과 현재 픽셀에 인접한 제 2 픽셀이 속한 폴리곤 영역을 서로 비교하고, 비교 결과에 따라 현재 픽셀(제 1 픽셀이라고 함)이 속한 폴리곤 영역과 현재 픽셀에 인접한 제 2 픽셀이 속한 폴리곤 영역 사이의 인접 계수를 계산하고, 계산된 인접 계수를 이용하여 인접관계 매트릭스(M)를 갱신한다(S16). 예를 들어, 래스터 스캔 순으로 스캔중에 현재 픽셀의 오른쪽, 아래쪽 픽셀의 레이블(label)을 읽어 현재의 픽셀의 레이블과 다른 픽셀이 있는지를 판단한다. 만약, 현재의 픽셀의 레이블과 다른 픽셀이 있을 때마다 소정의 카운트 값(예컨대, +1)을 생성하고 생성된 카운트 값에 기초하여 인접 계수를 계산한 후에 계산된 인접 계수로 해당 인접관계 매트릭스의 값을 증분시킨다. 여기서, 증분시킨다는 것은 해당 인접관계 매트릭스의 현재의 값에 카운트 값을 가산한다는 것을 의미할 수 있다.In addition, in the process of scanning the area map in the raster scan order, for each of the pixels in the area map, the polygon area to which the current pixel (referred to as the first pixel) belongs and the second pixel adjacent to the current pixel belong The polygon areas are compared with each other, and the adjacency coefficient between the polygon area to which the current pixel (referred to as the first pixel) belongs and the polygon area to which the second pixel adjacent to the current pixel belongs is calculated according to the comparison result, and the calculated adjacency coefficient is used. to update the adjacency matrix M (S16). For example, it is determined whether there is a pixel different from the label of the current pixel by reading the labels of the pixels to the right and the bottom of the current pixel during scanning in the raster scan order. If there is a pixel different from the label of the current pixel, a predetermined count value (eg, +1) is generated, an adjacency coefficient is calculated based on the generated count value, and then the calculated adjacency coefficient is used in the adjacency matrix. increment the value. Here, incrementing may mean adding the count value to the current value of the corresponding adjacency matrix.
이와 같이 래스터 스캔을 최종적으로 완료하게 되면(S18에서 "Yes") 영역 맵내에 존재하는 인접한 서로 다른 두 개의 영역들에 대한 인접관계 매트릭스가 최종적으로 완성(즉, 갱신)된다. 예를 들어, 도 6의 영역 맵에 대해 도 7에서의 좌측과 같은 인접관계 매트릭스가 최종적으로 완성(즉, 갱신)될 수 있다.As such, when the raster scan is finally completed (“Yes” in S18), the adjacency matrix for two different adjacent regions existing in the region map is finally completed (that is, updated). For example, for the area map of FIG. 6 , an adjacency matrix as shown on the left in FIG. 7 may be finally completed (ie, updated).
따라서, 제어부(30)는 최종적으로 완성된 인접관계 매트릭스를 근거로 병합할 영역 아이디를 나타내는 병합 맵을 룩업테이블(look up table; LUT) 형태로 생성한다(S20).Accordingly, the
마지막으로, 제어부(30)는 통신부(10)에서 수신한 영역 맵에 병합 맵을 적용함으로써 인접한 서로 다른 두 영역(즉, 폴리곤 영역)간의 병합을 수행한다(S22). 그에 따라, 제어부(30)는 인접한 서로 다른 두 개의 폴리곤 영역이 병합된 영역 맵을 생성하여 출력할 수 있다. 여기서, 출력되는 영역 맵은 외부 장치에게로 전송될 수 있다.Finally, the
또한, 상술한 본 발명의 이미지 처리 방법은, 컴퓨터로 읽을 수 있는 기록매체에 컴퓨터가 읽을 수 있는 코드로서 구현하는 것이 가능하다. 컴퓨터가 읽을 수 있는 기록매체는 컴퓨터 시스템에 의하여 읽혀질 수 있는 데이터가 저장되는 모든 종류의 기록 장치를 포함한다. 컴퓨터가 읽을 수 있는 기록매체의 예로는 ROM, RAM, CD-ROM, 자기 테이프, 플로피디스크, 광데이터 저장장치 등이 있다. 또한, 컴퓨터가 읽을 수 있는 기록매체는 네트워크로 연결된 컴퓨터 시스템에 분산되어, 분산방식으로 컴퓨터가 읽을 수 있는 코드가 저장되고 실행될 수 있다. 그리고, 상기 방법을 구현하기 위한 기능적인(function) 프로그램, 코드 및 코드 세그먼트들은 본 발명이 속하는 기술분야의 프로그래머들에 의해 용이하게 추론될 수 있다.In addition, the above-described image processing method of the present invention can be implemented as computer-readable codes on a computer-readable recording medium. The computer-readable recording medium includes all types of recording devices in which data readable by a computer system is stored. Examples of computer-readable recording media include ROM, RAM, CD-ROM, magnetic tape, floppy disk, and optical data storage device. In addition, the computer-readable recording medium is distributed in a computer system connected through a network, so that the computer-readable code can be stored and executed in a distributed manner. In addition, functional programs, codes, and code segments for implementing the method can be easily inferred by programmers in the art to which the present invention pertains.
이상의 설명은 본 발명의 기술 사상을 예시적으로 설명한 것에 불과한 것으로서, 본 발명이 속하는 기술 분야에서 통상의 지식을 가진 자라면 본 발명의 본질적인 특성에서 벗어나지 않는 범위에서 다양한 수정 및 변형이 가능할 것이다. 따라서, 본 발명에 개시된 실시예들은 본 발명의 기술 사상을 한정하기 위한 것이 아니라 설명하기 위한 것이고, 이러한 실시예에 의하여 본 발명의 기술 사상의 범위가 한정되는 것은 아니다. 본 발명의 보호 범위는 아래의 청구범위에 의하여 해석되어야 하며, 그와 동등한 범위 내에 있는 모든 기술 사상은 본 발명의 권리범위에 포함되는 것으로 해석되어야 할 것이다.The above description is merely illustrative of the technical spirit of the present invention, and various modifications and variations will be possible without departing from the essential characteristics of the present invention by those skilled in the art to which the present invention pertains. Therefore, the embodiments disclosed in the present invention are not intended to limit the technical spirit of the present invention, but to explain, and the scope of the technical spirit of the present invention is not limited by these embodiments. The protection scope of the present invention should be construed by the following claims, and all technical ideas within the equivalent range should be construed as being included in the scope of the present invention.
10 : 통신부 20 : 저장부
30 : 제어부 31 : 폴리곤 생성부
32 : 영역 맵 생성부 33 : 인접관계 매트릭스 생성부
34 : 병합조건 설정부 35 : 병합 맵 생성부
36 : 병합부 100 : 이미지 처리 장치10: communication unit 20: storage unit
30: control unit 31: polygon generation unit
32: area map generation unit 33: adjacency matrix generation unit
34: merge condition setting unit 35: merge map generation unit
36: merging unit 100: image processing device
Claims (15)
연산 처리 기능을 갖는 프로세서;를 포함하고,
상기 프로세서는 상기 저장부에 저장된 명령들을 로드함으로써,
상기 이미지에 포함된 복수의 폴리곤 영역들 사이의 인접 관계를 나타내는 인접 계수를 포함하는 인접관계 매트릭스를 생성하되, 상기 이미지의 픽셀들 중 제 1 픽셀이 속한 제 1 폴리곤 영역과 상기 제 1 픽셀에 인접한 제 2 픽셀이 속한 제 2 폴리곤 영역을 서로 비교하고, 비교 결과에 따라 상기 제 1 폴리곤 영역과 상기 제 2 폴리곤 영역이 서로 다른 영역인지를 판단하고, 상기 제 1 폴리곤 영역과 다른 것으로 판단된 상기 제 2 폴리곤 영역에 속한 제 2 픽셀들 중에서 상기 제 1 픽셀에 인접한 제 2 픽셀들의 개수에 기초하여 카운트 값을 생성하고, 생성된 카운트 값에 기초하여 상기 제 1 폴리곤 영역과 상기 제 2 폴리곤 영역 사이의 인접 계수를 계산하고, 상기 계산된 인접 계수를 이용하여 상기 인접관계 매트릭스를 생성하고,
상기 인접관계 매트릭스의 생성이 완료됨에 따라 상기 생성완료된 인접관계 매트릭스를 근거로 폴리곤 영역들을 병합하여 폴리곤 영역이 병합된 영역 맵을 출력하고,
상기 프로세서는 상기 폴리곤 영역들을 병합함에 있어서, 상기 인접한 서로 다른 두 개의 폴리곤 영역에 대응하는 인접 계수와 상기 인접한 서로 다른 두 개의 폴리곤 영역간의 병합이 이루어질 기준값이 되는 임계치를 비교하고, 비교 결과에 따라 인접 계수가 임계치를 초과하면 상기 인접한 서로 다른 두 개의 폴리곤 영역을 병합하는,
이미지 처리 장치.a storage unit which stores in advance a region map including a region ID value for a polygon region to which each pixel of the image belongs; and
A processor having an arithmetic processing function; includes;
The processor by loading the instructions stored in the storage unit,
and generating an adjacency matrix including an adjacency coefficient representing adjacency between a plurality of polygon regions included in the image, wherein a first polygon region to which a first pixel of the pixels of the image belongs and an adjacency matrix adjacent to the first pixel The second polygon area to which the second pixel belongs is compared with each other, and it is determined whether the first polygon area and the second polygon area are different from each other according to the comparison result, and the first polygon area determined to be different from the first polygon area is determined. A count value is generated based on the number of second pixels adjacent to the first pixel among the second pixels belonging to the second polygon area, and a count value is generated between the first polygon area and the second polygon area based on the generated count value. calculating an adjacency coefficient, and generating the adjacency matrix using the calculated adjacency coefficient;
As the generation of the adjacency matrix is completed, polygon areas are merged based on the generated adjacency matrix to output a polygon area merged area map;
When merging the polygon regions, the processor compares an adjacency coefficient corresponding to the two adjacent polygon regions with a threshold value serving as a reference value for merging between the two adjacent polygon regions, and according to a result of the comparison merging the adjacent two different polygon regions when the coefficient exceeds a threshold,
image processing unit.
상기 프로세서는,
상기 제 1 픽셀이 속한 제 1 폴리곤 영역과 상기 제 1 픽셀에 인접한 제 2 픽셀이 속한 제 2 폴리곤 영역의 비교가 종료되면, 상기 제 1 픽셀의 오른쪽에 인접한 픽셀을 상기 제 1 픽셀로 갱신하고, 갱신된 제 1 픽셀의 오른쪽에 인접한 픽셀 및 아래에 인접한 픽셀을 상기 제 2 픽셀로서 설정하여 비교를 반복하는,
이미지 처리 장치.The method of claim 1,
The processor is
When the comparison of the first polygon area to which the first pixel belongs and the second polygon area to which the second pixel adjacent to the first pixel belongs is finished, the pixel adjacent to the right of the first pixel is updated as the first pixel; repeating the comparison by setting the pixel adjacent to the right and the pixel adjacent below the updated first pixel as the second pixel;
image processing unit.
상기 저장부는 인접한 서로 다른 두 개의 폴리곤 영역간의 병합을 위한 병합조건을 더 저장하고,
상기 프로세서는 상기 병합조건을 이용하여 폴리곤 영역들을 병합하는,
이미지 처리 장치.The method of claim 1,
The storage unit further stores a merging condition for merging between two adjacent polygonal regions,
The processor merges polygon regions using the merging condition,
image processing unit.
상기 병합조건은 폴리곤 영역의 크기에 대한 조건을 포함하고,
상기 프로세서는,
상기 인접한 서로 다른 두 개의 폴리곤 영역을 병합할 때 상기 폴리곤 영역의 크기에 근거하여 보다 큰 폴리곤 영역으로 병합시키는,
이미지 처리 장치.6. The method of claim 5,
The merging condition includes a condition for the size of the polygon area,
The processor is
When merging the adjacent two different polygon areas, merging into a larger polygon area based on the size of the polygon area,
image processing unit.
상기 프로세서는,
상기 인접관계 매트릭스의 생성이 완료됨에 따라 상기 생성완료된 인접관계 매트릭스를 근거로 병합할 폴리곤 영역을 나타내는 병합 맵을 생성하고, 상기 병합 맵의 생성이 완료됨에 따라 상기 생성완료된 병합 맵을 상기 영역 맵에 적용하여 인접한 서로 다른 두 개의 폴리곤 영역이 병합된 영역 맵을 생성하는,
이미지 처리 장치.The method of claim 1,
The processor is
As the generation of the adjacency matrix is completed, a merge map indicating a polygon area to be merged is generated based on the generated adjacency matrix, and as the generation of the merge map is completed, the generated merged map is added to the area map. To create an area map where two adjacent polygonal areas are merged by applying,
image processing unit.
상기 영역 맵을 수신하는 통신부;를 추가로 포함하되,
상기 통신부는 수신한 영역 맵을 상기 프로세서에게로 보낸 후에 영역 맵 전송완료신호를 상기 프로세서에게로 보내고,
상기 프로세서는 상기 영역 맵을 수신완료함에 따른 영역 맵 수신완료신호를 액크(ACK)신호로서 상기 통신부에 보낸 후에 상기 영역 맵을 상기 저장부에 저장시키는,
이미지 처리 장치.The method of claim 1,
Further comprising; a communication unit for receiving the area map,
The communication unit sends the received area map to the processor and then sends an area map transmission completion signal to the processor;
the processor transmits an area map reception completion signal according to the reception completion of the area map as an ACK signal to the communication unit and then stores the area map in the storage unit;
image processing unit.
상기 저장부가, 이미지의 각 픽셀이 속하는 폴리곤 영역에 대한 영역 아이디값을 포함하는 영역 맵을 미리 저장하는 단계;
상기 프로세서가, 상기 이미지에 포함된 복수의 폴리곤 영역들 사이의 인접 관계를 나타내는 인접 계수를 포함하는 인접관계 매트릭스를 생성하되, 상기 이미지의 픽셀들 중 제 1 픽셀이 속한 제 1 폴리곤 영역과 상기 제 1 픽셀에 인접한 제 2 픽셀이 속한 제 2 폴리곤 영역을 서로 비교하고, 비교 결과에 따라 상기 제 1 폴리곤 영역과 상기 제 2 폴리곤 영역이 서로 다른 영역인지를 판단하고, 상기 제 1 폴리곤 영역과 다른 것으로 판단된 상기 제 2 폴리곤 영역에 속한 제 2 픽셀들 중에서 상기 제 1 픽셀에 인접한 제 2 픽셀들의 개수에 기초하여 카운트 값을 생성하고, 생성된 카운트 값에 기초하여 상기 제 1 폴리곤 영역과 상기 제 2 폴리곤 영역 사이의 인접 계수를 계산하고, 상기 계산된 인접 계수를 이용하여 상기 인접관계 매트릭스를 생성하는 단계; 및
상기 프로세서가, 상기 인접관계 매트릭스의 생성이 완료됨에 따라 상기 생성완료된 인접관계 매트릭스를 근거로 폴리곤 영역들을 병합하여 폴리곤 영역이 병합된 영역 맵을 출력하는 단계;를 포함하고,
상기 폴리곤 영역이 병합된 영액 맵을 출력하는 단계는,
상기 인접한 서로 다른 두 개의 폴리곤 영역에 대응하는 인접 계수와 상기 인접한 서로 다른 두 개의 폴리곤 영역간의 병합이 이루어질 기준값이 되는 임계치를 비교하고, 비교 결과에 따라 인접 계수가 임계치를 초과하면 상기 인접한 서로 다른 두 개의 폴리곤 영역을 병합하는,
이미지 처리 방법.A method performed in an image processing apparatus comprising a storage unit and a processor, the method comprising:
storing, by the storage unit, a region map including region ID values for polygon regions to which each pixel of the image belongs in advance;
wherein the processor generates an adjacency matrix including an adjacency coefficient representing an adjacency relationship between a plurality of polygon regions included in the image, wherein a first polygon region to which a first pixel of the pixels of the image belongs and the first polygon region A second polygon area to which a second pixel adjacent to one pixel belongs is compared with each other, and it is determined whether the first polygon area and the second polygon area are different from each other according to the comparison result, and is different from the first polygon area. A count value is generated based on the number of second pixels adjacent to the first pixel among the determined second pixels belonging to the second polygon area, and the first polygon area and the second pixel are generated based on the generated count value. calculating an adjacency coefficient between polygon regions and generating the adjacency matrix using the calculated adjacency coefficient; and
and outputting, by the processor, an area map in which the polygon areas are merged by merging polygon areas based on the generated adjacency matrix as the generation of the adjacency matrix is completed, and
The step of outputting the spirit map in which the polygon area is merged includes:
The adjacent coefficient corresponding to the two different adjacent polygon areas is compared with a threshold value that is a reference value for merging between the two adjacent different polygon areas, and if the adjacent coefficient exceeds the threshold according to the comparison result, the two adjacent different polygon areas are compared. to merge two polygonal areas,
Image processing method.
상기 영역 맵을 미리 저장하는 단계는 인접한 서로 다른 두 개의 폴리곤 영역간의 병합을 위한 병합조건을 더 저장하고,
상기 폴리곤 영역이 병합된 영역 맵을 출력하는 단계는 상기 병합조건을 이용하여 폴리곤 영역들을 병합하는,
이미지 처리 방법.12. The method of claim 11,
The step of pre-saving the area map further stores a merging condition for merging between two adjacent polygon areas,
The step of outputting the area map in which the polygon areas are merged includes merging the polygon areas using the merging condition.
Image processing method.
상기 폴리곤 영역이 병합된 영역 맵을 출력하는 단계는,
상기 인접관계 매트릭스의 생성이 완료됨에 따라 상기 생성완료된 인접관계 매트릭스를 근거로 병합할 폴리곤 영역을 나타내는 병합 맵을 생성하고, 상기 병합 맵의 생성이 완료됨에 따라 상기 생성완료된 병합 맵을 상기 영역 맵에 적용하여 인접한 서로 다른 두 개의 폴리곤 영역이 병합된 영역 맵을 생성하는,
이미지 처리 방법.12. The method of claim 11,
The step of outputting an area map in which the polygon area is merged includes:
As the generation of the adjacency matrix is completed, a merge map indicating a polygon area to be merged is generated based on the generated adjacency matrix, and as the generation of the merge map is completed, the generated merged map is added to the area map. To create an area map where two adjacent polygonal areas are merged by applying,
Image processing method.
A computer-readable storage medium storing a program including instructions for performing the image processing method according to claim 11 .
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020220030253A KR102447747B1 (en) | 2022-03-10 | 2022-03-10 | Image processing apparatus and method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
KR1020220030253A KR102447747B1 (en) | 2022-03-10 | 2022-03-10 | Image processing apparatus and method |
Publications (1)
Publication Number | Publication Date |
---|---|
KR102447747B1 true KR102447747B1 (en) | 2022-09-27 |
Family
ID=83452106
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
KR1020220030253A KR102447747B1 (en) | 2022-03-10 | 2022-03-10 | Image processing apparatus and method |
Country Status (1)
Country | Link |
---|---|
KR (1) | KR102447747B1 (en) |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR100210400B1 (en) | 1996-08-31 | 1999-07-15 | 전주범 | Method of classifying range images by quadtree |
KR20020062557A (en) * | 2001-01-20 | 2002-07-26 | 삼성전자 주식회사 | Apparatus for object extraction based on the feature matching of region in the segmented images and method therefor |
US20060104529A1 (en) * | 2004-11-12 | 2006-05-18 | Giuseppe Messina | Raster to vector conversion of a digital image |
KR102247662B1 (en) * | 2021-01-29 | 2021-05-03 | 주식회사 아이코드랩 | Device and method for automatically coloring cartoon sketch image |
CN113190939A (en) * | 2021-03-22 | 2021-07-30 | 桂林航天工业学院 | Large sparse complex network topology analysis and simplification method based on polygon coefficient |
KR102305229B1 (en) * | 2021-01-13 | 2021-09-27 | 셀렉트스타 주식회사 | Method and device for producing feature map information for extracting boundary information from image |
KR102316960B1 (en) | 2019-11-28 | 2021-10-22 | 광운대학교 산학협력단 | Method and apparatus for realtime object detection in unmanned aerial vehicle image |
-
2022
- 2022-03-10 KR KR1020220030253A patent/KR102447747B1/en active IP Right Grant
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
KR100210400B1 (en) | 1996-08-31 | 1999-07-15 | 전주범 | Method of classifying range images by quadtree |
KR20020062557A (en) * | 2001-01-20 | 2002-07-26 | 삼성전자 주식회사 | Apparatus for object extraction based on the feature matching of region in the segmented images and method therefor |
US20060104529A1 (en) * | 2004-11-12 | 2006-05-18 | Giuseppe Messina | Raster to vector conversion of a digital image |
US7567720B2 (en) * | 2004-11-12 | 2009-07-28 | Stmicroelectronics S.R.L. | Raster to vector conversion of a digital image |
KR102316960B1 (en) | 2019-11-28 | 2021-10-22 | 광운대학교 산학협력단 | Method and apparatus for realtime object detection in unmanned aerial vehicle image |
KR102305229B1 (en) * | 2021-01-13 | 2021-09-27 | 셀렉트스타 주식회사 | Method and device for producing feature map information for extracting boundary information from image |
KR102247662B1 (en) * | 2021-01-29 | 2021-05-03 | 주식회사 아이코드랩 | Device and method for automatically coloring cartoon sketch image |
CN113190939A (en) * | 2021-03-22 | 2021-07-30 | 桂林航天工业学院 | Large sparse complex network topology analysis and simplification method based on polygon coefficient |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP5861123B2 (en) | Feature extraction device, feature extraction method, feature extraction program, and image processing device | |
US8237710B1 (en) | Methods and apparatus for fill rule evaluation over a tessellation | |
US8988449B2 (en) | Image processing apparatus and image processing method | |
KR102247662B1 (en) | Device and method for automatically coloring cartoon sketch image | |
AU2016225841B2 (en) | Predicting accuracy of object recognition in a stitched image | |
CN111274968B (en) | Object-oriented road information extraction method and device and electronic equipment | |
CN113724128B (en) | Training sample expansion method | |
KR102447747B1 (en) | Image processing apparatus and method | |
CN111726814A (en) | Wireless access point deployment method and device, electronic equipment and storage medium | |
KR20210086980A (en) | Method, device, chip circuit and computer program product for recognizing mixed typeset texts | |
CN111127652A (en) | Indoor map construction method and device for robot and electronic equipment | |
CN113792827A (en) | Target object recognition method, electronic device, and computer-readable storage medium | |
US10074194B2 (en) | Graphical object content rendition | |
CN109948653B (en) | Image similarity judging method, electronic equipment and storage medium | |
US20120218582A1 (en) | Image forming apparatus, image forming method, and storage medium | |
US20160239964A1 (en) | Dot Counting Service | |
CN111814542A (en) | Geographic object extraction method and device and electronic equipment | |
CN115294301B (en) | Head model construction method, device, equipment and medium based on face image | |
JP4569785B2 (en) | Binarization device and binarization processing program | |
CN114827562A (en) | Projection method, projection device, projection equipment and computer storage medium | |
CN110310354B (en) | Vertex identification method and device in three-dimensional scene | |
CN111481108B (en) | Repositioning method and device for sweeper | |
KR102449790B1 (en) | Apparatus and method for automatically coloring sketch images | |
Lee et al. | Gradient preserving RGB-to-gray conversion using random forest | |
Soltanpoor et al. | Graph-based image segmentation using imperialist competitive algorithm |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
E701 | Decision to grant or registration of patent right | ||
GRNT | Written decision to grant |