CN104571513A - A method and system for simulating touch commands by shielding camera areas - Google Patents

A method and system for simulating touch commands by shielding camera areas Download PDF

Info

Publication number
CN104571513A
CN104571513A CN201410845233.1A CN201410845233A CN104571513A CN 104571513 A CN104571513 A CN 104571513A CN 201410845233 A CN201410845233 A CN 201410845233A CN 104571513 A CN104571513 A CN 104571513A
Authority
CN
China
Prior art keywords
event
preset
imaging area
image
touch
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
CN201410845233.1A
Other languages
Chinese (zh)
Inventor
易骏
杨晓东
杜明辉
袁仁坤
范立斌
林奇勇
范振粤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
DONGGUAN SOUTHSTAR ELECTRONICS Ltd
Original Assignee
DONGGUAN SOUTHSTAR ELECTRONICS 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 DONGGUAN SOUTHSTAR ELECTRONICS Ltd filed Critical DONGGUAN SOUTHSTAR ELECTRONICS Ltd
Priority to CN201410845233.1A priority Critical patent/CN104571513A/en
Publication of CN104571513A publication Critical patent/CN104571513A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/017Gesture based interaction, e.g. based on a set of recognized hand gestures

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Studio Devices (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The invention provides a method and a system for simulating a touch instruction by shielding a camera shooting area. Acquiring an image sequence of one shielding operation captured by a camera; identifying an acquired image sequence, separating two areas with and without a shelter in each image, and converting each separated image into a binary image; analyzing the change condition of the shielding object of each image in the image sequence, and identifying an operation event occurring in the image sequence; judging whether the identified operation event is consistent with a preset event in a preset event sequence or not, and if so, generating a corresponding simulation touch instruction; if not, generating no simulation touch instruction; and executing corresponding simulated touch operation according to the generated simulated touch instruction. Compared with the existing hand touch recognition, the invention greatly reduces the requirement on the system operation capability; compared with the existing touch input mode, the method saves keys or touch input elements.

Description

一种通过遮蔽摄像区域模拟触摸指令方法及系统A method and system for simulating touch commands by shielding camera areas

技术领域 technical field

本发明涉及一种物联网终端用户指令输入及设备控制领域,具体涉及一种通过遮蔽摄像区域模拟触摸指令方法及系统。 The present invention relates to the field of Internet of Things terminal user command input and device control, in particular to a method and system for simulating a touch command by shielding a camera area.

背景技术 Background technique

摄像系统被越来越广泛地用于各种应用场景,并衍生出各种带摄像功能的物联网终端产品,比如用于安防的网络监控摄像头、婴儿监护器、行车记录仪、可视门铃等等。这些物联网设备除了可以被远端用户通过互联网远程使用外,还具有被近端用户直接(面对面)操控使用的功能。比如网络监控摄像头的对讲功能中,近端用户可以控制对讲声音大小;部分婴儿监护器所带的夜光灯功能则允许近端用户直接调整灯光的明暗和色彩;行车记录仪和 可视门铃也大多带有直接对灯光或声音直接进行操控的功能。由此可见,近端用户对设备的部分功能子系统有近端操控的需求。 Camera systems are more and more widely used in various application scenarios, and various IoT terminal products with camera functions have been derived, such as network surveillance cameras for security, baby monitors, driving recorders, video doorbells, etc. wait. In addition to being remotely used by remote users through the Internet, these IoT devices also have the function of being directly (face-to-face) manipulated and used by near-end users. For example, in the intercom function of the network surveillance camera, the near-end user can control the volume of the intercom sound; the night light function of some baby monitors allows the near-end user to directly adjust the brightness and color of the light; Most of them also have the function of directly controlling the light or sound. It can be seen that the near-end user has a requirement for near-end control of some functional subsystems of the device.

      现有的摄像系统一般都具备一定的视频识别运算能力, 因此可以使用摄像头来作为输入设备,而现有的做法是通过对用户的指令输入主体(人手触摸)进行识别来实现操控,但是这种做法存在以下缺陷:由于基于视觉的人手识别需要涉及肤色、手形的识别运算,且运算量较为庞大,因此对嵌入式摄像系统的运算能力的要求比较高;再者就是需要嵌入按键或触摸屏等近端输入元件,这增加了系统的复杂性。 Existing camera systems generally have certain video recognition computing capabilities, so the camera can be used as an input device, and the existing method is to realize the control by recognizing the user's instruction input subject (human touch), but this The method has the following defects: since the human hand recognition based on vision needs to involve the recognition operation of skin color and hand shape, and the amount of calculation is relatively large, the requirements for the computing power of the embedded camera system are relatively high; end input elements, which increases the complexity of the system.

发明内容 Contents of the invention

本发明要解决的技术问题之一,在于提供一种通过遮蔽摄像区域模拟触摸指令方法,通过将对摄像区域的不同遮蔽操作映射为不同的模拟触摸指令,并利用生成的模拟触摸指令对电子设备进行控制,从而实现非触摸操作,并降低对系统运算能力的要求。 One of the technical problems to be solved by the present invention is to provide a method for simulating touch commands by shielding the camera area, by mapping different masking operations on the camera area into different simulated touch commands, and using the generated simulated touch commands to control electronic devices. Control, so as to achieve non-touch operation, and reduce the requirements for system computing power.

本发明要解决的技术问题之一是这样实现的:一种通过遮蔽摄像区域模拟触摸指令方法,所述方法包括如下步骤: One of the technical problems to be solved by the present invention is achieved in this way: a method for simulating a touch command by shielding the imaging area, the method comprising the following steps:

步骤10、采集摄像头捕捉的一次遮蔽操作的图像序列; Step 10, collecting an image sequence of a masking operation captured by the camera;

步骤20、识别采集的图像序列,将每一图像中有遮蔽物和无遮蔽物的两个区域分隔开,并将每一分隔后的图像均转换为二值化图像; Step 20, identifying the acquired image sequence, separating the two regions with and without occlusion in each image, and converting each separated image into a binary image;

步骤30、分析图像序列中每一图像的遮蔽物的变化情况,识别出图像序列发生的操作事件; Step 30. Analyzing the change of the occluder of each image in the image sequence, and identifying the operation event occurring in the image sequence;

步骤40、判断识别到的操作事件是否与预设事件序列中的预设事件相符,若是,则生成对应的模拟触摸指令,并进入步骤50;否,则不生成模拟触摸指令,并返回步骤10等待下一次遮蔽操作; Step 40, determine whether the recognized operation event matches the preset event in the preset event sequence, if so, generate a corresponding simulated touch command, and proceed to step 50; otherwise, do not generate a simulated touch command, and return to step 10 Wait for the next masking operation;

步骤50、根据生成的模拟触摸指令执行对应的模拟触摸操作。 Step 50: Execute a corresponding simulated touch operation according to the generated simulated touch instruction.

进一步地,所述步骤30具体为:如果图像序列中有遮蔽物的区域从小变大,且最终有遮蔽物的区域占据整个摄像区域的比例达到预设的遮蔽比例上限,则识别为遮蔽事件,之后进入步骤40;如果图像序列中无遮蔽物的区域从小变大,且最终无遮蔽物的区域占据整个摄像区域的比例达到预设的未遮蔽比例上限,则识别为解除遮蔽事件,之后进入步骤40;如果有遮蔽物的区域占据整个摄像区域的比例未最终达到预设的遮蔽比例上限,或者无遮蔽物的区域占据整个摄像区域的比例未最终达到预设的未遮蔽比例上限,则不被识别,并返回步骤10等待下一次遮蔽操作。 Further, the step 30 is specifically: if the area with the occluder in the image sequence becomes larger from small to large, and finally the ratio of the area with the occluder to the entire imaging area reaches the preset upper limit of the occlusion ratio, then identify it as an occlusion event, Then go to step 40; if the unoccluded area in the image sequence grows from small to large, and finally the proportion of the unoccluded area to the entire imaging area reaches the preset upper limit of the unmasked ratio, then it is recognized as an unoccluded event, and then enters the step 40; If the ratio of the area with occluders to the entire camera area does not reach the preset upper limit of the masking ratio, or the ratio of the area without occluders to the entire camera area does not reach the preset upper limit of the unmasked ratio, it will not be selected Identify, and return to step 10 to wait for the next masking operation.

进一步地,每所述遮蔽事件和解除遮蔽事件均具有事件发生方向以及事件发生速度;所述事件发生方向包括平行于所述摄像区域且进入角度为β的线性移动方向、垂直于所述摄像区域的发散方向或者垂直于所述摄像区域的收缩方向,其中0°≤β≤360°;所述事件发生速度为事件发生过程中各分阶段的速度集合或者事件发生的平均速度。 Further, each of the shading events and unshading events has an event occurrence direction and an event occurrence speed; the event occurrence direction includes a linear movement direction parallel to the imaging area and an entry angle of β, and a direction perpendicular to the imaging area. The divergence direction of or perpendicular to the contraction direction of the imaging area, where 0°≤β≤360°; the event occurrence speed is the set of speeds of each stage in the event occurrence process or the average speed of the event occurrence.

进一步地,所述预设事件包括事件类型、事件方向以及预设速度,且每所述预设事件均映射有一模拟触摸指令;所述预设速度为一具有上下限的范围值;所述模拟触摸指令包括方向滑动指令和点击指令。 Further, the preset event includes event type, event direction and preset speed, and each preset event is mapped to an analog touch command; the preset speed is a range value with upper and lower limits; the simulated The touch instruction includes a directional slide instruction and a click instruction.

进一步地,所述步骤40具体为:判断识别到的操作事件是否与预设事件序列中的预设事件相符,若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度相符,就生成对应该操作事件的模拟触摸指令,并进入步骤50;若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度不相符,则不生成模拟触摸指令,并终止对本次遮蔽操作的处理,同时返回步骤10等待下一次遮蔽操作。 Further, the step 40 is specifically: judging whether the recognized operation event is consistent with the preset event in the preset event sequence, if the recognized operation event is consistent with the event type, event direction and preset speed of the preset event , generate a simulated touch instruction corresponding to the operation event, and enter step 50; if the recognized operation event does not match the event type, event direction, and preset speed of the preset event, then no simulated touch instruction is generated, and the control of the operation is terminated. The processing of this masking operation returns to step 10 to wait for the next masking operation.

本发明要解决的技术问题之二,在于提供一种通过遮蔽摄像区域模拟触摸指令系统,通过将对摄像区域的不同遮蔽操作映射为不同的模拟触摸指令,并利用生成的模拟触摸指令对电子设备进行控制,从而实现非触摸操作,并降低对系统运算能力的要求。 The second technical problem to be solved by the present invention is to provide a system for simulating touch commands by shading the imaging area, by mapping different shading operations on the imaging area into different simulating touch commands, and using the generated simulating touch commands to control electronic devices. Control, so as to achieve non-touch operation, and reduce the requirements for system computing power.

本发明要解决的技术问题之二是这样实现的:一种通过遮蔽摄像区域模拟触摸指令系统,所述系统包括摄像单元、图像预处理单元、遮蔽识别单元、模拟触摸指令生成单元以及模拟触摸指令执行单元; The second technical problem to be solved by the present invention is achieved in the following way: a system for simulating touch commands by shielding the imaging area, the system includes a camera unit, an image preprocessing unit, a shading recognition unit, a simulated touch command generating unit, and a simulated touch command execution unit;

所述摄像单元,用于采集摄像头捕捉的一次遮蔽操作的图像序列; The camera unit is used to collect an image sequence captured by the camera for a shading operation;

所述图像预处理单元,用于识别采集的图像序列,将每一图像中有遮蔽物和无遮蔽物的两个区域分隔开,并将每一分隔后的图像均转换为二值化图像; The image pre-processing unit is used to identify the acquired image sequence, separate the two areas with occluded objects and unoccluded objects in each image, and convert each separated image into a binary image ;

所述遮蔽识别单元,用于分析图像序列中每一图像的遮蔽物的变化情况,识别出图像序列发生的操作事件; The occlusion identification unit is used to analyze the change of the occlusion of each image in the image sequence, and identify the operation events that occur in the image sequence;

所述模拟触摸指令生成单元,用于判断识别到的操作事件是否与预设事件序列中的预设事件相符,若是,则生成对应的模拟触摸指令,并进入所述模拟触摸指令执行单元;否,则不生成模拟触摸指令,并返回所述摄像单元等待下一次遮蔽操作; The simulated touch instruction generation unit is used to judge whether the recognized operation event matches the preset event in the preset event sequence, and if so, generate a corresponding simulated touch instruction and enter the simulated touch instruction execution unit; No , then no simulated touch instruction is generated, and the camera unit is returned to wait for the next shielding operation;

所述模拟触摸指令执行单元,用于根据生成的模拟触摸指令执行对应的模拟触摸操作。 The simulated touch command execution unit is configured to perform a corresponding simulated touch operation according to the generated simulated touch command.

进一步地,所述遮蔽识别单元具体为:如果图像序列中有遮蔽物的区域从小变大,且最终有遮蔽物的区域占据整个摄像区域的比例达到预设的遮蔽比例上限,则识别为遮蔽事件,之后进入所述模拟触摸指令生成单元;如果图像序列中无遮蔽物的区域从小变大,且最终无遮蔽物的区域占据整个摄像区域的比例达到预设的未遮蔽比例上限,则识别为解除遮蔽事件,之后进入所述模拟触摸指令生成单元;如果有遮蔽物的区域占据整个摄像区域的比例未最终达到预设的遮蔽比例上限,或者无遮蔽物的区域占据整个摄像区域的比例未最终达到预设的未遮蔽比例上限,则不被识别,并返回摄像单元等待下一次遮蔽操作。 Further, the occlusion identification unit is specifically: if the area with an occluder in the image sequence grows from small to large, and finally the ratio of the area with an occluder to the entire imaging area reaches the preset upper limit of the occlusion ratio, identify it as an occlusion event , and then enter the simulated touch command generation unit; if the unobstructed area in the image sequence increases from small to large, and finally the ratio of the unoccluded area to the entire imaging area reaches the preset upper limit of the unmasked ratio, then it is recognized as a release A shading event, and then enter the analog touch command generation unit; if the ratio of the area with an occluder to the entire imaging area does not finally reach the preset upper limit of the occlusion ratio, or the ratio of the area without an occlusion to the entire imaging area does not finally reach The preset upper limit of the unmasked ratio is not recognized, and returns to the camera unit to wait for the next shading operation.

进一步地,每所述遮蔽事件和解除遮蔽事件均具有事件发生方向以及事件发生速度;所述事件发生方向包括平行于所述摄像区域且进入角度为β的线性移动方向、垂直于所述摄像区域的发散方向或者垂直于所述摄像区域的收缩方向,其中0°≤β≤360°;所述事件发生速度为事件发生过程中各分阶段的速度集合或者事件发生的平均速度。 Further, each of the shading events and unshading events has an event occurrence direction and an event occurrence speed; the event occurrence direction includes a linear movement direction parallel to the imaging area and an entry angle of β, and a direction perpendicular to the imaging area. The divergence direction of or perpendicular to the contraction direction of the imaging area, where 0°≤β≤360°; the event occurrence speed is the set of speeds of each stage in the event occurrence process or the average speed of the event occurrence.

进一步地,所述预设事件包括事件类型、事件方向以及预设速度,且每所述预设事件均映射有一模拟触摸指令;所述预设速度为一具有上下限的范围值;所述模拟触摸指令包括方向滑动指令和点击指令。 Further, the preset event includes event type, event direction and preset speed, and each preset event is mapped to an analog touch command; the preset speed is a range value with upper and lower limits; the simulated The touch instruction includes a directional slide instruction and a click instruction.

进一步地,所述模拟触摸指令生成单元具体为:判断识别到的操作事件是否与预设事件序列中的预设事件相符,若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度相符,就生成对应该操作事件的模拟触摸指令,并进入模拟触摸指令执行单元;若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度不相符,则不生成模拟触摸指令,并终止对本次遮蔽操作的处理,同时返回所述摄像单元等待下一次遮蔽操作。 Further, the simulated touch command generating unit is specifically: judging whether the recognized operation event is consistent with the preset event in the preset event sequence, if the recognized operation event is consistent with the event type, event direction and expected event of the preset event If the speed matches, the simulated touch instruction corresponding to the operation event will be generated and entered into the simulated touch instruction execution unit; if the recognized operation event does not match the event type, event direction and preset speed of the preset event, no simulation will be generated. Touch the command, and terminate the processing of this shielding operation, and return to the camera unit to wait for the next shielding operation.

本发明具有如下优点:将对摄像区域的不同遮蔽操作映射为不同的模拟触摸指令,并利用生成的模拟触摸指令对电子设备进行控制。与现有人手触摸识别相比,对系统运算能力的要求大大降低了;与现有触摸输入方式相比,节省了按键或触摸输入元件。 The present invention has the following advantages: different shielding operations on the imaging area are mapped into different simulated touch commands, and electronic equipment is controlled by using the generated simulated touch commands. Compared with the existing human touch recognition, the requirement for the computing power of the system is greatly reduced; compared with the existing touch input method, keys or touch input components are saved.

附图说明 Description of drawings

下面参照附图结合实施例对本发明作进一步的说明。 The present invention will be further described below in conjunction with the embodiments with reference to the accompanying drawings.

图1为本发明方法执行流程图。 Fig. 1 is a flow chart of the execution of the method of the present invention.

图2为本发明摄像区域遮蔽的示意图。 FIG. 2 is a schematic diagram of the masking of the imaging area of the present invention.

图3为本发明中线性移动方向(a角度进入)的遮蔽事件的示意图。 FIG. 3 is a schematic diagram of occlusion events in the linear movement direction (a angle entry) in the present invention.

图4为本发明中线性移动方向(b角度移出)的解除遮蔽事件的示意图。 FIG. 4 is a schematic diagram of an unmasking event in a linear movement direction (b angular movement out) in the present invention.

图5为本发明中发散方向的遮蔽事件的示意图。 FIG. 5 is a schematic diagram of shading events in the divergent direction in the present invention.

图6为本发明中收缩方向的解除遮蔽事件的示意图。 FIG. 6 is a schematic diagram of an unshading event in a shrinking direction in the present invention.

图7为本发明系统结构示意图。 Fig. 7 is a schematic diagram of the system structure of the present invention.

具体实施方式 Detailed ways

请参阅图1至图6所示,一种通过遮蔽摄像区域模拟触摸指令方法的一较佳实施例,所述方法包括: Please refer to FIG. 1 to FIG. 6, a preferred embodiment of a method for simulating a touch command by covering an imaging area, the method includes:

步骤10、采集摄像头捕捉的一次遮蔽操作的图像序列; Step 10, collecting an image sequence of a masking operation captured by the camera;

当用户希望对电子设备进行近端操作时,用户就使用遮蔽物在摄像头贴近镜头处对镜头实施遮蔽操作,而摄像头将会捕捉该次遮蔽操作的图像序列,且所述图像序列会完整地记录用户遮蔽操作的全过程。用于遮蔽摄像区域的遮蔽物,可以是手指或者任意遮蔽片,如图2所示,只要遮蔽物可覆盖的区域大于直径为D(lens)的摄像区域即可。 When the user wants to perform a near-end operation on the electronic device, the user uses a shielding object to shield the lens near the camera lens, and the camera will capture the image sequence of the shielding operation, and the image sequence will be completely recorded The whole process of user masking operation. The shield used to shield the imaging area can be a finger or any shielding sheet, as shown in Figure 2, as long as the area covered by the shield is larger than the imaging area with a diameter of D (lens).

所述遮蔽操作包括: The masking operations include:

I. 遮蔽物从未遮蔽摄像区域到遮蔽摄像区域的过程; I. The process of the occluder from the unshielded camera area to the covered camera area;

II. 遮蔽物从遮蔽摄像区域到从摄像区域内移除的过程; II. The process of the occluder from covering the camera area to being removed from the camera area;

且以上I和II两个过程可以发生在任意的方向上。 And the above two processes I and II can occur in any direction.

其中未遮蔽摄像区域是指摄像区域内没有出现遮蔽物的影像,遮蔽摄像区域是指摄像区域有遮蔽物的影像。 Wherein, the non-occluded imaging area refers to an image in which no occluder appears in the imaging area, and the covered imaging area refers to an image in which an occluder exists in the imaging area.

步骤20、识别采集的图像序列,将每一图像中有遮蔽物和无遮蔽物的两个区域分隔开,并将每一分隔后的图像均转换为二值化图像; Step 20, identifying the acquired image sequence, separating the two regions with and without occlusion in each image, and converting each separated image into a binary image;

例如在对采集的图像序列进行识别时,可以将有遮蔽物的区域识别为前景区域,将无遮蔽物的区域识别为背景区域,那么识别出的每一图像都将被转换为包括前景区域和背景区域的二值化图像。 For example, when identifying the captured image sequence, the area with occluded objects can be identified as the foreground area, and the area without occluded objects can be identified as the background area, then each identified image will be converted to include the foreground area and Binarized image of the background region.

步骤30、分析图像序列中每一图像的遮蔽物的变化情况,识别出图像序列发生的操作事件;该步骤30具体为: Step 30, analyze the change of the occluder of each image in the image sequence, and identify the operation event that occurred in the image sequence; the step 30 is specifically:

如果图像序列中有遮蔽物的区域(即前景区域)从小变大,且最终有遮蔽物的区域占据整个摄像区域的比例达到预设的遮蔽比例上限,则识别为遮蔽事件,之后进入步骤40;如果图像序列中无遮蔽物的区域(即背景区域)从小变大,且最终无遮蔽物的区域占据整个摄像区域的比例达到预设的未遮蔽比例上限,则识别为解除遮蔽事件,之后进入步骤40;如果有遮蔽物的区域占据整个摄像区域的比例未最终达到预设的遮蔽比例上限,或者无遮蔽物的区域占据整个摄像区域的比例未最终达到预设的未遮蔽比例上限,则不被识别,并返回步骤10等待下一次遮蔽操作。 If the area with an occluder in the image sequence (ie, the foreground area) becomes larger from small to large, and finally the ratio of the area with an occluder to the entire camera area reaches the preset upper limit of the occlusion ratio, then it is recognized as an occlusion event, and then enter step 40; If the unoccluded area in the image sequence (that is, the background area) grows from small to large, and the proportion of the unoccluded area to the entire camera area reaches the preset upper limit of the unoccluded ratio, it is recognized as an unoccluded event, and then enters the step 40; If the ratio of the area with occluders to the entire camera area does not reach the preset upper limit of the masking ratio, or the ratio of the area without occluders to the entire camera area does not reach the preset upper limit of the unmasked ratio, it will not be selected Identify, and return to step 10 to wait for the next masking operation.

每所述遮蔽事件和解除遮蔽事件均具有事件发生方向,用于反映用户从摄像头的某一方位向另一方位实施的遮蔽事件;所述事件发生方向包括平行于所述摄像区域且进入角度为β的线性移动方向、垂直于所述摄像区域的发散方向或者垂直于所述摄像区域的收缩方向,其中0°≤β≤360°。如图3至图6所示,其中,图3表示的是平行于所述摄像区域的线性移动方向(a角度进入)的遮蔽事件的一个遮蔽过程;图4表示的是平行于所述摄像区域的线性移动方向(b角度移出)的解除遮蔽事件的一个解除遮蔽过程;图5表示的是垂直于所述摄像区域的发散方向的遮蔽事件的一个遮蔽过程,即遮蔽物沿垂直于所述摄像区域并远离该摄像区域的方向移动;图6表示的是垂直于所述摄像区域的收缩方向的解除遮蔽事件的一个解除遮蔽过程,即遮蔽物沿垂直于所述摄像区域并靠近该摄像区域的方向移动。 Each of the shading event and unshading event has an event occurrence direction, which is used to reflect the shading event implemented by the user from a certain orientation of the camera to another orientation; the event occurrence direction includes parallel to the camera area and an entry angle of The linear movement direction of β, the divergence direction perpendicular to the imaging area, or the shrinking direction perpendicular to the imaging area, wherein 0°≤β≤360°. As shown in Figures 3 to 6, among them, Figure 3 shows a shading process of a shading event parallel to the linear movement direction (a angle entering) of the imaging area; Figure 4 shows a shading process parallel to the imaging area An unmasking process of the unmasking event in the linear moving direction (b angle moves out); Figure 5 shows a shading process of the shading event perpendicular to the divergence direction of the imaging area, that is, the occluder moves along the direction perpendicular to the imaging area area and move away from the direction of the camera area; Figure 6 shows a release process of the masking event perpendicular to the contraction direction of the camera area, that is, the occluder moves along the direction perpendicular to the camera area and close to the camera area direction to move.

所述遮蔽事件和解除遮蔽事件还具有事件速度,所述事件发生速度为事件发生过程中各分阶段的速度集合或者事件发生的平均速度,该事件速度主要用于描述事件的时间特性。在本实施例中使用的是简单的平均速度来描述遮蔽事件和解除遮蔽事件发生的快慢程度。 The occlusion event and the unmasking event also have an event velocity, which is a set of velocities at each stage in the event occurrence process or an average velocity of the event occurrence, and the event velocity is mainly used to describe the time characteristics of the event. In this embodiment, a simple average speed is used to describe the speed of occurrence of occlusion events and unocclusion events.

步骤40、判断识别到的操作事件是否与预设事件序列中的预设事件相符,若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度相符,就生成对应该操作事件的模拟触摸指令,并进入步骤50;若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度不相符,则不生成模拟触摸指令,并终止对本次遮蔽操作的处理,同时返回步骤10等待下一次遮蔽操作。所述模拟触摸指令包括方向滑动指令和点击指令。 Step 40, judging whether the recognized operation event matches the preset event in the preset event sequence, if the recognized operation event matches the event type, event direction and preset speed of the preset event, generate the corresponding operation event If the recognized operation event does not match the event type, event direction and preset speed of the preset event, the simulated touch command will not be generated, and the processing of this masking operation will be terminated. At the same time return to step 10 to wait for the next masking operation. The simulated touch instruction includes a directional slide instruction and a click instruction.

本实施例的预设事件包括: The preset events of this embodiment include:

    0度方向的遮蔽事件(即遮蔽物沿摄像区域水平向右遮蔽); The occlusion event in the direction of 0 degrees (that is, the occlusion is occluded horizontally to the right along the camera area);

    0度方向的解除遮蔽事件(即遮蔽物沿摄像区域水平向右解除遮蔽); Unblocking events in the 0-degree direction (that is, the occlusion is unblocked horizontally to the right along the camera area);

    90度方向的遮蔽事件(即遮蔽物沿摄像区域竖直向上遮蔽); The occlusion event in the 90-degree direction (that is, the occluder covers vertically upward along the camera area);

    90度方向的解除遮蔽事件(即遮蔽物沿摄像区域竖直向上解除遮蔽); Unblocking events in the 90-degree direction (that is, the occluder is unblocked vertically upward along the camera area);

    180度方向的遮蔽事件(即遮蔽物沿摄像区域水平向左遮蔽); The occlusion event in the 180-degree direction (that is, the occlusion is occluded horizontally to the left along the camera area);

    180度方向的解除遮蔽事件(即遮蔽物沿摄像区域水平向左解除遮蔽); Unblocking event in 180-degree direction (that is, the occluder is unblocked horizontally to the left along the camera area);

    270度方向的遮蔽事件(即遮蔽物沿摄像区域竖直向下遮蔽); Covering events in the 270-degree direction (that is, the cover is covered vertically downward along the camera area);

    270度方向的解除遮蔽事件(即遮蔽物沿摄像区域竖直向下解除遮蔽); Unblock event in 270-degree direction (that is, the occluder unblocks vertically downward along the camera area);

    发散方向的遮蔽事件(遮蔽物靠近摄像头); Occlusion events in the divergent direction (the occlusion is close to the camera);

    收缩方向的解除遮蔽事件(遮蔽物远离摄像头)。 Unocclusion events in the shrinking direction (the occlusion moves away from the camera).

    本实施例中预设事件与模拟触摸指令之间的映射关系: In this embodiment, the mapping relationship between preset events and simulated touch commands:

    预设速度限制下的 0度方向的遮蔽事件加上 0度方向的解除遮蔽事件:水平向右滑动指令;   Under the preset speed limit, the masking event in the 0-degree direction plus the un-masking event in the 0-degree direction: the horizontal slide command to the right;

预设速度限制下的 90度方向的遮蔽事件加上90度方向的解除遮蔽事件:水平向上滑动指令; 90-degree shading event plus 90-degree unshading event under the preset speed limit: Horizontal upward slide command;

预设速度限制下的 180度方向的遮蔽事件 加上180度方向的解除遮蔽事件:水平向左滑动指令: 180-degree shading event under the preset speed limit plus 180-degree unshading event: Horizontal left swipe command:

预设速度限制下的 270度方向的遮蔽事件 加上 270度方向的解除遮蔽事件: 水平向下滑动指令: 270-degree shading event at preset speed limit plus 270-degree unshading event: Horizontal downward slide command:

    预设速度限制下的发散方向的遮蔽事件:点击指令;   Covering events in the divergence direction under the preset speed limit: click on the command;

    预设速度限制下的收缩方向的解除遮蔽事件:解除点击指令。 Unmasking event in the contraction direction under the preset speed limit: release the click command.

    所述预设速度为一具有上下限的范围值,所述预设速度限制下的遮蔽事件和解除遮蔽事件是指:遮蔽事件和解除遮蔽事件的速度要高于预设速度的下限,并低于预设速度的上限。 The preset speed is a range value with an upper and lower limit, and the shading event and the unshading event under the preset speed limit mean that the speed of the shading event and the unshading event is higher than the lower limit of the preset speed and lower than the lower limit of the preset speed. at the upper limit of the preset speed.

步骤50、根据生成的模拟触摸指令执行对应的模拟触摸操作。 Step 50: Execute a corresponding simulated touch operation according to the generated simulated touch instruction.

    例如,在一带有灯光功能的摄像系统中,可以用生成的向上滑动指令来控制增加灯光亮度,用生成的向下滑动指令来控制降低灯光亮度。又例如,在一带有音乐播放功能的摄像系统中,可以用生成的向上滑动指令来控制增加音量,用生成的向下滑动指令来控制降低音量,用生成的向右滑动指令来控制将播放歌曲切换到上一首,用生成的向左滑动指令来控制将播放歌曲切换到下一首,用点击指令和解除点击指令来切换播放和暂停播放状态。 For example, in a camera system with lighting function, the generated upward slide command can be used to control the increase of light brightness, and the generated downward slide command can be used to control the decrease of light brightness. For another example, in a camera system with a music playback function, the generated upward sliding command can be used to control the volume increase, the generated downward sliding command can be used to control the volume down, and the generated right sliding command can be used to control the song to be played. Switch to the previous song, use the generated left sliding command to control the switching of the playing song to the next song, and use the click command and release the click command to switch between playing and pausing.

请参阅图2至图7所示,一种通过遮蔽摄像区域模拟触摸指令系统的一较佳实施,所述系统包括摄像单元、图像预处理单元、遮蔽识别单元、模拟触摸指令生成单元以及模拟触摸指令执行单元; Please refer to Fig. 2 to Fig. 7, a preferred implementation of a system for simulating a touch command by shielding the camera area, the system includes a camera unit, an image preprocessing unit, a occlusion recognition unit, a simulated touch command generation unit, and a simulated touch instruction execution unit;

所述摄像单元,用于采集摄像头捕捉的一次遮蔽操作的图像序列; The camera unit is used to collect an image sequence captured by the camera for a shading operation;

当用户希望对电子设备进行近端操作时,用户就使用遮蔽物在摄像头贴近镜头处对镜头实施遮蔽操作,而摄像头将会捕捉该次遮蔽操作的图像序列,且所述图像序列会完整地记录用户遮蔽操作的全过程。用于遮蔽摄像区域的遮蔽物,可以是手指或者任意遮蔽片,如图2所示,只要遮蔽物可覆盖的区域大于直径为D(lens)的摄像区域即可。 When the user wants to perform a near-end operation on the electronic device, the user uses a shielding object to shield the lens near the camera lens, and the camera will capture the image sequence of the shielding operation, and the image sequence will be completely recorded The whole process of user masking operation. The shield used to shield the imaging area can be a finger or any shielding sheet, as shown in Figure 2, as long as the area covered by the shield is larger than the imaging area with a diameter of D (lens).

所述遮蔽操作包括: The masking operations include:

I. 遮蔽物从未遮蔽摄像区域到遮蔽摄像区域的过程; I. The process of the occluder from the unshielded camera area to the covered camera area;

II. 遮蔽物从遮蔽摄像区域到从摄像区域内移除的过程; II. The process of the occluder from covering the camera area to being removed from the camera area;

且以上I和II两个过程可以发生在任意的方向上。 And the above two processes I and II can occur in any direction.

其中未遮蔽摄像区域是指摄像区域内没有出现遮蔽物的影像,遮蔽摄像区域是指摄像区域有遮蔽物的影像 Among them, the unoccluded imaging area refers to the image without occlusions in the imaging area, and the shaded imaging area refers to the image with the occlusion in the imaging area.

所述图像预处理单元,用于识别采集的图像序列,将每一图像中有遮蔽物和无遮蔽物的两个区域分隔开,并将每一分隔后的图像均转换为二值化图像; The image pre-processing unit is used to identify the acquired image sequence, separate the two areas with occluded objects and unoccluded objects in each image, and convert each separated image into a binary image ;

例如在对采集的图像序列进行识别时,可以将有遮蔽物的区域识别为前景区域,将无遮蔽物的区域识别为背景区域,那么识别出的每一图像都将被转换为包括前景区域和背景区域的二值化图像。 For example, when identifying the captured image sequence, the area with occluded objects can be identified as the foreground area, and the area without occluded objects can be identified as the background area, then each identified image will be converted to include the foreground area and Binarized image of the background region.

所述遮蔽识别单元,用于分析图像序列中每一图像的遮蔽物的变化情况,识别出图像序列发生的操作事件;该遮蔽识别单元具体为: The occlusion identification unit is used to analyze the change of the occlusion of each image in the image sequence, and identify the operation events that occur in the image sequence; the occlusion identification unit is specifically:

如果图像序列中有遮蔽物的区域(即前景区域)从小变大,且最终有遮蔽物的区域占据整个摄像区域的比例达到预设的遮蔽比例上限,则识别为遮蔽事件,之后进入所述模拟触摸指令生成单元;如果图像序列中无遮蔽物的区域(即背景区域)从小变大,且最终无遮蔽物的区域占据整个摄像区域的比例达到预设的未遮蔽比例上限,则识别为解除遮蔽事件,之后进入所述模拟触摸指令生成单元;如果有遮蔽物的区域占据整个摄像区域的比例未最终达到预设的遮蔽比例上限,或者无遮蔽物的区域占据整个摄像区域的比例未最终达到预设的未遮蔽比例上限,则不被识别,并返回摄像单元等待下一次遮蔽操作。 If the area with occluders in the image sequence (that is, the foreground area) grows from small to large, and finally the ratio of the area with occluders to the entire camera area reaches the preset upper limit of the occlusion ratio, it will be recognized as an occlusion event, and then enter the simulation Touch command generation unit; if the unobstructed area in the image sequence (that is, the background area) grows from small to large, and the proportion of the unoccluded area in the entire camera area reaches the preset upper limit of the unmasked ratio, it will be recognized as unmasked event, and then enter the analog touch command generating unit; if the ratio of the area with a occluder to the entire imaging area does not finally reach the preset upper limit of the occlusion ratio, or the ratio of the area without an occluder to the entire imaging area does not finally reach the preset If the upper limit of the unmasked ratio is set, it will not be recognized, and return to the camera unit to wait for the next shading operation.

每所述遮蔽事件和解除遮蔽事件均具有事件发生方向,用于反映用户从摄像头的某一方位向另一方位实施的遮蔽事件;所述事件发生方向包括平行于所述摄像区域且进入角度为β的线性移动方向、垂直于所述摄像区域的发散方向或者垂直于所述摄像区域的收缩方向,其中0°≤β≤360°。如图3至图6所示,其中,图3表示的是平行于所述摄像区域的线性移动方向(a角度进入)的遮蔽事件的一个遮蔽过程;图4表示的是平行于所述摄像区域的线性移动方向(b角度移出)的解除遮蔽事件的一个解除遮蔽过程;图5表示的是垂直于所述摄像区域的发散方向的遮蔽事件的一个遮蔽过程,即遮蔽物沿垂直于所述摄像区域并远离该摄像区域的方向移动;图6表示的是垂直于所述摄像区域的收缩方向的解除遮蔽事件的一个解除遮蔽过程,即遮蔽物沿垂直于所述摄像区域并靠近该摄像区域的方向移动。 Each of the shading event and unshading event has an event occurrence direction, which is used to reflect the shading event implemented by the user from a certain orientation of the camera to another orientation; the event occurrence direction includes parallel to the camera area and an entry angle of The linear movement direction of β, the divergence direction perpendicular to the imaging area, or the shrinking direction perpendicular to the imaging area, wherein 0°≤β≤360°. As shown in Figures 3 to 6, among them, Figure 3 shows a shading process of a shading event parallel to the linear movement direction (a angle entering) of the imaging area; Figure 4 shows a shading process parallel to the imaging area An unmasking process of the unmasking event in the linear moving direction (b angle moves out); Figure 5 shows a shading process of the shading event perpendicular to the divergence direction of the imaging area, that is, the occluder moves along the direction perpendicular to the imaging area area and move away from the direction of the camera area; Figure 6 shows a release process of the masking event perpendicular to the contraction direction of the camera area, that is, the occluder moves along the direction perpendicular to the camera area and close to the camera area direction to move.

所述遮蔽事件和解除遮蔽事件还具有事件速度,所述事件发生速度为事件发生过程中各分阶段的速度集合或者事件发生的平均速度,该事件速度主要用于描述事件的时间特性。在本实施例中使用的是简单的平均速度来描述遮蔽事件和解除遮蔽事件发生的快慢程度。 The occlusion event and the unmasking event also have an event velocity, which is a set of velocities at each stage in the event occurrence process or an average velocity of the event occurrence, and the event velocity is mainly used to describe the time characteristics of the event. In this embodiment, a simple average speed is used to describe the speed of occurrence of occlusion events and unocclusion events.

所述模拟触摸指令生成单元,用于判断识别到的操作事件是否与预设事件序列中的预设事件相符,若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度相符,就生成对应该操作事件的模拟触摸指令,并进入模拟触摸指令执行单元;若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度不相符,则不生成模拟触摸指令,并终止对本次遮蔽操作的处理,同时返回摄像单元等待下一次遮蔽操作。所述模拟触摸指令包括方向滑动指令和点击指令。 The simulated touch instruction generation unit is used to judge whether the recognized operation event is consistent with the preset event in the preset event sequence, if the recognized operation event is consistent with the event type, event direction and preset speed of the preset event , generate a simulated touch command corresponding to the operation event, and enter the simulated touch command execution unit; if the recognized operation event does not match the event type, event direction and preset speed of the preset event, no simulated touch command is generated, And terminate the processing of this shading operation, and return to the camera unit to wait for the next shading operation. The simulated touch instruction includes a directional slide instruction and a click instruction.

本实施例的预设事件包括: The preset events of this embodiment include:

    0度方向的遮蔽事件(即遮蔽物沿摄像区域水平向右遮蔽); The occlusion event in the direction of 0 degrees (that is, the occlusion is occluded horizontally to the right along the camera area);

    0度方向的解除遮蔽事件(即遮蔽物沿摄像区域水平向右解除遮蔽); Unblocking events in the 0-degree direction (that is, the occlusion is unblocked horizontally to the right along the camera area);

    90度方向的遮蔽事件(即遮蔽物沿摄像区域竖直向上遮蔽); The occlusion event in the 90-degree direction (that is, the occluder covers vertically upward along the camera area);

    90度方向的解除遮蔽事件(即遮蔽物沿摄像区域竖直向上解除遮蔽); Unblocking events in the 90-degree direction (that is, the occluder is unblocked vertically upward along the camera area);

    180度方向的遮蔽事件(即遮蔽物沿摄像区域水平向左遮蔽); The occlusion event in the 180-degree direction (that is, the occlusion is occluded horizontally to the left along the camera area);

    180度方向的解除遮蔽事件(即遮蔽物沿摄像区域水平向左解除遮蔽); Unblocking event in 180-degree direction (that is, the occluder is unblocked horizontally to the left along the camera area);

    270度方向的遮蔽事件(即遮蔽物沿摄像区域竖直向下遮蔽); Covering events in the 270-degree direction (that is, the cover is covered vertically downward along the camera area);

    270度方向的解除遮蔽事件(即遮蔽物沿摄像区域竖直向下解除遮蔽); Unblock event in 270-degree direction (that is, the occluder unblocks vertically downward along the camera area);

    发散方向的遮蔽事件(遮蔽物靠近摄像头); Occlusion events in the divergent direction (the occlusion is close to the camera);

    收缩方向的解除遮蔽事件(遮蔽物远离摄像头)。 Unocclusion events in the shrinking direction (the occlusion moves away from the camera).

    本实施例中预设事件与模拟触摸指令之间的映射关系: In this embodiment, the mapping relationship between preset events and simulated touch commands:

    预设速度限制下的 0度方向的遮蔽事件加上 0度方向的解除遮蔽事件:水平向右滑动指令;   Under the preset speed limit, the masking event in the 0-degree direction plus the un-masking event in the 0-degree direction: the horizontal slide command to the right;

预设速度限制下的 90度方向的遮蔽事件加上90度方向的解除遮蔽事件:水平向上滑动指令; 90-degree shading event plus 90-degree unshading event under the preset speed limit: Horizontal upward slide command;

预设速度限制下的 180度方向的遮蔽事件 加上 180度方向的解除遮蔽事件:水平向左滑动指令: 180-degree shading event under the preset speed limit plus 180-degree unshading event: Horizontal left swipe command:

预设速度限制下的 270度方向的遮蔽事件 加上 270度方向的解除遮蔽事件: 水平向下滑动指令: 270-degree shading event at preset speed limit plus 270-degree unshading event: Horizontal downward slide command:

    预设速度限制下的发散方向的遮蔽事件:点击指令;   Covering events in the divergence direction under the preset speed limit: click on the command;

    预设速度限制下的收缩方向的解除遮蔽事件:解除点击指令。 Unmasking event in the contraction direction under the preset speed limit: release the click command.

所述预设速度为一具有上下限的范围值,所述预设速度限制下的遮蔽事件和解除遮蔽事件是指:遮蔽事件和解除遮蔽事件的速度要高于预设速度的下限,并低于预设速度的上限。 The preset speed is a range value with an upper and lower limit, and the shading event and the unshading event under the preset speed limit mean that the speed of the shading event and the unshading event is higher than the lower limit of the preset speed and lower than the lower limit of the preset speed. at the upper limit of the preset speed.

模拟触摸指令执行单元,用于根据生成的模拟触摸指令执行对应的模拟触摸操作。 The simulated touch command execution unit is configured to execute a corresponding simulated touch operation according to the generated simulated touch command.

例如,在一带有灯光功能的摄像系统中,可以用生成的向上滑动指令来控制增加灯光亮度,用生成的向下滑动指令来控制降低灯光亮度。又例如,在一带有音乐播放功能的摄像系统中,可以用生成的向上滑动指令来控制增加音量,用生成的向下滑动指令来控制降低音量,用生成的向右滑动指令来控制将播放歌曲切换到上一首,用生成的向左滑动指令来控制将播放歌曲切换到下一首,用点击指令和解除点击指令来切换播放和暂停播放状态。 For example, in a camera system with a lighting function, the generated upward sliding command can be used to control the increase of the brightness of the light, and the generated downward sliding command can be used to control the reduction of the brightness of the light. For another example, in a camera system with a music playback function, the generated upward sliding command can be used to control the volume increase, the generated downward sliding command can be used to control the volume down, and the generated right sliding command can be used to control the song to be played. Switch to the previous song, use the generated left sliding command to control the switching of the playing song to the next song, and use the click command and release the click command to switch between playing and pausing.

综上所述,本发明将对摄像区域的不同遮蔽操作映射为不同的模拟触摸指令,并利用生成的模拟触摸指令对电子设备进行控制。与现有人手触摸识别相比,对系统运算能力的要求大大降低了;与现有触摸输入方式相比,节省了按键或触摸输入元件。 To sum up, the present invention maps different shielding operations on the imaging area into different simulated touch commands, and uses the generated simulated touch commands to control the electronic device. Compared with the existing human touch recognition, the requirement for the computing power of the system is greatly reduced; compared with the existing touch input method, keys or touch input elements are saved.

虽然以上描述了本发明的具体实施方式,但是熟悉本技术领域的技术人员应当理解,我们所描述的具体的实施例只是说明性的,而不是用于对本发明的范围的限定,熟悉本领域的技术人员在依照本发明的精神所作的等效的修饰以及变化,都应当涵盖在本发明的权利要求所保护的范围内。 Although the specific embodiments of the present invention have been described above, those skilled in the art should understand that the specific embodiments we have described are only illustrative, rather than used to limit the scope of the present invention. Equivalent modifications and changes made by skilled personnel in accordance with the spirit of the present invention shall fall within the protection scope of the claims of the present invention.

Claims (10)

1.一种通过遮蔽摄像区域模拟触摸指令方法,其特征在于:包括如下步骤: 1. A method for simulating a touch command by covering the imaging area, is characterized in that: comprises the steps: 步骤10、采集摄像头捕捉的一次遮蔽操作的图像序列; Step 10, collecting an image sequence of a masking operation captured by the camera; 步骤20、识别采集的图像序列,将每一图像中有遮蔽物和无遮蔽物的两个区域分隔开,并将每一分隔后的图像均转换为二值化图像; Step 20, identifying the acquired image sequence, separating the two regions with and without occlusion in each image, and converting each separated image into a binary image; 步骤30、分析图像序列中每一图像的遮蔽物的变化情况,识别出图像序列发生的操作事件; Step 30. Analyzing the change of the occluder of each image in the image sequence, and identifying the operation event occurring in the image sequence; 步骤40、判断识别到的操作事件是否与预设事件序列中的预设事件相符,若是,则生成对应的模拟触摸指令,并进入步骤50;否,则不生成模拟触摸指令,并返回步骤10等待下一次遮蔽操作; Step 40, determine whether the recognized operation event matches the preset event in the preset event sequence, if so, generate a corresponding simulated touch command, and proceed to step 50; otherwise, do not generate a simulated touch command, and return to step 10 Wait for the next masking operation; 步骤50、根据生成的模拟触摸指令执行对应的模拟触摸操作。 Step 50: Execute a corresponding simulated touch operation according to the generated simulated touch instruction. 2.根据权利要求1所述的一种通过遮蔽摄像区域模拟触摸指令方法,其特征在于:所述步骤30具体为:如果图像序列中有遮蔽物的区域从小变大,且最终有遮蔽物的区域占据整个摄像区域的比例达到预设的遮蔽比例上限,则识别为遮蔽事件,之后进入步骤40;如果图像序列中无遮蔽物的区域从小变大,且最终无遮蔽物的区域占据整个摄像区域的比例达到预设的未遮蔽比例上限,则识别为解除遮蔽事件,之后进入步骤40;如果有遮蔽物的区域占据整个摄像区域的比例未最终达到预设的遮蔽比例上限,或者无遮蔽物的区域占据整个摄像区域的比例未最终达到预设的未遮蔽比例上限,则不被识别,并返回步骤10等待下一次遮蔽操作。 2. The method for simulating touch commands by covering the imaging area according to claim 1, characterized in that: the step 30 is specifically: if the area with the occluder in the image sequence grows from small to large, and finally there is an occluder If the proportion of the area occupying the entire imaging area reaches the preset upper limit of the occlusion ratio, it will be identified as an occlusion event, and then go to step 40; if the area without occlusion in the image sequence becomes larger from small to large, and finally the area without occlusion occupies the entire imaging area If the ratio of the ratio reaches the preset upper limit of the unmasked ratio, it is recognized as an unmasked event, and then enters step 40; If the proportion of the area occupying the entire imaging area does not reach the preset upper limit of the unmasked proportion, it will not be recognized, and return to step 10 to wait for the next shading operation. 3.根据权利要求2所述的一种通过遮蔽摄像区域模拟触摸指令方法,其特征在于:每所述遮蔽事件和解除遮蔽事件均具有事件发生方向以及事件发生速度;所述事件发生方向包括平行于所述摄像区域且进入角度为β的线性移动方向、垂直于所述摄像区域的发散方向或者垂直于所述摄像区域的收缩方向,其中0°≤β≤360°;所述事件发生速度为事件发生过程中各分阶段的速度集合或者事件发生的平均速度。 3. A method for simulating a touch command by shielding an imaging area according to claim 2, wherein: each of said shielding event and unshading event has an event occurrence direction and an event occurrence speed; said event occurrence direction includes parallel A linear movement direction in the imaging area and an entry angle of β, a diverging direction perpendicular to the imaging area, or a shrinking direction perpendicular to the imaging area, wherein 0°≤β≤360°; the event occurrence speed is The collection of velocities for each stage in the course of an event or the average velocity of an event. 4.根据权利要求3所述的一种通过遮蔽摄像区域模拟触摸指令方法,其特征在于:所述预设事件包括事件类型、事件方向以及预设速度,且每所述预设事件均映射有一模拟触摸指令;所述预设速度为一具有上下限的范围值;所述模拟触摸指令包括方向滑动指令和点击指令。 4. A method for simulating a touch command by covering an imaging area according to claim 3, wherein the preset event includes event type, event direction and preset speed, and each preset event is mapped to a An analog touch command; the preset speed is a range value with upper and lower limits; the simulated touch command includes a direction slide command and a click command. 5.根据权利要求4所述的一种通过遮蔽摄像区域模拟触摸指令方法,其特征在于:所述步骤40具体为:判断识别到的操作事件是否与预设事件序列中的预设事件相符,若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度相符,就生成对应该操作事件的模拟触摸指令,并进入步骤50;若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度不相符,则不生成模拟触摸指令,并终止对本次遮蔽操作的处理,同时返回步骤10等待下一次遮蔽操作。 5. A method for simulating a touch command by shielding an imaging area according to claim 4, wherein the step 40 is specifically: judging whether the recognized operation event matches a preset event in a preset event sequence, If the identified operation event matches the event type, event direction and preset speed of the preset event, an analog touch instruction corresponding to the operation event is generated and enters step 50; if the identified operation event is consistent with the preset event If the type, event direction, and preset speed do not match, no simulated touch command will be generated, and the processing of this shielding operation will be terminated, and at the same time, return to step 10 to wait for the next shielding operation. 6.一种通过遮蔽摄像区域模拟触摸指令系统,其特征在于:包括摄像单元、图像预处理单元、遮蔽识别单元、模拟触摸指令生成单元以及模拟触摸指令执行单元; 6. A system for simulating a touch command by covering an imaging area, characterized in that it includes a camera unit, an image preprocessing unit, a occlusion recognition unit, a simulated touch command generation unit, and a simulated touch command execution unit; 所述摄像单元,用于采集摄像头捕捉的一次遮蔽操作的图像序列; The camera unit is used to collect an image sequence captured by the camera for a shading operation; 所述图像预处理单元,用于识别采集的图像序列,将每一图像中有遮蔽物和无遮蔽物的两个区域分隔开,并将每一分隔后的图像均转换为二值化图像; The image pre-processing unit is used to identify the acquired image sequence, separate the two areas with occluded objects and unoccluded objects in each image, and convert each separated image into a binary image ; 所述遮蔽识别单元,用于分析图像序列中每一图像的遮蔽物的变化情况,识别出图像序列发生的操作事件; The occlusion identification unit is used to analyze the change of the occlusion of each image in the image sequence, and identify the operation events that occur in the image sequence; 所述模拟触摸指令生成单元,用于判断识别到的操作事件是否与预设事件序列中的预设事件相符,若是,则生成对应的模拟触摸指令,并进入所述模拟触摸指令执行单元;否,则不生成模拟触摸指令,并返回所述摄像单元等待下一次遮蔽操作; The simulated touch instruction generation unit is used to judge whether the recognized operation event matches the preset event in the preset event sequence, and if so, generate a corresponding simulated touch instruction and enter the simulated touch instruction execution unit; No , then no simulated touch instruction is generated, and the camera unit is returned to wait for the next shielding operation; 所述模拟触摸指令执行单元,用于根据生成的模拟触摸指令执行对应的模拟触摸操作。 The simulated touch command execution unit is configured to perform a corresponding simulated touch operation according to the generated simulated touch command. 7.根据权利要求6所述的一种通过遮蔽摄像区域模拟触摸指令系统,其特征在于:所述遮蔽识别单元具体为:如果图像序列中有遮蔽物的区域从小变大,且最终有遮蔽物的区域占据整个摄像区域的比例达到预设的遮蔽比例上限,则识别为遮蔽事件,之后进入所述模拟触摸指令生成单元;如果图像序列中无遮蔽物的区域从小变大,且最终无遮蔽物的区域占据整个摄像区域的比例达到预设的未遮蔽比例上限,则识别为解除遮蔽事件,之后进入所述模拟触摸指令生成单元;如果有遮蔽物的区域占据整个摄像区域的比例未最终达到预设的遮蔽比例上限,或者无遮蔽物的区域占据整个摄像区域的比例未最终达到预设的未遮蔽比例上限,则不被识别,并返回摄像单元等待下一次遮蔽操作。 7. The system for simulating touch commands by shielding the imaging area according to claim 6, wherein the shielding recognition unit is specifically: if the region with a shield in the image sequence becomes larger from small to large, and finally there is a shield If the proportion of the area occupied by the entire imaging area reaches the preset upper limit of the occlusion ratio, it will be recognized as an occlusion event, and then enter the analog touch command generation unit; If the proportion of the area occupied by the entire imaging area reaches the preset upper limit of the unmasked ratio, it will be recognized as an unmasking event, and then enter the analog touch command generation unit; If the upper limit of the occlusion ratio is set, or the ratio of the unoccluded area to the entire imaging area does not finally reach the preset upper limit of the unmasking ratio, it will not be recognized and return to the camera unit to wait for the next occlusion operation. 8.根据权利要求7所述的一种通过遮蔽摄像区域模拟触摸指令系统,其特征在于:每所述遮蔽事件和解除遮蔽事件均具有事件发生方向以及事件发生速度;所述事件发生方向包括平行于所述摄像区域且进入角度为β的线性移动方向、垂直于所述摄像区域的发散方向或者垂直于所述摄像区域的收缩方向,其中0°≤β≤360°;所述事件发生速度为事件发生过程中各分阶段的速度集合或者事件发生的平均速度。 8. A system for simulating touch commands by shielding the imaging area according to claim 7, characterized in that: each of the shielding events and unshading events has an event occurrence direction and an event occurrence speed; the event occurrence direction includes parallel A linear movement direction in the imaging area and an entry angle of β, a diverging direction perpendicular to the imaging area, or a shrinking direction perpendicular to the imaging area, wherein 0°≤β≤360°; the event occurrence speed is The collection of velocities for each stage in the course of an event or the average velocity of an event. 9.根据权利要求8所述的一种通过遮蔽摄像区域模拟触摸指令系统,其特征在于:所述预设事件包括事件类型、事件方向以及预设速度,且每所述预设事件均映射有一模拟触摸指令;所述预设速度为一具有上下限的范围值;所述模拟触摸指令包括方向滑动指令和点击指令。 9. A system for simulating touch commands by shielding camera areas according to claim 8, wherein the preset events include event types, event directions and preset speeds, and each preset event is mapped to a An analog touch command; the preset speed is a range value with upper and lower limits; the simulated touch command includes a direction slide command and a click command. 10.根据权利要求9所述的一种通过遮蔽摄像区域模拟触摸指令系统,其特征在于:所述模拟触摸指令生成单元具体为:判断识别到的操作事件是否与预设事件序列中的预设事件相符,若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度相符,就生成对应该操作事件的模拟触摸指令,并进入模拟触摸指令执行单元;若识别到的操作事件与预设事件的事件类型、事件方向以及预设速度不相符,则不生成模拟触摸指令,并终止对本次遮蔽操作的处理,同时返回所述摄像单元等待下一次遮蔽操作。 10. A system for simulating a touch command by shielding an imaging area according to claim 9, wherein the simulating touch command generating unit is specifically: judging whether the recognized operation event is consistent with the preset event sequence in the preset event sequence The event matches, if the identified operation event matches the event type, event direction and preset speed of the preset event, an analog touch instruction corresponding to the operation event will be generated and entered into the analog touch instruction execution unit; if the identified operation event If the event type, event direction and preset speed of the preset event do not match, no simulated touch command is generated, and the processing of this shielding operation is terminated, and at the same time, it returns to the camera unit to wait for the next shielding operation.
CN201410845233.1A 2014-12-31 2014-12-31 A method and system for simulating touch commands by shielding camera areas Pending CN104571513A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410845233.1A CN104571513A (en) 2014-12-31 2014-12-31 A method and system for simulating touch commands by shielding camera areas

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410845233.1A CN104571513A (en) 2014-12-31 2014-12-31 A method and system for simulating touch commands by shielding camera areas

Publications (1)

Publication Number Publication Date
CN104571513A true CN104571513A (en) 2015-04-29

Family

ID=53087791

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410845233.1A Pending CN104571513A (en) 2014-12-31 2014-12-31 A method and system for simulating touch commands by shielding camera areas

Country Status (1)

Country Link
CN (1) CN104571513A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109542315A (en) * 2018-11-22 2019-03-29 维沃移动通信有限公司 Control method and system of mobile terminal
CN109791738A (en) * 2016-10-07 2019-05-21 爱信艾达株式会社 Driving assist system and computer program

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070201863A1 (en) * 2006-02-28 2007-08-30 Microsoft Corporation Compact interactive tabletop with projection-vision
CN102566827A (en) * 2010-12-30 2012-07-11 株式会社理光 Method and system for detecting object in virtual touch screen system
CN102799344A (en) * 2011-05-27 2012-11-28 株式会社理光 Virtual touch screen system and method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070201863A1 (en) * 2006-02-28 2007-08-30 Microsoft Corporation Compact interactive tabletop with projection-vision
CN102566827A (en) * 2010-12-30 2012-07-11 株式会社理光 Method and system for detecting object in virtual touch screen system
CN102799344A (en) * 2011-05-27 2012-11-28 株式会社理光 Virtual touch screen system and method

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109791738A (en) * 2016-10-07 2019-05-21 爱信艾达株式会社 Driving assist system and computer program
CN109791738B (en) * 2016-10-07 2021-12-21 爱信艾达株式会社 Travel assist device and computer program
CN109542315A (en) * 2018-11-22 2019-03-29 维沃移动通信有限公司 Control method and system of mobile terminal
CN109542315B (en) * 2018-11-22 2021-05-25 维沃移动通信有限公司 Control method and system of mobile terminal

Similar Documents

Publication Publication Date Title
CN108596092B (en) Gesture recognition method, device, equipment and storage medium
CN110209273A (en) Gesture recognition method, interaction control method, device, medium and electronic equipment
CN113330395B (en) Multi-screen interaction method and device, terminal equipment and vehicle
JP2016520946A (en) Human versus computer natural 3D hand gesture based navigation method
US20110273551A1 (en) Method to control media with face detection and hot spot motion
CN108616712B (en) Camera-based interface operation method, device, equipment and storage medium
CN111158467A (en) A gesture interaction method and terminal
US20160203614A1 (en) Method and apparatus of detecting object using event-based sensor
CN102200830A (en) Non-contact control system and control method based on static gesture recognition
Kumar et al. Mouse simulation using two coloured tapes
CN106657455B (en) Electronic equipment with rotatable camera
CN111527468A (en) A method, device and device for remote interaction
CN111783600B (en) Face recognition model training method, device, equipment and medium
EP3617851B1 (en) Information processing device, information processing method, and recording medium
CN105867595A (en) Human-machine interaction mode combing voice information with gesture information and implementation device thereof
CN113625878B (en) Gesture information processing method, device, equipment, storage medium and program product
CN113359995B (en) Man-machine interaction method, device, equipment and storage medium
US20180260031A1 (en) Method for controlling distribution of multiple sub-screens and device using the same
CN104571513A (en) A method and system for simulating touch commands by shielding camera areas
Parimala et al. Real-time Brightness, Contrast and The Volume Control with Hand Gesture Using Open CV Python
CN116797971A (en) Video stream identification method and device
CN109981967B (en) Shooting method and device for intelligent robot, terminal equipment and medium
Zaletelj et al. Vision-based human-computer interface using hand gestures
JP2016024743A (en) Moving image processor, moving image information processing program and moving image processing method
CN106339089B (en) A kind of interactive action identifying system and method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20150429

RJ01 Rejection of invention patent application after publication